BOSASO, Somalia (Reuters) - Islamist al Shabaab militants attacked a checkpoint in Somalia’s semi-autonomous Puntland region, killing at least seven people in the early hours of Monday, police said.

The fighters then ambushed officers rushing in to help colleagues on the outskirts of the city of Bosaso, an officer at the scene told Reuters.

Al Shabaab said it took the checkpoint then left, though the police said they fought off the assault.

Al Shabaab has launched a string of attacks on Somalia’s capital Mogadishu and other areas controlled by the federal government in a bid to oust the Western-backed authorities and impose the group’s interpretation of Islamic law.

Attacks are relatively rare in Puntland, which has its own government and security forces patrolling its territory on the northeastern tip of the Horn of Africa, jutting out into the Gulf of Aden and the Arabian Sea.

“At about 1 a.m., many well-armed al Shabaab fighters attacked us from all directions in an attempt to capture the checkpoint,” police captain Abdifatah Mohamed said.

Three police and four civilians died and at least 13 others were wounded in the clashes, he said over the phone from the checkpoint.

Abdiasis Abu Musab, al Shabaab’s military operation spokesman, said its fighters killed seven soldiers and wounded 11 others.

“We captured the Bosaso checkpoint and left this morning. We also ambushed a police reinforcement,” he said.

Puntland is also home to a splinter group of al Shabaab that has sworn allegiance to Islamic State. Security sources say a small contingent of foreign fighters is based there.