Skip to content
MartinsAI.
All work
Authentication system in active developmentEngineering & AI systems architecture

CowriterAI

AI-powered academic writing platform for Nigerian university students

CowriterAI is an AI-powered academic writing platform aimed at Nigerian university students, where email-first sign-up is a weaker assumption than phone-number-first. The authentication system is built on Payload CMS with better-auth, using the phoneNumber and phoneHarmony better-auth plugins to drive a multi-step sign-up wizard, backed by a three-call server-side sequence for phone-based account creation.

The front end of the sign-up flow was migrated to react-hook-form to get schema-driven validation and better control over the multi-step wizard state, replacing a less structured earlier implementation.

The broader platform blueprint covers AI agent workflows built on TanStack Start with the eve framework and custom PayloadCMS Endpoints, bot channels across Telegram, WhatsApp, and Messenger for students who prefer chat-based access over a web dashboard, a student dashboard that uses Payload Versions to keep a full AI edit history on submitted work, and AI SDK Elements for the chat interface itself.

Highlights

  • Phone-number-first auth using better-auth's phoneNumber and phoneHarmony plugins for a market where phone, not email, is primary
  • Multi-channel design spanning web, Telegram, WhatsApp, and Messenger from one agent backend
  • Payload Versions used to preserve full AI edit history per student submission

Stack

TypeScriptTanStack StartPayload CMSbetter-authreact-hook-formAI SDK

Have something similar in mind?

Let's talk