ISTANBUL — Turkey announced on Thursday that it would repatriate an American suspected of being a member of the Islamic State, after a commitment from the United States that his entry would not be blocked.

The American, Muhammad Darwish Bassam , 39, had been stranded on a strip of land at the Turkish-Greek border for the past four days after Turkey had tried to deport him to Greece, but Greek officials refused him entry.

The announcement by the Interior Ministry came a day after President Recep Tayyip Erdogan of Turkey met with President Trump in Washington. Turkey has used Mr. Bassam’s case to highlight its demand that Western countries take back their citizens who joined the Islamic State and have been detained by Turkish forces.

A spokesman at the United States Embassy in Ankara, the Turkish capital, declined to confirm the announcement on privacy grounds.