Islamic world, and under Khan Krym-Girei the city of Aqmescit was endowed with piped water, sewerage and a theatre where Molière was performed in French, while the port of Kezlev stood comparison with Rotterdam and Bakhchysarai, the capital, was described as Europe's cleanest and greenest city. In 1441, an embassy from the representatives of several strongest clans of the Crimea, including the Golden Horde clans Shırın and Barın and the Cumanic clan — Kıpçak, went to the Grand Duchy of Lithuania to invite Hacı Giray to rule in the Crimea. He became the founder of the Giray dynasty, which ruled until the annexation of the Crimean Khanate by Russia in 1783. Hacı I Giray was a Jochid descendant of Genghis Khan and of his grandson Batu Khan of the Golden Horde. During the reign of Meñli I Giray, Hacı's son, the army of the Great Horde that still existed then invaded the Crimea from the north, Crimean Khan won the general battle, overtaking the army of the Horde Khan in Takht-Lia, where he was killed, the Horde ceased to exist, and the Crimean Khan became the Great Khan and the successor of this state. Since then, the Crimean Khanate was among the strongest powers in Eastern Europe until the beginning of the 18th century. The Khanate officially operated as a vassal state of the Ottoman Empire, with great autonomy after 1580. At the same time, the Nogai hordes, not having their own khan, were vassals of the Crimean one, Muskovy and Polish-Lithuanian commonwealth paid annual tribute to the khan (until 1700 and 1699 respectively). In the 17th century, the Crimean Tatars helped Ukrainian Cossacks led by Bohdan Khmelnytsky in the struggle for independence, which allowed them to win several decisive victories over Polish troops. In 1711, when Peter I of Russia went on a campaign with all his troops (80,000) to gain access to the Black Sea, he was surrounded by the army of the Crimean Khan Devlet II Giray, finding himself in a hopeless situation. And only the betrayal of the Ottoman vizier Baltacı Mehmet Pasha allowed Peter to get out of the encirclement of the Crimean Tatars. When Devlet II Giray protested against the vizier's decision, his response was: "You should know your Tatar affairs. The affairs of the Sublime Porte are entrusted to me. You do not have the right to interfere in them". Treaty of the