Skip to main content
Use the Agents API to build an AI voice agent programmatically instead of through the dashboard. The API covers the build stage of the lifecycle: create the agent, save its configuration as a draft, then publish the configuration you want live calls to use.

Base URL

Authentication

Every request requires your workspace API key in the X-API-Key header.
Treat the API key as a secret. Send it only from server-side code and never commit it to source control.

Endpoints

Create agent

POST /v1/agents — create an agent from an agent template.

Save agent draft

PUT /v1/agents/{agentId}/save — store configuration without affecting live calls.

Publish agent

POST /v1/agents/{agentId}/publish — release the configuration used for live calls.

Build an agent

1

Create the agent

Send a name and a templateId to POST /v1/agents. The response returns the agent id, which is the agentId path parameter for the remaining calls.
2

Save the configuration as a draft

Send the configuration to PUT /v1/agents/{agentId}/save. A draft lets you iterate without changing the behavior of live calls.
3

Publish the configuration

Send the configuration to POST /v1/agents/{agentId}/publish. The published version is the one used for live calls.
The save and publish requests take the full agent configuration, not a partial patch. Both require systemPrompt, pipelineType, ambienceId, and triggers.

Configuration reference

The save and publish request bodies share the same fields. The tables below group them by purpose. See the individual endpoint pages for every field, type, and constraint.

Core

Language model

Voice and audio

Conversation behavior

Privacy

Errors

Errors return a code and an error message.