CARACAS, Venezuela (AP) — Venezuela’s crisis quickly escalated Wednesday as an opposition leader backed by the Trump administration declared himself interim president in a direct challenge to embattled socialist Nicolas Maduro, who retaliated by breaking off relations with the United States, his biggest trade partner.

For the past two weeks, ever since Maduro took the oath for a second six-year term in the face of widespread international condemnation, the newly invigorated opposition had been preparing for nationwide demonstrations Wednesday coinciding with the anniversary marking the end of Venezuela’s last military dictatorship in 1958.

While Maduro has shown no signs of leaving, his main rival, National Assembly President Juan Guaido, upped the ante by declaring himself interim president before masses of anti-government demonstrators — the only way, he said, to rescue Venezuela from “dictatorship.” Outside the capital, seven demonstrators were killed amid disturbances during protests that rocked several cities.

In a seemingly coordinated action, the U.S. led a chorus of Western hemisphere nations, including Canada, Brazil, Argentina and Colombia, that immediately recognized Guaido, with President Donald Trump calling on Maduro to resign and promising to use the “full weight” of the U.S. economic and diplomatic power to push for the restoration of Venezuela’s democracy.

“The people of Venezuela have courageously spoken out against Maduro and his regime and demanded freedom and the rule of law,” Trump said in a statement.

The stunning move, which to some harkened back to dark episodes of heavy-handed U.S. interventions in Latin America during the Cold War, drew a strong rebuke from Maduro. He responded by swiftly cutting off diplomatic relations with the United States, the biggest importer of the OPEC nation’s oil, giving American diplomats 72 hours to leave the country.

“Before the people and nations of the world, and as constitutional president. .... I’ve decided to break diplomatic and political relations with the imperialist U.S. government,” Maduro thundered while holding up a decree banning the diplomats before a crowd of red-shirted supporters gathered at the presidential palace.

“Don’t trust the gringos,” he said, rattling off a long list of U.S.-backed military coups — Guatemala, Chile, Brazil — in decades past. “They don’t have friends or loyalties. They only have interests, guts and the ambition to take Venezuela’s oil, gas and gold.”

Not to be undone, Guaido issued his own statement, urging foreign embassies to disavow Maduro’s orders and keep their diplomats in the country. A few hours later, U.S. Secretary of State Mike Pompeo said the United States would abide by Guaido’s directive and ignore Maduro’s order to withdraw its diplomats.

The 35-year-old Guaido, a virtually unknown lawmaker at the start of the year, has reignited the hopes of Venezuela’s often beleaguered opposition by taking a rebellious tack amid a crushing economic crisis that has forced millions to flee or go hungry.

Raising his right hand in unison with tens of thousands of supporters, the fresh-faced leader of the opposition-controlled congress took a symbolic oath to assume executive powers he says are his right under two articles of Venezuela constitution to take over as interim president and form a transitional government until he calls new elections.

“Today, January 23, 2019, I swear to formally assume the powers of the national executive as president in charge of Venezuela,” he told the cheering crowd as he stood behind a lectern emblazoned with Venezuela’s national coat of arms.

“We know that this will have consequences,” he shouted, moments before quickly slipping away to an unknown location amid speculation he would soon be arrested.

The price of oil slipped for the third time in four days Wednesday, an indication that international energy markets are not overly concerned yet that the situation in Venezuela — America’s third top oil supplier and owner of Houston-based Citgo — will disrupt global crude supplies.

The assault on Maduro’s rule came after large crowds gathered in Caracas waving flags and chanting “Get out Maduro!” in what was the largest demonstration since a wave of unrest that left more than 120 dead in 2017.

While the protests in the capital were mostly peaceful there were no signs that security forces heeded Guaido’s call to join the anti-Maduro movement and go light on demonstrators.

Hours after most demonstrators went home, violence broke out in Altamira, an upscale zone of Caracas and an opposition stronghold, when National Guardsmen descended on hundreds of youths, some of them with their faces covered, lingering around a plaza. Popping tear gas canisters sent hundreds running and hordes of protesters riding two and three on motorcycles fleeing in panic.

Blocks away, a small group knocked a pair of guardsman riding tandem off their motorcycle, pelting them with coconuts as they sped down a wide avenue. Some in the group struck the two guardsmen with their hands while others ran off with their gear and set their motorcycle on fire.

Elsewhere, four demonstrators were killed by gunfire in the western city of Barinas as security forces were dispersing a crowd. Three others were killed amid unrest in the border city of San Cristobal.

Amid the showdown, all eyes were on the military, the traditional arbiter of political disputes in Venezuela — and to whom Guaido has been targeting his message.

Maduro, who lacks the military pedigree of his mentor and predecessor, the late Hugo Chavez, has sought to shore up support from the armed forces by doling out key posts to top generals, including heading the PDVSA oil monopoly that is the source of virtually all of Venezuela’s export earnings. He has also been playing commander in chief, appearing last week at a military command meeting wearing camouflage fatigues and receiving the blessing of the defense minister, Gen. Vladimir Padrino Lopez, who said his troops were prepared to die for Maduro.

But beyond the public displays of loyalty from the top brass, a number of cracks have started to appear.

On Monday, Venezuelans awoke to news that a few dozen national guardsmen had taken captive a loyalist officer and seized a stockpile of assault rifles in a pre-dawn raid. The government quickly quelled the uprising, but residents in a nearby slum took to the streets to show their support for the mutineers by burning cars and throwing stones at security forces, who fired back with tear gas.

Disturbances continued into Tuesday, with small pockets of unrest in a few working-class neighborhoods where the government has traditionally enjoyed strong support.

Retired Maj. Gen. Cliver Alcala, a one-time aide to Chavez and now in exile, said the opposition’s newfound momentum has reverberated with the military’s lower ranks, many of whom are suffering the same hardships as regular Venezuelan families.

“I am absolutely certain that right now, especially younger troops are asking themselves whether Maduro is their commander in chief or a usurper,” Alcala said.

Though intimidation has worked for the government in the past, it may not this time, said Dimitris Pantoulas, a Caracas-based political analyst. Discontent now appears to be more widespread and the ranks of security forces and government-allied groups have been thinned by the mass exodus of mostly young Venezuelans, he said.

“The government is resorting to its old tricks, but the people no longer believe them,” Pantoulas said.