Skip to main content
POST
Create a new campaign contact rule

Authorizations

Authorization
string
header
required

Use a Bearer token to access these API endpoints. Example: "Bearer {your-token}"

Body

application/json
name
string
required

Human-readable label for the rule. 3-255 characters. Not required to be unique.

Required string length: 3 - 255
Example:

"Aggressive call rule"

type
enum<string>

Determines task scheduling behavior. 'call' rules honor retry interval and working-hours window. 'text' rules are forced to one-shot semantics: max_total_calls and max_calls_per_day are coerced to 1, and retry_interval_minutes / end_time / escalation_* are nulled. Default: 'call'.

Available options:
call,
text
Example:

"call"

max_calls_per_day
integer

Maximum number of attempts to the same contact per calendar day, evaluated in the contact's local timezone. Ignored when type='text' (forced to 1). Default: 3 for call, 1 for text.

Required range: x >= 1
Example:

3

max_total_calls
integer

Hard cap on total attempts to the same contact across the campaign's full date range. Once reached, no further tasks are scheduled for that contact. Default: 10 for call, 1 for text.

Required range: x >= 1
Example:

10

retry_interval_minutes
integer | null

Minimum minutes between successive attempts to the same contact. Honored only for type='call'. Null for type='text'. Default: 120.

Required range: x >= 1
Example:

120

start_time
string

Earliest allowed local time of day (HH:MM, 24h) the system may attempt to reach a contact. Interpreted in the contact's local timezone, not server time. Default: '09:00'.

Example:

"09:00"

end_time
string | null

Latest allowed local time of day (HH:MM, 24h). Honored only for type='call'. Null for type='text'. Default: '18:00'.

Example:

"18:00"

dnc_check
boolean

When true, contacts on the Do Not Call list are skipped at task-creation time. Default: true.

Example:

true

remove_on_opt_out
boolean

When true, an inbound opt-out (STOP keyword, unsubscribe webhook) automatically removes the contact from active pool items. Default: true.

Example:

true

escalation_after_failed_attempts
integer | null

Trigger threshold for escalation_type. After this many consecutive failed attempts on a contact, the escalation hook fires. 0 disables escalation. Default: 0.

Required range: x >= 0
Example:

0

escalation_type
string | null

Free-form identifier consumed by your downstream escalation logic. Common values: 'notify_manager', 'reassign_to_human', 'mark_failed'. Null disables.

Maximum string length: 255
escalation_target
string | null

Free-form payload paired with escalation_type — typically a manager email, a team UUID, or human-readable instructions. Interpretation is up to your handler.

Response

Rule created.

success
boolean
Example:

true

message
string
Example:

"Rule created successfully"

data
object

Campaign contact rule. Drives task cadence, retry interval, working-hours window, and escalation policy when attached to a campaign.