Before you start
- An API key.
- An agent with a phone number set up through Twilio or Telnyx.
- The agent’s
agent_id.
Place a call
initiated:
Request fields
string
required
The agent that makes the call.
string
required
The number to call, in E.164 format. For example,
+15551234567.object
Values for the
{{placeholders}} in the agent’s instructions and first message. Keys and values are strings.string
Replaces the agent’s first message for this call only.
string
twilio or telnyx. Use this when the agent has both. If you leave it out, Eclatira uses Twilio when it is set up, and Telnyx otherwise.Personalize each call
Put placeholders in the agent’s instructions or first message with double braces:Retry safely
Network errors happen. To retry a request without placing a second call, send anIdempotency-Key header:
- If you repeat a request with the same key and the same body, you get the first response back. No new call is placed.
- If you reuse a key with a different body, the request is rejected.
POST /api/v1/calls and POST /api/v1/batches.
Get the result
When the call ends, read it withGET /api/v1/calls/{call_id}:
To list all calls, use
GET /api/v1/calls with limit and offset.
Flag a call for review
You can mark a finished call for human review. This is the same as the review toggle in the dashboard:Call a list of numbers
A batch calls many people with the same agent. It uses the same engine as the CSV upload in the dashboard, with the same scheduling, retries and concurrency.to_number. It can also have its own variables and first_message.
A batch starts right away. To run it later, add scheduled_at with an ISO 8601 time. To get one notification when the whole batch is done, add webhook_url.