Developers

API Reference

Complete reference for contacts, campaigns, templates, and automations endpoints

API Reference

All endpoints require an API key in the Authorization header. See Authentication for details.

For transactional email endpoints (/v1/send), see Send Email.


Contacts

GET /api/v1/contacts

List contacts with pagination, search, and filters.

Permission: contacts:read

Query parameters:

ParameterTypeDescription
pagenumberPage number (default: 1)
limitnumberResults per page, 1-100 (default: 20)
searchstringSearch by email, first name, or last name
statusstringSUBSCRIBED, UNSUBSCRIBED, BOUNCED, or COMPLAINED
tagstringFilter by tag name

Response:

JSON
Loading...

POST /api/v1/contacts

Create a new contact. Checks for duplicates and suppression list.

Permission: contacts:write

Request body:

FieldTypeRequiredDescription
emailstringYesEmail address
firstNamestringNoFirst name (max 100)
lastNamestringNoLast name (max 100)
phonestringNoPhone number (max 30)
tagsstring[]NoTags to assign (max 50)
customFieldsobjectNoCustom key-value data
Bash
Loading...

Error codes: duplicate_contact (409), email_suppressed (400)

GET /api/v1/contacts/:id

Get a single contact with list and segment memberships.

Permission: contacts:read

PATCH /api/v1/contacts/:id

Update a contact's fields. Only include fields you want to change. Setting tags replaces all existing tags.

Permission: contacts:write

FieldTypeDescription
firstNamestringFirst name
lastNamestringLast name
phonestringPhone number
tagsstring[]Replaces all tags
statusstringSUBSCRIBED or UNSUBSCRIBED
customFieldsobjectCustom data

DELETE /api/v1/contacts/:id

Permanently delete a contact.

Permission: contacts:write


Campaigns

GET /api/v1/campaigns

List campaigns with optional status filter.

Permission: campaigns:read

Query parameters:

ParameterTypeDescription
pagenumberPage number (default: 1)
limitnumberResults per page, 1-100 (default: 20)
statusstringDRAFT, SCHEDULED, SENDING, SENT, PAUSED, CANCELLED

POST /api/v1/campaigns

Create a campaign draft or schedule one. Campaigns created via API start as DRAFT (or SCHEDULED if scheduledAt is provided). The sender email must be verified.

Permission: campaigns:write

Request body:

FieldTypeRequiredDescription
namestringYesCampaign name (max 200)
subjectLinestringYesSubject line (max 998)
fromEmailstringYesVerified sender email
templateIdstringNoTemplate to use
fromNamestringNoSender display name
replyTostringNoReply-to address
previewTextstringNoPreview text (max 200)
recipientTypestringNoall, segment, or list (default: all)
segmentIdstringNoRequired when recipientType is segment
listIdstringNoRequired when recipientType is list
scheduledAtstringNoISO datetime (must be in the future)
Bash
Loading...

Error codes: sender_not_verified (400), not_found (404) for invalid template/segment/list IDs

GET /api/v1/campaigns/:id

Get a single campaign with template, segment, and list details.

Permission: campaigns:read

GET /api/v1/campaigns/:id/stats

Get full campaign analytics.

Permission: campaigns:read

Response:

JSON
Loading...

Templates

GET /api/v1/templates

List email templates (metadata only, no HTML content).

Permission: templates:read

Query parameters:

ParameterTypeDescription
pagenumberPage number (default: 1)
limitnumberResults per page, 1-100 (default: 20)
searchstringSearch by name or description
categorystringFilter by template category

GET /api/v1/templates/:id

Get a single template including rendered HTML and text content.

Permission: templates:read


Automations

GET /api/v1/automations

List automations with optional status filter.

Permission: automations:read

Query parameters:

ParameterTypeDescription
pagenumberPage number (default: 1)
limitnumberResults per page, 1-100 (default: 20)
statusstringACTIVE, PAUSED, or DRAFT

GET /api/v1/automations/:id

Get a single automation's details including trigger type, goal metrics, and performance stats.

Permission: automations:read

Response fields: id, name, description, triggerType, status, totalEntered, totalCompleted, revenueGenerated, goalType, goalConversions, goalConversionRate, goalRevenue, allowReEntry, reEntryDelayHours, createdAt, updatedAt


Common patterns

Pagination

All list endpoints return:

JSON
Loading...

Error responses

JSON
Loading...

See Error Handling for the full error code reference.