Mailing Lists
REQUIREMENT
The base URL for all API requests is https://platform.sendbound.com/api/v1REQUIREMENT
The API token MUST be included as a query parameter in all subsequent requests. The token value is assigned to the api_token parameter as a query parameter.This section of the documentation describes how to create and manage email lists.
CREATE EMAIL LIST
This operation allows you to create a new mailing list.
POST /lists
api_token=NAim6P4gapLXU2ZUad7i46RAgtSnqTqRtFBX7BZpbyFTntUYZ8Dgtppf0byD
{
"name":"Mailing List One",
"from_email": "plastic@xoned.co.uk",
"from_name": "John Doe",
"default_subject": "Some Subject",
"contact": {
"company": "Xoned Plastic",
"state": "Abamae",
"address_1":"XONED Limited",
"address_2": "1566 Plt 32",
"city":"Donkome",
"zip": "00123",
"country_id": "94",
"email": "plastic@xoned.co.uk",
"url": "https://xoned.co.uk",
"phone": "+1210000001"
},
"subscribe_confirmation": "0",
"send_welcome_email": "0",
"unsubscribe_notification":"0"
}
curl --location --request POST 'https://platform.sendbound.com/api/v1/lists?api_token=NAim6P4gapLXU2ZUad7i46RAgtSnqTqRtFBX7BZpbyFTntUYZ8Dgtppf0byD' \
--header 'Content-Type: application/json' \
--data-raw '{
"name":"Mailing List One",
"from_email": "plastic@xoned.co.uk",
"from_name": "John Doe",
"default_subject": "Some Subject",
"contact": {
"company": "Xoned Plastic",
"state": "Abamae",
"address_1":"XONED Limited",
"address_2": "1566 Plt 32",
"city":"Donkome",
"zip": "00123",
"country_id": "94",
"email": "plastic@xoned.co.uk",
"url": "https://xoned.co.uk",
"phone": "+1210000001"
},
"subscribe_confirmation": "0",
"send_welcome_email": "0",
"unsubscribe_notification":"0"
}'
{
"status": 1,
"message": "List was successfully created",
"list_uid": "61f57d8213962"
}
Query Parameters
api_token
Kindly reference here to obtain the API token.
Request Parameters
Kindly reference here for request definition
Response Parameters
status
This represents the status of the operation. 1
means success
and 0
means failure
message
This parameter contains a succss or failure message.
list_uid
This parameter holds a unique identifier to the email list.
GET ALL EMAIL LIST
This operation allows you to retrieve all email lists.
GET /lists
api_token=NAim6P4gapLXU2ZUad7i46RAgtSnqTqRtFBX7BZpbyFTntUYZ8Dgtppf0byD
curl --location --request GET 'https://platform.sendbound.com/api/v1/lists?api_token=NAim6P4gapLXU2ZUad7i46RAgtSnqTqRtFBX7BZpbyFTntUYZ8Dgtppf0byD'
[
{
"id": 2,
"uid": "61f57cf694dd9",
"name": "Mailing List One",
"default_subject": "Some Subject",
"from_email": "plastic@xoned.co.uk",
"from_name": "John Doe",
"status": null,
"created_at": "2022-01-29T17:44:22.000000Z",
"updated_at": "2022-01-29T17:44:22.000000Z"
},
{
"id": 3,
"uid": "61f57d8213962",
"name": "Mailing List One",
"default_subject": "Some Subject",
"from_email": "plastic@xoned.co.uk",
"from_name": "John Doe",
"status": null,
"created_at": "2022-01-29T17:46:42.000000Z",
"updated_at": "2022-01-29T17:46:42.000000Z"
}
]
Query Parameters
api_token
Kindly reference here to obtain the API token.
Response Parameters
A list of email list objects.
GET SPECIFIC EMAIL LIST
This operation allows you to retrieve a specific email list by its unique id.
GET /lists/{uid}
api_token=NAim6P4gapLXU2ZUad7i46RAgtSnqTqRtFBX7BZpbyFTntUYZ8Dgtppf0byD
curl --location --request GET 'https://platform.sendbound.com/api/v1/lists/61f57cf694dd9?api_token=NAim6P4gapLXU2ZUad7i46RAgtSnqTqRtFBX7BZpbyFTntUYZ8Dgtppf0by
{
"list": {
"uid": "61f57cf694dd9",
"name": "Mailing List One",
"default_subject": "Some Subject",
"from_email": "plastic@xoned.co.uk",
"from_name": "John Doe",
"remind_message": null,
"status": null,
"created_at": "2022-01-29T17:44:22.000000Z",
"updated_at": "2022-01-29T17:44:22.000000Z",
"fields": [
{
"key": "EMAIL",
"label": "Email",
"type": "string",
"tag": "EMAIL",
"default_value": null,
"visible": 1,
"required": true
},
{
"key": "FIRST_NAME",
"label": "First Name",
"type": "string",
"tag": "FIRST_NAME",
"default_value": null,
"visible": 1,
"required": false
},
{
"key": "LAST_NAME",
"label": "Last Name",
"type": "string",
"tag": "LAST_NAME",
"default_value": null,
"visible": 1,
"required": false
}
]
},
"contact": {
"company": "Xoned Plastic",
"address_1": "XONED Limited",
"address_2": "1566 Plt 32",
"country": "Iran",
"state": "Abamae",
"zip": "00123",
"phone": "+1210000001",
"url": "https://xoned.co.uk",
"email": "plastic@xoned.co.uk",
"city": "Donkome"
},
"statistics": {
"subscriber_count": 0,
"open_uniq_rate": 0,
"click_rate": 0,
"subscribe_rate": 0,
"unsubscribe_rate": 0,
"unsubscribe_count": 0,
"unconfirmed_count": 0
}
}
Query Parameters
api_token
Kindly reference here to obtain the API token.
PATH PARAMETERS
uid
This represents the unique identifier of the email list.
Response Parameters
All list informations in json
ADD TAG OR ADDITIONAL FIELD TO MAILING LIST
This operation allows you to tag your email list.
POST /lists/{uid}/add-field
api_token=NAim6P4gapLXU2ZUad7i46RAgtSnqTqRtFBX7BZpbyFTntUYZ8Dgtppf0byD
{
"type":"text",
"label": "ZOOM",
"tag": "pierson"
}
curl --location --request POST 'https://platform.sendbound.com/api/v1/lists/61f57cf694dd9/add-field?api_token=NAim6P4gapLXU2ZUad7i46RAgtSnqTqRtFBX7BZpbyFTntUYZ8Dgtppf0byD' \
--header 'Content-Type: application/json' \
--data-raw '{
"type":"text",
"label": "ZOOM",
"tag": "pierson"
}'
{
"status": 1,
"message": "List's field was created",
"field": {
"mail_list_id": 2,
"visible": true,
"required": false,
"type": "text",
"label": "ZOOM",
"tag": "pierson",
"uid": "61f588267fd25",
"updated_at": "2022-01-29T18:32:06.000000Z",
"created_at": "2022-01-29T18:32:06.000000Z",
"id": 10
}
}
Query Parameters
api_token
Kindly reference here to obtain the API token.
PATH PARAMETERS
uid
This represents the unique identifier of the email list.
Request Parameters
type
This represents the type of field to be added
label
This represents the label of the tag or additional field
tag
This represents the tag value.
Response Parameters
status
This represents the status of the operation. 1
means success
and 0
means failure
message
This parameter contains a succss or failure message.
field
This parameter holds a json
representing unique information to the added tag.
DELETE EMAIL LIST
This operation allows you to tag your email list.
DELETE /lists/{uid}
api_token=NAim6P4gapLXU2ZUad7i46RAgtSnqTqRtFBX7BZpbyFTntUYZ8Dgtppf0byD
curl --location --request DELETE 'https://platform.sendbound.com/api/v1/lists/61f57cf694dd9?api_token=NAim6P4gapLXU2ZUad7i46RAgtSnqTqRtFBX7BZpbyFTntUYZ8Dgtppf0byD'
{
"status": 1,
"message": "Deleted"
}
Query Parameters
api_token
Kindly reference here to obtain the API token.
PATH PARAMETERS
uid
This represents the unique identifier of the email list.
Response Parameters
status
This represents the status of the operation. 1
means success
and 0
means failure
message
This parameter contains a succss or failure message.