According to the deal, announced at a press conference, Traore had agreed to seven conditions, including a guarantee of Damiba’s safety and the security of soldiers who backed him, and the honouring of promises made to the West African regional bloc to return to constitutional rule by July 2024.

Traore said earlier that order was being restored after violent protests against the French embassy and days of fighting as his faction moved to topple the government.

Splits have emerged within the army, with many soldiers appearing to seek Russian support as the influence of former colonial power France wanes.

Traore’s team urged people to halt attacks on the French embassy, targeted by protesters after an officer said France had sheltered Damiba at a French military base in the West African country and that he was planning a counter-offensive. France denied that the base had hosted Damiba after his ousting on Friday.

“We want to inform the population that the situation is under control and order is being restored,” an army officer said in a statement broadcast on national television.

Another statement said Traore would continue to act as president until a transitional civilian or military president is designated in the coming weeks.

“We invite you to continue with your activities and refrain from all acts of violence and vandalism notably that against the French embassy and the French military base,” the officer loyal to Traore said, urging people to remain calm.

He urged Burkinabes to go about their business as usual and to refrain from acts of violence and vandalism, especially against the French embassy and the French military base.

Damiba himself led a coup earlier this year against a civilian government that had lost support over rising violence by Islamist extremists.

Damiba’s failure to stop the militant groups had led to anger in the ranks of the armed forces in the former French protectorate.