In 1770 Wolfgang von Kempelen built an automaton capable of playing chess. Like many of the oddities touring the courts of central Europe at the time, it was given an Eastern appearance; dressed as man in a turban sitting at a desk. It was carved out of wood and made its moves using its left hand.
Von Kempelen brought the machine to the court of Maria Theresa of Austria and their foremost intellectual, Count Ludwig von Cobenzi, was invited to play. Von Kempelen made a big show of opening up each of doors in the chest revealing the machinery inside. Each door revealed tightly packed brass cogs and pin wheels.
Von Cobenzi was quickly defeated, as were all of the other competitors that day. Many courtiers expressed fear as this wooden creation came to life, its eyes scanning the room and its head in constant motion. As it moved there were loud whirs and clicking coming from the chest. Von Kempelen would invite spectators to try to tamper with the machine with magnets and weights in order to figure out the mechanism.
It is clear to us now that this must have been a hoax. All automatons built pre Babbage were comparatively simple. For instance Leonardo's (da Vinci) Robot sounds a lot more interesting than it actually was. Don't look it up, just keep whatever image you have in your mind instead.
There were a series of chess masters that sat inside the chest. The seat was able to slide around inside the box and by the time von Kempelen opened each door the hidden player would have moved out of sight. There were also movable walls of fake machinery inside which could be rearranged quickly. It was simply a well choreographed illusion. The position of the pieces was known using magnets on the underside of the board and the arm was controlled using a system of levers.
The Turk grew in infamy and was invited to play various famous people of the time. Everyone's favourite, not-quite-president Benjamin Franklin, who had published multiple books on chess, played The Turk and lost twice. He refused to believe that there wasn't human involvement because he believed that if an automaton could actually play chess then it would never lose (which The Turk occasionally did). Franklin came up again on this site with an article about one of his magic squares.
Ownership of The Turk was given to Mätzel, a Bavarian musician. The height of The Turk's fame was when it played Emperor Napoleon. To test the creation Napoleon played an illegal move on the second turn which The Turk removed from the board entirely before making its response. Napoleon then played a second illegal move and The Turk used its arm to sweep all of the pieces off the board. This was a pretty ballsy move against the most powerful person in the world. However this amused Napoleon and they played a proper game afterwards.
Other people of note that played it include Catherine the Great (big supporter of Euler and science in general) and Charles Babbage (co-inventor of the mechanical computer) who was apparently inspired by The Turk.
Many pamphlets from skeptics of the time claimed that they had solved the hoax, but most of the proposed solutions were more elaborate than the closely guarded truth. My favourites include a chess playing monkey and a legless war veteran. Edgar Allan Poe was obsessed with The Turk and published his own ideas on how it worked. He included references to it in a few of his short stories, for instance in "Von Kempelen and his Discovery" it paints the inventor as either a conman or an alchemist. (It isn't very good.)
In the mid 1800's The Turk's fame had dried up and when Mätzel died during a voyage the machine fell into the possession of the Sea Captain and from there it was Edgar Allan Poe's physician who bought it and restored it. Finally it was sold to a museum in Baltimore. In 1854 the museum burned down and with it The Turk was gone.
Part of the enduring legacy of this magic prop is because it was destroyed before anyone could confirm exactly how it worked. It has allowed many myths to surround the story and perhaps that is a fitting end.