Skip to main content

Contacts

Contacts are the people in your email lists. The Contacts API allows you to create, retrieve, update, and delete contacts in your easymail account.

Overview

Each contact has a unique email address and can include additional information like name, language preference, and custom fields. Contacts can be added to one or more lists for targeted email campaigns.

Endpoints

MethodEndpointDescription
POST/contactsCreate a new contact
GET/contactsList all contacts
GET/contacts/{uuid}Get a specific contact
PATCH/contacts/{uuid}Update a contact
DELETE/contacts/{uuid}Delete a contact
POST/contacts/{uuid}/unsubscribeUnsubscribe a contact from all mail
POST/contacts/{uuid}/resubscribeReverse a contact's unsubscribe
GET/contacts/{uuid}/eventsList a contact's event timeline

Contact Object

FieldTypeDescription
uuidstringUnique identifier for the contact
emailstringContact's email address
first_namestring|nullContact's first name
last_namestring|nullContact's last name
phonestring|nullContact's phone number
external_idstring|nullExternal identifier for integration purposes
languagestring|nullISO 639-1 language code (2 characters)
country_codestring|nullISO 3166-1 alpha-2 country code (2 characters)
created_atstringISO 8601 timestamp (UTC)
updated_atstringISO 8601 timestamp (UTC)

Subscription status

Every contact has a subscription status describing whether it can be mailed:

  • subscribed — the contact can receive mail: neither unsubscribed nor undeliverable.
  • unsubscribed — the contact has opted out of all mail.
  • suppressed — the contact is undeliverable (for example, after a permanent bounce) and is held back from sending regardless of consent.

These values are not mutually exclusive: a contact can be both unsubscribed and suppressed. subscribed is the exact complement — neither of the other two.

Filter a list by status with the status parameter on List Contacts. Get Contact returns the headline status along with detailed subscription, deliverability, and engagement objects for a single contact. For the per-event history behind those summaries — opens, clicks, bounces, subscribes, and purchases, in order — use List Contact Events.

Set the opt-out with Unsubscribe Contact and Resubscribe Contact. These act on the account-wide consent only; they do not change list membership, and resubscribing does not clear a suppressed state.