All endpoints on this page are [User+Key]. API keys use
agents:read, agents:write, agents:delete, and agents:run scopes as appropriate.Endpoints
| Method | Path | Description | Auth |
|---|---|---|---|
GET | /agents | List agents for a tenant | [User+Key] |
GET | /agents/recent-chats | List recent agent chats | [User+Key] |
POST | /agents | Create an agent and version 1 | [User+Key] |
GET | /agents/:id | Get an agent | [User+Key] |
GET | /agents/:id/integrations | Check connected-app readiness | [User+Key] |
PATCH | /agents/:id | Update name or status without a new version | [User+Key] |
POST | /agents/:id/deploy | Deploy a new version | [User+Key] |
POST | /agents/:id/copy | Copy or fork an agent | [User+Key] |
DELETE | /agents/:id | Archive an agent | [User+Key] |
POST | /agents/:id/schedule/enable | Enable its schedule | [User+Key] |
POST | /agents/:id/schedule/disable | Disable its schedule | [User+Key] |
GET | /agents/:id/runs | List runs | [User+Key] |
GET | /agents/:id/runs/:runId | Get a run | [User+Key] |
POST | /agents/:id/runs/:runId/stop | Stop a run | [User+Key] |
POST | /agents/:id/messages | Run or continue an agent | [User+Key] |
POST | /agents/:id/messages/stream | Run or continue an agent over SSE | [User+Key] |
List agents
GET /agents
Tenant whose agents to list.
List recent agent chats
GET /agents/recent-chats
Tenant whose agent chats to list.
Maximum number to return, from 1 to 50.
Create an agent
POST /agents
Creation validates the full configuration and publishes version 1.
Tenant that owns the agent.
Human-readable agent name.
The outcome the agent should pursue.
Behavioral and output guidance.
Supported model identifier.
Knowledge base used for retrieval. This choice is fixed after creation.
Allow web search during runs.
Allow durable-memory behavior when tenant and knowledge-base settings permit it.
Connected apps the agent may use.
IDs of MCP servers already registered for the organization.
Skill attachments, each with
skill_id and mode always or auto.Delegates, each identified by
agent_id.Custom HTTP tool definitions. Secret header values are encrypted and masked when read back.
Subject bound to an API-key-created agent for connected apps and durable-memory isolation.
Optional schedule draft. Supported modes are
manual, daily, weekly, monthly, custom, and cron./swagger.
Get an agent
GET /agents/:id
Returns the current agent configuration, schedule, version, and recent run information. Secret custom-tool headers are masked.
Check connected-app readiness
GET /agents/:id/integrations
Returns the connection status of the apps enabled for the identity that will run the agent, including whether scheduled runs are supported.
Update agent metadata
PATCH /agents/:id
Updates name or status (active or archived) without creating a new version.
Deploy a new version
POST /agents/:id/deploy
Accepts the same complete configuration as agent creation. A successful deploy increments the version; a failed validation leaves the previous version unchanged.
In-flight runs stay pinned to the version they started with. New runs use the newly deployed version.
Copy an agent
POST /agents/:id/copy
Optional name for the copy.
Optional destination knowledge base.
Archive an agent
DELETE /agents/:id
Archives the agent and disables its schedule while preserving its run history.
Enable or disable a schedule
POST /agents/:id/schedule/enable enables the saved non-manual schedule. POST /agents/:id/schedule/disable pauses it. Neither action creates a new agent version.
Schedules run on cron-style cadences. See Scheduling for UTC behavior and supported recurrence patterns.
List and inspect runs
GET /agents/:id/runs returns the agent’s runs. GET /agents/:id/runs/:runId returns one run and verifies that it belongs to the agent in the path.
Run status can be queued, running, completed, failed, or cancelled.
Stop a run
POST /agents/:id/runs/:runId/stop
Stops an in-flight run. Partial output already generated remains available with the run and its chat. Stopping a terminal run returns a conflict response.
Send an agent message
POST /agents/:id/messages
Starts a run, or continues the run associated with chat_id, and returns a complete JSON response.
Message to send to the agent.
Existing agent chat to continue. Omit it to start a new run and chat.
Optional model override for this turn.
External end-user subject for API-key calls.
Skills to load for this message.
Additional delegates available for this message.
chat_id, run_id, and run data. Reuse chat_id to continue the same run.
Stream an agent message
POST /agents/:id/messages/stream
Accepts the same body as the non-streaming endpoint and returns SSE. Response headers include X-Chat-Id and, for a new run, X-Run-Id.
ping, agent_thought, final_response, sources, tokens, done, and error.
Next steps
Agent lifecycle
Understand versions, pinned runs, schedules, and terminal states.
Build an agent
Create and invoke an agent end to end.
Agent configuration
Learn how tools, skills, connected apps, and delegates combine.
Chat streaming
Consume runtime events safely.