This page is generated from the aura binary (npm run docs:cli in studio/): every usage line, argument and option below is the output of aura <command> --help. Square brackets mark optional items, angle brackets mark values you provide.
Every command also accepts --help and --gateway-url <URL>: Management plane URL (default: https://api.aurabase.cloud ). Local: http://localhost:8090 . Equivalent to the AURA_GATEWAY_URL environment variable.
aura db#
Manage the database (migrations, SDK, schema)
Copy
aura db [OPTIONS] <COMMAND>
Command Description aura db migrationManage migrations aura db tableManage tables (schema) aura db pushApply local migrations (+ remote sync if a project is linked) aura db pullPull remote schema aura db watchWatch for changes and sync aura db resetReset the database (purge and recreate) — DESTRUCTIVE, asks for confirmation aura db seedInsert test data (seed.sql), or an example schema with --example aura db generateGenerate types (TypeScript/JS or Rust) aura db statusShow migration status aura db slow-queriesMost expensive SQL queries in the project (pg_stat_statements) aura db statsConnections and database size for the project aura db diffCompare remote schema and generate a diff migration aura db rawExecute raw SQL directly aura db policyManage RLS policies aura db functionManage project Postgres SQL functions (PL/pgSQL, SQL) aura db triggerManage Postgres triggers on a table aura db backupManage database backups aura db inspectDiagnostics the SQL guard does not allow in raw queries: index usage, table sizes, blocking locks aura db connectionDirect PostgreSQL access (psql, Prisma, Drizzle, pg_dump): host, role and a one-time password aura db extensionsList or enable PostgreSQL extensions of the linked project aura db api-keysManage project API keys aura db restoreRestore a plain-SQL pg_dump file (statements, $$ bodies, COPY blocks) into the project
aura db migration#
Manage migrations
Copy
aura db migration [OPTIONS] <COMMAND>
aura db migration new#
Create a new migration
Copy
aura db migration new [OPTIONS] <NAME>
Argument Description <NAME>
aura db migration list#
List all migrations and their status
Copy
aura db migration list [OPTIONS]
aura db migration down#
Revert the last N applied migrations (default: 1)
Copy
aura db migration down [OPTIONS] [N]
Argument Description [N][default: 1]
aura db migration repair#
Manually mark a migration as applied or reverted
Copy
aura db migration repair [OPTIONS] <NAME>
Argument Description <NAME>Migration file name (e.g. 20240101_create_users.sql)
Option Description --appliedMark as applied --revertedMark as reverted
aura db table#
Manage tables (schema)
Copy
aura db table [OPTIONS] <COMMAND>
aura db table list#
List tables and their columns
Copy
aura db table list [OPTIONS]
aura db table create#
Create a table e.g. aura db table create users "name:text,email:text,age:int"
Copy
aura db table create [OPTIONS] <NAME> [COLUMNS]
Argument Description <NAME>Table name [COLUMNS]Columns in "name:type,..." format (see --help for all 16 supported types)
aura db table drop#
Drop a table
Copy
aura db table drop [OPTIONS] <NAME>
Argument Description <NAME>Table name
Option Description -f, --forceDrop without asking for confirmation
aura db table rls#
Enable or disable Row Level Security
Copy
aura db table rls [OPTIONS] <NAME> <STATE>
Argument Description <NAME>Table name <STATE>on | off
aura db table realtime#
Enable or disable Realtime CDC
Copy
aura db table realtime [OPTIONS] <NAME> <STATE>
Argument Description <NAME>Table name <STATE>on | off
aura db push#
Apply local migrations (+ remote sync if a project is linked)
Copy
aura db push [OPTIONS]
aura db pull#
Pull remote schema
Copy
aura db pull [OPTIONS]
aura db watch#
Watch for changes and sync
Copy
aura db watch [OPTIONS]
aura db reset#
Reset the database (purge and recreate) — DESTRUCTIVE, asks for confirmation
Copy
aura db reset [OPTIONS]
Option Description -f, --forceSkip the confirmation prompt
aura db seed#
Insert test data (seed.sql), or an example schema with --example
Copy
aura db seed [OPTIONS]
Option Description --example <NAME>Install an embedded example schema instead of seed.sql (available: docs)
aura db generate#
Generate types (TypeScript/JS or Rust)
Copy
aura db generate [OPTIONS]
Option Description --lang <LANG>Output language: ts (default) | rust [default: ts] [possible values: ts, rust]
aura db status#
Show migration status
Copy
aura db status [OPTIONS]
aura db slow-queries#
Most expensive SQL queries in the project (pg_stat_statements)
Copy
aura db slow-queries [OPTIONS]
Option Description --limit <LIMIT>Number of queries to display [default: 10] --json
aura db stats#
Connections and database size for the project
Copy
aura db stats [OPTIONS]
aura db diff#
Compare remote schema and generate a diff migration
Copy
aura db diff [OPTIONS]
Option Description --name <NAME>Name of the generated migration (default: schema_diff)
aura db raw#
Execute raw SQL directly
Copy
aura db raw [OPTIONS] [SQL]
Argument Description [SQL]SQL query to execute (use - to read it from stdin). May start with a -- comment
Option Description -f, --file <FILE>Read the SQL from a file instead of the command line -p, --params [<PARAMS>...]Positional parameters ($1, $2...) to bind --jsonRaw JSON output --dry-runActually run the query then ROLL BACK the transaction (dry run). Constraint errors still surface and rows are returned, but nothing is committed --read-onlyExecute inside a READ-ONLY transaction — PostgreSQL rejects any write at the engine level (this flag can only restrict) --as <AS_ROLE>Execute the query as an anonymous visitor (anon) or application user (authenticated, with --user) instead of admin: verifies an RLS policy as the application would see it. Can only restrict [possible values: anon, authenticated] --user <AS_USER>UUID of the impersonated user (auth.uid()), required with --as authenticated
aura db policy#
Manage RLS policies
Copy
aura db policy [OPTIONS] <COMMAND>
aura db policy list#
List RLS policies
Copy
aura db policy list [OPTIONS]
Option Description --table <TABLE>--allInclude system/storage internal policies --json
aura db policy add#
Create an RLS policy
Copy
aura db policy add [OPTIONS] <TABLE> <NAME> <CMD>
Argument Description <TABLE><NAME><CMD>
Option Description --using-expr <USING_EXPR>--check-expr <CHECK_EXPR>
aura db policy update#
Update expressions on an existing RLS policy (ALTER POLICY)
Copy
aura db policy update [OPTIONS] <TABLE> <NAME>
Argument Description <TABLE><NAME>
Option Description --using-expr <USING_EXPR>--check-expr <CHECK_EXPR>
aura db policy delete#
Delete an RLS policy
Copy
aura db policy delete [OPTIONS] <TABLE> <NAME>
Argument Description <TABLE><NAME>
Option Description -f, --force
aura db function#
Manage project Postgres SQL functions (PL/pgSQL, SQL)
Copy
aura db function [OPTIONS] <COMMAND>
aura db function list#
List Postgres functions in the project schema (name, arguments, security, GRANT)
Copy
aura db function list [OPTIONS]
aura db function create#
Create or replace a Postgres function
Copy
aura db function create [OPTIONS] <NAME>
Argument Description <NAME>Function name (ASCII alphanumeric and '_' — no silent sanitization)
Option Description -b, --body <BODY>Function body (SQL or PL/pgSQL, without enclosing $$) --body-file <BODY_FILE>File containing the function body (alternative to --body) --returns <RETURNS>Postgres return type (e.g. void, text, trigger, setof uuid, numeric(10,2)) [default: void] --language <LANGUAGE>Language: plpgsql | sql [default: plpgsql] --args <ARGS>Arguments in "name:type,name2:type2" format (IN mode only) --security <SECURITY>Security mode: invoker (server default) | definer --grant-execute-to <GRANT_EXECUTE_TO>Roles allowed to EXECUTE (repeatable, or comma-separated)
aura db function drop#
Drop a Postgres function
Copy
aura db function drop [OPTIONS] <NAME>
Argument Description <NAME>
Option Description -f, --force
aura db trigger#
Manage Postgres triggers on a table
Copy
aura db trigger [OPTIONS] <COMMAND>
aura db trigger list#
List triggers on a table
Copy
aura db trigger list [OPTIONS] <TABLE>
Argument Description <TABLE>Table name
aura db trigger create#
Create a trigger on a table
Copy
aura db trigger create [OPTIONS] --function <FUNCTION_NAME> --events <EVENTS> <TABLE> <NAME>
Argument Description <TABLE>Table name owning the trigger <NAME>Trigger name
Option Description --function <FUNCTION_NAME>Postgres function to execute (created via aura db function create, RETURNS trigger) --timing <TIMING>Timing: before | after | instead_of [default: before] --events <EVENTS>Events: insert | update | delete | truncate (repeatable or comma-separated) --for-each <FOR_EACH>Granularity: row | statement (truncate requires statement) [default: row]
aura db trigger drop#
Drop a trigger from a table
Copy
aura db trigger drop [OPTIONS] <TABLE> <NAME>
Argument Description <TABLE>Table name <NAME>Trigger name
Option Description -f, --force
aura db backup#
Manage database backups
Copy
aura db backup [OPTIONS] <COMMAND>
aura db backup list#
List backups
Copy
aura db backup list [OPTIONS]
aura db backup create#
Create a backup
Copy
aura db backup create [OPTIONS]
Option Description --label <LABEL>
aura db backup restore#
Restore from a backup (overwrites current data; --verify-only replays it in a rolled-back transaction)
Copy
aura db backup restore [OPTIONS] <ID>
Option Description --verify-onlyReplay the backup in a transaction that is rolled back: nothing is modified -y, --yesSkip the confirmation prompt (required without a terminal) [alias: --force]
aura db backup download#
Download a backup's SQL dump
Copy
aura db backup download [OPTIONS] <ID>
Option Description -o, --output <OUTPUT>
aura db backup delete#
Delete a backup
Copy
aura db backup delete [OPTIONS] <ID>
Option Description -f, --force
aura db backup schedule#
View or configure the AUTOMATIC backup schedule
Copy
aura db backup schedule [OPTIONS] <COMMAND>
aura db backup schedule get#
Show the automatic backup schedule
Copy
aura db backup schedule get [OPTIONS]
aura db backup schedule set#
Configure the automatic backup schedule
Copy
aura db backup schedule set [OPTIONS]
Option Description --frequency <FREQUENCY>Frequency: hourly | daily | weekly --retention-days <RETENTION_DAYS>Retention in days (integer > 0) --enableEnable automatic backups --disableDisable automatic backups
aura db inspect#
Diagnostics the SQL guard does not allow in raw queries: index usage, table sizes, blocking locks
Copy
aura db inspect [OPTIONS] <KIND>
Argument Description <KIND>What to inspect [possible values: indexes, tables, locks]
aura db connection#
Direct PostgreSQL access (psql, Prisma, Drizzle, pg_dump): host, role and a one-time password
Copy
aura db connection [OPTIONS]
Option Description --new-passwordIssue a new password and print the connection string (revokes the current password) --yesDo not ask for confirmation before replacing an existing password --jsonRaw JSON output
aura db extensions#
List or enable PostgreSQL extensions of the linked project
Copy
aura db extensions [OPTIONS] <COMMAND>
Command Description aura db extensions listList installed extensions aura db extensions enableEnable an allowed extension (pgcrypto, uuid-ossp, pg_trgm, citext, hstore, ltree, unaccent, vector, pg_graphql, btree_gin, btree_gist, fuzzystrmatch, intarray, pg_stat_statements)
aura db extensions list#
List installed extensions
Copy
aura db extensions list [OPTIONS]
aura db extensions enable#
Enable an allowed extension (pgcrypto, uuid-ossp, pg_trgm, citext, hstore, ltree, unaccent, vector, pg_graphql, btree_gin, btree_gist, fuzzystrmatch, intarray, pg_stat_statements)
Copy
aura db extensions enable [OPTIONS] <NAME>
Argument Description <NAME>Extension name
aura db api-keys#
Manage project API keys
Alias: apikeys
Copy
aura db api-keys [OPTIONS] <COMMAND>
aura db api-keys list#
List API keys
Copy
aura db api-keys list [OPTIONS]
aura db api-keys create#
Create a new API key
Copy
aura db api-keys create [OPTIONS] <NAME>
Argument Description <NAME>
Option Description --scope <SCOPE>Scope: anon | authenticated | service_role [default: anon]
aura db api-keys revoke#
Revoke an API key
Copy
aura db api-keys revoke [OPTIONS] <ID>
Option Description -f, --force
aura db restore#
Restore a plain-SQL pg_dump file (statements, $$ bodies, COPY blocks) into the project
Copy
aura db restore [OPTIONS] <FILE>
Argument Description <FILE>SQL file (.sql) to restore
Option Description -f, --forceForce overwrite or execution without interactive confirmation --from <N>Resume at item N of the dump (as printed after an error) [default: 1] --continue-on-errorKeep going after a failed item instead of stopping --source-schema <SOURCE_SCHEMA>Schema qualifier written by pg_dump, removed so objects land in the project schema [default: public] --dry-runParse the dump and print the plan without executing anything
aura connect#
Open an interactive psql console
Copy
aura connect [OPTIONS]
aura migration#
Manage SQL migrations (same commands as aura db migration)
Copy
aura migration [OPTIONS] <COMMAND>
aura migration new#
Create a new migration
Copy
aura migration new [OPTIONS] <NAME>
Argument Description <NAME>
aura migration list#
List all migrations and their status
Copy
aura migration list [OPTIONS]
aura migration down#
Revert the last N applied migrations (default: 1)
Copy
aura migration down [OPTIONS] [N]
Argument Description [N][default: 1]
aura migration repair#
Manually mark a migration as applied or reverted
Copy
aura migration repair [OPTIONS] <NAME>
Argument Description <NAME>Migration file name (e.g. 20240101_create_users.sql)
Option Description --appliedMark as applied --revertedMark as reverted
aura migrate#
Third-party migration and import/export tools (e.g. Supabase)
Copy
aura migrate [OPTIONS] <COMMAND>
Command Description aura migrate export-supabaseExport users (password hashes, OAuth identities) and a pg_dump of the public schema from a Supabase project, for aura auth import and aura db restore
aura migrate export-supabase#
Export users (password hashes, OAuth identities) and a pg_dump of the public schema from a Supabase project, for aura auth import and aura db restore
Copy
aura migrate export-supabase [OPTIONS]
Option Description --db-url <DB_URL>Direct PostgreSQL connection string to Supabase (e.g. postgresql://postgres:password@db.xxx.supabase.co :5432/postgres) --output-dir <OUTPUT_DIR>Destination directory for exported files (default: ./supabase-export) [default: ./supabase-export]
aura projects create#
Create a new project in an organization
Copy
aura projects create [OPTIONS] <NAME>
Argument Description <NAME>Project name
Option Description --engine <ENGINE>Engine (postgres | mongodb, default postgres) --org <ORG>Organization slug (default: default_org_slug from config) --no-waitDo not wait for provisioning to finish (follow later with aura projects wait <id>) --jsonJSON output (id, slug, url, anon_key, service_role_key) for scripting/CI --timeout <TIMEOUT>Maximum provisioning timeout, in seconds [default: 300]
aura branch#
Create, list and delete database branches (a copy of a project, with its own URL and keys)
Copy
aura branch [OPTIONS] <COMMAND>
Command Description aura branch createCreate a branch: a new project cloned from a PostgreSQL project (schema, RLS policies, functions, triggers, views and, unless --no-data, the rows) aura branch listList the branches of a project (or of the whole organization with --all) aura branch deleteDelete a branch and its database
aura branch create#
Create a branch: a new project cloned from a PostgreSQL project (schema, RLS policies, functions, triggers, views and, unless --no-data, the rows)
Copy
aura branch create [OPTIONS] <NAME>
Argument Description <NAME>Branch name (letters, digits, . _ - /; up to 63 characters)
Option Description --from <FROM>Source project: id, slug or name (default: the linked project) --org <ORG>Organization slug, to resolve --from by name (default: default_org_slug from config) --ttl <TTL>Time to live: 72h, 3d, 2w... between 1h and 30d (default 72h) --no-dataClone the schema only, without any row --no-waitDo not wait for the clone to finish (follow it with aura branch list) --jsonJSON output (id, slug, url, anon_key, service_role_key, expires_at) for scripting/CI --timeout <TIMEOUT>Maximum wait, in seconds [default: 900]
aura branch list#
List the branches of a project (or of the whole organization with --all)
Copy
aura branch list [OPTIONS]
Option Description --from <FROM>Source project: id, slug or name (default: the linked project) --org <ORG>Organization slug (default: default_org_slug from config) --allList every branch of the organization --jsonRaw JSON output (for scripting/CI)
aura branch delete#
Delete a branch and its database
Copy
aura branch delete [OPTIONS] <NAME>
Argument Description <NAME>Branch name
Option Description --from <FROM>Source project: id, slug or name (default: the linked project) --org <ORG>Organization slug (default: default_org_slug from config) -f, --forceSkip the confirmation prompt
aura advisor#
Run security and architecture advisor audit (CI/CD check)
Copy
aura advisor [OPTIONS] <COMMAND>
aura advisor audit#
Run security and architecture audits
Copy
aura advisor audit [OPTIONS]
Option Description --strictFail with non-zero exit code if critical security issues are detected --jsonRaw JSON output (for scripting/CI)