Getting started
Host APIs
Own the UI in your repo. Borrow the boring API security. Bring your own keys. Walk the trays below — one idea at a time. Essay: Host APIs blog post.
Guide
01 / 07
UI posts to your /api. Handlers live in atroui.
What Host APIs are
Registry form and tool UIs post to /api/* on your Next.js app. Each route is a thin stub that calls a published handler:
ts
import { handleContactPost } from "atroui/api/contact"
export const runtime = "nodejs"
export async function POST(req: Request) {
return handleContactPost(req)
}Handlers in atroui/api/* already include validation, honeypot checks, body caps, and rate limits. You bring SMTP/Resend or HF/Gemini/xAI keys in your env.