Overview
The Campaigns API allows you to create, launch, and monitor outbound calling campaigns programmatically.List Campaigns
Get all campaigns in your account.Query Parameters
| Parameter | Type | Description |
|---|---|---|
status | string | Filter by status: draft, active, paused, completed |
agent_id | string | Filter by assigned agent |
page | integer | Page number (default: 1) |
per_page | integer | Items per page (default: 20) |
Response
Get Campaign
Retrieve a single campaign with detailed statistics.Response
Create Campaign
Create a new outbound calling campaign.Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
name | string | Yes | Campaign name |
description | string | No | Campaign description |
agent_id | string | Yes | Agent to make calls |
settings | object | No | Campaign configuration |
Settings Object
| Field | Type | Default | Description |
|---|---|---|---|
calling_hours_start | string | ”09:00” | Start time (HH:MM) |
calling_hours_end | string | ”17:00” | End time (HH:MM) |
timezone | string | ”UTC” | IANA timezone |
concurrent_calls | integer | 1 | Simultaneous calls |
max_retries | integer | 3 | Retry attempts per contact |
Response
Add Contacts to Campaign
Add contacts to a campaign for calling.Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
contacts | array | Yes | Array of contact objects |
contacts[].phone | string | Yes | Phone number (E.164 format) |
contacts[].first_name | string | No | First name |
contacts[].last_name | string | No | Last name |
contacts[].email | string | No | Email address |
contacts[].company | string | No | Company name |
Response
Start Campaign
Start a campaign to begin making calls.Response
Pause Campaign
Pause an active campaign.Response
Resume Campaign
Resume a paused campaign.Response
Get Campaign Callbacks
Get pending callbacks for a campaign.Response
Campaign Status
| Status | Description |
|---|---|
draft | Created but not started |
active | Currently making calls |
paused | Temporarily stopped |
completed | All contacts processed |
cancelled | Manually stopped |
Error Codes
| Code | Description |
|---|---|
campaign_not_found | Campaign ID doesn’t exist |
campaign_already_active | Cannot start an active campaign |
campaign_not_active | Cannot pause a non-active campaign |
agent_not_found | Specified agent doesn’t exist |
no_contacts | Campaign has no contacts to call |

