All endpoints on this page are [User+Key]. API keys use
agents:read, agents:write, agents:delete, and agents:run scopes as appropriate.Endpoints
List agents
GET /agents
string
required
Tenant whose agents to list.
List recent agent chats
GET /agents/recent-chats
string
required
Tenant whose agent chats to list.
number
Maximum number to return, from 1 to 50.
Create an agent
POST /agents
Creation validates the full configuration and publishes version 1.
string
required
Tenant that owns the agent.
string
required
Human-readable agent name.
string
required
The outcome the agent should pursue.
string
required
Behavioral and output guidance.
string
required
Supported model identifier.
string
required
Knowledge base used for retrieval. This choice is fixed after creation.
boolean
Allow web search during runs.
boolean
Allow durable-memory behavior when tenant and knowledge-base settings permit it.
string[]
Connected apps the agent may use.
string[]
IDs of MCP servers already registered for the organization.
object[]
Skill attachments, each with
skill_id and mode always or auto.object[]
Delegates, each identified by
agent_id.object[]
Custom HTTP tool definitions. Secret header values are encrypted and masked when read back.
string
Subject bound to an API-key-created agent for connected apps and durable-memory isolation.
object
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
string
Optional name for the copy.
string
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.
string
required
Message to send to the agent.
string
Existing agent chat to continue. Omit it to start a new run and chat.
string
Optional model override for this turn.
string
External end-user subject for API-key calls.
string[]
Skills to load for this message.
string[]
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.