After Turkey launched a cross-border operation against the YPG in the western enclave of Afrin in January, President Recep Tayyip Erdogan threatened to take the offensive to Manbij. The

The US has a military presence in Manbij and has provided military support to the YPG in the fight against the Islamic State (IS) extremist group, causing anger among Turkish officials.

The northern city of Manbij is held by the People's Protection Units (YPG) Kurdish militia, a group which Ankara says is the "terrorist" offshoot of Kurdish hardliners in Turkey.

Turkish and US officials on Friday agreed on a "roadmap" for further cooperation to ensure the security of a Kurdish-held city which became a major headache between the NATO allies, according to a joint statement.

The offensive also caused tension between the allies because Washington urged Turkey to show "restraint" and said it could harm the fight against IS extremists.

US officials were in Ankara on Friday as part of a working group on Syria. After talks with Turkish counterparts, the statement was issued by the Turkish foreign ministry and the US embassy in Ankara.

"The two sides outlined the main contours of a roadmap for their further cooperation in ensuring security and stability in Manbij," the statement said, giving no further detail.

The working group was established to try to resolve the Manbij issue and coordinate US-Turkey efforts in Syria after Turkish Foreign Minister Mevlut Cavusoglu and then US Secretary of State Rex Tillerson met in February.

Turkish officials were in Washington in March as part of the working group, set up after the threats by Ankara and repeated calls for the YPG to leave the city.

Cavusoglu is due to meet the new US Secretary of State Mike Pompeo in Washington on June 4.

According to the joint statement, the two men will "consider the recommendations" of the working group during their meeting.

Ankara says the YPG is linked to the Kurdistan Workers' Party (PKK), which is blacklisted as a terrorist organisation by Ankara, the US and the European Union.

The PKK has waged an insurgency inside Turkey since 1984.

Erdogan has repeatedly urged the US to halt support for the YPG.

His ruling Justice and Development Party published a manifesto on Thursday calling for "concrete steps" by the US to end its backing of the YPG and provide "concrete support" to Turkey in its fight against the PKK.

Erdogan vowed Turkey would "continue its operations in Syria until the last terrorist is cleared".