Puntland military retook the town, which Bari region Governor Yusuf Mohamed said earlier on Thursday had been attacked by the al Shabaab fighters.
"It was heavy fighting. We lost 20 soldiers and 14 of our military cars were burnt. We have now retaken the town," Major Mohamed Abdi, a Puntland military officer, told Reuters by phone.
The assault came days after Puntland sentenced to death five al Shabaab members who were arrested as they drove a vehicle carrying three barrels packed with explosives into Bosasso, Puntland's capital, on April 26.
Af Urur lies about 100 km (60 miles) south of Bosasso, near the Galgala hills, an area controlled by al Shabaab . It fighters have attacked and captured the town several times.
"They have not retaken the town, but we just left it peacefully after killing 61 soldiers and capturing 16 military cars," said Abdiasis Abu Musab, al Shabaab’s military operation spokesman.
Al Shabaab regularly launches attacks in Somalia , but tends to focus on the capital Mogadishu and other regions controlled by the federal government. It aims to drive out African Union peacekeepers, topple Somalia 's Western-backed government and impose its strict version of Islam on the Horn of Africa state.
Attacks are comparatively rare in Puntland, where the security forces are relatively regularly paid and receive substantial US assistance.
The region is also home to a splinter group of al Shabaab that has sworn allegiance to Islamic State. Security sources say a small contingent of foreigners is there as well.