Terreno Documentation
Terreno is Django/Rails for TypeScript — with universal app support.
Terreno is Django/Rails for TypeScript — a batteries-included, full-stack framework where the undifferentiated 80% of an app is already written. On the backend you get Mongoose models, auto-generated REST APIs, permissions, an admin panel, authentication, and an AI service. On the frontend you get one universal app — a single React Native codebase that ships to iOS, Android, and web. It is built to be driven by AI coding agents from the first prompt to a production deploy.
- Batteries included — auth, CRUD APIs, admin, permissions, AI, realtime, feature flags, and consent are already built, so your code is business logic.
- Universal by default — one React Native codebase ships to iOS, Android, and web. Not a web framework with a mobile bolt-on.
- AI-native — agents are a first-class client of the framework, not an afterthought.
Canonical copy, language rules, and the Django/Rails comparison: Positioning.
Structure
- Tutorials — Learning-oriented, hands-on lessons
- How-to guides — Problem-oriented, practical steps
- Reference — Technical reference for APIs and packages
- Explanation — Concepts and context
- Implementation Plans — Forward-looking plans for major features
Packages
| Package | Description |
|---|---|
| @terreno/api | REST API framework for Express/Mongoose (modelRouter, auth, OpenAPI) |
| @terreno/test | Shared Bun test helpers, MongoDB preload utilities, and HTTP fixtures |
| @terreno/ui | React Native UI component library for iOS, Android, and web |
| @terreno/syncdb | Local-first data layer with TinyBase, durable outbox, and delta sync |
| @terreno/ai | Provider-agnostic AI service with streaming chat, request logging, and admin tools |
| @terreno/admin-backend | Admin panel backend plugin for @terreno/api |
| @terreno/admin-frontend | Admin panel frontend screens for @terreno/api backends |
| @terreno/admin-spa | Standalone admin SPA (Expo Router web) plus Express serve plugin |
| @terreno/api-health | Health check plugin for @terreno/api |
| @terreno/comms | Pluggable communications providers |
| @terreno/feature-flags | Feature flags and A/B testing plugin for @terreno/api |
| @terreno/mcp | MCP server that gives coding agents Terreno docs, codegen tools, and prompts |
Legacy
| Package | Description |
|---|---|
| @terreno/rtk (deprecated for data sync) | OpenAPI SDK, Better Auth Redux, and feature flags for Terreno frontends |
Migrating from RTK? See How to migrate from @terreno/rtk to @terreno/syncdb.
Quick links
- Getting started
- Positioning
- Local-first data
- AGENTS.md — Onboarding context for AI assistants
- ROADMAP.md — Public roadmap
- CONTRIBUTING.md — Setup, tests, and pull requests