Former president of Panama, Ricardo Martinelli, was acquitted of corruption and illegal interception.
The prosecution had charged Mr Martinelli with using public funds to record private conversations in order to intimidate rival politicians during their term of office.
The 2009 to 201
After being found guilty, he celebrated with supporters outside the Panama City court.
67-year-old Martinelli, who denied any wrongdoing, said the entire trial was a farce staged by his opponents.
He was accused of spying on some 150 politicians, union leaders and journalists.
Suspected victims of the interception included senior members of the opposition Revolutionary Democratic Party and legislator Jose Luis Varela. The brother of Juan Carlos Varela, who succeeded Mr Martinelli as President in 2014.
In 2015, the Supreme Court of Panama ordered the arrest of Mr. Martinelli and he flew to the US just days before the court opened a corruption investigation against him.
Mr. Martinelli was arrested near his home in Coral Gables, Florida, in June 2017 and taken to US federal custody after Panama had filed for extradition.
He applied for political asylum and said the allegations against him were part of a political revenge, and his legal team filed a series of appeals against extradition. The US, however, approved it in June 2018.
Martinelli was held in the same prison where Panama's former military leader, General Manuel Noriega, spent the last few years of his life.
General Noriega died at the age of 83 in May last year after being jailed in the US and Panama for drug trafficking, money laundering and extortion.