VoiceDock Docs
ApiCampaigns

Create a campaign

Create a new outbound calling campaign with leads and schedule.

POST
/campaigns

Create a new outbound calling campaign with leads and schedule.

Authorization

BearerAuth
AuthorizationBearer <token>

API key authentication. Get your key from the dashboard.

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

curl -X POST "https://example.com/campaigns" \  -H "Content-Type: application/json" \  -d '{    "name": "Sales Outreach",    "agent_id": "2b1e3b65-2c04-4fa2-a2d7-467901e98978",    "schedule_start_time": "09:00:00",    "schedule_end_time": "17:00:00",    "timezone": "Europe/Amsterdam"  }'
{
  "campaign": {
    "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
    "name": "Q1 Sales Outreach",
    "agent_id": "2b1e3b65-2c04-4fa2-a2d7-467901e98978",
    "status": "draft",
    "system_message_template": "You are calling {{name}} from {{company}}. Convince them to schedule a demo.",
    "schedule_start_time": "09:00:00",
    "schedule_end_time": "17:00:00",
    "timezone": "Europe/Amsterdam",
    "total_leads": 0,
    "completed_leads": 0,
    "failed_leads": 0,
    "created_at": "2019-08-24T14:15:22Z",
    "updated_at": "2019-08-24T14:15:22Z"
  }
}
{
  "error": "Invalid API key",
  "message": "string"
}
{
  "error": "Invalid API key",
  "message": "string"
}