API reference
Contacts
Create, read, update, and delete the contacts in your audience.
A contact is an email address plus optional profile and custom data. Contacts are unlimited — Deckle bills on sends, not audience size.
The contact object#
json
{
"id": "contact_a1b2c3",
"email": "jane@example.com",
"name": "Jane Doe",
"subscribed": true,
"source": "api",
"data": { "plan": "pro" },
"created_at": "2026-07-10T10:30:00.000Z",
"updated_at": "2026-07-10T10:30:00.000Z"
}Create or update a contact#
POST
/v1/contactsUpserts by email. A new email returns 201; an existing one is updated and returns 200. Omitted fields are left unchanged on update.
Body parameters
emailstringRequiredThe contact’s email address. Normalized to lowercase.
namestringOptionalDisplay name. An empty string is stored as
null.subscribedbooleanOptionalSubscription state. Defaults to
true on create.sourcestringOptionalWhere the contact came from. Defaults to
api on create.dataobjectOptionalArbitrary custom fields as a JSON object (not an array), e.g.
{ "plan": "pro" }.curl -X POST https://app.getdeckle.com/api/v1/contacts \
-H "Authorization: Bearer sk_live_..." \
-H "Content-Type: application/json" \
-d '{ "email": "jane@example.com", "name": "Jane Doe",
"data": { "plan": "pro" } }'Automation enrollment
A newly-created subscribed contact is automatically enrolled in any live automation triggered bycontact.subscribed.List contacts#
GET
/v1/contactsQuery parameters
limitintegerOptionalItems per page. Default
50, max 100.cursorstringOptionalPagination cursor.
emailstringOptionalFilter by exact email address.
subscribedbooleanOptionalFilter by subscription state (
true or false).ts
const { data, has_more, next_cursor } = await deckle.contacts.list({ limit: 50 });Retrieve a contact#
GET
/v1/contacts/:idts
const contact = await deckle.contacts.get("contact_a1b2c3");Update a contact#
PATCH
/v1/contacts/:idPartial update — only the fields you send change. The email address cannot be changed via PATCH.
ts
await deckle.contacts.update("contact_a1b2c3", {
subscribed: false,
data: { plan: "free" },
});Delete a contact#
DELETE
/v1/contacts/:idawait deckle.contacts.delete("contact_a1b2c3");