Blogger Robert Alai and a prison officer based in Mandera have been arraigned in Nairobi.
Mr Alai was arrested and taken to court after police accused him of being sympathisers of Somalia-based Al-Shabaab terror group.
Mr Alai was presented before Senior Resident Magistrate Tobiko Sinkiyan on Wednesday afternoon.
According to the anti-terror police who arrested the accused, Alai posted online photos of officers who were killed in the June 15 terror attack in Wajir.
Police on Wednesday told the court that the photos Mr Alai posted on Twitter were taken by Al-Shabaab at the scene of the attack and sent to the duo.
Police therefore want their links with terrorists further investigated over the next 30 days.
“This is a sensitive matter, it involves various agencies and officers who will interview them to confirm their associates and terror links,” prosecution said.
But defence lawyers opposed the application, saying Mr Alai has known home and places of work hence no need for the long detention.