At least 40 demonstrators stormed Brazil’s Chamber of Deputies demanding a military coup.
The protesters scuffled with guards and took over the podium as a session began on November 16.
Denouncing government corruption, protesters called for a return to military rule – which Brazil saw from 1964 to 1985.
In Rio de Janeiro, police fired tear gas at public sector workers protesting against cuts.
Demonstrators swept past security guards and smashed a glass door to get into the parliament chamber, where they shouted “general here, general here” and sang the national anthem.
According to Reuters, it took police three hours to round up all the protesters.They were all detained.
Later in the day, President Michel Temer’s spokesman, Alexandre Parola, called the protest an “affront” and said it was a “violation of the norms of democratic co-existence.”
Public confidence in Brazilian institutions has been eroded by a massive corruption scandal and the impeachment of President Dilma Rousseff.
Michel Temer was Dilma Rousseff’s vice-president before being promoted after her dismissal.
Last week Dilma Rousseff filed court documents accusing Michel Temer of accepting a large bribe. Michel Temer’s party says the money was a legal campaign donation.
Brazil was one of several Latin American nations where the military overthrew democratic governments in the 1960s and 70s.
The generals said they were countering the very real threat of a communist insurgency and had support from a considerable part of Brazil’s elite.
The military regime detained, tortured – and in some cases – killed its opponents, while overseeing rapid economic growth.
Also on November 16, protesters gathered outside the state legislature where austerity plans to tackle the city’s financial crisis were being debated
Police fired tear gas, rubber bullets and stun grenades into a crowd of about 2,000 protesters, ranging from teachers to off-duty police officers, AFP reported.
Brazil has been hit by a drop in global oil and commodity prices and declared a financial emergency ahead of the Rio Olympics earlier this year.
Many public workers have not been paid in months.