The deal was reached days after Turkish President Recep Tayyip Erdogan warned that the Turkish military was about to launch an assault on U.S.-backed Kurdish forces in Syria, who were integral to the battlefield success against the terror group.
While U.S. officials warned that offensive could have risked upending the gains made against ISIS or freed thousands of ISIS fighters held by Kurdish forces, the Pentagon issued a fresh warning that the terror group is re-surging in Syria.
Turkish and American military officials had been meeting in Ankara for several days when they reached the deal on Wednesday. They agreed to set up a joint operations center, based in Turkey, to oversee a safe zone in northeastern Syria, according to similar statements from the U.S. embassy in Turkey and the Turkish Defense Ministry.
A U.S. defense official confirmed to ABC News that the two countries reached the agreement to address Turkey's security concerns, but declined to provide details.
Turkey considers the U.S.-armed and backed Syrian Democratic Forces to be a terrorist organization because their ranks are mostly comprised of Kurds. Those Kurdish soldiers served as de facto U.S. ground forces in Syria in the fight against ISIS, but some members have ties to a Kurdish group across the border in Turkey known as the Kurdistan Workers' Party or PKK -- an organization the U.S. and Turkey consider a terrorist group.
Turkish military forces had been increasing deployments along the Turkish side of the border in recent weeks -- including heavy weaponry, tanks and artillery -- in readiness for the attack. The U.S. has consistently said Turkey has legitimate security concerns because of those connections, but President Donald Trump and Secretary of State Mike Pompeo have signaled that they will not allow Turkey to harm the Kurdish forces that supported their counter-ISIS mission.
The deal reached on Wednesday has averted that crisis, for now. The U.S. and Turkey had previously reached agreements to conduct joint patrols in nearby areas, but Turkey has criticized the U.S. for slow-walking measures to counter what it sees as an existential threat, with Erdogan saying on Monday that it was Turkey's "top priority" to "eliminate" this "cancer cell."
While the agreement seems to lay the groundwork for those repatriations to begin, the conditions in this area remain desperate. Months after the last ISIS town fell, a new Pentagon inspector general report released on Tuesday described "ongoing lawlessness and violence."
Areas liberated from ISIS and now run by civilian councils affiliated with the SDF, still struggle with offering basic services, such as water, medical care and removing rubble. They're also having difficulty destroying mines and other explosives, and eliminating cells of ISIS fighters, which continue to conduct attacks. Those issues have been exacerbated by the withdrawal of some U.S. troops and all U.S. diplomats, according to the Pentagon report.
"The reduction of U.S. forces has decreased the support available for Syrian partner forces at a time when their forces need more training and equipping to respond to the ISIS resurgence," the report said.
In particular, the drawdown of U.S. troops has come as the SDF have requested more training and assistance in rooting out ISIS cells and is struggling to maintain ad hoc prisons with some 10,000 ISIS fighters behind bars, 2,000 of whom are not from Iraq or Syria.
With a diminished U.S. military presence, the administration was able to secure added troop commitments from the United Kingdom and France, a U.S. official told ABC News last month.
The State Department also pulled out all of its personnel when Trump first announced he was withdrawing all troops from Syria last December. While those teams are scheduled to head back into the country, they have not yet, undermining for months now the stabilization projects that U.S. officials have said are critical to keeping ISIS away. The administration also cut all funding for those projects and asked partner countries to step in instead, raising $325 million, but leaving their future in jeopardy, too.
The U.S. has "a significant way to go if we are to ensure our military gains are accompanied and cemented by a robust stabilization response," a State Department inspector general report found last month.
But the department's chief doesn't think so.
"We're doing all the right things," Pompeo said on Wednesday. "I'm sure it's the case that there's pockets where they've become a little stronger. I can assure you there are places where it's become weaker as well."
Among the most pressing challenges now, according to the Pentagon report, is what to do with the 70,000 displaced persons who have been detained fleeing ISIS, 50,000 of whom are under the age of 18. There is a growing threat that some of them will be radicalized and recruited by ISIS, but the U.S. lacks the capacity to monitor the humanitarian situation in the camps, according to the report.
Beyond those potential new targets, the terror group still has between 14,000 and 18,000 fighters between Iraq and Syria, per the report, although firm numbers are very difficult to come by.