Skip to content

API reference

Broadcasts API

Create, send, schedule and cancel marketing email.

Paths are relative to https://isent.dev/api/v1. Every request needs an API key; see API overview for errors, rate limits and pagination.

List broadcasts

GET/broadcasts

Parameters

List broadcasts: parameters
NameInTypeDescription
limitquerynumberItems per page, 1 to 100 (default 20).
afterquerystringReturn items after this id (the last id of the previous page).

Responses

List broadcasts: responses
StatusMeaning
200OK.
400The body is not valid JSON.
401Missing, invalid or restricted API key.
403Not allowed: role, key scope, unverified domain, plan limit (plan_limit_reached) or a new team's members-only sending (sending_restricted).
422Validation failed.
429Rate limit (rate_limit_exceeded), monthly quota (monthly_quota_exceeded) or a new team's daily limit (daily_limit_reached).
cURL
curl -X GET https://isent.dev/api/v1/broadcasts \
  -H "Authorization: Bearer $ISENT_API_KEY"

Create a broadcast

POST/broadcasts

A draft. Content can use {{first_name}}, {{last_name}}, {{email}}, contact properties and {{{unsubscribe_url}}}.

Body

A JSON object.

Create a broadcast: body
NameTypeDescription
nameRequiredstring1 to 120 characters.
segment_idstring | nullAudience segment; null sends to every contact.
topic_idstring | nullLimit to contacts subscribed to this topic.
template_idstring | nullNone
fromstringNone
reply_tostring | nullNone
subjectstringAt most 998 characters.
preview_textstring | nullAt most 200 characters.
htmlstring | nullNone
textstring | nullNone

Responses

Create a broadcast: responses
StatusMeaning
201Created.
400The body is not valid JSON.
401Missing, invalid or restricted API key.
403Not allowed: role, key scope, unverified domain, plan limit (plan_limit_reached) or a new team's members-only sending (sending_restricted).
409Conflict with the current state, or an idempotency key reused.
422Validation failed.
429Rate limit (rate_limit_exceeded), monthly quota (monthly_quota_exceeded) or a new team's daily limit (daily_limit_reached).

Retrieve a broadcast

GET/broadcasts/{id}

Parameters

Retrieve a broadcast: parameters
NameInTypeDescription
idRequiredpathstringNone

Responses

Retrieve a broadcast: responses
StatusMeaning
200OK.
400The body is not valid JSON.
401Missing, invalid or restricted API key.
403Not allowed: role, key scope, unverified domain, plan limit (plan_limit_reached) or a new team's members-only sending (sending_restricted).
404Not found.
422Validation failed.
429Rate limit (rate_limit_exceeded), monthly quota (monthly_quota_exceeded) or a new team's daily limit (daily_limit_reached).
cURL
curl -X GET https://isent.dev/api/v1/broadcasts/{id} \
  -H "Authorization: Bearer $ISENT_API_KEY"

Update a draft broadcast

PATCH/broadcasts/{id}

Parameters

Update a draft broadcast: parameters
NameInTypeDescription
idRequiredpathstringNone

Body

A JSON object.

Update a draft broadcast: body
NameTypeDescription
namestring1 to 120 characters.
segment_idstring | nullAudience segment; null sends to every contact.
topic_idstring | nullLimit to contacts subscribed to this topic.
template_idstring | nullNone
fromstringNone
reply_tostring | nullNone
subjectstringAt most 998 characters.
preview_textstring | nullAt most 200 characters.
htmlstring | nullNone
textstring | nullNone

Responses

Update a draft broadcast: responses
StatusMeaning
200OK.
400The body is not valid JSON.
401Missing, invalid or restricted API key.
403Not allowed: role, key scope, unverified domain, plan limit (plan_limit_reached) or a new team's members-only sending (sending_restricted).
404Not found.
409Conflict with the current state, or an idempotency key reused.
422Validation failed.
429Rate limit (rate_limit_exceeded), monthly quota (monthly_quota_exceeded) or a new team's daily limit (daily_limit_reached).

Delete a broadcast

DELETE/broadcasts/{id}

Parameters

Delete a broadcast: parameters
NameInTypeDescription
idRequiredpathstringNone

Responses

Delete a broadcast: responses
StatusMeaning
200OK.
400The body is not valid JSON.
401Missing, invalid or restricted API key.
403Not allowed: role, key scope, unverified domain, plan limit (plan_limit_reached) or a new team's members-only sending (sending_restricted).
404Not found.
409Conflict with the current state, or an idempotency key reused.
422Validation failed.
429Rate limit (rate_limit_exceeded), monthly quota (monthly_quota_exceeded) or a new team's daily limit (daily_limit_reached).
cURL
curl -X DELETE https://isent.dev/api/v1/broadcasts/{id} \
  -H "Authorization: Bearer $ISENT_API_KEY"

Send or schedule a broadcast

POST/broadcasts/{id}/send

Recipients are queued within a minute and delivered by the send worker.

Parameters

Send or schedule a broadcast: parameters
NameInTypeDescription
idRequiredpathstringNone

Body

An optional JSON object.

Send or schedule a broadcast: body
NameTypeDescription
scheduled_atstringISO 8601, or "in 1 hour". Omit to send now.

Responses

Send or schedule a broadcast: responses
StatusMeaning
200OK.
400The body is not valid JSON.
401Missing, invalid or restricted API key.
403Not allowed: role, key scope, unverified domain, plan limit (plan_limit_reached) or a new team's members-only sending (sending_restricted).
404Not found.
409Conflict with the current state, or an idempotency key reused.
422Validation failed.
429Rate limit (rate_limit_exceeded), monthly quota (monthly_quota_exceeded) or a new team's daily limit (daily_limit_reached).

Cancel a broadcast

POST/broadcasts/{id}/cancel

Emails already handed off still deliver; the rest are canceled.

Parameters

Cancel a broadcast: parameters
NameInTypeDescription
idRequiredpathstringNone

Responses

Cancel a broadcast: responses
StatusMeaning
200OK.
400The body is not valid JSON.
401Missing, invalid or restricted API key.
403Not allowed: role, key scope, unverified domain, plan limit (plan_limit_reached) or a new team's members-only sending (sending_restricted).
404Not found.
409Conflict with the current state, or an idempotency key reused.
422Validation failed.
429Rate limit (rate_limit_exceeded), monthly quota (monthly_quota_exceeded) or a new team's daily limit (daily_limit_reached).
cURL
curl -X POST https://isent.dev/api/v1/broadcasts/{id}/cancel \
  -H "Authorization: Bearer $ISENT_API_KEY"