Skip to main content
POST
/
api
/
v1
/
outbound
/
campaigns
Typescript (SDK)
import { SyllableSDK } from "syllable-sdk";

const syllableSDK = new SyllableSDK({
  apiKeyHeader: process.env["SYLLABLESDK_API_KEY_HEADER"] ?? "",
});

async function run() {
  const result = await syllableSDK.outbound.campaigns.create({
    campaignName: "Outbound Campaign 1",
    description: "This is a test campaign",
    mode: "voice",
    smsSessionTtl: 720,
    labels: [
      "test",
      "demo",
    ],
    campaignVariables: {
      "key": "value",
      "key2": "value2",
    },
    dailyStartTime: "09:00:00",
    dailyEndTime: "17:00:00",
    source: "+19032900844",
    callerId: "19995551234",
    hourlyRate: 25,
    retryCount: 1,
    retryInterval: "30m",
    activeDays: [
      "mon",
      "tue",
      "wed",
      "thu",
      "fri",
    ],
    voicemailDetection: {
      "voicemail_detection_overall_timeout": 30,
      "voicemail_detection_post_speech_timeout": 1.75,
      "voicemail_detection_pre_speech_timeout": 3.5,
    },
  });

  console.log(result);
}

run();
{
  "campaign_name": "<string>",
  "campaign_variables": {},
  "caller_id": 19995551234,
  "active_days": [
    "mon"
  ],
  "id": 123,
  "last_updated_by": "<string>",
  "description": "This is a test campaign",
  "mode": "voice",
  "sms_session_ttl": 720,
  "label": "test",
  "labels": [
    "test",
    "demo"
  ],
  "daily_start_time": "09:00:00",
  "daily_end_time": "17:00:00",
  "source": "+19032900844",
  "hourly_rate": 1,
  "retry_count": 0,
  "retry_interval": "30m",
  "voicemail_detection": {
    "voicemail_detection_overall_timeout": 30,
    "voicemail_detection_post_speech_timeout": 1.75,
    "voicemail_detection_pre_speech_timeout": 3.5
  },
  "agent_id": "agent_id",
  "created_at": "2023-11-07T05:31:56Z",
  "updated_at": "2023-11-07T05:31:56Z"
}

Authorizations

Syllable-API-Key
string
header
required

Body

application/json
campaign_name
string
required

Human readable name of campaign

Example:

"Outbound Campaign 1"

campaign_variables
Campaign Variables · object
required

Variables for campaign

Example:
{ "key": "value", "key2": "value2" }
caller_id
string | null
required

Caller ID for call

Example:

19995551234

active_days
enum<string>[]
required

Days of the week when campaign is active

Enum representing days of the week.

Available options:
mon,
tue,
wed,
thu,
fri,
sat,
sun
Example:

"[\"mon\", \"tue\", \"wed\", \"thu\", \"fri\"]"

description
string | null

Description of campaign

Example:

"This is a test campaign"

mode
string | null

Mode of the campaign (e.g. voice, sms)

Example:

"voice"

sms_session_ttl
integer | null

Time to live for SMS session in minutes

Example:

720

label
string | null
deprecated

Label for campaign (DEPRECATED - use labels instead)

Example:

"test"

labels
string[] | null

Labels for campaign

Example:
["test", "demo"]
daily_start_time
string | null

Start time of campaign each day

Example:

"09:00:00"

daily_end_time
string | null

End time of campaign each day

Example:

"17:00:00"

source
string | null

Source phone number, email, or SMS number

Example:

"+19032900844"

hourly_rate
integer
default:1

Target number of outreach calls per hour

Example:

25

retry_count
integer
default:0

Number of retries per target

Example:

1

retry_interval
string | null

How long to wait before retrying

Example:

"30m"

voicemail_detection
Voicemail Detection · object

Config for voicemail detection for voice campaigns. Set to None to disable.

Example:
{
  "voicemail_detection_overall_timeout": 30,
  "voicemail_detection_post_speech_timeout": 1.75,
  "voicemail_detection_pre_speech_timeout": 3.5
}

Response

OutboundCampaign · object | null

Successful Response

campaign_name
string
required

Human readable name of campaign

Example:

"Outbound Campaign 1"

campaign_variables
Campaign Variables · object
required

Variables for campaign

Example:
{ "key": "value", "key2": "value2" }
caller_id
string | null
required

Caller ID for call

Example:

19995551234

active_days
enum<string>[]
required

Days of the week when campaign is active

Enum representing days of the week.

Available options:
mon,
tue,
wed,
thu,
fri,
sat,
sun
Example:

"[\"mon\", \"tue\", \"wed\", \"thu\", \"fri\"]"

id
integer
required

Unique ID for campaign

Example:

1

last_updated_by
string
required

Email of user who last updated campaign

description
string | null

Description of campaign

Example:

"This is a test campaign"

mode
string | null

Mode of the campaign (e.g. voice, sms)

Example:

"voice"

sms_session_ttl
integer | null

Time to live for SMS session in minutes

Example:

720

label
string | null
deprecated

Label for campaign (DEPRECATED - use labels instead)

Example:

"test"

labels
string[] | null

Labels for campaign

Example:
["test", "demo"]
daily_start_time
string | null

Start time of campaign each day

Example:

"09:00:00"

daily_end_time
string | null

End time of campaign each day

Example:

"17:00:00"

source
string | null

Source phone number, email, or SMS number

Example:

"+19032900844"

hourly_rate
integer
default:1

Target number of outreach calls per hour

Example:

25

retry_count
integer
default:0

Number of retries per target

Example:

1

retry_interval
string | null

How long to wait before retrying

Example:

"30m"

voicemail_detection
Voicemail Detection · object

Config for voicemail detection for voice campaigns. Set to None to disable.

Example:
{
  "voicemail_detection_overall_timeout": 30,
  "voicemail_detection_post_speech_timeout": 1.75,
  "voicemail_detection_pre_speech_timeout": 3.5
}
agent_id
integer | null

ID of agent assigned to campaign

Example:

"agent_id"

created_at
string<date-time>

Timestamp of campaign creation

Example:

"2025-12-17T00:00:00Z"

updated_at
string<date-time>

Timestamp of campaign update

Example:

"2025-12-17T00:00:00Z"