Prosecutors in New York do not plan to criminally charge Rudy Giuliani in connection with a probe into his interactions with Ukrainian figures, they revealed in a letter to a judge Monday in what a lawyer for Giuliani declared a “total victory.”

They said they made the decision after a review of evidence resulting from raids on his residence and law office in April 2021. Federal prosecutors were investigating whether Giuliani’s dealings with figures in Ukraine in the run-up to the 2020 election required him to register as a foreign agent.

Prosecutors said a grand jury probe that led to the issuance of warrants that resulted in the seizure of Giuliani’s electronic devices had concluded.

They said that based on information currently available, criminal charges would not be forthcoming.

“In my business, we would call that total victory,” Giuliani’s lawyer, Robert Costello, told The Associated Press. “We appreciate what the US attorney’s has done. We only wish they had done it a lot sooner.”

Sixteen of Giuliani’s devices were seized as part of a federal investigation into his interactions with Ukrainian figures to see whether he violated a law governing lobbying on behalf of foreign countries or entities.

Giuliani is an attorney, former New York City mayor and former personal lawyer for ex-President Donald Trump. His communications with clients are generally protected by law, though there are exceptions.

Giuliani maintained throughout the probe that he had done nothing wrong. At the time of the filing by prosecutors, Giuliani was on a talk show and apparently unaware of the development.

Nicholas Biase, a spokesperson for federal prosecutors, declined to comment on the court filing.

Giuliani remains a target of a special grand jury in Atlanta investigating attempts by Trump and others to overturn the former president's 2020 election defeat in Georgia.

Giuliani testified before the grand jury in August, but he was sanguine when he returned to New York, saying he had “satisfied his obligation under the subpoena.”

The letter by prosecutors quietly ends a probe that was revealed with much fanfare in April 2021 when federal agents were seen carting off computers and cellphones in Manhattan searches.

Shortly afterward, prosecutors said the FBI had successfully downloaded 11 devices and returned them to Giuliani, but needed more time to unlock seven others.

The letter Monday was prompted in part by the need for prosecutors to tell a judge that a former federal judge who had overseen a privilege inspection of the electronic devices, to see what had to be excluded from review by criminal prosecutors, was no longer needed.

The court-appointed monitor, Barbara S. Jones, filed an initial report in January that revealed Giuliani’s lawyers had asked her to block prosecutors from seeing just three of 2,200 seized electronic files deemed relevant to the investigation.

But in the past several months, news of any further progress on the review or any other aspect of the case largely evaporated. Prosecutors in New York went silent, a signal they were unlikely to add Giuliani to the long list of Trump associates charged with a federal crime.

Giuliani, 78, has been under federal scrutiny for several years over his ties to Ukraine. He was central to Trump’s efforts to dig up dirt against Democratic rival Joe Biden and to press Ukraine for an investigation into Biden and his son, Hunter.

He also sought to undermine Marie Yovanovitch, former U.S. ambassador to Ukraine, who was pushed out on Trump’s orders. He also met several times with a Ukrainian lawmaker who released edited recordings of Biden in an effort to smear him before the election.

Giuliani, a former federal prosecutor and onetime presidential candidate, vehemently denied any wrongdoing. At the time of the raids, he accused the Justice Department of “running roughshod over the constitutional rights of anyone involved in, or legally defending, former President Donald J. Trump.”