In so doing, Ankara managed to shift the international discourse away from the US threat of sanctions over its purchase of the Russian S-400 missile system.
It also allowed Turkish President Recep Tayyip Erdogan to change the narrative at home after the defeat of his party at the Istanbul mayoral elections and show his electorate that he is taking action on the Syrian refugee issue.
Erdogan plans to relocate 700,000 Syrian refugees to the border areas it aims to seize from Kurdish fighters.
Ankara's threats of an incursion across its border with Syria successfully cornered the US government into a hasty agreement to establish a safe zone in northern Syria.
However, this flimsy deal might set the stage for a Turkish-Kurdish war.
The devil is in the details
The content of the August 7 agreement remains unclear as the two sides released a rather vague joint statement.
It stipulates that Turkey and the US would "set up as soon as possible a joint operations centre in Turkey to coordinate and manage the establishment of the safe zone together and the safe zone shall become a peace corridor".
Erdogan interpreted this announcement as the beginning of the safe zone process while his Defence Minister Hulusi Akar said "we witnessed with satisfaction that our partners grew closer to our position".
The Pentagon seemed more cautious and noted that an agreement was reached only on forming a joint military operations centre and on the "security mechanisms" but hinted that more talks are needed before a "safe zone" is established.
However, the two most contentious issues in these talks remain unresolved: the size of this safe zone and who controls it.
While there seems to be an agreement on its length - 140km all the way to the Iraqi border - there is no consensus yet on its depth.
The US latest offer was 5km of demilitarised strip and an extra 9km free of heavy weapons; Turkey for its part insists on at least 30km-deep zone from which all Kurdish fighters are withdrawn.
The question of who will provide security in this safe zone also remains unanswered: Turkey wants to have full control, while the Trump administration prefers US and European troops.
The Russia factor
The third party in this equation, the SDF, is concerned about losing the gain it has hard earned in northeast Syria over the past four years.
To safeguard against this, it has made overtures to restart talks with Russia and the Syrian regime.
It is possible that the US will intervene to prevent them from this move, as it did last February when SDF engaged Moscow and Damascus in preparation for Trump's decision to withdraw from Syria.
The interests of the Syrian regime, Russia and the SDF are now aligned as both reject the US-Turkish deal.
Moscow could potentially become a spoiler if its influence on the SDF expands or at least have a say in what might unfold.
Russia also has the option of threatening to heavily bomb Idlib to pressure Turkey not to move forward with the deal, which could potentially force more than 3 million additional Syrian refugees to the Turkish border.
Ankara can also retaliate by increasing the support of the armed groups and inflict more losses on the Syrian regime and Russian assets.
To help ease the pressure on Kurdish fighters west of the Euphrates, the People's Protection Units (YPG) has escalated since last month military operations against Turkish targets east of the Euphrates. The remnants of the Islamic State of Iraq and the Levant (ISIL, also known as ISIS) group have been exploiting these differences by launching their own attacks east of the Euphrates.
In fact, a Pentagon report released on August 6 warned that ISIL is resurging in Syria and the SDF is not ready to continue this battle without US support.
A possible conflict
The warring parties in northeast Syria are indeed more invested in consolidating their control over Syrian territories than maintaining peace and stability.
The Turkish government knows that the White House will not put at risk the life of US soldiers in Syria and it is using this to its advantage, trying to pressure the Trump administration into heeding its demands to respond to Turkish threats.
For the time being, this strategy has worked and Erdogan has changed Trump's calculations on Syria. It doesn't matter anymore if Erdogan is bluffing or not about a potential incursion into Syria, the Trump administration seems cornered by Ankara and is showing a weak hand in these talks.
The recently concluded US-Turkish agreement deals with tensions east of the Euphrates River from a military and technical standpoint, not from a political one, which is reminiscent of previous experiments with de-escalation in Syria under the Astana process.
If the US does not deal hands-on with the tricky political issues, the two warring parties, Turkey and SDF, will ultimately fight it through in a direct war.
As the examples of Afrin and Manbij show, it is easy to invade or reach a deal, but more difficult to maintain stability.
Whatever the US and Turkey might agree on will face the challenge of instability and potential escalation of the conflict if there is no political reconciliation between Turkish and Kurdish sides, and most importantly a wider Syrian political solution.
The views expressed in this article are the author's own and do not necessarily reflect Al Jazeera's editorial stance.