Franklin Briceno and Christine Armario

Associated Press

LIMA, Peru – Former Peruvian President Alan García shot himself in the head and died Wednesday moments after police arrived at his home to arrest him on corruption allegations in Latin America's largest graft probe.

President Martin Vizcarra announced the death on Twitter, saying that doctors in the capital city of Lima performed emergency surgery and tried three times to resuscitate Garcia.

It was a shocking end for a man who twice ruled Peru before becoming ensnared more recently in the corruption scandal involving the construction giant Odebrecht. The scandal has touched nearly every living former president.

When they arrived, police found García on the second floor of his home, a leafy mansion in the city's Miraflores district. He asked for a moment to call his lawyer, entered a bedroom and closed the door behind him, Interior Minister Carlos Morán said.

"Minutes later, the sound of gunfire was heard," Morán said. "Police forced their way into the room and found him."

Prosecutors suspect the former president received more than $100,000 from Odebrecht, disguised as a payment to speak at a conference in Brazil.

García repeatedly professed his innocence and said he was the victim of false testimony by political enemies who accused him of taking more than $100,000 from the company. Odebrecht admitted in a 2016 plea agreement with the U.S. Justice Department that it paid nearly $800 million throughout Latin America in exchange for lucrative public works contracts.

The former head of state's attorney accused authorities of neglecting to provide García with information on why he was being detained or show their official identifications when they showed up to arrest him.

"The president, upset over this situation, knowing his absolute innocence ... had this terrible accident," attorney Erasmo Reyna said.

The stunning turn of events comes four months after García sought asylum in Uruguay as prosecutors in Peru investigated allegations he illegally took payments from Odebrecht. He remained there for a little more than two weeks before his request was denied.

In rejecting his claim, the South American nation's embassy said there was no evidence to support García's contention that he was being targeted politically.

"In Peru, the three branches of government function freely and autonomously, especially in the case of judicial power," Uruguayan President Tabaré Vázquez said.

Peru has gone further than any other country outside Brazil in prosecuting politicians tied to the Odebrecht probe. All but one living former head of state is being investigated for corruption tied to the scandal.

Just last week, former President Pedro Pablo Kuczynski was also detained on money laundering allegations tied to the probe. Congressional allies said he was taken Tuesday night to a local clinic with high blood pressure.

On Wednesday, Alberto Quintanilla, a congressman from the left-leaning political party Nuevo Peru, expressed solidarity with Garcia's family and said that he hoped officials "would advance knowledge of the truth" through their investigations, but also respect due process.

García was a populist firebrand whose erratic first presidency in the 1980s was marked by hyperinflation, rampant corruption and the rise of the Shining Path guerrilla movement.

When he returned to power two decades later, he ran a more conservative government, helping usher in a commodities-led investment boom in which Odebrecht played a major supporting role.

A judicial order obtained by The Associated Press shows Judge Juan Sanchez ordered authorities to arrest García and search for documents in his home related to the money laundering allegations.