Ship and scale
Chapter 11 of 11
One schema in practice
Compiling data, identity and side effects together removes whole classes of bugs. Start locally in one command and explore the guides and reference for your stack.
Across the preceding chapters, browsers, mobile apps, hosted handlers, cron schedules, warehouse workers and AI agents all operated on one schema. Every write from every caller landed on a single commit timeline.
Try it
One CLI command inspects recent commits across HTTP sessions, MCP tool calls and scheduled jobs from the change log.
Six pillars and six guarantees#
The same six architectural guarantees held from the first private record through multi-shard failover.
| Pillar | Guarantee | Chapter |
|---|---|---|
| One typed graph | GuaranteeRows, files, search indexes, jobs and grants live in one schema under shared access policies and snapshots | ChapterSearch and models |
| Caller-bound | GuaranteeAccess policies walk the graph from verified identity across queries, file URLs, actions and expiring grants | ChapterRules, queries and files |
| Compiled | GuaranteeStatic checks block breaking pushes, compile policies into one SQL statement per request and generate SDKs and MCP tools | ChapterAgents and copilots |
| Commit-atomic | GuaranteeLive subscriptions, webhooks, background jobs, ledger debits and causal replicas advance on one commit timeline | ChapterActions, jobs and webhooks |
| Distributed from links | GuaranteeRequired ownership links group and move root subtrees across shards behind one unchanging address | ChapterOrganizations and billing |
| Checked and fault-tested | GuaranteePush validation, reach diagnostics, dry-run previews and public fault campaigns verify every guarantee | ChapterScale and the chaos lab |
Cross-layer guarantees#
Compiling data, identity and commit order together gives you cross-feature guarantees without custom glue. Deleting an AgentGrant in Agents and copilots drops restricted rows from an agent’s open live stream on that commit, and queueing a job in Actions, jobs and webhooks commits or rolls back inside the same write transaction.
Live revocation
Deleting a grant drops restricted rows from open streams on that commit.
Transactional jobs
Queued jobs commit or roll back inside the same statement as your writes.
Single-root restore
Rewind one root record and its descendants while other roots stay live.
Setting allows_training to false in Search and models excludes those records from the next Parquet export with no pipeline changes. When a bad import hits a single root in Scale and the chaos lab, napalm placement restore-root rewinds that root and its linked descendants while the rest of the cluster continues uninterrupted.
Guides by use case#
Scaffold a project locally in one command, then follow Your first app for the five setup steps or jump to the quickstart to install the CLI and sign in.
napalm new notes-app notesFrom there, pick the step-by-step guide for the architecture you are building.
| Architecture | Guides |
|---|---|
| Realtime web and mobile apps | GuidesReact, Vite & single-page apps, Next.js & React, React Native, Flutter and Realtime & collaboration |
| Agents, MCP and copilots | GuidesCoding agents, In-app AI copilots, Tools for agents, Multi-agent pipelines and Watching and stopping an agent |
| Documents, search, models and evals | GuidesFiles, media & document search, Datasets & ML training, Model serving, Evals and Model registry |
| Multi-tenant SaaS, sharding and ledgers | GuidesMulti-tenant B2B SaaS, Billing & payments and Actions & background jobs |
| Change data and warehouse sync | GuidesWarehouse sync, Search index & cache sync and Queues & streams |
| Moving from another platform | GuidesMoving to Napalm, Coming from Postgres, Coming from Supabase, Coming from Firebase, Coming from Convex and Coming from Gel |
Learn and reference#
Beyond the application guides, Learn covers each subsystem in depth, Testing covers branch harnesses and policy verification, and Reference documents every schema extension, HTTP endpoint, generated SDK method, CLI flag and limit.
| Surface | Covers |
|---|---|
| Schema & extensions | CoversSchema declarations, access policies, files, vector indexes, jobs, agent grants and placement roots |
| Testing & verification | CoversBranch test harnesses, caller-matrix policy suites, dry-run previews and pull-request CI checks |
| Project API | CoversProject HTTP routes for queries, live streams, files, search and /ask |
| Control API | CoversControl HTTP routes for projects, schemas, branches, clusters, placement and orgs |
| SDKs | CoversTyped client SDKs generated by napalm generate across eight languages |
| CLI reference | CoversEvery command, flag and exit code in napalm |
Coding agents can also consume the docs directly. openapi.yaml specifies every HTTP route, llms-full.txt bundles the full documentation as plain text, and Known limits lists current boundaries and architectural trade-offs.
Run napalm new and build from one schema.