The CLI

Start. Build. Ship.

Start a production-ready Supabase project in one command, then keep building: run migrations, manage environments, and deploy to production, all from the same CLI.

~/my-app

$ npx agentlink-sh@latest my-app

# start

$ agentlink-sh db migrate add_orders

# migrate

$ agentlink-sh env use prod

# environments

$ agentlink-sh env deploy prod

# deploy

DAY ONE

The Foundation, Ready to Build On.

The first command sets up everything deterministic so your agent can focus on what requires reasoning. Everything after (migrations, environments, deploys) runs through the same CLI.

Supabase Project

Local Docker or Supabase Cloud, auto-configured with extensions, schema isolation, and API settings.

Database Schemas

Tables, RPC functions, triggers, and indexes. Separate api and public schemas from day one.

Auth & Multi-tenancy

Auth hooks, profiles, tenants, memberships, invitations, and RLS policies: all wired together.

Edge Functions

Queue worker, email sending, and shared utilities with the withSupabase auth wrapper pre-configured.

Frontend

React + TanStack Start (SPA), Supabase client, auth UI, theme switcher, and RPC-first data access.

AI Agent Tooling

Plugin for Cursor and Claude Code with 6 domain skills, MCP server, and a builder agent that knows the architecture.

COMMANDS

Your Toolkit.

Scaffold, develop, manage environments, and deploy: all from one CLI.

Every command runs via npx agentlink-sh@latest, no install step, always the latest version.

Getting Started

$ npx agentlink-sh@latest

Interactive wizard: scaffold a new project (no install step)

$ npx agentlink-sh@latest my-app

Scaffold a named project

$ npx agentlink-sh@latest my-app --prompt "Build a CRM"

Create with a prompt for the agent

$ npx agentlink-sh@latest my-app --local

Use local Docker instead of Cloud

Database

$ npx agentlink-sh@latest db apply

Apply schema files to database

$ npx agentlink-sh@latest db migrate <name>

Generate a migration from your schema files

$ npx agentlink-sh@latest db types

Generate TypeScript types

$ npx agentlink-sh@latest db sql "SELECT ..."

Run ad-hoc SQL queries

Environments

$ npx agentlink-sh@latest env add prod

Connect a production environment

$ npx agentlink-sh@latest env use local

Switch active dev environment

$ npx agentlink-sh@latest env list

List all environments

Deploy

$ npx agentlink-sh@latest env deploy

Deploy schema, edge functions, and secrets

$ npx agentlink-sh@latest env deploy --dry-run

Preview changes without applying

$ npx agentlink-sh@latest env add prod --setup-ci

Connect prod + scaffold GitHub Actions workflow

More Flags

--no-frontendBackend only
--linkLink existing project
--resumeResume failed scaffold
--no-skillsSkip companion skills
--non-interactiveCI/CD mode
--debugWrite debug log

THE FIRST RUN

From Zero to Building.

The first run is the only time you wait. From there, the CLI stays with you for every schema change, environment switch, and deploy. Resume support means interrupted scaffolds pick up where they left off.

terminal

$ npx agentlink-sh@latest my-app

Setting up your project...

Check prerequisites

Supabase CLI and the schema converger come bundled with agentlink-sh. No manual install. Local mode also checks for psql and Docker.

Initialize Supabase

Creates project structure, config.toml, and schema files

Start Supabase

Spins up Docker locally or creates a Cloud project

Setup database

Applies schemas, extensions, queues, auth hooks, and generates migrations

Scaffold frontend

Writes React + TanStack Start (SPA) files with Supabase client pre-wired

Install agent tooling

Plugin (Cursor or Claude Code), 6 domain skills, MCP server, and AGENTS.md

Open your agent

Opens your project in Cursor or Claude Code, ready to build

Two Modes. Same Result.

Cloud

Default

Creates a Supabase Cloud project. No Docker required.

  • OAuth authentication
  • Auto-detected region
  • Connection pooler
  • Deploy-ready from day one

Local

Runs Supabase in Docker via supabase start.

  • Works offline
  • Full psql access
  • MCP server for your agent
  • Exact production parity

PROJECT STRUCTURE

What Gets Created.

project
my-app/├── supabase/│   ├── config.toml│   ├── database/│   │   ├── cluster/extensions/      # pgmq, pg_cron, pg_net│   │   ├── rbac/                     # roles, permissions, bindings│   │   └── schemas/│   │       ├── public/│   │       │   ├── tables/           # profiles, tenants, memberships…│   │       │   └── functions/        # _auth_*, _internal_admin_*, _hook_*│   │       └── api/│   │           └── functions/        # RPCs: profile_get, tenant_create…│   ├── migrations/                   # auto-generated│   └── functions/│       ├── _shared/                  # responses, email-components│       ├── internal-queue-worker/    # PGMQ handler│       ├── internal-send-auth-email/ # auth emails│       └── internal-invite-member/   # invitations├── src/                              # React + TanStack Start (SPA)├── .env.local                        # API keys + DB URL├── AGENTS.md                         # agent instructions└── agentlink.json                    # project manifest

One CLI. From day one to production.

Get started →

Works on macOS, Linux, Windows, and Node.