Database
Every Wok includes a dedicated Postgres database — not a shared schema. You get full SQL, an instant REST API over your tables, six-hour logical backups, and continuous WAL archiving, with strong isolation from other tenants.
NOTIFY pgrst auto-fires on success so your REST API picks up schema changes immediately.Instant REST API
Tables are exposed over a PostgREST REST API automatically, guarded by row-level security. Read and write with @supabase/supabase-js or plain HTTP:
const { data } = await tw
.from("orders")
.select("id, total, customer:customers(name)")
.gte("total", 100)
.order("created_at", { ascending: false })
.limit(20);Changing the schema
Schema changes go through a migration so the same change can be replayed on the Published copy of your app. Each one is recorded with its SQL and a checksum, and promotion replays exactly the migrations your Preview recorded.
lollipop migrate --wok-id $WOK --name add_orders_status \
--sql "alter table orders add column status text default 'new';"Run one-off queries, seeds and data fixes with exec-sql instead. A create, alter or drop issued that way stays on the copy you ran it against, and the promoted app breaks the moment its code expects the change.
Backups
Every Wok's database is logically dumped every six hours via pg_dump to storage in a separate availability zone. Continuous WAL archiving adds point-in-time recovery with an RPO measured in minutes.
Isolation
Each Wok's Postgres runs as its own container with its own credentials. Paid plans run on your own private server; Free runs on the shared platform. See Isolation for dedicated and confidential options.