REST API to Create New Campaign Lists and Subscribers

Banckle Banckle · March 24, 2014 · Short URL: https://vator.tv/n/35d6

Create, Manage and Track Email and Newsletter Campaign using REST API

Banckle has recently released Banckle Cloud APIs for all its products to help developers create social applications for their websites using any programming language and it will also be platform independent. The main purpose of these Cloud APIs is to provide our customers the ability to ensure the best customer support, sales and marketing functions to their users.

We are proud to announce the release of a new Cloud API for real-time email marketing and campaign delivery known as Banckle.Campaign for Cloud API. It enables developers to create, manage, send and track email and newsletter campaigns with ease. It gives developers complete freedom to develop and enhance the capabilities of your email marketing software. These APIs allow you to easily create new campaigns, view or update existing campaigns, improve productivity by duplicating successful campaigns and perform a lot of other customization and management functions. It provided a centralized platform to manage growing subscribers list as well as users can create awesome templates for their newsletters and campaign readers.

What you require to use this API

In order to access the cloud API for Banckle.Campaign, you must:

  1. Have a valid Banckle Account. Sign Up for new Banckle Account
  2. Have permission to access Banckle.Campaign API service.
  3. You can access Banckle.Campaign API by using Swagger API Explorer.

 

Code Samples of how to create a list and add subscribers

 

First you have to get token to run Banckle Swagger API Explorer for Campaign API. You can request new token by using the following link:

 

curl "https://campaign.banckle.com/api/authenticate.do?userid=EMAIL&password=PASSWORD" -X POST

 

Response of the above link will be like this:

 

{
  "result": {
    "loginId": "your_username",
    "token": "a9b774c9-b89d-4878-8893-a4ea7fcb5a7b",
    "isAdmin": true
  },
  "status": 301,
  "success": true
}

 

You can see the token value in the above output, copy this token and enter it in the top right text box of the explorer and press enter. Now you are ready to use Campaign API and test its different methods.

 

REST code sample for creating a list

Following is the REST code to create new list:

POST /api/lists/token/{token}/action/add

Request - Using CURL

 

curl https://campaign.banckle.com/api//lists/token/42b55f24-e073-490d-bad6-bae11394a450/action/add \
  -d '\{"title":"CampaignList"\}' \
  -H "Content-Type: application/json" -v -X POST

 

Response of the above query will be like the one given below:

 

{
  "result": {
"id": 421,
    "schedule": "",
    "title": "CampaignList",
    "status": "New",
    "subscribers_count": 0,
    "last_sent": "",
    "contact_ids": [
 
    ]
  },
  "status": 324,
  "success": true
}

 

REST code sample for creating a Subscriber

Following is the REST code to add subscriber:

POST /api/contact/token/{token}/action/add

Request - Using CURL

 

curl https://campaign.banckle.com/api/contact/token/42b55f24-e073-490d-bad6-bae11394a450/action/add \
  -d' {"email":"campaign.mytest@abc.com","first_name":"John","last_name":"Doe","list_ids":["421"]}' \
  -H "Content-Type: application/json" -v -X POST

 

Response of the above query will be like the one given below:

 

{
  "result": {
    "id": 452159,
    "first_name": "John",
    "status": "Subscribed",
    "email": "campaign.mytest@abc.com",
    "name": "campaign.mytest@abc.com",
    "last_name": "Doe",
    "list_ids": [
 
    ],
    "lists_count": 0
  },
  "status": 335,
  "success": true
}

 

Overview: Banckle.Campaign for Cloud API

 

Banckle.Campaign for Cloud API is an email marketing API platform which can be used for creating, managing, sending and tracking email and newsletter campaigns on the fly. It gives you complete freedom to develop and enhance the capabilities of your email marketing softwares. The email campaign API has REST based architecture, which allows you to easily manipulate information and resources using simple HTTP requests and responses. The API explorer shows an easy to use implementation of RESTful API creates, read, update, and delete operations.

 

More about Banckle.Campaign for Cloud API

 

-          Experience Banckle Campaign App in the real-time 

-          Homepage of Banckle.Campaign for Cloud API  

-          Post your technical questions/queries to Banckle Forum 

-          Receive notifications about latest news and supported features by subscribing to Banckle blog


Contact Information

Suite 163, 79 Longueville Road

Lane Cove, NSW, 2066

Australia

Banckle – Business and Social Apps 

support@banckle.com

Phone: +1 214 329 1520

Support VatorNews by Donating

Read more from our "Trends and news" series

More episodes