Skip to main content
POST
/
v1
/
audiences
/
{audienceId}
/
contacts
Create Contact
curl --request POST \
  --url https://api.example.com/v1/audiences/{audienceId}/contacts \
  --header 'Content-Type: application/json' \
  --data '
{
  "email": "<string>",
  "first_name": "<string>",
  "last_name": "<string>",
  "unsubscribed": true
}
'
audienceId
string
required
The ID of the audience.
email
string
required
The contact’s email address.
first_name
string
The contact’s first name.
last_name
string
The contact’s last name.
unsubscribed
boolean
default:"false"
Whether the contact is unsubscribed.

Request

cURL
curl -X POST https://www.unosend.co/api/v1/audiences/aud_123/contacts \
  -H "Authorization: Bearer un_xxxxxxxxxx" \
  -H "Content-Type: application/json" \
  -d '{
    "email": "[email protected]",
    "first_name": "John",
    "last_name": "Doe"
  }'

Response

200
{
  "id": "con_123",
  "email": "[email protected]",
  "first_name": "John",
  "last_name": "Doe",
  "unsubscribed": false,
  "created_at": "2024-01-15T10:30:00.000Z"
}