Agents
Create a new agent
Create a new agent by passing the agent name in the request body.
New agents have versioning enabled by default. To set the prompt, firstMessage, tools, or any runtime config, fork a draft from the auto-created initial version, edit it, publish, and activate — see the Versioning Lifecycle guide for the full flow.
The legacy PATCH /workflow/{workflowId} endpoint writes directly to the underlying workflow document and bypasses the version lifecycle; edits made that way are not captured as a version and may not propagate to live calls. Use the drafts flow above.
post/agent
Request body
Response
Agent created successfully
Example response
{
"status": true,
"data": "60d0fe4f5311236168a109ca"
}