The US military says it has conducted an air strike against Taliban forces in southern Afghanistan, days after American and Taliban officials signed an ambitious peace deal.

US military spokesman Colonel Sonny Leggett said it was the first American strike against the militant group in 11 days.

He said the attack was to counter a Taliban assault on Afghan government forces in Nahr-e Saraj, Helmand province.

Donald Trump confirmed on Tuesday that he had spoken on the phone to a Taliban leader, making him the first US president believed to have spoken directly with the militant group responsible for the deaths of thousands of US troops in nearly 19 years of fighting in Afghanistan.

Col Leggett said Taliban forces had conducted 43 attacks on Afghan troops on Tuesday in Helmand.

He called on the Taliban to stop the attacks and uphold their commitments based on the agreement signed on February 29 between their leaders and US peace envoy Zalmay Khalilzad in Doha, Qatar, which lays out a conditions-based path to the withdrawal of American forces from Afghanistan.

The Afghan Defence Ministry said in another statement that a Taliban attack on a checkpoint in northern Kunduz province had killed seven of its soldiers.

The statement said 10 Taliban fighters were killed in the shootout.

The Taliban have not claimed any of these attacks so far or confirmed the US air strike, but spokesman Zabihullah Mujahid said a week of reduced violence had ended.

Col Leggett said US forces are responsible for defending their Afghan allies, according to agreements between the US and Afghan governments.