Skip to main content
A campaign dials a list of contacts with one of your agents, from one of your outbound-capable numbers, inside a daily calling window in the timezone you pick. The runner respects a per-campaign concurrency cap and retries contacts whose calls ended in outcomes you selected (no_answer, voicemail, failed, …) with a configurable backoff, up to max_attempts per contact. Lifecycle: draft → (scheduled →) runningcompleted, with paused and cancelled reachable via actions. Contacts are only editable while the campaign is a draft.

Endpoints

{campaign_id} is the campaign’s UUID (public_id).

Campaign object


Create a campaign

Required: name, agent, from_number, daily_window_start, daily_window_end. Returns 201 Created with the campaign in status="draft". Validation errors (400) cover unknown agents, numbers not registered to your org, demo numbers, invalid IANA timezones, and end_at <= start_at.

Retrieve / update / delete

GET /v1/campaigns/{id} returns the campaign plus a contacts array (first 500 contact objects; filter with ?contact_status=pending|scheduled|calling|completed|failed|exhausted). PATCH accepts any subset of the writable fields, but only while status is draft, scheduled, or paused — otherwise 409 Conflict. DELETE returns 204 No Content and removes the campaign and its contacts (already-made call logs are kept).

Add contacts

Only allowed while the campaign is a draft (409 otherwise). Two formats:
  • CSV: UTF-8, must have a phone or phone_number column. Every other column becomes a per-contact variable.
  • JSON: a top-level list, or {"contacts": [...]} — each object needs phone_number (or phone); all other keys become variables.
  • Max 5,000 rows per request. Numbers are normalized to E.164 (8–15 digits); invalid rows are rejected individually, not the whole batch.
Response (201 Created)

Contact object

{id, phone_number, variables, status, attempts, next_attempt_at, last_outcome, call_id, created_at, updated_at}status is pending, scheduled, calling, completed, failed, or exhausted (retries used up); call_id links the most recent call.

Campaign actions

POST /v1/campaigns/{id}/{action} where action is: Returns 200 OK with the updated campaign. Invalid transitions return 409; unknown actions return 404.

Stats

Response
recent_calls holds the 20 most recently updated contacts that have a call attached.

Outbound Calls

Place a single ad-hoc outbound call instead.

Phone Numbers

Campaigns need an outbound-capable (non-demo) number.

Agents

The agent that speaks on campaign calls.

Calls

Every attempt appears in call history.