Skip to main content
POST
Creates a prompt-based voice agent and deploys it immediately — the returned agent_id can be used right away as override_agent_id on Dial.
Only prompt-based agents can be created via the API. Flow agents (multi-step conversational flows with branching, function calls, and knowledge bases) are built in the dashboard.

Body Parameters

string
required
Agent display name.
string
required
System prompt that defines the agent’s behavior.
string
default:"he-IL"
The agent’s main language: he-IL, en-US, ar-EG, ru-RU or el-GR. Short forms (he, en, ar, ru, el) are accepted and stored as the full tag. The voice must speak it.
string
default:"Ori"
Voice display name. One of Sapir, Steve, Sivan, Saar, Ori, Yael, Guy, Gefen, Gal, Gabriel.
string
Message the agent speaks first when it answers. When empty, the agent opens the conversation from the prompt.
array
Variables to supply at call time (via vars_provided on Dial).
array
Variables the agent should extract from the conversation after the call.
array
Up to 5 webhooks fired when a call with this agent ends. See Webhooks for the payload and signature.
integer
default:"15"
Longest a call with this agent may last, in minutes. One of 10, 15, 20.
string[]
default:"[]"
Additional languages the agent may switch into mid-call, on top of its main language: any of he-IL, en-US, ar-EG, ru-RU, el-GR other than the main. When the caller speaks one of them (or asks for it), the agent continues in that language. The voice must speak every one; every voice listed under voice speaks all four languages. Omit it (or send null) for the main language only.
object
Let the agent end the call itself. Omit it (or send null) and the agent never hangs up on its own.
string
default:"service"
Which side of the call the agent is on. service: it answers for your business. customer: it calls a business on someone’s behalf, for example to book a table or ask a question, and speaks as that business’s customer.

Response

The created Agent object.