Skip to content

API reference

This interactive reference is generated directly from the control plane's OpenAPI 3.1 specification (apps/control-plane/openapi.json) — the same spec served at runtime from GET /api/v1/openapi.json and published as a release asset. It is always in sync with the implementation (a CI drift gate enforces it).

For authentication, error envelopes, and pagination conventions, read the API overview first.

Multi-tenant AI agent platform management API.

Authentication

  • Human operators — OIDC browser flow via GET /auth/login/auth/callback. Session cookie is set server-side.
  • CLI operators — Device authorization grant via POST /auth/device. The CLI opens the returned verificationUri in the operator's browser, polls GET /auth/device/token, and persists the issued token in ~/.config/opencrane/credentials.json.
  • Automation / CI — Bearer token via the OPENCRANE_TOKEN environment variable, validated against the OPENCRANE_API_TOKEN server-side env var.
  • Endpoints tagged Auth and Meta (/auth/*, /openapi.json) require no credentials.

Servers

/api/v1Versioned API prefix

Platform DNS


Show the configured platform DNS-01 issuer (ClusterIssuer or namespaced Issuer)

GET
/platform/dns

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Query Parameters

issuerName
Type
string

Responses

Current issuer status.

application/json
JSON
{
  
"configured": true,
  
"issuerName": "string",
  
"issuerKind": "string",
  
"issuerNamespace": "string",
  
"provider": "string",
  
"email": "string",
  
"server": "string"
}

Playground

Authorization
Variables
Key
Value

Samples


Configure the platform DNS-01 issuer for wildcard TLS (ClusterIssuer or namespaced Issuer)

PUT
/platform/dns

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Request Body

application/json
JSON
{
  
"provider": "string",
  
"zone": "string",
  
"email": "string",
  
"server": "string",
  
"issuerName": "string",
  
"apiToken": "string",
  
"solverConfig": {
  
  
"additionalProperties": "string"
  
}
}

Responses

Issuer configured.

application/json
JSON
{
  
"status": "string",
  
"issuerName": "string",
  
"issuerKind": "string",
  
"issuerNamespace": "string",
  
"provider": "string",
  
"zone": "string",
  
"secretName": "string"
}

Playground

Authorization
Body

Samples


Show the fleet awareness contract rollout state

GET
/awareness/rollout

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Responses

Current rollout state.

application/json
JSON
{
  
"targetVersion": "string",
  
"stableVersion": "string",
  
"waves": [
  
  
"string"
  
],
  
"promotedWaves": [
  
  
"string"
  
],
  
"shadowMode": true,
  
"nextWave": "string"
}

Playground

Authorization

Samples


Define (or redefine) the awareness rollout; resets the frontier

PUT
/awareness/rollout

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Request Body

application/json
JSON
{
  
"targetVersion": "string",
  
"stableVersion": "string",
  
"waves": [
  
  
"string"
  
],
  
"shadowMode": true
}

Responses

Rollout defined.

application/json
JSON
{
  
"targetVersion": "string",
  
"stableVersion": "string",
  
"waves": [
  
  
"string"
  
],
  
"promotedWaves": [
  
  
"string"
  
],
  
"shadowMode": true,
  
"nextWave": "string"
}

Playground

Authorization
Body

Samples


Advance the rollout frontier (one wave, or up to a named wave)

POST
/awareness/rollout/promote

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Request Body

application/json
JSON
{
  
"wave": "string"
}

Responses

Frontier advanced.

application/json
JSON
{
  
"targetVersion": "string",
  
"stableVersion": "string",
  
"waves": [
  
  
"string"
  
],
  
"promotedWaves": [
  
  
"string"
  
],
  
"shadowMode": true,
  
"nextWave": "string"
}

Playground

Authorization
Body

Samples


One-step rollback: return every wave to the stable version

POST
/awareness/rollout/rollback

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Responses

Rolled back.

application/json
JSON
{
  
"targetVersion": "string",
  
"stableVersion": "string",
  
"waves": [
  
  
"string"
  
],
  
"promotedWaves": [
  
  
"string"
  
],
  
"shadowMode": true,
  
"nextWave": "string"
}

Playground

Authorization

Samples


Resolve the awareness contract version a tenant runs

GET
/awareness/rollout/resolve/{tenant}

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

tenant*
Type
string
Required

Responses

Resolved version.

application/json
JSON
{
  
"tenant": "string",
  
"version": "string",
  
"promoted": true,
  
"shadow": true,
  
"wave": "string"
}

Playground

Authorization
Variables
Key
Value

Samples


Fleet participation, drift, and policy-violation monitoring

GET
/awareness/participation

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Query Parameters

severity
Type
string
Valid values
"critical""warning"

Responses

Fleet participation report.

application/json
JSON
{
  
"total": 0,
  
"participating": 0,
  
"drifted": 0,
  
"critical": 0,
  
"warning": 0,
  
"tenants": [
  
  
{
  
  
  
"tenant": "string",
  
  
  
"lastSeenAt": "string",
  
  
  
"runningContractVersion": "string",
  
  
  
"expectedContractVersion": "string",
  
  
  
"participating": true,
  
  
  
"drifted": true,
  
  
  
"policyViolations": 0,
  
  
  
"severity": "string"
  
  
}
  
]
}

Playground

Authorization
Variables
Key
Value

Samples


Inspect a chat-window session's awareness scope binding

GET
/sessions/{sessionKey}/scope

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

sessionKey*
Type
string
Required

Responses

Current session scope binding.

application/json
JSON
{
  
"sessionKey": "string",
  
"principal": "string",
  
"scopes": [
  
  
{
  
  
  
"scope": "string",
  
  
  
"payloadId": "string"
  
  
}
  
],
  
"createdAt": "string",
  
"updatedAt": "string"
}

Playground

Authorization
Variables
Key
Value

Samples


Bind a session scope (CP intersects with the principal's entitlements)

PUT
/sessions/{sessionKey}/scope

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

sessionKey*
Type
string
Required

Request Body

application/json
JSON
{
  
"principal": "string",
  
"scopes": [
  
  
{
  
  
  
"scope": "string",
  
  
  
"payloadId": "string"
  
  
}
  
]
}

Responses

Authorised binding; rejected lists any over-scope dropped.

application/json
JSON
{
  
"sessionKey": "string",
  
"principal": "string",
  
"scopes": [
  
  
{
  
  
  
"scope": "string",
  
  
  
"payloadId": "string"
  
  
}
  
],
  
"createdAt": "string",
  
"updatedAt": "string",
  
"rejected": [
  
  
{
  
  
  
"scope": "string",
  
  
  
"payloadId": "string"
  
  
}
  
]
}

Playground

Authorization
Variables
Key
Value
Body

Samples


Clear a session's scope binding

DELETE
/sessions/{sessionKey}/scope

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

sessionKey*
Type
string
Required

Responses

Binding cleared.

application/json
JSON
{
  
"sessionKey": "string",
  
"cleared": true
}

Playground

Authorization
Variables
Key
Value

Samples


List all tenants

GET
/tenants

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Responses

Tenant list.

application/json
JSON
[
  
{
  
  
"name": "string",
  
  
"displayName": "string",
  
  
"email": "string",
  
  
"team": "string",
  
  
"phase": "string",
  
  
"ingressHost": "string",
  
  
"createdAt": "string"
  
}
]

Playground

Authorization

Samples


Create a new tenant (dual-write: K8s CRD + database)

POST
/tenants

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Request Body

application/json
JSON
{
  
"name": "string",
  
"displayName": "string",
  
"email": "string",
  
"team": "string",
  
"monthlyBudgetUsd": 0,
  
"resources": {
  
},
  
"skillAllowlist": [
  
  
"string"
  
],
  
"policyRef": "string"
}

Responses

Tenant created.

application/json
JSON
{
  
"name": "string",
  
"status": "string"
}

Playground

Authorization
Body

Samples


Detect drift between Tenant CRDs and PostgreSQL projection rows

GET
/tenants/drift

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Responses

Drift report.

application/json
JSON
{
}

Playground

Authorization

Samples


Repair Tenant projection rows from CRD source of truth

POST
/tenants/repair

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Query Parameters

dryRun

When true (default), report planned changes without applying them.

Type
boolean
Default
true

Responses

Repair report.

application/json
JSON
{
}

Playground

Authorization
Variables
Key
Value

Samples


Get a single tenant by name

GET
/tenants/{name}

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

name*
Type
string
Required

Responses

Tenant detail.

application/json
JSON
{
  
"name": "string",
  
"displayName": "string",
  
"email": "string",
  
"team": "string",
  
"phase": "string",
  
"ingressHost": "string",
  
"createdAt": "string"
}

Playground

Authorization
Variables
Key
Value

Samples


Update a tenant (dual-write: K8s CRD + database)

PUT
/tenants/{name}

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

name*
Type
string
Required

Request Body

application/json
JSON
{
  
"displayName": "string",
  
"email": "string",
  
"team": "string",
  
"monthlyBudgetUsd": 0,
  
"resources": {
  
},
  
"skillAllowlist": [
  
  
"string"
  
],
  
"policyRef": "string"
}

Responses

Tenant updated.

application/json
JSON
{
  
"name": "string",
  
"status": "string"
}

Playground

Authorization
Variables
Key
Value
Body

Samples


Delete a tenant (dual-write: K8s CRD + database)

DELETE
/tenants/{name}

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

name*
Type
string
Required

Responses

Tenant deleted.

application/json
JSON
{
  
"name": "string",
  
"status": "string"
}

Playground

Authorization
Variables
Key
Value

Samples


Suspend a tenant (scale deployment to zero)

POST
/tenants/{name}/suspend

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

name*
Type
string
Required

Responses

Tenant suspended.

application/json
JSON
{
  
"name": "string",
  
"status": "string"
}

Playground

Authorization
Variables
Key
Value

Samples


Resume a suspended tenant

POST
/tenants/{name}/resume

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

name*
Type
string
Required

Responses

Tenant resumed.

application/json
JSON
{
  
"name": "string",
  
"status": "string"
}

Playground

Authorization
Variables
Key
Value

Samples


Get dataset memberships for a tenant

GET
/tenants/{name}/datasets

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

name*
Type
string
Required

Responses

Dataset memberships.

application/json
JSON
{
  
"org": [
  
  
"string"
  
],
  
"team": [
  
  
"string"
  
],
  
"project": [
  
  
"string"
  
],
  
"personal": [
  
  
"string"
  
]
}

Playground

Authorization
Variables
Key
Value

Samples


Update dataset memberships for a tenant

PUT
/tenants/{name}/datasets

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

name*
Type
string
Required

Request Body

application/json
JSON
{
  
"org": [
  
  
"string"
  
],
  
"team": [
  
  
"string"
  
],
  
"project": [
  
  
"string"
  
],
  
"personal": [
  
  
"string"
  
]
}

Responses

Dataset memberships updated.

application/json
JSON
{
  
"org": [
  
  
"string"
  
],
  
"team": [
  
  
"string"
  
],
  
"project": [
  
  
"string"
  
],
  
"personal": [
  
  
"string"
  
]
}

Playground

Authorization
Variables
Key
Value
Body

Samples


Compile the effective awareness, MCP, and skill contract for a tenant

GET
/tenants/{name}/effective-contract

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

name*
Type
string
Required

Responses

Effective contract.

application/json
JSON
{
  
"contractId": "string",
  
"contractVersion": "string",
  
"tenant": {
  
},
  
"awareness": {
  
},
  
"mcp": {
  
},
  
"skills": {
  
}
}

Playground

Authorization
Variables
Key
Value

Samples


List all access policies

GET
/policies

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Responses

Policy list.

application/json
JSON
[
  
{
  
  
"name": "string",
  
  
"namespace": "string",
  
  
"tenantSelector": {
  
  
},
  
  
"domains": [
  
  
  
"string"
  
  
],
  
  
"egressRules": [
  
  
  
{
  
  
  
}
  
  
],
  
  
"mcpServers": {
  
  
},
  
  
"createdAt": "string"
  
}
]

Playground

Authorization

Samples


Create an access policy (dual-write: K8s CRD + database)

POST
/policies

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Request Body

application/json
JSON
{
}

Responses

Policy created.

application/json
JSON
{
  
"name": "string",
  
"status": "string"
}

Playground

Authorization
Body

Samples


Detect drift between AccessPolicy CRDs and PostgreSQL projection rows

GET
/policies/drift

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Responses

Drift report.

application/json
JSON
{
}

Playground

Authorization

Samples


Repair AccessPolicy projection rows from CRD source of truth

POST
/policies/repair

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Query Parameters

dryRun
Type
boolean
Default
true

Responses

Repair report.

application/json
JSON
{
}

Playground

Authorization
Variables
Key
Value

Samples


Get a single access policy by name

GET
/policies/{name}

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

name*
Type
string
Required

Responses

Policy detail.

application/json
JSON
{
  
"name": "string",
  
"namespace": "string",
  
"tenantSelector": {
  
},
  
"domains": [
  
  
"string"
  
],
  
"egressRules": [
  
  
{
  
  
}
  
],
  
"mcpServers": {
  
},
  
"createdAt": "string"
}

Playground

Authorization
Variables
Key
Value

Samples


Update an access policy

PUT
/policies/{name}

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

name*
Type
string
Required

Request Body

application/json
JSON
{
}

Responses

Policy updated.

application/json
JSON
{
}

Playground

Authorization
Variables
Key
Value
Body

Samples


Delete an access policy

DELETE
/policies/{name}

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

name*
Type
string
Required

Responses

Policy deleted.

application/json
JSON
{
  
"name": "string",
  
"status": "string"
}

Playground

Authorization
Variables
Key
Value

Samples


List all cluster tenants

GET
/cluster-tenants

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Responses

Cluster tenant list.

application/json
JSON
[
  
{
  
  
"name": "string",
  
  
"displayName": "string",
  
  
"baseDomain": "string",
  
  
"isolationTier": "string",
  
  
"compute": {
  
  
  
"mode": "string",
  
  
  
"nodePool": "string"
  
  
},
  
  
"resources": {
  
  
  
"quota": {
  
  
  
  
"cpu": "string",
  
  
  
  
"memory": "string",
  
  
  
  
"pods": 0,
  
  
  
  
"storage": "string",
  
  
  
  
"gpu": 0
  
  
  
}
  
  
},
  
  
"status": {
  
  
  
"phase": "string",
  
  
  
"message": "string",
  
  
  
"boundNamespace": "string",
  
  
  
"provisioner": "string"
  
  
}
  
}
]

Playground

Authorization

Samples


Create a cluster tenant (rejects an isolation tier no provisioner can serve)

POST
/cluster-tenants

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Request Body

application/json
JSON
{
  
"name": "string",
  
"displayName": "string",
  
"baseDomain": "string",
  
"isolationTier": "string",
  
"compute": {
  
  
"mode": "string",
  
  
"nodePool": "string"
  
},
  
"resources": {
  
  
"quota": {
  
  
  
"cpu": "string",
  
  
  
"memory": "string",
  
  
  
"pods": 0,
  
  
  
"storage": "string",
  
  
  
"gpu": 0
  
  
}
  
}
}

Responses

Cluster tenant created.

application/json
JSON
{
  
"name": "string",
  
"displayName": "string",
  
"baseDomain": "string",
  
"isolationTier": "string",
  
"compute": {
  
  
"mode": "string",
  
  
"nodePool": "string"
  
},
  
"resources": {
  
  
"quota": {
  
  
  
"cpu": "string",
  
  
  
"memory": "string",
  
  
  
"pods": 0,
  
  
  
"storage": "string",
  
  
  
"gpu": 0
  
  
}
  
},
  
"status": {
  
  
"phase": "string",
  
  
"message": "string",
  
  
"boundNamespace": "string",
  
  
"provisioner": "string"
  
}
}

Playground

Authorization
Body

Samples


Get a single cluster tenant by name

GET
/cluster-tenants/{name}

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

name*
Type
string
Required

Responses

Cluster tenant detail.

application/json
JSON
{
  
"name": "string",
  
"displayName": "string",
  
"baseDomain": "string",
  
"isolationTier": "string",
  
"compute": {
  
  
"mode": "string",
  
  
"nodePool": "string"
  
},
  
"resources": {
  
  
"quota": {
  
  
  
"cpu": "string",
  
  
  
"memory": "string",
  
  
  
"pods": 0,
  
  
  
"storage": "string",
  
  
  
"gpu": 0
  
  
}
  
},
  
"status": {
  
  
"phase": "string",
  
  
"message": "string",
  
  
"boundNamespace": "string",
  
  
"provisioner": "string"
  
}
}

Playground

Authorization
Variables
Key
Value

Samples


Update a cluster tenant (re-gates the isolation tier when it changes)

PUT
/cluster-tenants/{name}

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

name*
Type
string
Required

Request Body

application/json
JSON
{
}

Responses

Cluster tenant updated.

application/json
JSON
{
  
"name": "string",
  
"displayName": "string",
  
"baseDomain": "string",
  
"isolationTier": "string",
  
"compute": {
  
  
"mode": "string",
  
  
"nodePool": "string"
  
},
  
"resources": {
  
  
"quota": {
  
  
  
"cpu": "string",
  
  
  
"memory": "string",
  
  
  
"pods": 0,
  
  
  
"storage": "string",
  
  
  
"gpu": 0
  
  
}
  
},
  
"status": {
  
  
"phase": "string",
  
  
"message": "string",
  
  
"boundNamespace": "string",
  
  
"provisioner": "string"
  
}
}

Playground

Authorization
Variables
Key
Value
Body

Samples


Delete a cluster tenant

DELETE
/cluster-tenants/{name}

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

name*
Type
string
Required

Responses

Cluster tenant deleted.

application/json
JSON
{
  
"name": "string",
  
"status": "string"
}

Playground

Authorization
Variables
Key
Value

Samples


Get the observed status of a cluster tenant

GET
/cluster-tenants/{name}/status

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

name*
Type
string
Required

Responses

Cluster tenant status.

application/json
JSON
{
  
"phase": "string",
  
"message": "string",
  
"boundNamespace": "string",
  
"provisioner": "string"
}

Playground

Authorization
Variables
Key
Value

Samples


List all MCP servers with grants and credentials

GET
/mcp-servers

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Responses

MCP server list.

application/json
JSON
[
  
{
  
  
"id": "string",
  
  
"name": "string",
  
  
"endpoint": "string",
  
  
"transport": "string",
  
  
"grants": [
  
  
  
{
  
  
  
}
  
  
],
  
  
"credentials": [
  
  
  
{
  
  
  
  
"id": "string",
  
  
  
  
"displayName": "string",
  
  
  
  
"brokeringMode": "string",
  
  
  
  
"secretRef": "string"
  
  
  
}
  
  
]
  
}
]

Playground

Authorization

Samples


Create a new MCP server

POST
/mcp-servers

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Request Body

application/json
JSON
{
  
"name": "string",
  
"endpoint": "string",
  
"transport": "string",
  
"grants": [
  
  
{
  
  
}
  
],
  
"credentials": [
  
  
{
  
  
}
  
]
}

Responses

MCP server created.

application/json
JSON
{
  
"id": "string",
  
"name": "string",
  
"endpoint": "string",
  
"transport": "string",
  
"grants": [
  
  
{
  
  
}
  
],
  
"credentials": [
  
  
{
  
  
  
"id": "string",
  
  
  
"displayName": "string",
  
  
  
"brokeringMode": "string",
  
  
  
"secretRef": "string"
  
  
}
  
]
}

Playground

Authorization
Body

Samples


Get a single MCP server by identifier

GET
/mcp-servers/{id}

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

id*
Type
string
Required

Responses

MCP server detail.

application/json
JSON
{
  
"id": "string",
  
"name": "string",
  
"endpoint": "string",
  
"transport": "string",
  
"grants": [
  
  
{
  
  
}
  
],
  
"credentials": [
  
  
{
  
  
  
"id": "string",
  
  
  
"displayName": "string",
  
  
  
"brokeringMode": "string",
  
  
  
"secretRef": "string"
  
  
}
  
]
}

Playground

Authorization
Variables
Key
Value

Samples


Update an MCP server and fully replace grants and credentials

PUT
/mcp-servers/{id}

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

id*
Type
string
Required

Request Body

application/json
JSON
{
}

Responses

MCP server updated.

application/json
JSON
{
  
"id": "string",
  
"name": "string",
  
"endpoint": "string",
  
"transport": "string",
  
"grants": [
  
  
{
  
  
}
  
],
  
"credentials": [
  
  
{
  
  
  
"id": "string",
  
  
  
"displayName": "string",
  
  
  
"brokeringMode": "string",
  
  
  
"secretRef": "string"
  
  
}
  
]
}

Playground

Authorization
Variables
Key
Value
Body

Samples


Delete an MCP server and its linked grant rows

DELETE
/mcp-servers/{id}

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

id*
Type
string
Required

Responses

MCP server deleted.

application/json
JSON
{
  
"id": "string",
  
"status": "string"
}

Playground

Authorization
Variables
Key
Value

Samples


List the brokered credentials of an MCP server

GET
/mcp-servers/{id}/credentials

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

id*
Type
string
Required

Responses

Credential list.

application/json
JSON
[
  
{
  
  
"id": "string",
  
  
"displayName": "string",
  
  
"brokeringMode": "string",
  
  
"secretRef": "string"
  
}
]

Playground

Authorization
Variables
Key
Value

Samples


Add a brokered credential to an MCP server (does not touch grants)

POST
/mcp-servers/{id}/credentials

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

id*
Type
string
Required

Request Body

application/json
JSON
{
  
"displayName": "string",
  
"brokeringMode": "string",
  
"secretRef": "string"
}

Responses

Credential added.

application/json
JSON
{
  
"id": "string",
  
"displayName": "string",
  
"brokeringMode": "string",
  
"secretRef": "string"
}

Playground

Authorization
Variables
Key
Value
Body

Samples


Remove a single brokered credential from an MCP server

DELETE
/mcp-servers/{id}/credentials/{credentialId}

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

id*
Type
string
Required
credentialId*
Type
string
Required

Responses

Credential deleted.

application/json
JSON
{
  
"id": "string",
  
"status": "string"
}

Playground

Authorization
Variables
Key
Value

Samples


List all groups with member counts and awareness grants

GET
/groups

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Responses

Group list.

application/json
JSON
[
  
{
  
  
"id": "string",
  
  
"name": "string",
  
  
"description": "string",
  
  
"memberCount": 0,
  
  
"awarenessGrants": [
  
  
  
{
  
  
  
}
  
  
]
  
}
]

Playground

Authorization

Samples


Create a new group and optional awareness grants

POST
/groups

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Request Body

application/json
JSON
{
  
"name": "string",
  
"description": "string"
}

Responses

Group created.

application/json
JSON
{
  
"id": "string",
  
"name": "string",
  
"description": "string",
  
"memberCount": 0,
  
"awarenessGrants": [
  
  
{
  
  
}
  
]
}

Playground

Authorization
Body

Samples


Get a single group by identifier

GET
/groups/{id}

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

id*
Type
string
Required

Responses

Group detail.

application/json
JSON
{
  
"id": "string",
  
"name": "string",
  
"description": "string",
  
"memberCount": 0,
  
"awarenessGrants": [
  
  
{
  
  
}
  
]
}

Playground

Authorization
Variables
Key
Value

Samples


Update a group and replace awareness grants

PUT
/groups/{id}

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

id*
Type
string
Required

Request Body

application/json
JSON
{
}

Responses

Group updated.

application/json
JSON
{
  
"id": "string",
  
"name": "string",
  
"description": "string",
  
"memberCount": 0,
  
"awarenessGrants": [
  
  
{
  
  
}
  
]
}

Playground

Authorization
Variables
Key
Value
Body

Samples


Delete a group and its awareness grants

DELETE
/groups/{id}

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

id*
Type
string
Required

Responses

Group deleted.

application/json
JSON
{
  
"id": "string",
  
"status": "string"
}

Playground

Authorization
Variables
Key
Value

Samples


List all skill bundles with entitlements and promotion history

GET
/skills/catalog

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Responses

Skill bundle list.

application/json
JSON
[
  
{
  
  
"id": "string",
  
  
"name": "string",
  
  
"description": "string",
  
  
"version": "string",
  
  
"digest": "string",
  
  
"scope": "string",
  
  
"status": "string",
  
  
"tags": [
  
  
  
"string"
  
  
],
  
  
"sourceName": "string",
  
  
"publishedAt": "string",
  
  
"grants": [
  
  
  
{
  
  
  
}
  
  
],
  
  
"promotions": [
  
  
  
{
  
  
  
}
  
  
]
  
}
]

Playground

Authorization

Samples


Create a new skill bundle

POST
/skills/catalog

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Request Body

application/json
JSON
{
}

Responses

Skill bundle created.

application/json
JSON
{
  
"id": "string",
  
"status": "string"
}

Playground

Authorization
Body

Samples


Backfill all published bundles' content into the OCI store (P4D.2)

POST
/skills/catalog/backfill

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Responses

Backfill summary with per-bundle outcomes.

application/json
JSON
{
  
"total": 0,
  
"pushed": 0,
  
"skipped": 0,
  
"failed": 0,
  
"results": [
  
  
{
  
  
  
"id": "string",
  
  
  
"name": "string",
  
  
  
"digest": "string",
  
  
  
"outcome": "string",
  
  
  
"reason": "string"
  
  
}
  
]
}

Playground

Authorization

Samples


Get a single skill bundle by identifier

GET
/skills/catalog/{id}

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

id*
Type
string
Required

Responses

Skill bundle detail.

application/json
JSON
{
  
"id": "string",
  
"name": "string",
  
"description": "string",
  
"version": "string",
  
"digest": "string",
  
"scope": "string",
  
"status": "string",
  
"tags": [
  
  
"string"
  
],
  
"sourceName": "string",
  
"publishedAt": "string",
  
"grants": [
  
  
{
  
  
}
  
],
  
"promotions": [
  
  
{
  
  
}
  
]
}

Playground

Authorization
Variables
Key
Value

Samples


Update a skill bundle and fully replace entitlements and promotions

PUT
/skills/catalog/{id}

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

id*
Type
string
Required

Request Body

application/json
JSON
{
}

Responses

Skill bundle updated.

application/json
JSON
{
  
"id": "string",
  
"status": "string"
}

Playground

Authorization
Variables
Key
Value
Body

Samples


Delete a skill bundle and its linked entitlement grants

DELETE
/skills/catalog/{id}

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

id*
Type
string
Required

Responses

Skill bundle deleted.

application/json
JSON
{
  
"id": "string",
  
"status": "string"
}

Playground

Authorization
Variables
Key
Value

Samples


List all third-party sources

GET
/third-party-sources

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Responses

Third-party source list.

application/json
JSON
[
  
{
  
  
"id": "string",
  
  
"name": "string",
  
  
"type": "string",
  
  
"url": "string",
  
  
"syncStatus": "string",
  
  
"lastSyncedAt": "string"
  
}
]

Playground

Authorization

Samples


Register a new third-party source

POST
/third-party-sources

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Request Body

application/json
JSON
{
}

Responses

Source registered.

application/json
JSON
{
}

Playground

Authorization
Body

Samples


Get a single third-party source

GET
/third-party-sources/{id}

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

id*
Type
string
Required

Responses

Source detail.

application/json
JSON
{
  
"id": "string",
  
"name": "string",
  
"type": "string",
  
"url": "string",
  
"syncStatus": "string",
  
"lastSyncedAt": "string"
}

Playground

Authorization
Variables
Key
Value

Samples


Update a third-party source

PUT
/third-party-sources/{id}

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

id*
Type
string
Required

Request Body

application/json
JSON
{
}

Responses

Source updated.

application/json
JSON
{
}

Playground

Authorization
Variables
Key
Value
Body

Samples


Delete a third-party source and its linked items

DELETE
/third-party-sources/{id}

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

id*
Type
string
Required

Responses

Source deleted.

application/json
JSON
{
}

Playground

Authorization
Variables
Key
Value

Samples


List all issued access tokens (hashes only, never plaintext)

GET
/access-tokens

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Responses

Token list.

application/json
JSON
[
  
{
  
  
"id": "string",
  
  
"name": "string",
  
  
"owner": "string",
  
  
"createdAt": "string",
  
  
"expiresAt": "string",
  
  
"lastUsedAt": "string"
  
}
]

Playground

Authorization

Samples


Create a new access token. Returns plaintext token once — store it securely.

POST
/access-tokens

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Request Body

application/json
JSON
{
  
"name": "string",
  
"owner": "string",
  
"expiresAt": "string"
}

Responses

Token created. The plainTextToken field will not be returned again.

application/json
JSON
{
  
"id": "string",
  
"plainTextToken": "string"
}

Playground

Authorization
Body

Samples


Revoke and delete an access token

DELETE
/access-tokens/{id}

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

id*
Type
string
Required

Responses

Token deleted.

Playground

Authorization
Variables
Key
Value

Samples


List configured provider API keys (configured status only, never the key value)

GET
/providers/keys

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Responses

Provider key status list.

application/json
JSON
[
  
{
  
  
"provider": "string",
  
  
"configured": true,
  
  
"updatedAt": "string"
  
}
]

Playground

Authorization

Samples


Create or update a provider API key

PUT
/providers/keys/{provider}

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

provider*
Type
string
Required

Request Body

application/json
JSON
{
  
"apiKey": "string"
}

Responses

Key updated.

application/json
JSON
{
  
"provider": "string",
  
"configured": true,
  
"updatedAt": "string"
}

Playground

Authorization
Variables
Key
Value
Body

Samples


Delete a configured provider API key

DELETE
/providers/keys/{provider}

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

provider*
Type
string
Required

Responses

Key deleted.

Playground

Authorization
Variables
Key
Value

Samples


Get global monthly spend ceiling

GET
/ai-budget/global

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Responses

Global budget.

application/json
JSON
{
  
"monthlyLimitUsd": 0,
  
"currentSpendUsd": 0,
  
"budgetAlertState": "string"
}

Playground

Authorization

Samples


Update the global monthly spend ceiling

PUT
/ai-budget/global

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Request Body

application/json
JSON
{
  
"monthlyLimitUsd": 0
}

Responses

Global budget updated.

application/json
JSON
{
  
"monthlyLimitUsd": 0,
  
"currentSpendUsd": 0,
  
"budgetAlertState": "string"
}

Playground

Authorization
Body

Samples


List all per-account monthly spend ceilings

GET
/ai-budget/accounts

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Responses

Account budgets.

application/json
JSON
[
  
{
  
  
"monthlyLimitUsd": 0,
  
  
"currentSpendUsd": 0,
  
  
"budgetAlertState": "string"
  
}
]

Playground

Authorization

Samples


Create or update the budget ceiling for a specific account

PUT
/ai-budget/accounts/{userId}

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

userId*
Type
string
Required

Request Body

application/json
JSON
{
  
"monthlyLimitUsd": 0
}

Responses

Account budget updated.

application/json
JSON
{
  
"monthlyLimitUsd": 0,
  
"currentSpendUsd": 0,
  
"budgetAlertState": "string"
}

Playground

Authorization
Variables
Key
Value
Body

Samples


Remove the per-account budget ceiling

DELETE
/ai-budget/accounts/{userId}

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

userId*
Type
string
Required

Responses

Budget removed.

application/json
JSON
{
}

Playground

Authorization
Variables
Key
Value

Samples


Get current spend and budget state for a tenant

GET
/ai-budget/{tenantName}/spend

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

tenantName*
Type
string
Required

Responses

Spend data.

application/json
JSON
{
  
"monthlyLimitUsd": 0,
  
"currentSpendUsd": 0,
  
"budgetAlertState": "string"
}

Playground

Authorization
Variables
Key
Value

Samples


Get LiteLLM virtual key metadata for a tenant (never the key value)

GET
/ai-budget/{tenantName}/litellm-key

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

tenantName*
Type
string
Required

Responses

LiteLLM key metadata.

application/json
JSON
{
}

Playground

Authorization
Variables
Key
Value

Samples


Revoke the LiteLLM virtual key for a tenant

POST
/ai-budget/{tenantName}/litellm-key/revoke

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Path Parameters

tenantName*
Type
string
Required

Responses

Key revoked.

application/json
JSON
{
}

Playground

Authorization
Variables
Key
Value

Samples


Audit

Operations


Query audit log entries with optional tenant filter and cursor pagination

GET
/audit

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Query Parameters

tenant

Filter to a specific tenant.

Type
string
limit

Maximum entries to return.

Type
integer
Default
100
Minimum
1
Maximum
1000
cursor

Opaque cursor from a previous response for keyset pagination.

Type
string

Responses

Paginated audit entries.

application/json
JSON
{
  
"data": [
  
  
{
  
  
  
"timestamp": "string",
  
  
  
"tenant": "string",
  
  
  
"action": "string",
  
  
  
"resource": "string",
  
  
  
"message": "string"
  
  
}
  
],
  
"pagination": {
  
  
"limit": 0,
  
  
"nextCursor": "string",
  
  
"hasMore": true
  
}
}

Playground

Authorization
Variables
Key
Value

Samples


Token Usage


List token usage records

GET
/token-usage

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Parameters

Query Parameters

tenant
Type
string
limit
Type
integer
Default
100

Responses

Token usage records.

application/json
JSON
[
  
{
  
  
"tenant": "string",
  
  
"model": "string",
  
  
"inputTokens": 0,
  
  
"outputTokens": 0,
  
  
"totalCostUsd": 0,
  
  
"recordedAt": "string"
  
}
]

Playground

Authorization
Variables
Key
Value

Samples


Get latest server utilisation snapshot (CPU, memory, storage, active tenants)

GET
/metrics/server

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Responses

Server utilisation snapshot.

application/json
JSON
{
  
"cpuPercent": 0,
  
"memoryUsedBytes": 0,
  
"memoryTotalBytes": 0,
  
"storageUsedBytes": 0,
  
"storageTotalBytes": 0,
  
"activeTenants": 0,
  
"sampledAt": "string"
}

Playground

Authorization

Samples


Get projection drift metrics with threshold evaluation and alert state

GET
/metrics/projection-drift

Authorizations

bearerAuth

Static bearer token. Pass as Authorization: Bearer .

Type
HTTP (bearer)

Responses

Projection drift metrics.

application/json
JSON
{
  
"tenant": {
  
},
  
"accessPolicy": {
  
},
  
"evaluatedAt": "string",
  
"alertFired": true
}

Playground

Authorization

Samples


Return current auth mode and authenticated user identity (if any)

GET
/auth/me

No authentication required. Returns 200 with the current session or an anonymous identity when no session is established.

Responses

Auth status.

application/json
JSON
{
  
"mode": "string",
  
"authenticated": true,
  
"user": {
  
  
"sub": "string",
  
  
"email": "string",
  
  
"name": "string"
  
}
}

Playground

Samples


Exchange the current OIDC session for a short-lived token to the caller's OpenClaw pod

POST
/auth/pod-token

Single sign-on across the control plane and the tenant pod: requires an established OIDC session (cookie) and returns a short-lived, audience-bound token minted via the Kubernetes TokenRequest API for the caller's tenant. The token targets the OpenClaw pod's session audience (reachable at ingressHost) — it is NOT an obot-gateway token; Obot is called only from inside the pod. The tenant is resolved solely from the session's verified email, so a caller cannot obtain a token for another user's pod. Re-call before expiresAt; re-login only when the session itself expires. Returns 401 without a session, 403 when no tenant matches the session email, 409 when the pod has no ingress host yet or when the email maps to more than one tenant.

Responses

Short-lived pod access token.

application/json
JSON
{
  
"token": "string",
  
"expiresAt": "string",
  
"tenant": "string",
  
"ingressHost": "string",
  
"audience": "string"
}

Playground

Samples


Redirect the browser to the configured OIDC identity provider to start login

GET
/auth/login

Browser redirect — not intended for programmatic use. Returns 503 when OIDC is not configured.

Parameters

Query Parameters

returnTo

Path to redirect back to after a successful login.

Type
string

Responses

Redirect to identity provider.

Playground

Variables
Key
Value

Samples


OIDC authorization callback — validates the response and establishes a session

GET
/auth/callback

Called by the identity provider after a successful login. Redirects back to the SPA.

Parameters

Query Parameters

code
Type
string
state
Type
string

Responses

Redirect back into the application.

Playground

Variables
Key
Value

Samples


Destroy the current session

POST
/auth/logout

Invalidates the server-side session. Does not perform IdP-side logout (RP-initiated logout is out of scope for Phase 5).

Responses

Session destroyed.

Playground

Samples


Initiate a CLI device authorization grant

POST
/auth/device

Returns a device code and short user code. The CLI prints the verificationUri for the operator to open in a browser. No credentials required.

Responses

Device grant created.

application/json
JSON
{
  
"deviceCode": "string",
  
"userCode": "string",
  
"verificationUri": "string",
  
"expiresIn": 0,
  
"interval": 0
}

Playground

Samples


Activate a device grant in the browser (requires OIDC session)

GET
/auth/device/activate

The operator opens this URL after a CLI login prompt. If no OIDC session is present the user is redirected to the identity provider first. On success an access token is created and the CLI poll endpoint unblocks.

Parameters

Query Parameters

userCode*

Short user code from the CLI prompt (e.g. ABCD-1234).

Type
string
Required

Responses

Grant activated. HTML confirmation page returned.

Playground

Variables
Key
Value

Samples


Poll for the access token after browser activation

GET
/auth/device/token

Returns 202 while pending, 200 with token when authorized, 410 when the grant has expired. The token is delivered exactly once.

Parameters

Query Parameters

deviceCode*

Secret device code returned by POST /auth/device.

Type
string
Required

Responses

Grant authorized — token ready.

application/json
JSON
{
  
"status": "string",
  
"token": "string"
}

Playground

Variables
Key
Value

Samples


Meta


Retrieve the OpenAPI 3.1 specification for this API

GET
/openapi.json

Responses

OpenAPI 3.1 document.

application/json
JSON
{
}

Playground

Samples


Powered by VitePress OpenAPI

Released under the AGPL-3.0-or-later License.