The Russian annexation of Karabakh was not formalized until the Treaty of Gulistan in 1813, when, as a result of Russo-Persian War (1804-1813), Fath-Ali Shah of Iran officially ceded Karabakh to Tsar Alexander I of Russia.On May 14, 1805 amidst the still ongoing Russo-Persian War of 1804-1813, Ibrahim Khalil Khan and the Russian general Pavel Tsitsianov signed an agreement transferring the Karabakh khanate under Russian dominion.1996 Hindi-language Indian feature film, Dastak for her role as “Miss Universe Sushmita Sen”.It was directed, produced and written by Mahesh Bhatt, Mukesh Bhatt and Vikram Bhatt respectively. But, she has appeared in some of the chat shows like Koffee With Karan.However, the agreement was of little value, as the borders were changing constantly up to the end of the war in 1813.Following the Russian violation of the agreement that recognized Ibrahim Khalil Khan and his descendants as rulers of Karabakh in perpetuity, According to a prominent historian who hailed from the Karabakh Khanate - Mirza Adigozal Bey; "The power of the Karabakh beylerbeylik covered a vast territory – from the Georgian border near “Sinig Korpu” Bridge (currently “red Bridge”) to Khudafarin Bridge on the Araz river.However, according to Safavid tradition, the shah had to control the South Caucasus and southern Dagestan before his coronation.
During this period, Panah-Ali khan Javanshir of Karabakh consolidated his local power by establishing a de facto independent khanate and subordinating the five Armenian meliks (princes) in the region, which were referred to as Khamsa ("five" in Arabic), with support of the Armenian prince Melik Shahnazar II Shahnazarian of Varanda, who first accepted Panah-Ali Khan's suzerainty.
It was due to that, that Mohammed Hasan Khan Qajar considered Karabakh his hereditary estate.
Mohammad Hasan Khan besieged Panahabad, but soon had to retreat because of the attack on his own domain by one of his major opponents to the Iranian throne, Karim Khan Zand.
Panah-Ali Khan's son Ibrahim-Khalil Khan was sent back to Karabakh as governor.
Under Ibrahim-Khalil khan Javanshir, the Karabakh khanate became one of the strongest entities of the South Caucasus and Shusha turned into a big town.
The siege of Shusha lasted for six months and Fatali khan eventually had to retreat.