overview your first call subscribers mailing lists list ai campaigns sender profiles send campaign analytics

Email Marketing API Overview

Topics covered:

introduction

The email blaster API uses an HTTPS RESTful architecture. This means that all data is sent and received using JSON.

If you are not familiar with JSON or REST, please take the time to do your own reading before commencing development. Further information can be found below:

Introduction to JSON: json.org
Introduction to REST: wikipedia - REST

For debugging and further assistance, Postman API tester is a great way to test your calls.

API key

Before getting started with the email blaster API, you will first need to generate your secure API key. This allows access to the API and grants you permission to make requests. All requests should contain your API key.

The API key can be generated from inside your email blaster. From the main menu, select: apps > api.

Note: If you have not installed the API app inside your email blaster. You will first need to install it. From the main menu, click on: apps > add more apps.

headers

When sending a JSON request to the API, please ensure that the Content-Type header of your request is set to:

application/json

Each API call should also include your API key. This should also be set as a header attribute:

api_key => {your_api_key}

As a security mechanism, sending an invalid API key, or not providing an API key in your requests will result in a temporary block from using the API. A block will occur after 5+ consecutive instances.

URL

The live production API can be reached by using the following URL:

https://api.emailblaster.cloud/2.0/

SSL

For added security and data protection, all requests should be made over SSL. The email blaster API provides a signed certificate for this purpose. All of your requests should be made to https pages (not http).

request types

The email blaster API uses the following http methods for requests:

GET This request is used to fetch data from the API. Using a GET will not make any changes or updates to stored data. It is simply a means to fetch resources.

POST Most commonly used to create a new data item. A POST request will normally create a new record.

PATCH Used to update a record, such as new subscriber details. You only need to provide the data which you wish to update.

DELETE The quick and easy way to delete a data item or record.

(Each request to the API must include one of the valid request type methods shown above.)

cURL examples

Requests to the API will normally be made using the cURL library. This section provides example cURL requests:

GET

curl --header "application/json" \
--header "api_key:your_api_key" \
--request GET \
https://api.emailblaster.cloud/2.0/lists/folderview

POST

curl --header "application/json" \
--header "api_key:your_api_key" \
--request POST \
--data '{"email" : "bob@example.com","list" : "242"}' \
https://api.emailblaster.cloud/2.0/subscriber/subscribe

PATCH

curl --header "application/json" \
--header "api_key:your_api_key" \
--request PATCH \
--data '{"name" : "bob folder"}' \
https://api.emailblaster.cloud/2.0/lists/folderupdate/43

DELETE

curl --header "application/json" \
--header "api_key:your_api_key" \
--request DELETE \
https://api.emailblaster.cloud/2.0/subscriber/delete/42034

error response

When making any API call, a {status} value will always be returned. Monitoring the status value will enable you to check for any errors made during the call.

A successful request will always return:

{"status":"ok"}

Unsuccessful requests will return a descriptive error response, such as:

{"status":"invalid email"}

Give us a call
01327
438077
Connect
Let's go
Where? Unit 10A
Burcote Wood Business Park
Towcester
Northants
NN12 8TA
Email Blaster is a trading name of JC Peters Ltd registered in England & Wales no. 07168254