The full-stack TypeScript framework for AI agents. An agent is a file: drop it in agents/ and it gets an HTTP route, token streaming, human-in-the-loop approvals and a typed client. React pages with file routing and SSR, OAuth sessions, Postgres, WebSockets, cron, and nine deploy targets. Apache-2.0.
README
Build the app your agent lives in. Routing, auth, real-time, deploy — wired.
Part of the Theo family of products. TheoKit is the web framework layer — independent and self-contained, with TheoCloud as its principal deploy target. See the Ecosystem section for how it relates to its siblings.
npx create-theokit my-app
cd my-app
pnpm dev
Node >= 22.12.0 is required — every manifest declares it and the CLI refuses to
start below it rather than failing later somewhere unrelated.
The scaffold ships a working agent chat, so the five minutes are spent reading it, not assembling it.
Point the agent at a provider. The FIRST segment of the model id picks it, and that decides which key is read — so the id and the key move together:
echo 'OPENROUTER_API_KEY=sk-or-v1-...' >> .env # matches `openrouter/…` below
openrouter/openai/gpt-4o-mini reaches OpenAI's catalog THROUGH the gateway. A
bare openai/gpt-4o-mini goes to OpenAI directly and needs OPENAI_API_KEY,
even with an OpenRouter key present — the prefix is a selection, not a hint.
**An agent