Create Voice Campaign

Creates an AI voice campaign: an AI agent calls every customer in one of your broadcast groups from your numbers, as Campaigns does in DoubleTick. It starts calling at once, or at scheduledAt.

Before you call

  • AI campaigns must be turned on for your organization, otherwise the call fails with 403.
  • The API key's user needs the Create & manage voice campaigns permission, otherwise it fails with 401.
  • segmentId is a static broadcast group of your organization. A dynamic group fails with 422; another organization's group with 404.
  • aiBotId is one of your AI agents. Another organization's agent fails with 404. The agent's call settings must be complete.
  • integrationIds are 1 to 10 of your numbers, all one kind: phone numbers with callChannel PSTN_AI, WhatsApp numbers with WHATSAPP_AI (the default).

How it works

  • A broadcast group can have one active campaign at a time. A second one fails with 422 until the first is cancelled or finished.
  • scheduledAt must be in the future and name its time zone (Z or +05:30). Without it the campaign starts calling at once.
  • windowStart and windowEnd are daily calling hours, HH:mm, in your organization's time zone; send both, with the end later the same day.
  • concurrency is how many calls run at once, 1 to 200. Left out, the campaign takes what the agent's other campaigns leave, up to 10. More than the agent or the numbers have free fails with 400.
  • Failed calls are retried automatically unless autoRetryEnabled is false.
  • A refusal you can act on carries a code in the error: CAMPAIGN_LIST_BUSY, CAMPAIGN_LIST_DYNAMIC, CAMPAIGN_CONCURRENCY_TOO_HIGH, CAMPAIGN_AGENT_SETUP_INCOMPLETE, CAMPAIGN_AGENT_NO_WHATSAPP_CALLS or CAMPAIGN_NUMBERS_CANNOT_CALL. A paused agent answers 422 with reason AI_AGENT_PAUSED.

Rate limit

  • 5 requests per minute for each API key user.
Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Body Params
string
required
length ≤ 255

The campaign's name.

string
required

The static broadcast group to call.

uuid
required

The AI agent that makes the calls.

integrationIds
array of strings, unique
required
length between 1 and 10

The numbers to call from, in order, all one kind.

integrationIds*
string
enum
Defaults to WHATSAPP_AI

PSTN_AI for phone numbers, WHATSAPP_AI for WhatsApp numbers.

Allowed:
integer
1 to 200

Calls at the same time.

string
^([01]\d|2[0-3]):[0-5]\d$

Daily calling hours start, HH:mm, your organization's time zone. Send with windowEnd.

string
^([01]\d|2[0-3]):[0-5]\d$

Daily calling hours end, HH:mm, later the same day.

boolean
Defaults to true

Retry failed calls automatically.

integer | null
≥ 0

Hours of calling time between tries.

integer | null
≥ 1

Tries per customer a day.

integer | null
≥ 1

Tries per customer in all; left out, one.

priorityConfig
object

Who is called first, lower first: never called (NEW), failed, missed. All three or none; default 2, 1, 1.

boolean | null

Override the agent's own setting for handing a call to a person.

date-time

Start later, at this future time, with its time zone (Z or +05:30).

Responses

code CAMPAIGN_CONCURRENCY_TOO_HIGH), an agent whose call settings are incomplete, or numbers that cannot place these calls.

Language
Credentials
Header
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json