Create Recipient List
This API allows you to create a list consisting of the details of your recipients.
Request Type
- POST
Request URL
https://campaigns.zoho.com/emailapi/v1/recipients
Content-Type
application/json
List of Request Body Attributes
Parameters | Data Type | Description |
name* | String | Name of the list. |
description | String | Description provided for the list. |
recipients* | JSON Array | Contains the details of the recipients. ➤ address* - Email address ➤ name - Name of the recipient ➤ additional_data - Additional information of the recipient such as Country, Phone. ➤ merge_data - Data to be replaced instead of merge tags. |
List of Response Body Attributes
Parameters | Data Type | Description |
list_id | Integer | Unique ID of the list which can be used in APIs. |
response | JSON Object | Contains the response details of the API. |
code | Integer | Success or failure code. |
message | String | Success or failure message returned by the API. |
errors | JSON Object | Contains the error details of the API such as 'code' and 'message'. |
Possible Errors
Error Code | Description |
400501 | A recipient list with the same name already exists. |
400503 | Recipient list name not provided. |
400504 | Recipients/contacts not provided. |
400011 | Recipient limit exceeded. |
400013 | None of the recipients are valid. |
Sample Request Payload
Copied{
"name":"List 5",
"description":"List 4 test",
"recipients":[
{
"address":"patricia@zylker.com",
"name":"Patricia",
"additional_data":{
"country":"IN",
"ph":"9876543210"
},
"merge_data":{
"first_name":"Patricia"
}
},
{
"address":"boyle@zylker.com",
"name":"Boyle",
"additional_data":{
"country":"IN",
"ph":"1234567890"
},
"merge_data":{
"first_name":"Boyle"
}
},
{
"address":"julia@zylker.com",
"name":"Julia",
"additional_data":{
"country":"EU",
"ph":"9999999999"
},
"merge_data":{
"first_name":"Julia"
}
},
{
"address":"jamal@zylker.com",
"name":"Jamal",
"additional_data":{
"country":"US",
"ph":"9000000000"
},
"merge_data":{
"first_name":"Jamal"
}
},
{
"address":"musashi@zylker.com",
"name":"Musashi",
"additional_data":{
"country":"JP",
"ph":"1111111111"
},
"merge_data":{
"first_name":"Musashi"
}
}
]
}
Sample Response - Succcess
Copied{
"list_id": "8000000128001",
"response": {
"code": 200503,
"message": "Recipient list added successfully"
}
}
Sample Response - Failure
Copied{
"errors": [
{
"code": 500501,
"message": "An error occurred in Recipient List API"
}
]
}