productivity
Auth0 CLI for AI Agents
Use the Auth0 CLI from KosmoKrator to call Auth0 tools headlessly, return JSON, inspect schemas, and automate workflows from coding agents, scripts, and CI.Auth0 CLI Setup
Auth0 can be configured headlessly with `kosmokrator integrations:configure auth-zero`.
# 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 auth-zero --set access_token="$AUTH_ZERO_ACCESS_TOKEN" --set domain="$AUTH_ZERO_DOMAIN" --enable --read allow --write ask --json
kosmokrator integrations:doctor auth-zero --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.
| Key | Env var | Type | Required | Label |
|---|---|---|---|---|
access_token | AUTH_ZERO_ACCESS_TOKEN | Secret secret | yes | Access Token |
domain | AUTH_ZERO_DOMAIN | Text text | yes | Tenant Domain |
Command Patterns
The generic command is stable across every integration. The provider shortcut is shorter for humans.
kosmo integrations:call auth-zero.auth_zero_list_users '{"page":1,"per_page":1,"q":"example_q","sort":"example_sort"}' --json kosmo integrations:auth-zero auth_zero_list_users '{"page":1,"per_page":1,"q":"example_q","sort":"example_sort"}' --json Discovery
These commands return structured output for coding agents that need to inspect capabilities before choosing a function.
kosmo integrations:docs auth-zero --json
kosmo integrations:docs auth-zero.auth_zero_list_users --json
kosmo integrations:schema auth-zero.auth_zero_list_users --json
kosmo integrations:search "Auth0" --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.
auth-zero.auth_zero_list_users
List users in the Auth0 tenant. Supports search with Lucene syntax, pagination, and sorting.
read - Parameters
- page, per_page, q, sort
kosmo integrations:call auth-zero.auth_zero_list_users '{"page":1,"per_page":1,"q":"example_q","sort":"example_sort"}' --json kosmo integrations:auth-zero auth_zero_list_users '{"page":1,"per_page":1,"q":"example_q","sort":"example_sort"}' --json auth-zero.auth_zero_get_user
Retrieve a single Auth0 user by their user ID (e.g. "auth0|abc123").
read - Parameters
- id
kosmo integrations:call auth-zero.auth_zero_get_user '{"id":"example_id"}' --json kosmo integrations:auth-zero auth_zero_get_user '{"id":"example_id"}' --json auth-zero.auth_zero_create_user
Create a new user in Auth0. Requires email, password, and the connection name (database connection).
write - Parameters
- email, password, connection, name
kosmo integrations:call auth-zero.auth_zero_create_user '{"email":"example_email","password":"example_password","connection":"example_connection","name":"example_name"}' --json kosmo integrations:auth-zero auth_zero_create_user '{"email":"example_email","password":"example_password","connection":"example_connection","name":"example_name"}' --json auth-zero.auth_zero_list_connections
List identity connections configured in the Auth0 tenant. Optionally filter by strategy (e.g. "auth0", "google-oauth2").
read - Parameters
- strategy
kosmo integrations:call auth-zero.auth_zero_list_connections '{"strategy":"example_strategy"}' --json kosmo integrations:auth-zero auth_zero_list_connections '{"strategy":"example_strategy"}' --json auth-zero.auth_zero_list_roles
List roles defined in the Auth0 tenant with optional pagination.
read - Parameters
- page, per_page
kosmo integrations:call auth-zero.auth_zero_list_roles '{"page":1,"per_page":1}' --json kosmo integrations:auth-zero auth_zero_list_roles '{"page":1,"per_page":1}' --json auth-zero.auth_zero_get_tenant_settings
Retrieve the Auth0 tenant settings (session lifetime, idle timeout, default directory, etc.).
read - Parameters
- none
kosmo integrations:call auth-zero.auth_zero_get_tenant_settings '{}' --json kosmo integrations:auth-zero auth_zero_get_tenant_settings '{}' --json auth-zero.auth_zero_get_current_user
Run a lightweight Auth0 Management API health check by retrieving tenant settings.
read - Parameters
- none
kosmo integrations:call auth-zero.auth_zero_get_current_user '{}' --json kosmo integrations:auth-zero auth_zero_get_current_user '{}' --json Function Schemas
Use these parameter tables when building CLI payloads without calling integrations:schema first.
auth-zero.auth_zero_list_users 4 parameters
kosmo integrations:schema auth-zero.auth_zero_list_users --json | Parameter | Type | Required | Description |
|---|---|---|---|
page | integer | no | Page index (zero-based). Default: 0. |
per_page | integer | no | Number of results per page. Default: 50, max: 100. |
q | string | no | Lucene search query (e.g. "email:*@example.com"). |
sort | string | no | Field to sort by, with optional direction (e.g. "created_at:-1" or "name:1"). |
auth-zero.auth_zero_get_user 1 parameters
kosmo integrations:schema auth-zero.auth_zero_get_user --json | Parameter | Type | Required | Description |
|---|---|---|---|
id | string | yes | The Auth0 user identifier (e.g. "auth0|abc123", "google-oauth2|xyz"). |
auth-zero.auth_zero_create_user 4 parameters
kosmo integrations:schema auth-zero.auth_zero_create_user --json | Parameter | Type | Required | Description |
|---|---|---|---|
email | string | yes | Email address for the new user. |
password | string | yes | Password for the new user (must meet connection requirements). |
connection | string | yes | The database connection name to create the user in (e.g. "Username-Password-Authentication"). |
name | string | no | Full name of the user. |
auth-zero.auth_zero_list_connections 1 parameters
kosmo integrations:schema auth-zero.auth_zero_list_connections --json | Parameter | Type | Required | Description |
|---|---|---|---|
strategy | string | no | Filter by connection strategy (e.g. "auth0", "google-oauth2", "samlp", "oidc"). |
auth-zero.auth_zero_list_roles 2 parameters
kosmo integrations:schema auth-zero.auth_zero_list_roles --json | Parameter | Type | Required | Description |
|---|---|---|---|
page | integer | no | Page index (zero-based). Default: 0. |
per_page | integer | no | Number of results per page. Default: 50. |
auth-zero.auth_zero_get_tenant_settings 0 parameters
kosmo integrations:schema auth-zero.auth_zero_get_tenant_settings --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
auth-zero.auth_zero_get_current_user 0 parameters
kosmo integrations:schema auth-zero.auth_zero_get_current_user --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
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.