U.S. President Donald Trump is calling on Turkish President Recep Tayyip Erdogan to release an American pastor who has been in prison for two years awaiting trial on terrorism charges.

A Turkish court Wednesday ordered Andrew Brunson to remain in jail until his next hearing on October 12. Brunson was arrested in 2016 and charged with supporting followers of U.S.-based Turkish cleric Fethullah Gulen, who has been blamed by Ankara for the failed 2016 coup against President Erdogan. Brunson is also accused of assisting the outlawed Kurdish insurgent group PKK.

Trump called Brunson’s continued detention “a total disgrace” in a post on Twitter hours after the court hearing. “He has been held hostage far too long,” the president tweeted. “@RT_Erdogan should do something to free this wonderful Christian husband & father. He has done nothing wrong, and his family needs him!”

Trump reportedly raised the pastor’s case in a telephone call Monday with his Turkish counterpart. 

Speaking to reporters outside the courthouse, Philip Kosnett, U.S. charge d’affaires in Turkey, expressed disappointment with the decision.

“I’ve read the indictment; I’ve attended three hearings. I don’t believe that there is any indication that Pastor Brunson is guilty of any sort of criminal or terrorist activity,” Kosnett said. “Our government remains deeply concerned about his status, as well as the status of other American citizens and local Turkish employees of the U.S. diplomatic mission who have been detained under the state of emergency rules.”

Kosnett, speaking before the court decision, had warned of the damaging effect of the case on U.S.-Turkish relations.

In Washington, a State Department official said the United States has been closely engaged with the Turkish government on Brunson’s case and repeated calls for his release.

“We have seen no credible evidence that Mr. Brunson is guilty of these crimes. The case against him is built on anonymous accusations and speculation,” the official told VOA in a statement. “We strongly believe that he is innocent, and we call on the Turkish government to resolve his case in a timely, transparent, and fair manner.”

Senator Roger Wicker of Mississippi, who is chairman of the Helsinki Commission, an independent U.S. government agency that monitors democracy and human rights in Europe, said, “The cruelty of today’s decision is astonishing.

“By extending Pastor Brunson’s indefinite detention and setting his next trial date for mid-October, the Turkish government has declared its intention to keep this innocent man in jail past the two-year anniversary of his arrest without conviction or any credible evidence against him. There is no room in NATO for hostage-taking. Pastor Brunson should be freed immediately,” Wicker added.

The 50-year-old Brunson has lived in Turkey for more than two decades. The North Carolina native worked as a pastor serving a small Protestant congregation in the western Turkish City of Izmir, close to the town of Aliaga, where he is now on trial. Brunson has spent much of his incarceration in solitary confinement. Brunson describes the charges against him as “shameful and disgusting.”

Last month, U.S. Senators Lindsey Graham and Jeanne Shaheen also pressed for Brunson’s release in a meeting with Erdogan in Ankara.

The U.S. Congress is threatening to introduce sanctions on Turkey if the pastor is not released. 

Several members of Congress have accused Turkey of hostage taking by seeking to use Brunson as diplomatic leverage. Adding to Congress’ anger, three local employees of U.S. diplomatic missions in Turkey are also being held on terrorism charges. Ankara strongly denies allegations of hostage taking, maintaining that the cases are a matter for the courts. 

Observers warn the continued detention of Brunson now increases the likelihood of Washington imposing measures against Ankara.

“It’s (the Brunson case) very important because it’s already an obstacle and sticking point between the countries, having prompted the discussion about sanctions against Turkey,” political columnist Semih Idiz of Al-Monitor said. “Senators are coming to Turkey and Trump referring to Brunson as a hostage. Tensions will increase, calls for sanctions against Turkey will increase, and the downward spiral in relations will continue (if the trial continues).”

The blocking of the U.S. sale to Turkey of a new F-35 fighter is a move that has been threatened by Congress. 

Turkish financial markets fell heavily on the news of Brunson’s ongoing detention. The falls reversed earlier gains stoked by the expectation of the pastor’s release and the hope of improved U.S.-Turkish relations.

Erdogan and his advisers have linked the Brunson case to calls to extradite Gulen in connection with the 2016 coup attempt. Turkish Foreign Minister Mevlut Cavusoglu said Sunday U.S. authorities were cooperating in investigating Gulen and his followers. Observers, however, say the detention of Brunson suggests Ankara could be looking for more concessions from Washington.

Erdogan could release Brunson under the presidential power to free jailed foreign citizens if it is deemed to be in the country’s national interest.

The ongoing jailing of Brunson comes as analysts point out the two countries were making tentative progress on a number of disputes. In the past few months, there have been intense diplomatic efforts to resolve differences over Syria and Ankara’s controversial purchase of a Russian S-400 missile system. Observers warn if Congress carries out its threat to sanction Turkey over Brunson’s jailing, it will likely add to broader diplomatic tensions.