Mali's interim government has condemned the action by "uniformed and armed men" from the Special Anti-Terrorist Forces (Forsat) in a TV statement, AFP news agency reports.
The Malian Association of Human Rights (AMDH) said it was "deeply shocked" and called it a serious attack on the rule of law.
It said officers had fired shots in the centre of the capital, Bamako, on Friday before heading to the city's central prison, where Forsat commander, Oumar Samake had been detained hours earlier.
The special forces unit has received training from both the EU and the US to help in the fight against jihadist groups which have been waging a decade-long insurgency in Mali.
The UN and France have thousands of peacekeepers based there to help tackle the jihadists.
But the unrest has left the country deeply unstable, and it has seen two military coups in the past year.
The special forces unit commander was detained for allegedly using brute force to quash protests last year.
Samake had been detained for his alleged role in lethal clashes between security forces and opponents of former president Ibrahim Boubacar Keita last year, in a wave of protests that eventually led to Keita's overthrow.
One such protest on July 10, 2020 sparked several days of deadly unrest.
Mali's political opposition said at the time that 23 people were killed; the UN reported 14 protesters killed, including two children.
Similarly, Nigeria's secret police, Department of State Services (DSS) has a penchant for breaking laws and disobeying court orders.
For instance, the DSS on July 1 stormed the home of Yoruba Nation agitator, Sunday Adeyemo, aka Sunday Igboho, killing two of his associates and arresting 12 others.
The court ordered that the 12 persons should be released but the DSS disobeyed the court and only later released some of them.
Also, on August 03, 2019, DSS operatives in a commando style abducted human rights activist, Omoyele Sowore.
Sowore was illegally arrested around 1:30am in Lagos State for creating and championing ‘#RevolutionNow’, a hash tag used to criticise President Muhammadu Buhari's administration on the social media over poor governance.
He was moved to the agency's headquarters in Abuja where he was illegally detained for 144 days despite different court orders issued for his release.
In a twist of event, lawless DSS operatives invaded the Federal High Court in Abuja on December 6, 2019, to rearrest him without any court order.
He remained in unlawful detention until 18 days later when he was released by the secret police for the second time.
The DSS had accused Sowore of baseless crimes like money laundering and that he was plotting to overthrow President Buhari even though it failed to produce any evidence to substantiate its claim.