In 1728, the Guipuzcoan Company of Caracas was founded by the king, and the cacao business grew in importance. Caracas was made one of the three provinces of Nueva Granada, corresponding to Venezuela, in 1739. Over the next three decades the Viceroyalty was variously split, with Caracas province becoming the Venezuela province. Luis de Unzaga created the Captaincy General of Venezuela in the summer of 1777, with Caracas as the capital. Venezuela then attempted to become independent, first with the 1797 Gual and España conspiracy, based in Caracas, and then the successful 1811 Venezuelan Declaration of Independence. Caracas then came under worse luck: in 1812, an earthquake destroyed Caracas, a quarter of its population migrated in 1814, and the Venezuelan War of Independence continued until 24 June 1821, when Simón Bolívar defeated royalists in the Battle of Carabobo. Urban reforms only took place towards the end of the 19th century, under Antonio Guzmán Blanco: some landmarks were built, but the city remained distinctly colonial until the 1930s.