Gunmen in government uniform attacked a Mogadishu Supreme Court complex on Sunday, killing at least 16 people.
"Armed men entered the court and then we heard a blast. Then they started opening fire. We do not know the number of casualties," court employee Hussein Ali told Reuters.
The wire agency reported at least 16 people dead - the bodies counted by its reporters - while the Associated Press, unable to confirm a death toll from authorities, said one police officer saw five dead bodies.
“I never expected to make it out alive today,” Halima Geddi, a witness who saw the attack, told the AP. “There is no peace. No one protects us. I came to see my boy who was supposed to be tried here.”
Two car bombs exploded and a gunfight occurred outside the courts as armed men and Somali security forces exchanged fire.
"We managed to put down the attack [and] we killed most of the attackers and they have killed and wounded several people including some soldiers," Qasim Omar, a local police officer, told Xinhua.
No group has claimed responsibility for the attack, but the Al Qaeda-linked militant group al Shabaab has carried out a number of attacks this year, including suicide bombings.
A third car bomb at a different location exploded and killed four people, including two Turkish aid workers, according to the BBC.