President Alassane Ouattara of Ivory Coast says he has reached an agreement with soldiers who have mutinied.
He said he had taken into account their demands over pay and conditions and asked troops to return to barracks.
But some soldiers then besieged the defence minister in the city of Bouake, although they later let him leave.
The mutiny began there on Friday and spread to the commercial capital, Abidjan, where soldiers overtook the army headquarters.
They fired in the air as they took control of the base in the Abidjan’s Plateau district.
In his statement late on Sunday, the president said: “I confirm that I have agreed to take into account the demands of the soldiers over bonuses and better working conditions.”
Ivory Coast profile
Defence Minister Alain-Richard Donwahi had travelled to Bouake, Ivory Coast’s second city, to discuss the protesters’ demands.
But a group of soldiers trapped Mr Donwahi in a local official’s home in the city, demanding to know when they would be paid and how much.
Several hours later, they allowed him to leave.
Earlier on Saturday, firing was heard at the military base in Akouedo, on the eastern edge of Abidjan, which is home to parachute commandos that are considered loyal to Mr Ouattara.
Similar protests were also reported in the cities of Man, Daloa, Daoukro, Odienne and Korhogo.
The BBC’s Alex Duval Smith in Ivory Coast says the mutiny has brought back memories of Ivory Coast’s 10-year civil war, which ended in 2011.
Some of the mutineers were thought to be former rebels who joined the army after the conflict.
The rebels swept into Abidjan from Bouake in 2011, helping Mr Ouattara take power after his predecessor Laurent Gbagbo – now on trial at the International Criminal Court – refused to accept defeat in elections the previous year.
Join GhanaStar.com to receive daily email alerts of breaking news in Ghana. GhanaStar.com is your source for all Ghana News. Get the latest Ghana news, breaking news, sports, politics, entertainment and more about Ghana, Africa and beyond.