Database (and Storage, Edge Functions, Auth) operate on a fullstack app’s Supabase project. Create one first:
naive.apps.create({ name, type: "fullstack" }). These are curated surfaces over the same scoped Supabase proxy that powers the apps primitive.Two ways to use it
Database works for your own project and for each of your end-users’ projects, using Naive’s multi-tenancy:{ appId }.
SQL
PostgREST CRUD
Schema changes
migrate runs DDL against the database (works on any plan). Supabase’s tracked database/migrations endpoint is gated to approved orgs — reach it directly through the Supabase proxy (.../supabase/proxy/v1/projects/{ref}/database/migrations) where your org has access.
REST
/v1/apps/<app-id>/…; an end-user’s project is /v1/users/<user-id>/apps/<app-id>/…. The SDK picks the right path automatically (naive.database vs naive.forUser(id).database). See the Database API reference.
Billing
Free — no per-operation credit cost. The underlying Supabase project comes with the fullstack app. Account Kits can gate thedatabase primitive per user.