All contact endpoints require a secret key (
sk_*).List contacts
GET /contacts
Returns a cursor-paginated list of contacts for the authenticated project.
Query parameters
Number of contacts to return per page. Maximum
100.Pagination cursor returned from a previous response. Omit on the first request.
Filter contacts by email address (partial match).
Response
Array of contact objects.
Cursor to pass as
cursor on the next request. null when there are no more pages.true when additional pages are available.Total number of contacts. Only included on the first page (when no
cursor is provided).Example
200
Create contact
POST /contacts
Creates a new contact or updates an existing one (upsert by email address).
Body parameters
Contact email address. Used as the unique identifier for upsert.
Subscription status for marketing emails.
Custom key-value data to store on the contact. Merged with any existing data.
Response
Returns the contact object. HTTP201 when a new contact was created; 200 when an existing contact was updated.
Contact ID.
Contact email address.
Subscription status.
Custom contact data.
ISO 8601 creation timestamp.
ISO 8601 last-updated timestamp.
Example
201
Get contact
GET /contacts/:id
Retrieves a single contact by ID.
Path parameters
The contact ID.
Response
Returns the contact object.Example
200
Update contact
PATCH /contacts/:id
Updates a contact’s subscription status or custom data fields.
Path parameters
The contact ID.
Body parameters
New email address for the contact.
Updated subscription status.
Custom data fields to merge into the contact’s existing data.
Response
Returns the updated contact object.Example
200
Delete contact
DELETE /contacts/:id
Permanently deletes a contact and all associated data.
Path parameters
The contact ID.
Response
Returns204 No Content on success.
Example
Import contacts (CSV)
POST /contacts/import
Queues a CSV file for bulk contact import. The import runs asynchronously in the background.
The request must use
multipart/form-data with the CSV file in a field named file. Maximum file size is 5 MB. The CSV must have at minimum an email column.Body (multipart/form-data)
CSV file. Must include an
email column. Additional columns are stored as contact data fields.Response
Returns202 Accepted with a jobId you can poll for status.
Confirmation message.
Use this to check import progress.
Example
Get import status
GET /contacts/import/:jobId
Returns the status of a CSV import job.
Path parameters
The job ID returned from the import request.
Bulk subscribe
POST /contacts/bulk-subscribe
Queues a bulk subscribe operation for up to 1,000 contacts.
Body parameters
Array of contact IDs to subscribe. Maximum 1,000 per request.
Response
Returns202 Accepted with a jobId.
Example
Bulk unsubscribe
POST /contacts/bulk-unsubscribe
Queues a bulk unsubscribe operation for up to 1,000 contacts.
Body parameters
Array of contact IDs to unsubscribe. Maximum 1,000 per request.
Bulk delete
POST /contacts/bulk-delete
Queues a bulk delete operation for up to 1,000 contacts.
Body parameters
Array of contact IDs to delete. Maximum 1,000 per request.
Get bulk action status
GET /contacts/bulk/:jobId
Returns the status of a bulk subscribe, unsubscribe, or delete job.
Path parameters
The job ID returned from the bulk operation request.