Al-Jazeera broadcaster had quoted the al-Shabaab spokesperson Abdiaziz Abu Mus'ab as saying the militants had killed dozens of Ugandan peacekeeping troops under the African Union Mission for Somalia (Amisom).
It frequently targets Amisom bases and Somali government institutions - attacks that have intensified recently, even as American strikes against the group have increased.
The al-Shabaab claimed they lost only 14 of their fighters.
The attack started when two suicide auto bombs exploded at the entrance to the heavily fortified base in Bulo-Marer, an agricultural town in Somalia's Lower Shabelle region, said Somali army Colonel Ahmed Hassan.
"It was a hellish battle", Major Farah Osman said.
A counter offensive against the militants left at least 22 of the attackers dead, Brig. Four Ugandan soldiers were killed, the army said.
"They were repulsed, but all these attacks were to stop reinforcement", Ali Nur said. "Then al Shabaab attacked this morning as a revenge", he said. "11 years since UPDF sent troops to Somalia's civil war, there seems to be no end plan", Former FDC party president, Dr Kizza Besigye said Monday.
30 members of the terrorist group al-Shabab were killed by African Union troops on Sunday during a gunfight that lasted hours.
U.S. officials have not commented on the poet's apparent death. The group attacked a peace group in Somalia.
The militants initially detonated two suicide auto bombs that hit one AU vehicle and one Somali military vehicle, Somali army major Farah Osman, who is stationed near the AMISOM (African Union Mission in Somalia) base, said.