MUNICH, Germany — The United States and the Taliban have agreed to a temporary truce that, if successful, would open the way for a deal that would bring American troops home from Afghanistan and end 18 years of war. 

The truce marks a milestone in efforts to end America’s longest-running conflict and fulfill President Donald Trump’s campaign pledge to bring U.S. troops home from foreign conflicts. 

But prospects for a real and lasting peace remain unclear. 

A U.S. official said Friday the agreement for a seven-day “reduction in violence” is “very specific” and covers the entire country, including Afghan government forces. 

There were indications a formal announcement could come as early as the weekend. The agreement will take effect "very soon."

The official said the agreement will be followed by the start of all-Afghan peace talks within 10 days. The official spoke on condition of anonymity because the official wasn't authorized to discuss details ahead of an official announcement.

The developments came as U.S. Secretary of State Mike Pompeo and Defense Secretary Mark Esper met Friday in Munich with Afghanistan's President Ashraf Ghani.

RELATED: 15 Army surgeons from Niagara Falls deployed to Afghanistan

RELATED: Oregon soldier, 21, dies in Afghanistan

RELATED: 2 US soldiers killed, 6 wounded in Afghanistan attack