The power struggle could trigger unrest in a country that has seen increased political volatility in recent years.

Peru‘s opposition-run Congress defied President Martin Vizcarra’s threat to close it by electing the first of up to six new leading court justices in a raucous vote on Monday, bringing the nation to the brink of a constitutional crisis.

On the eve of the vote, Vizcarra said he would close Congress if politicians went forward with the appointments, calling it an illegitimate attempt to capture the Constitutional Tribunal (TC), the likely referee in any legal dispute on an escalating political crisis.

Some proposed nominees have come under fire for their links to judges ensnared in several back-to-back corruption probes that have discredited the country’s institutions in recent years.

The power struggle threatens to hobble governing and could trigger unrest in a country that has seen increased political volatility in recent years. Some politicians have vowed to physically resist any attempt to send them home.

The opposition party that controls Congress – led by jailed former presidential candidate Keiko Fujimori – says Vizcarra cannot override Congress’s constitutional authority to name new members of the TC.

“Close Congress, we’re not afraid,” Congressman Gilbert Violeta said in a debate marked by shouting, fist-pounding and a brief attempt to shut out Vizcarra’s prime minister.

Peru’s President Martin Vizcarra addresses the nation at the government palace in Lima, Peru [File: Handout/Peruvian Presidency/Reuters]

Despite Prime Minister Salvador del Solar’s last-minute appeal to heed Vizcarra’s calls, politicians elected one new nominee to the TC, Gonzalo Ortiz de Zevallos, a relative of the president of Congress with no judicial experience listed on his LinkedIn profile.

But Congress suspended debate on other proposed justices until later on Monday, when a vote of confidence will also be held on Vizcarra’s government over the matter.

Under Peru’s constitution, presidents can dissolve Congress to call new elections if the politicians deliver two votes of no-confidence in a government. The current Congress has already voted once that it had no confidence in the government.

Vizcarra told local TV channel America Television late on Sunday that he would count the election of new members of the TC as a vote of no-confidence and proceed to close Congress “in strict application of the constitution”.

If he follows through with the threat, politicians might try to impeach Vizcarra. In the Congress of 130 seats, 87 votes would be needed to remove Vizcarra in an impeachment, the same number of votes that officially elected Ortiz to the TC, though leftist politicians questioned whether the tally was legitimate.

“Let them impeach me if they have the votes,” Vizcarra told America Television on Sunday, ruling out stepping down.

A former vice president, Vizcarra has emerged as an unlikely champion of efforts to uproot corruption since taking office last year to replace former president Pedro Pablo Kuczynski, who stepped down in a corruption scandal involving Brazilian builder Odebrecht.

Vizcarra is barred from running in the next presidential election due to constitutional limits on consecutive terms. He proposed a snap election that would have ended his term and Congress’s term a year before they were due to end. But politicians shelved that proposal last week.