Constituent Congress of Peru, 1822 ratified in succession to the former presidents of the Republic of Peru: José de la Riva Agüero and José Bernardo de Tagle (better known as the Marquis of Torre Tagle). After the proclamation of the independence of Peru, the ancient capital of the Viceroyalty of Peru, Lima, on July 28, 1821, General José de San Martín assumed command of the military political free departments of Peru, under the title protector, according to the decree of August 3, 1821. San Martín was the one who gave the state its first Peruvian flag, anthem, currency, and its administration and its first primitive
Viceroyalty of Peru on July 21, 1821. The independence of Peru was proclaimed on July 28, 1821. Viceroy José de la Serna e Hinojosa, still in command of a sizable military force, retired to Jauja, and later to Cusco. On July 26, 1822, San Martín and Simón Bolívar met in Guayaquil to define a strategy for the liberation of the rest of Peru. The meeting was secret, and exactly what occurred is not known. However, afterwards San Martín returned to Argentina while Bolívar prepared to launch an offensive against the remaining royalist forces in Peru and Upper Peru (Bolivia). In September 1823 Bolívar