On August 22, 1791, enslaved people in the French colony of Saint-Domingue launched a mass uprising against the plantation system. Over the following thirteen years, forces led first by Toussaint Louverture and later by Jean-Jacques Dessalines fought French colonial troops, Spanish and British interventions, and internal factional conflicts. Louverture gained control of the colony and drafted a constitution in 1801 but was captured by Napoleonic forces in 1802 and died in a French prison. Dessalines continued the war and declared independence on January 1, 1804, establishing Haiti.