The United States' Kurdish allies had been gearing up for a new fight for weeks, digging trenches and defense tunnels in northeastern Syria in preparation for an offensive Turkey's president warned was imminent.
On the ground, U.S. troops were bringing in reinforcements through the border with Iraq, beefing up patrols and observation points to prevent friction between the Turks and their Kurdish partners.
Then, in a surprise announcement, President Donald Trump declared he was pulling all 2,000 U.S. troops out of Syria, declaring ISIS had been vanquished. The move, conveyed in a tweet Wednesday, plunged the volatile region into profound uncertainty, leaving America's only allies in Syria in the lurch.
The U.S. forces "were as surprised as we were" by the White House decision, said Mustafa Bali, spokesman for the Kurdish-led Syrian Democratic Forces.
A quick and unplanned withdrawal of American forces opens the door for major turmoil as various groups rush to fill the political and security vacuum, giving leverage to America's enemies including Russia, Iran and President Bashar Assad's government. Experts warn ISIS, currently fighting to hang on to its last pockets in Syria, would soon find its way back.
"A full withdrawal sends the wrong signal, one that also will be heard by other counterterrorism partners far from Syria," said William F. Wechsler, senior adviser for Middle East programs at the Atlantic Council.
Not surprisingly, Russian President Vladimir Putin welcomed Trump's decision, saying Thursday the U.S. forces should not have been in Syria to start with. A key ally of Assad, Russia's military intervention beginning in 2015 turned the tide of the war in the Syrian leader's favor.
"I agree with the U.S. president, we have made significant progress in fighting terrorism on that territory and dealt serious blows to IS in Syria," the Russian leader said.
But Trump, whose announcement contradicted his own experts' assessments, now faces major pushback and political pressure from the Pentagon and other U.S. officials not to withdraw from Syria.
On Thursday, he defended his decision, saying on Twitter: "Does the USA want to be the Policeman of the Middle East, getting NOTHING but spending precious lives and trillions of dollars protecting others who, in almost all cases, do not appreciate what we are doing? Do we want to be there forever?"
The announcement of a pullout is widely seen as an abandonment of a loyal ally, even though America's partnership with the Kurds against the Islamic State group in Syria was always seen as a temporary marriage of convenience. With U.S. air support, the Kurds drove ISIS from much of northern and eastern Syria in a costly four-year campaign.
In a strongly worded statement laced with bitterness, the Kurdish force said that a premature U.S. pullout before ISIS militants are defeated would have dangerous repercussions, including a resurgence of the extremist group and a destabilizing effect on the entire region.
"The war against terrorism has not ended and (the Islamic State group) has not been defeated," the statement said, adding that the fight against IS was at a "decisive" stage that requires even more support from the U.S.-led coalition.
"The decision to pull out under these circumstances will lead to a state of instability and create a political and military void in the region and leave its people between the claws of enemy forces," the statement said.
Kurdish officials and commanders met into the night, discussing their response, local residents said. A war monitor said among the options seriously discussed was releasing thousands of ISIS militants and their families detained in prisons and camps run by the Kurdish forces. It was not clear whether any decision was made, and Kurdish commanders made no mention of the discussions.
The U.S. announcement came at a particularly tense moment in northern Syria. Turkish President Recep Tayyip Erdogan has repeatedly threatened to launch a new offensive against the Kurds but in recent days had stepped up the rhetoric, threatening an assault could begin "at any moment."
Turkey views the People's Protection Units, or YPG, the main component of the Syrian Democratic Forces, as a terrorist group and an extension of the insurgency within its borders. U.S. support for the group has strained ties between the two NATO allies.
The Syrian government ultimately wants a foothold back into the oil-rich east, and the loss of U.S. support may push Kurdish forces into negotiating with the Damascus government. This shift in turn would open the door for Iranian-backed militias to enter the region.
"For the Syrian government, I think this is music to its ears," said Maha Yahya, director of Carnegie Middle East Center. She said a U.S. pullout will force Kurdish forces to negotiate with the regime with a bargaining position that has now been considerably weakened.
Israeli Prime Minister Benjamin Netanyahu weighed in Thursday, saying Israel will "intensify" its activity in Syria to prevent Iranian entrenchment following the withdrawal of American forces.
Israel's main interest in Syria is to prevent its archenemy Iran from establishing a permanent military presence there, and to block sophisticated Iranian arms from reaching Hezbollah forces in Lebanon. Israel has carried out hundreds of airstrikes during the Syrian civil war, mainly against suspect arms shipments allegedly bound for Hezbollah.
Although the U.S. has not actively assisted Israel in this mission, the presence of U.S. forces in Syria has served as a deterrent to Israel's enemies.
Ebrahim Ebrahim of the Syrian Democratic Council, the political wing of the SDF, called Trump's decision "treason" and said there is fear among residents in northern Syria that Turkey will invade the region following a U.S. withdrawal, and that government forces and ISIS militants will attack areas held by the Kurdish forces.
"The American withdrawal will be the trigger that blows up the region," he added.
Associated Press writers Bassem Mroue and Andrea Rosa in Beirut, Vladimir Isachenkov in Moscow and Josef Federman in Jerusalem contributed to this report.