KosmoKrator

data

Supabase CLI for AI Agents

Use the Supabase CLI from KosmoKrator to call Supabase tools headlessly, return JSON, inspect schemas, and automate workflows from coding agents, scripts, and CI.

Supabase CLI Setup

Supabase can be configured headlessly with `kosmokrator integrations:configure supabase`.

Install, configure, and verify
# Install KosmoKrator first if it is not available on PATH.
curl -fsSL https://raw.githubusercontent.com/OpenCompanyApp/kosmokrator/main/install.sh | bash

# Configure and verify this integration.
kosmokrator integrations:configure supabase --enable --read allow --write ask --json
kosmokrator integrations:doctor supabase --json
kosmokrator integrations:status --json

Credentials

Authentication type: Bearer token bearer_token. Configure credentials once, then reuse the same stored profile from scripts, coding CLIs, Lua, and MCP.

No credentials are required.

Command Patterns

The generic command is stable across every integration. The provider shortcut is shorter for humans.

Generic CLI call
kosmo integrations:call supabase.supabase_get_current_user '{}' --json
Provider shortcut
kosmo integrations:supabase supabase_get_current_user '{}' --json

Discovery

These commands return structured output for coding agents that need to inspect capabilities before choosing a function.

Discovery commands
kosmo integrations:docs supabase --json
kosmo integrations:docs supabase.supabase_get_current_user --json
kosmo integrations:schema supabase.supabase_get_current_user --json
kosmo integrations:search "Supabase" --json
kosmo integrations:list --json

Automation Contexts

The same configured command surface works in these environments. The command does not change unless the host wrapper, credentials, or permissions change.

CLI Functions

Every function below can be called headlessly. Commands are highlighted, copyable, and scroll horizontally when payloads are long.

supabase.supabase_get_current_user

Get the currently authenticated Supabase user profile information.

Read read
Parameters
none
Generic call
kosmo integrations:call supabase.supabase_get_current_user '{}' --json
Shortcut
kosmo integrations:supabase supabase_get_current_user '{}' --json

supabase.supabase_list_projects

List all Supabase projects in the organization. Returns project IDs, names, and regions.

Read read
Parameters
none
Generic call
kosmo integrations:call supabase.supabase_list_projects '{}' --json
Shortcut
kosmo integrations:supabase supabase_list_projects '{}' --json

supabase.supabase_get_project

Get details of a specific Supabase project by its reference ID.

Read read
Parameters
project_ref
Generic call
kosmo integrations:call supabase.supabase_get_project '{"project_ref":"example_project_ref"}' --json
Shortcut
kosmo integrations:supabase supabase_get_project '{"project_ref":"example_project_ref"}' --json

supabase.supabase_create_project

Create a Supabase project in an organization using the Management API.

Write write
Parameters
name, db_pass, organization_slug, region, desired_instance_size, body
Generic call
kosmo integrations:call supabase.supabase_create_project '{"name":"example_name","db_pass":"example_db_pass","organization_slug":"example_organization_slug","region":"example_region","desired_instance_size":"example_desired_instance_size","body":"example_body"}' --json
Shortcut
kosmo integrations:supabase supabase_create_project '{"name":"example_name","db_pass":"example_db_pass","organization_slug":"example_organization_slug","region":"example_region","desired_instance_size":"example_desired_instance_size","body":"example_body"}' --json

supabase.supabase_delete_project

Delete a Supabase project by project ref.

Write write
Parameters
project_ref
Generic call
kosmo integrations:call supabase.supabase_delete_project '{"project_ref":"example_project_ref"}' --json
Shortcut
kosmo integrations:supabase supabase_delete_project '{"project_ref":"example_project_ref"}' --json

supabase.supabase_list_organizations

List Supabase organizations visible to the authenticated account.

Read read
Parameters
none
Generic call
kosmo integrations:call supabase.supabase_list_organizations '{}' --json
Shortcut
kosmo integrations:supabase supabase_list_organizations '{}' --json

supabase.supabase_get_organization

Get a Supabase organization by slug.

Read read
Parameters
slug
Generic call
kosmo integrations:call supabase.supabase_get_organization '{"slug":"example_slug"}' --json
Shortcut
kosmo integrations:supabase supabase_get_organization '{"slug":"example_slug"}' --json

supabase.supabase_list_organization_members

List members of a Supabase organization.

Read read
Parameters
slug
Generic call
kosmo integrations:call supabase.supabase_list_organization_members '{"slug":"example_slug"}' --json
Shortcut
kosmo integrations:supabase supabase_list_organization_members '{"slug":"example_slug"}' --json

supabase.supabase_list_organization_projects

List Supabase projects for an organization.

Read read
Parameters
slug, offset, limit
Generic call
kosmo integrations:call supabase.supabase_list_organization_projects '{"slug":"example_slug","offset":1,"limit":1}' --json
Shortcut
kosmo integrations:supabase supabase_list_organization_projects '{"slug":"example_slug","offset":1,"limit":1}' --json

supabase.supabase_get_project_api_keys

Get API keys for a Supabase project.

Read read
Parameters
project_ref
Generic call
kosmo integrations:call supabase.supabase_get_project_api_keys '{"project_ref":"example_project_ref"}' --json
Shortcut
kosmo integrations:supabase supabase_get_project_api_keys '{"project_ref":"example_project_ref"}' --json

Function Schemas

Use these parameter tables when building CLI payloads without calling integrations:schema first.

supabase.supabase_get_current_user 0 parameters
Schema command
kosmo integrations:schema supabase.supabase_get_current_user --json
ParameterTypeRequiredDescription
No parameters.
supabase.supabase_list_projects 0 parameters
Schema command
kosmo integrations:schema supabase.supabase_list_projects --json
ParameterTypeRequiredDescription
No parameters.
supabase.supabase_get_project 1 parameters
Schema command
kosmo integrations:schema supabase.supabase_get_project --json
ParameterTypeRequiredDescription
project_ref string yes The project reference ID.
supabase.supabase_create_project 6 parameters
Schema command
kosmo integrations:schema supabase.supabase_create_project --json
ParameterTypeRequiredDescription
name string yes Project name.
db_pass string yes Initial database password for the project.
organization_slug string yes Organization slug that owns the project.
region string no Optional legacy region value accepted by Supabase.
desired_instance_size string no Optional compute size accepted by Supabase.
body object no Optional full request body. Overrides individual fields when present.
supabase.supabase_delete_project 1 parameters
Schema command
kosmo integrations:schema supabase.supabase_delete_project --json
ParameterTypeRequiredDescription
project_ref string yes Project ref.
supabase.supabase_list_organizations 0 parameters
Schema command
kosmo integrations:schema supabase.supabase_list_organizations --json
ParameterTypeRequiredDescription
No parameters.
supabase.supabase_get_organization 1 parameters
Schema command
kosmo integrations:schema supabase.supabase_get_organization --json
ParameterTypeRequiredDescription
slug string yes Organization slug.
supabase.supabase_list_organization_members 1 parameters
Schema command
kosmo integrations:schema supabase.supabase_list_organization_members --json
ParameterTypeRequiredDescription
slug string yes Organization slug.
supabase.supabase_list_organization_projects 3 parameters
Schema command
kosmo integrations:schema supabase.supabase_list_organization_projects --json
ParameterTypeRequiredDescription
slug string yes Organization slug.
offset integer no Offset for pagination.
limit integer no Maximum number of projects to return.
supabase.supabase_get_project_api_keys 1 parameters
Schema command
kosmo integrations:schema supabase.supabase_get_project_api_keys --json
ParameterTypeRequiredDescription
project_ref string yes Project ref.

Permissions

Headless calls still follow the integration read/write permission policy. Configure read/write defaults with integrations:configure. Add --force only for trusted automation that should bypass that policy.