Here we go, let's us enjoy this city! The city of Buenos Aires is not a part of Buenos Aires Province, nor is it the Province's capital, but an autonomous district. In 1880, after decades of political infighting, Buenos Aires was federalised and removed from Buenos Aires Province. The city limits were enlarged to include the towns of Belgrano and Flores (both are currently neighborhoods of the city).
The 1994 constitutional amendment granted the city autonomy, hence its formal name: Ciudad Autónoma de Buenos Aires (Autonomous City of Buenos Aires). Its citizens first elected a Chief of Government (i.e. Mayor) in 1996; before, the Mayor was directly appointed by the President of the Republic.