Syria conflict: Pompeo 'optimistic' on deal to protect Kurds
US Secretary of State Mike Pompeo says he is optimistic an agreement can be reached with Turkey to protect Kurdish fighters in Syria after the US leaves.
He was speaking in the United Arab Emirates following a phone call with his Turkish counterpart.
US forces in northern Syria have fought alongside a Kurdish militia against Islamic State (IS) militants.
Turkey, however, regards the People's Protection Units (YPG) as a terrorist group and has vowed to crush it.
Mr Pompeo is touring the Middle East to try to reassure allies following President Donald Trump's abrupt announcement last month that US forces would withdraw from Syria.
- War-weary Syrians in Manbij wait to learn fate
- Trump rewrites US-Syria policy
- After the caliphate: Has IS been defeated?
Talking to reporters in Abu Dhabi, Mr Pompeo said the US recognised "the Turkish people's right and [Turkish President Recep Tayyip] Erdogan's right to defend their country from terrorists".
"We also know that those fighting alongside us for all this time deserve to be protected as well," he said.
Mr Pompeo said he had spoken to Turkish Foreign Minister Mevlut Cavusoglu, adding: "Many details (are) still to be worked out but I'm optimistic that we can achieve a good outcome."
What has Turkey said?
Last week, President Erdogan angrily rejected calls by US National Security Adviser John Bolton for the Kurdish fighters to be protected.
He said such statements were "unacceptable".
Mr Erdogan told MPs from his governing Justice and Development Party that the US did not know who the various Kurdish groups were, adding: "If the US evaluates them as 'Kurdish brothers' then they are in a serious delusion."
Mr Bolton was on a visit to Ankara to seek guarantees over the Kurdish fighters, but President Erdogan declined to meet him.
Turkey considers the YPG an extension of the banned Kurdistan Workers' Party (PKK), which has fought for Kurdish autonomy in Turkey for three decades. The YPG denies any direct organisational links to the PKK.
US seeks united front against Iran
Analysis by Barbara Plett Usher, BBC News, Riyadh
This dispute with Turkey over America's Kurdish allies has overshadowed Mr Pompeo's sweeping Middle East trip.
Mr Pompeo really wants to turn the focus to countering Iran. He is calling for a united Arab front against what he describes as its destabilising activity and Saudi Arabia is key to that.
But outrage over the Saudi murder of the journalist Jamal Khashoggi has complicated the relationship. A senior US official said the Americans wanted the Saudis to give a more credible explanation of what happened and do more to punish the killers, and Mr Pompeo would press them on both points.
Why is the US withdrawing from Syria?
In 2014, militants overran 100,000 sq km (39,000 sq miles) of Syria and neighbouring Iraq, and imposed their brutal rule on almost 8 million people. Now, they control only 1% of the territory they once had.
However, the defeat of IS is far from final. A US defence department report estimated in August that there might be as many as 14,000 jihadists left in Syria and 17,000 in Iraq.
President Trump consequently shocked allies and faced strong criticism at home last month when he ordered US forces to immediately begin withdrawing from the approximately 30% of Syria controlled by the YPG-led Syrian Democratic Forces (SDF) alliance.
Mr Bolton later laid out several conditions for the withdrawal, which suggested that the four-month schedule agreed by Mr Trump could slip.
He told reporters in Israel that it would be done in a way that guaranteed IS "is defeated and is not able to revive itself", and that the US would "take care of those who have fought with us against [IS] and other terrorist groups".
What is the US presence in Syria?
About 2,000 US military personnel are reported to be deployed in Syria.
Ground troops first arrived in autumn 2015 when then-President Barack Obama sent in a small number of special forces to train and advise YPG fighters.
The US did this after several attempts at training and arming Syrian Arab rebel groups to battle IS militants descended into chaos.
Over the intervening years the number of US troops in Syria has increased, and a network of bases and airfields has been established in an arc across the north-eastern part of the country.