Mr. Erdogan, taking a personal interest in the case, said last year that there were “malicious” intentions in the prosecution, and he also raised the matter with Vice President Joseph R. Biden Jr. during talks at the United Nations, according to Turkish news reports.

“We have to seek justice, for he is our citizen,” Mr. Erdogan said of Mr. Zarrab in September.

The subject of Mr. Zarrab came up again three weeks ago during a visit to Ankara, Turkey, by Secretary of State Rex W. Tillerson. During that visit, Turkey’s foreign minister, Mevlut Cavusoglu, accused Preet Bharara, then the United States attorney in Manhattan, whose office first charged Mr. Zarrab, of being a pawn of anti-Turkish forces.

Mr. Bharara, who was fired by President Trump last month, had characterized Mr. Cavusoglu’s remarks as “political propaganda.” On Thursday, after The New York Times reported on the strategy by Mr. Giuliani and Mr. Mukasey to turn the case involving Mr. Zarrab into a matter of international diplomacy, Mr. Bharara said on Twitter, “One just hopes that the rule of law, and its independent enforcement, still matters in the United States and at the Department of Justice.”

The efforts on Mr. Zarrab’s behalf come as Mr. Erdogan gains even more power in Turkey, after a hotly disputed referendum that expanded his authoritarian rule and drew a congratulatory phone call from Mr. Trump on Monday.

Image Mr. Zarrab in Istanbul in 2013. Credit Ozan Kose/Agence France-Presse — Getty Images

Mr. Erdogan and Mr. Trump have made overtures to each other that suggest Turkey and the United States could become closer allies.

The new court filing, by Mr. Zarrab’s lead lawyer, Benjamin Brafman, includes affidavits from Mr. Giuliani and Mr. Mukasey that make it clear they hope to get Mr. Erdogan to accept the notion that a diplomatic deal could be of mutual interest to Turkey and the United States. They wrote in the affidavits that a resolution that would be favorable for Mr. Zarrab could be “part of some agreement between the United States and Turkey that will promote the national security interests of the United States.”

Mr. Giuliani and Mr. Mukasey said it was “hardly surprising” that senior Turkish and United States officials were receptive to a possible deal, considering that none of the transactions in which Mr. Zarrab is accused of participating “involved weapons or nuclear technology, or any other contraband,” and that “Turkey is situated in a part of the world strategically critical to the United States.”