CARACAS, Venezuela — President Nicolas Maduro said a stolen police helicopter fired on Venezuela's Supreme Court Tuesday in what he called a thwarted "terrorist attack" aimed at ousting him from power.

The confusing exchange, which is bound to ratchet up tensions in a country already paralyzed by months of deadly anti-government protests, took place as Maduro was speaking live on state television. He later said the helicopter had fired on the court with grenades, one of which didn't go off, helping avoid any loss of life. The nation's air defense system was immediately activated.

Venezuelan authorities inspect the area around the Supreme Court of Justice in Caracas after an alleged attack via helicopter by a rogue police officer. Miguel Gutierrez / EPA

Adding to the intrigue, pictures of a blue police helicopter carrying an anti-government banner appeared on social media around the same time as a video in which an alleged police pilot, identified as Oscar Perez, called for a rebellion against Maduro's "tyranny" as part of a coalition of members of the country's security forces. Authorities said they were still searching for the man.

"We have two choices: be judged tomorrow by our conscience and the people or begin today to free ourselves from this corrupt government," the man said while reading from a statement with four people dressed in military fatigues, ski masks and carrying what looked like assault rifles standing behind him.

Maduro sounded alternately calm and angry as he told the audience about what had happened in the airspace just beyond the presidential palace where they were gathered.

"It could've caused a tragedy with several dozen dead and injured," he said.

Venezuela's President Nicolas Maduro speaks during a gathering in support of him and his proposal for the National Constituent Assembly in Caracas on Tuesday. Handout / Reuters

Later, Information Minister Ernesto Villegas read a statement from the government accusing the helicopter of firing 15 shots against the Interior Ministry as a reception was taking place for 80 people celebrating national journalist's day. It then flew a short distance to the court, which was in session, and launched what he said were four Israeli-made grenades of "Colombian origin," two of them against national guardsmen protecting the building.

The pro-government president of the high court said there were no injuries from the attack and that the area was still being surveyed for damages.

Villegas said security forces were being deployed to apprehend Perez as well as recover the heisted German-built Bolkow helicopter. Photos of the pilot standing in front of the U.S. Capitol in Washington and a U.S. Coast Guard helicopter were displayed on state TV to further bolster the government's case that he was taking instructions from the CIA and the U.S. Embassy

Meanwhile many of Maduro's opponents took to social media to accuse the president of orchestrating an elaborate ruse to justify a crackdown against Venezuelans seeking to block his plans to rewrite the constitution. Venezuela has been roiled by anti-government protests the past three months that have left at least 75 people dead and hundreds injured.

Maduro said one of the pilots involved in the alleged attack used to fly for his former Interior Minister, Miguel Rodriguez Torres, who he accused of working for the CIA. Rodriguez Torres, who has been leading a campaign against by Maduro made up of leftist supporters of the late Hugo Chavez, immediately dismissed the accusation as baseless.

As the drama was unfolding outside the courtroom, inside magistrates were busy issuing a number of rulings further hemming in the opposition.

One dismissed a challenge against Maduro's plans for a constitutional assembly by chief prosecutor Luisa Ortega Diaz, a longtime loyalist who broke with the government over the issue. Another broadened the powers of the nation's Ombudsman, giving him the authority to carry out criminal investigations that until now had been the exclusive prerogative of Ortega's office.

The helicopter incident capped a volatile 24 hours that began with widespread looting in the coastal city of Maracay on Monday night and continued Tuesday when opposition lawmakers got into a heated scuffle with security forces assigned to protect the National Assembly.

At least 68 supermarkets, pharmacies and liquor stores were looted and several government offices burned following anti-government protests in Maracay, which is about a 90 minute drive from Caracas.

Maduro condemned the violence but with a stern warning to his opponents that's likely to only further inflame an already tense situation.

"We will never surrender. And what we couldn't accomplish through votes we will with weapons," he said.

On Tuesday, opposition lawmakers got into fisticuffs with national guardsmen as they tried to enter the National Assembly. In a video circulating on social media, the commander of a national guard unit protecting the legislature aggressively shoved National Assembly President Julio Borges as he's walking away from a heated discussion.

At nightfall, a few dozen people were still gathered inside the neoclassical building as pro-government supporters stood outside threatening violence.