Skip to main content

Endpoints

All endpoints require a JWT bearer token in the Authorization header. See Authentication for details.

Authorization: Bearer <token>

Agent Management

MethodEndpointDescription
GET/v1/agents/typesList supported agent types.
GET/v1/agentsList all agents in the current tenant (includes global agents). Supports is_global filter.
POST/v1/agentsCreate a new agent with an initial version. Accepts optional versionLabel (max 128 chars). Pass validateOnly: true to validate the payload without persisting.
POST/v1/agents/lookupLook up an agent by name and optional version label.
PATCH/v1/agents/{agent_id}Update agent metadata (name, displayName, description). Pass validateOnly: true to validate without persisting.
DELETE/v1/agents/{agent_id}Delete an agent and corresponding versions and permissions.

Agent Versions

MethodEndpointDescription
GET/v1/agents/{agent_id}/versionsList all versions of an agent.
GET/v1/agents/{agent_id}/versions/{version_id}Get a specific agent version.
POST/v1/agents/{agent_id}/versionsAdd a new version to an existing agent. Pass validateOnly: true to validate the config without persisting.
POST/v1/agents/versions/batch-getGet multiple agents and versions in one request. Maximum 100 agent IDs per request.

Agent Invocation

MethodEndpointDescription
POST/v1/agents/{agent_id}/versions/{version_id}/invokeInvoke a Tool or RAG agent.
POST/v1/agents/{agent_id}/versions/{version_id}/invoke-streamInvoke a Tool or RAG agent with streaming.
POST/v1/agents/{agent_id}/versions/{version_id}/invoke-taskInvoke a Task agent.
POST/v1/agents/{agent_id}/versions/{version_id}/invoke-task-streamInvoke a Task agent with streaming.
tip

Use latest as the version_id to invoke the most recent version.

Runs (Async Invocation)

MethodEndpointDescription
POST/v1/agents/{agent_id}/runsCreate a run (async invocation). Returns immediately with status queued.
GET/v1/agents/{agent_id}/runsList runs for an agent. Supports status filter.
GET/v1/agents/{agent_id}/runs/{run_id}Get the current status of a run.
POST/v1/agents/{agent_id}/runs/{run_id}/cancelCancel a run. Idempotent.
GET/v1/agents/{agent_id}/runs/{run_id}:streamStream run output as SSE. Supports ?starting_after={streamId} for resumption.
info

Runs are the async alternative to the synchronous invoke endpoints. Submit a run, then poll GET .../runs/{run_id} or connect to the SSE stream for real-time output.

Run Statuses

StatusDescription
queuedRun created, waiting for a worker to pick it up.
in_progressWorker is executing the agent pipeline.
completedExecution finished successfully. outputPayload is populated.
failedExecution failed. error field contains details.
cancellingCancellation requested, worker is stopping.
cancelledRun was cancelled before completion.

Create Run Request Body

{
"invokeRequest": {
"messages": [
{ "role": "user", "content": "Hello" }
]
},
"versionId": "optional-version-uuid"
}

Headers

HeaderRequiredDescription
Idempotency-KeyNoUUID to prevent duplicate run creation on retries.

MCP Server Management

MethodEndpointDescription
GET/v1/mcp-serversList all registered MCP servers.
POST/v1/mcp-serversRegister a new MCP server.
GET/v1/mcp-servers/{server_id}Get details of a specific MCP server.
PUT/v1/mcp-servers/{server_id}Update an MCP server configuration.
DELETE/v1/mcp-servers/{server_id}Delete an MCP server.
POST/v1/mcp-servers/{server_id}/validateTrigger on-demand validation.
GET/v1/mcp-servers/{server_id}/toolsList tools available on the server.

Files

MethodEndpointDescription
POST/v1/filesRequest a presigned upload URL for Code Interpreter file uploads.

Models and Guardrails

MethodEndpointDescription
GET/v1/modelsList supported LLM models. Supports filter[agentType].
GET/v1/guardrailsList supported guardrails.

Service Health

MethodEndpointDescription
GET/healthHealth check.

Query Parameters

Pagination

List endpoints support offset and limit query parameters:

ParameterTypeDefaultDescription
offsetinteger0Items to skip.
limitinteger50Max items to return.

Response includes:

{
"pagination": {
"totalItems": 42,
"offset": 0,
"limit": 50,
"hasMore": false
}
}

Filtering

ParameterEndpointTypeDescription
is_globalGET /v1/agentsbooleanFilter by global or tenant-specific agents.
filter[agentType]GET /v1/modelsstringFilter models by agent type.

OpenAPI Spec

Download the full spec: openapi.yaml