data
CockroachDB CLI for CI
Use the CockroachDB CLI for CI with headless JSON commands, schema discovery, credentials, and permission controls.
7 functions 6 read 1 write Bearer token auth
CockroachDB CLI for CI
Run integration calls from CI jobs with JSON output, explicit credentials, and predictable exit status.
Use this shape when a pipeline needs to read or update an external service. The CockroachDB CLI uses the same integration registry as the TUI, Lua runtime, and MCP gateway, but returns predictable command output for automation.
Command Shape
# CockroachDB CLI for CI
kosmokrator integrations:configure cockroachdb --set access_token="$COCKROACHDB_ACCESS_TOKEN" --enable --read allow --write ask --json
kosmo integrations:call cockroachdb.cockroachdb_list_clusters '{}' --json Discovery Before Execution
Agents and scripts can inspect CockroachDB docs and schemas before choosing a function.
kosmo integrations:docs cockroachdb --json
kosmo integrations:docs cockroachdb.cockroachdb_list_clusters --json
kosmo integrations:schema cockroachdb.cockroachdb_list_clusters --json
kosmo integrations:search "CockroachDB" --json
kosmo integrations:list --json Useful CockroachDB CLI Functions
| Function | Type | Parameters | Description |
|---|---|---|---|
cockroachdb.cockroachdb_list_clusters | Read | none | List all CockroachDB clusters in the organization. Returns cluster IDs, names, status, cloud provider, and regions. |
cockroachdb.cockroachdb_get_cluster | Read | cluster_id | Get details for a specific CockroachDB cluster by ID. Returns full cluster information including configuration, nodes, and connection strings. |
cockroachdb.cockroachdb_create_cluster | Write | name, cloud_provider, region, plan, spend_limit, cluster_version | Create a new CockroachDB cluster. Requires a name, cloud provider, and region configuration. |
cockroachdb.cockroachdb_list_databases | Read | cluster_id | List all databases in a CockroachDB cluster. Returns database names, sizes, and table counts. |
cockroachdb.cockroachdb_get_database | Read | cluster_id, database_name | Get details for a specific database in a CockroachDB cluster. Returns table list, sizes, and configuration. |
cockroachdb.cockroachdb_list_users | Read | cluster_id | List all SQL users in a CockroachDB cluster. Returns usernames and privileges. |
cockroachdb.cockroachdb_get_current_user | Read | none | Get information about the current authenticated CockroachDB Cloud user, including email, name, and organization role. |
Automation Notes
- Use
--jsonfor machine-readable output. - Keep credentials out of argv by using environment variables or stored KosmoKrator configuration.
- Configure read/write policy before unattended runs; use
--forceonly for trusted automation. - Use the MCP gateway instead when the agent needs dynamic tool discovery inside a conversation.