Skip to main content
All commands read credentials from .env.local; to override, pass the global flags before the command (result --url <url> --key <key> <command>). Run result <command> --help for full flags.

init

Verifies credentials, persists backend rules into AGENTS.md/CLAUDE.md. Idempotent - re-run any time.

status

Tables (with row counts), buckets, functions and auth at a glance. Run this before creating anything - it may already exist.

db

db create-table

  • Column spec: name:type[:required][:unique]
  • Types: string, integer, float, boolean, datetime, date, json, uuid
  • id, created_at, updated_at are added automatically - never spec them
  • RLS is on by default. With a user_id uuid column the owner policy is created automatically (rows scoped to the signed-in user, user_id defaults from the session; --no-policy skips it). Without one the command warns: an RLS table with no policy denies all reads and writes. --no-rls for shared/public data.

db migrate

Raw SQL for anything create-table can’t express: indexes, custom RLS policies, triggers, extensions (pgvector). Versioning is automatic; the migration already runs in one transaction, so never write BEGIN/COMMIT.

storage

realtime

% is a wildcard - chat:% covers chat:room-1, chat:room-2, etc. Clients cannot subscribe until a pattern covers the channel.

functions

The function runs at $NEXT_PUBLIC_BACKEND_URL/functions/my-fn.

secrets

Read inside functions with Deno.env.get("OPENWEATHER_KEY"). Treat secrets as permanent - deletion is unreliable on current backend versions.

deployments

Deploys the frontend to Result hosting. node_modules, .git, build output and .env* files never upload. Because env files stay home, set NEXT_PUBLIC_BACKEND_URL and NEXT_PUBLIC_BACKEND_ANON_KEY as build variables before the first deploy; never set BACKEND_ADMIN_KEY there. deploy --env KEY=value saves the variable and applies it to that build. The command polls up to 5 minutes and prints the live URL; history and status also live in the dashboard under Infrastructure, Deployments.

auth

logs