The Thief of Baghdad (Багдадский вор, Bagdadskiy vor) is a trilogy of novels written by Russian fantasy author Andrei Belyanin. The stories retell the tale of the character in an original manner, full of deliberate anachronism, magic, and Time Travel. Belyanin claims that the titular thief is a friend of his named Lev Obolensky, descended from a long line of Russian nobles. In the first novel of the same name, the author retells the story told to him by Lev, who insists that he was transported to Baghdad during "Arabian Nights" Days by a Literal Genie, who was commanded by Omar Khayyám (a famous Persian poet and, according to the novel, thief) to bring him "the greatest thief in the world". Instead, the genie (named Babuday-Aga) brings him a modern-day Russian man with absolutely no knowledge of thievery and Laser-Guided Amnesia. Not remembering who he is beyond his name, Lev begins to treat Omar as his own grandfather, and the genie uses magic to teach him the art of stealing. Omar's goal is to shame the ruler of Baghdad, Emir Selim ibn Harud al-Rashid, whose draconian anti-thievery laws have cost Omar many of his friends. Along the way, Lev befriends Hodja Nasreddin (a Muslim folk hero) and a donkey he names Rabinowitz. He ends up shaming the Emir's chief guard Shehmet, sneaking into the Emir's harem and "enjoying" his many wives, freeing a beautiful woman from her ghoul husband, making First Contact (and ending up convincing the peace-loving aliens to stay the hell away from Earth), and nearly getting the Emir to marry him. The genie then brings him home, and Lev goes to his writer friend to tell him the story.
In The Shamer of Shaitan, the genie once again sends Lev into the magical past, this time into the city of Kokand. The city guards, headed by Aslan-Bey, almost immediately capture him and bring him before Sultan Muslim al-Luli Suleiman ibn Dode, the city's ruler. The Sultan demands that the famous Thief of Baghdad steal him a certain woman to add to his harem. Then the Sultan's chief vizier turns out to be none other than Hodja Nasreddin in make-up, hiding right under Aslan-Bey's nose, who wants to capture the famous troublemaker. This time, Lev has all his memories and wants to go home, but he assumes that the genie wants him to shame Aslan-Bey and the Sultan of Kokand. Along the way, he meets many of his old acquaintances, including the beautiful widow Jamila (who is deeply in love with him but know he can't stay with her) and the cobbler Ahmed (the husband of the woman the Sultan wants). Lev ends up meeting and making an enemy of Shaitan himself and, eventually, realizes that the enemy of all humankind is the real target of his shaming. He finally manages to reach Samarkand and reunite Ahmed with his estranged wife, humiliating the demon along the way. The genie then appears and sends him back to the 21st century.
In Return the Thief!, the author finally meets Nasreddin, who has somehow ended up in the modern times. It is Nasreddin who tells the author of Lev's latest adventure in ancient Bukhara. This time, the genie brings Lev back to the past not to shame a particular person (or demon) but to prevent a war that threatens to engulf all the entire Muslim world.
The trilogy provides examples of the following tropes:
- "Arabian Nights" Days: The setting of the series. The time period is never made clear (although it's mentioned that the merchants of Kokand have trade relations with the Hanseatic League), but magic and fantastic creatures are present. Over the course of the trilogy, Lev visits four ancient cities (they appear to be city-states, since all of them have different rulers): Baghdad (modern-day Iraq), Kokand, Samarkand, and Bukhara (modern-day Uzbekistan).
- Bittersweet Ending: The second book ends with Lev and Nasreddin helping to reunite Ahmed with his estranged wife and shaming Shaitan himself. However, just before Lev is returned home, the genie shows him the grave of Omar Khayyam, a man Lev considered his honorary grandfather, who has died not long after Lev's departure in the first novel (it turns out he was already unwell while Lev was still there, but he didn't want to upset his "grandson"). The genie reveals that the reason he took Lev the second time was because he was fulfilling Omar's final wish: to bring back the Thief of Baghdad when the Muslim world needed him the most.
- Butt-Monkey: Shaitan in the second novel. Every time he appears to do something nasty to Lev or one of his friends, thing usually go bad for him.
- The Devil: The Big Bad of the second novel is Shaitan, the Muslim version of Satan. He first encounters Lev while attempting to pee in Nasreddin's ear for almost sleeping through his morning prayer. The author also suspects that the visions of a classical author visiting him at night are also one of Shaitan's tricks.
- Direct Line to the Author: Apparently, the author heard the stories directly from the Thief of Baghdad himself (except for the third one, which he heard from Nasreddin).
- Fish out of Temporal Water: Lev, three times. The first time, he has Laser-Guided Amnesia and is made to think he really belongs in the past. The other two times, he remembers everything. Also, Nasreddin ends up in the 21st century in the third novel and seems to adapt pretty well.
- Guile Hero: True to his folk hero status, Nasreddin is a master of this trope.
- Hollywood Exorcism: In the second novel, Shaitan possesses Aslan-Bey and tries to kill Lev. After all the other guards run away, Nasreddin and Lev decide to try to exorcise the demon. Nasreddin starts reading the appropriate Muslim prayers, while Lev whacks the chief guard with a big stick. In order to shame Shaitan, Nasreddin covers Aslan-Bey's nose and mouth, leaving only one orifice for the demon to take. It works, and Aslan-Bey thanks them before threatening them never to tell anyone about this.
- Impossible Thief: Lev Obolensky, the Thief of Baghdad, is known for his impossible feats in the art of "appropriating" other people's things.
- Literal Genie: Babuday-Aga tends to interpret his masters' wishes in his own way. When Omar Khayyam asks him to bring him a man who is to become his pupil in the art of thievery, he expects the genie to bring him a well-behaved Muslim from a good family, with green eyes and flexible hands. Babuday-Aga brings him a modern-day Russian man with blue eyes and a powerful build. Moreover, when he opens his eyes and sees a genie (floating with no legs), he yells out "Jesus Christ!", causing Omar to completely lose it and demand that the genie take the infidel where he found him. The genie counters that the kind of person Omar has described would never become a thief. In the second novel, a group of old cultists summon the genie and make a demand. True to the trope, he fulfills their wish... by turning them into cats. In the third novel, his penchant for this trope ends up helping Lev, since the Big Bad of this novel has become his master and wants him to bring Lev to him. Since his wishes are never expressed in a straightforward manner, Babuday-Aga uses Loophole Abuse to avoid doing that.
- Our Vampires Are Different: In the first novel, Lev is nearly killed by an old man who turns out to be a ghoul (a Middle-Eastern vampire). The ghoul ends up dead, and his young wife Jamila is finally free. She becomes Lev's on-and-off Love Interest.
- Reasonable Authority Figure: The ruler of Samarkand, Padishah Najim al-Ghazali, is a young man who has only recently ascended to the throne after the untimely death of his older brother (and no, this was not a Klingon Promotion). He turns out not to be as high-and-mighty as the Emir of Baghdad or the Sultan of Kokand, although Lev admits it could be just because he's still young. Instead of arresting Lev, he begs the thief to teach him how to do it.
- Snake People: In the second novel, Lev and Nasreddin find an oasis and take a drink from the well, only to be captured by a half-snake/half-woman creature. In return for letting them live, she demands that one of them pleasure her. Lev refuses, pointing out that, while her upper part is pretty nice, her lower half is flexible and scaly and notably lacking in certain body parts. Seemingly reluctantly, Nasreddin agrees, and Lev waits for him by the nearby dune. After a while, he sees his friend walk up with a satisfied smile. Nasreddin explains that, after the first kiss, the creature turns into a normal woman. Lev is angry at him for hiding that knowledge.
- Someone to Remember Him By: When leaving Jamila at the end of the second novel, she tells him that she will wait for him and hopes to have a blue-eyed son by that time.
- Wicked Witch: Lev and Jamila encounter one in the desert. She seems nice at first, although her cackling should have given her away, and then tries to eat Lev. He ends up getting her to break her two remaining teeth, meaning she can't eat him anymore. Suddenly, she becomes much nicer and even helps them find their way to the caravan.
- You Can Leave Your Hat On: The heroes encounter Ali Baba several years after his famous adventure. As they discover, he lives in perpetual fear of his wife Morgiana (in this version, she married him instead of his son), after seeing her kill so many thieves. At one point, she gets drugged and is convinced to perform the fabled Bee Sting dance, which turns out to be a Middle Eastern version of a strip tease. While his Muslim friends are standing there with their jaws on the floor, Lev quickly comes to his senses (having been to many strip clubs in modern-day Moscow) and goes to steal Ali Baba's horses.