Skip to main content

Add Contact to List

Add a contact to a list.

Request

POST /lists/{listUuid}/contacts

Path Parameters

ParameterTypeDescription
listUuidstringList's UUID

Request Body

ParameterTypeRequiredDescription
contact_uuidstringYesUUID of the contact to add

This endpoint is idempotent and always returns 204 No Content on success:

  • If the contact is not in the list, it is added.
  • If the contact is already in the list, the request is silently ignored (no duplicate is created).
  • If the contact previously unsubscribed from this list, the request is silently ignored and the contact is not re-added.

Example Request

curl -X POST "https://email.easy.tools/api/v1/lists/70dbd819-fac2-4dcf-b655-fb925e24410b/contacts" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-d '{
"contact_uuid": "88727c70-1a81-4677-a14f-d2039bfb8a5e"
}'

Response

Success Response (204 No Content)

No response body.

Error Responses

Not Found Error (404) - List

{
"error": {
"code": "RESOURCE_NOT_FOUND",
"message": "List with uuid '70dbd819-fac2-4dcf-b655-fb925e24410b' not found"
}
}

Not Found Error (404) - Contact

{
"error": {
"code": "RESOURCE_NOT_FOUND",
"message": "Contact with uuid 'daccf9ab-b134-4d18-835d-473fc11e6b24' not found"
}
}

Validation Error (422 Unprocessable Entity)

{
"error": {
"code": "VALIDATION_ERROR",
"message": "The given data was invalid",
"details": {
"contact_uuid": ["The contact uuid field is required."]
}
}
}