Suggest Edits

Email Campaigns

 
Suggest Edits

Return all your created campaigns

 

Header Auth

 Authentication is required for this endpoint.
gethttps://api.sendinblue.com/v3/emailCampaigns
curl --request GET \
  --url https://api.sendinblue.com/v3/emailCampaigns
var request = require("request");

var options = { method: 'GET',
  url: 'https://api.sendinblue.com/v3/emailCampaigns' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/emailCampaigns",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/emailCampaigns"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/emailCampaigns")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/emailCampaigns"

response = requests.request("GET", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/emailCampaigns")
  .get()
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/emailCampaigns");
var request = new RestRequest(Method.GET);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

{
  "campaigns": [
    {
      "id": 12,
      "name": "EN - Sales Summer 2017",
      "subject": "20% OFF for 2017 Summer Sales",
      "type": "classic",
      "status": "sent",
      "scheduledAt": "2017-06-01T12:30:00Z",
      "testSent": true,
      "header": "[DEFAULT_HEADER]",
      "footer": "[DEFAULT_FOOTER]",
      "sender": {
        "email": "marketing@mycompany.com",
        "name": "Marketing"
      },
      "replyTo": "replyto@domain.com",
      "toField": "{FNAME} {LNAME}",
      "htmlContent": "This is my HTML Content",
      "shareLink": "http://example.com/fhsgccc.html?t=9865448900",
      "tag": "Newsletter",
      "createdAt": "2017-05-01T12:30:00Z",
      "modifiedAt": "2017-05-01T12:30:00Z",
      "inlineImageActivation": true,
      "mirrorActive": true,
      "recurring": false,
      "recipients": {
        "lists": [
          5
        ],
        "exclusionLists": [
          13
        ]
      },
      "statistics": {
        "globalStats": {
          "uniqueClicks": 2300,
          "clickers": 2665,
          "complaints": 1,
          "delivered": 19765,
          "sent": 19887,
          "softBounces": 100,
          "hardBounces": 87,
          "uniqueViews": 7779,
          "unsubscriptions": 2,
          "viewed": 8999
        },
        "campaignStats": [
          {
            "listId": 5,
            "uniqueClicks": 2300,
            "clickers": 2665,
            "complaints": 1,
            "delivered": 19765,
            "sent": 19887,
            "softBounces": 100,
            "hardBounces": 87,
            "uniqueViews": 7779,
            "unsubscriptions": 2,
            "viewed": 8999,
            "deferred": 30
          }
        ],
        "mirrorClick": 120,
        "remaining": 1000,
        "linksStats": {
          "http://myUrl1.domain.com": 80
        },
        "statsByDomain": {
          "yahoo": {
            "uniqueClicks": 2300,
            "clickers": 2665,
            "complaints": 1,
            "delivered": 19765,
            "sent": 19887,
            "softBounces": 100,
            "hardBounces": 87,
            "uniqueViews": 7779,
            "unsubscriptions": 2,
            "viewed": 8999,
            "deferred": 30
          },
          "gmail": {
            "uniqueClicks": 2300,
            "clickers": 2665,
            "complaints": 1,
            "delivered": 19765,
            "sent": 19887,
            "softBounces": 100,
            "hardBounces": 87,
            "uniqueViews": 7779,
            "unsubscriptions": 2,
            "viewed": 8999,
            "deferred": 30
          }
        }
      }
    },
    {
      "id": 22,
      "name": "Weekly - 1",
      "subject": "Week 1 - Newsletter",
      "type": "Classic",
      "status": "draft",
      "scheduledAt": "",
      "testSent": false,
      "header": "[DEFAULT_HEADER]",
      "footer": "[DEFAULT_FOOTER]",
      "sender": {
        "email": "newsletter@mycompany.com",
        "name": "Newsletter"
      },
      "replyTo": "replyto@domain.com",
      "toField": "{FNAME} {LNAME}",
      "htmlContent": "This is my HTML Content",
      "shareLink": "http://example.com/fhsgccc.html?t=9865448900",
      "tag": "Newsletter",
      "createdAt": "2017-05-01T12:30:00Z",
      "modifiedAt": "2017-05-01T12:30:00Z",
      "inlineImageActivation": true,
      "mirrorActive": true,
      "recurring": false,
      "recipients": {
        "lists": [
          10
        ],
        "exclusionLists": [
          45
        ]
      },
      "statistics": {
        "globalStats": {
          "uniqueClicks": 2300,
          "clickers": 2665,
          "complaints": 1,
          "delivered": 19765,
          "sent": 19887,
          "softBounces": 100,
          "hardBounces": 87,
          "uniqueViews": 7779,
          "unsubscriptions": 2,
          "viewed": 8999
        },
        "campaignStats": [
          {
            "listId": 10,
            "uniqueClicks": 2300,
            "clickers": 2665,
            "complaints": 1,
            "delivered": 19765,
            "sent": 19887,
            "softBounces": 100,
            "hardBounces": 87,
            "uniqueViews": 7779,
            "unsubscriptions": 2,
            "viewed": 8999,
            "deferred": 30
          }
        ],
        "mirrorClick": 120,
        "remaining": 1000,
        "linksStats": {
          "http://myUrl1.domain.com": {
            "nbClick": 80
          },
          "http://myUrl2.domain.com": {
            "nbClick": 80
          },
          "http://myUrl3.domain.com": {
            "nbClick": 80
          }
        },
        "statsByDomain": {
          "gmail": {
            "uniqueClicks": 2300,
            "clickers": 2665,
            "complaints": 1,
            "delivered": 19765,
            "sent": 19887,
            "softBounces": 100,
            "hardBounces": 87,
            "uniqueViews": 7779,
            "unsubscriptions": 2,
            "viewed": 8999,
            "deferred": 30
          },
          "aol": {
            "uniqueClicks": 2300,
            "clickers": 2665,
            "complaints": 1,
            "delivered": 19765,
            "sent": 19887,
            "softBounces": 100,
            "hardBounces": 87,
            "uniqueViews": 7779,
            "unsubscriptions": 2,
            "viewed": 8999,
            "deferred": 30
          }
        }
      }
    }
  ],
  "count": 2
}

Query Params

type
string

Filter on the type of the campaigns

status
string

Filter on the status of the campaign

startDate
date-time

Mandatory if endDate is used. Starting (urlencoded) UTC date-time (YYYY-MM-DDTHH:mm:ss.SSSZ) to filter the sent email campaigns. Prefer to pass your timezone in date-time format for accurate result ( only available if either 'status' not passed and if passed is set to 'sent' )

endDate
date-time

Mandatory if startDate is used. Ending (urlencoded) UTC date-time (YYYY-MM-DDTHH:mm:ss.SSSZ) to filter the sent email campaigns. Prefer to pass your timezone in date-time format for accurate result ( only available if either 'status' not passed and if passed is set to 'sent' )

limit
int64

Number of documents per page

offset
int64

Index of the first document in the page

Response

Email campaigns informations

campaignsarray
countinteger

Number of Email campaigns retrieved

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Create an email campaign

 

Header Auth

 Authentication is required for this endpoint.
posthttps://api.sendinblue.com/v3/emailCampaigns
curl --request POST \
  --url https://api.sendinblue.com/v3/emailCampaigns
var request = require("request");

var options = { method: 'POST',
  url: 'https://api.sendinblue.com/v3/emailCampaigns' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/emailCampaigns",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/emailCampaigns"

	req, _ := http.NewRequest("POST", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/emailCampaigns")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/emailCampaigns"

response = requests.request("POST", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/emailCampaigns")
  .post(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/emailCampaigns");
var request = new RestRequest(Method.POST);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

Try the API to see results

Body Params

tag
string

Tag of the campaign

sender
object

Sender details including email and name (optional). For example {'name':'xyz' , 'email':'example@abc.com'}

 
sender.name
string

Sender Name

sender.email
email
required

Sender email

name
string
required

Name of the campaign

htmlContent
string

Mandatory if htmlUrl and templateId are empty. Body of the message (HTML)

htmlUrl
url

Mandatory if htmlContent and templateId are empty. Url to the message (HTML)

templateId
int64

Mandatory if htmlContent and htmlUrl are empty. Id of the SMTP template with status 'active'. Used to copy only its content fetched from htmlContent/htmlUrl to an email campaign for RSS feature.

scheduledAt
date-time

Sending UTC date-time (YYYY-MM-DDTHH:mm:ss.SSSZ). Prefer to pass your timezone in date-time format for accurate result.

subject
string
required

Subject of the campaign

replyTo
email

Email on which the campaign recipients will be able to reply to

toField
string

To personalize the «To» Field. If you want to include the first name and last name of your recipient, add {FNAME} {LNAME}. These contact attributes must already exist in your SendinBlue account. If input parameter 'params' used please use {{contact.FNAME}} {{contact.LNAME}} for personalization

recipients
object

List ids to include/exclude from campaign

 
recipients.exclusionListIds
array of integers

List ids to exclude from the campaign

recipients.listIds
array of integers

Mandatory if scheduledAt is not empty. List Ids to send the campaign to

attachmentUrl
url

Absolute url of the attachment (no local file). Extension allowed: xlsx, xls, ods, docx, docm, doc, csv, pdf, txt, gif, jpg, jpeg, png, tif, tiff, rtf, bmp, cgm, css, shtml, html, htm, zip, xml, ppt, pptx, tar, ez, ics, mobi, msg, pub and eps

inlineImageActivation
boolean

Use true to embedded the images in your email. Final size of the email should be less than 4MB. Campaigns with embedded images can not be sent to more than 5000 contacts

mirrorActive
boolean

Use true to enable the mirror link

recurring
boolean

For trigger campagins use false to make sure a contact receives the same campaign only once

type
string
required

Type of the campaign

footer
string

Footer of the email campaign

header
string

Header of the email campaign

utmCampaign
string

Customize the utm_campaign value. If this field is empty, the campaign name will be used. Only alphanumeric characters and spaces are allowed

params
object

Pass the set of attributes to customize the type classic campaign. For example, {'FNAME':'Joe', 'LNAME':'Doe'}. Only available if 'type' is 'classic'

 

Response

Email campaign created

idinteger

ID of the object created

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Get campaign informations

 

Header Auth

 Authentication is required for this endpoint.
gethttps://api.sendinblue.com/v3/emailCampaigns/campaignId
curl --request GET \
  --url https://api.sendinblue.com/v3/emailCampaigns/campaignId
var request = require("request");

var options = { method: 'GET',
  url: 'https://api.sendinblue.com/v3/emailCampaigns/campaignId' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/emailCampaigns/campaignId",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/emailCampaigns/campaignId"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/emailCampaigns/campaignId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/emailCampaigns/campaignId"

response = requests.request("GET", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/emailCampaigns/campaignId")
  .get()
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/emailCampaigns/campaignId");
var request = new RestRequest(Method.GET);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

{
  "id": 22,
  "name": "Weekly - 1",
  "subject": "Week 1 - Newsletter",
  "type": "classic",
  "status": "draft",
  "scheduledAt": "2017-09-22T12:30:00Z",
  "testSent": false,
  "header": "[DEFAULT_HEADER]",
  "footer": "[DEFAULT_FOOTER]",
  "sender": {
    "email": "newsletter@mycompany.com",
    "name": "Newsletter"
  },
  "replyTo": "replyto@domain.com",
  "toField": "{FNAME} {LNAME}",
  "htmlContent": "This is my HTML Content",
  "shareLink": "http://dhh.sendinblue.com/fhsgccc.html?t=9865448900",
  "tag": "Newsletter",
  "createdAt": "2017-05-01T12:30:00Z",
  "modifiedAt": "2017-05-01T12:30:00Z",
  "inlineImageActivation": true,
  "mirrorActive": true,
  "recurring": false,
  "recipients": {
    "lists": [
      22
    ],
    "exclusionLists": [
      45
    ]
  },
  "statistics": {
    "globalStats": {
      "uniqueClicks": 2300,
      "clickers": 2665,
      "complaints": 1,
      "delivered": 19765,
      "sent": 19887,
      "softBounces": 100,
      "hardBounces": 87,
      "uniqueViews": 7779,
      "unsubscriptions": 2,
      "viewed": 8999
    },
    "campaignStats": [
      {
        "listId": 22,
        "uniqueClicks": 2300,
        "clickers": 2665,
        "complaints": 1,
        "delivered": 19765,
        "sent": 19887,
        "softBounces": 100,
        "hardBounces": 87,
        "uniqueViews": 7779,
        "unsubscriptions": 2,
        "viewed": 8999,
        "deferred": 30
      }
    ],
    "mirrorClick": 120,
    "remaining": 1000,
    "linksStats": {
      "http://myUrl1.domain.com": {
        "nbClick": 80
      },
      "http://myUrl2.domain.com": {
        "nbClick": 80
      },
      "http://myUrl3.domain.com": {
        "nbClick": 80
      }
    },
    "statsByDomain": {
      "gmail": {
        "uniqueClicks": 2300,
        "clickers": 2665,
        "complaints": 1,
        "delivered": 19765,
        "sent": 19887,
        "softBounces": 100,
        "hardBounces": 87,
        "uniqueViews": 7779,
        "unsubscriptions": 2,
        "viewed": 8999,
        "deferred": 30
      }
    }
  }
}

Path Params

campaignId
int64
required

Id of the campaign

Response

Email campaign informations

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Campaign ID not found

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Update a campaign

 

Header Auth

 Authentication is required for this endpoint.
puthttps://api.sendinblue.com/v3/emailCampaigns/campaignId
curl --request PUT \
  --url https://api.sendinblue.com/v3/emailCampaigns/campaignId
var request = require("request");

var options = { method: 'PUT',
  url: 'https://api.sendinblue.com/v3/emailCampaigns/campaignId' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/emailCampaigns/campaignId",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "PUT",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/emailCampaigns/campaignId"

	req, _ := http.NewRequest("PUT", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/emailCampaigns/campaignId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Put.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/emailCampaigns/campaignId"

response = requests.request("PUT", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/emailCampaigns/campaignId")
  .put(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/emailCampaigns/campaignId");
var request = new RestRequest(Method.PUT);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

Try the API to see results

Path Params

campaignId
int64
required

Id of the campaign

Body Params

tag
string

Tag of the campaign

sender
object

Sender details including email and/or name. For example {'name':'xyz' , 'email':'example@abc.com'}

 
sender.name
string

Sender Name from which the campaign emails are sent

sender.email
email

Sender email from which the campaign emails are sent

name
string

Name of the campaign

htmlContent
string

Body of the message (HTML version). REQUIRED if htmlUrl is empty

htmlUrl
url

Url which contents the body of the email message. REQUIRED if htmlContent is empty

scheduledAt
date-time

UTC date-time on which the campaign has to run (YYYY-MM-DDTHH:mm:ss.SSSZ). Prefer to pass your timezone in date-time format for accurate result.

subject
string

Subject of the campaign

replyTo
email

Email on which campaign recipients will be able to reply to

toField
string

To personalize the «To» Field. If you want to include the first name and last name of your recipient, add {FNAME} {LNAME}. These contact attributes must already exist in your SendinBlue account. If input parameter 'params' used please use {{contact.FNAME}} {{contact.LNAME}} for personalization

recipients
object

List ids to include/exclude from campaign

 
recipients.exclusionListIds
array of integers

List ids which have to be excluded from a campaign

recipients.listIds
array of integers

Lists Ids to send the campaign to. REQUIRED if already not present in campaign and scheduledAt is not empty

attachmentUrl
url

Absolute url of the attachment (no local file). Extension allowed: xlsx, xls, ods, docx, docm, doc, csv, pdf, txt, gif, jpg, jpeg, png, tif, tiff, rtf, bmp, cgm, css, shtml, html, htm, zip, xml, ppt, pptx, tar, ez, ics, mobi, msg, pub and eps

inlineImageActivation
boolean

Status of inline image. inlineImageActivation = false means image can’t be embedded, & inlineImageActivation = true means image can be embedded, in the email. You cannot send a campaign of more than 4MB with images embedded in the email. Campaigns with the images embedded in the email must be sent to less than 5000 contacts.

mirrorActive
boolean

Status of mirror links in campaign. mirrorActive = false means mirror links are deactivated, & mirrorActive = true means mirror links are activated, in the campaign

recurring
boolean

FOR TRIGGER ONLY ! Type of trigger campaign.recurring = false means contact can receive the same Trigger campaign only once, & recurring = true means contact can receive the same Trigger campaign several times

footer
string

Footer of the email campaign

header
string

Header of the email campaign

utmCampaign
string

Customize the utm_campaign value. If this field is empty, the campaign name will be used. Only alphanumeric characters and spaces are allowed

params
object

Pass the set of attributes to customize the type 'classic' campaign. For example, {'FNAME':'Joe', 'LNAME':'Doe'}.

 

Response

Email Campaign has been updated

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Campaign ID not found

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Delete an email campaign

 

Header Auth

 Authentication is required for this endpoint.
deletehttps://api.sendinblue.com/v3/emailCampaigns/campaignId
curl --request DELETE \
  --url https://api.sendinblue.com/v3/emailCampaigns/campaignId
var request = require("request");

var options = { method: 'DELETE',
  url: 'https://api.sendinblue.com/v3/emailCampaigns/campaignId' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/emailCampaigns/campaignId",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "DELETE",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/emailCampaigns/campaignId"

	req, _ := http.NewRequest("DELETE", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/emailCampaigns/campaignId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Delete.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/emailCampaigns/campaignId"

response = requests.request("DELETE", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/emailCampaigns/campaignId")
  .delete(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/emailCampaigns/campaignId");
var request = new RestRequest(Method.DELETE);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

Try the API to see results

Path Params

campaignId
int64
required

id of the campaign

Response

Email campaign has been deleted

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Campaign ID not found

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Send an email campaign id of the campaign immediately

 

Header Auth

 Authentication is required for this endpoint.
posthttps://api.sendinblue.com/v3/emailCampaigns/campaignId/sendNow
curl --request POST \
  --url https://api.sendinblue.com/v3/emailCampaigns/campaignId/sendNow
var request = require("request");

var options = { method: 'POST',
  url: 'https://api.sendinblue.com/v3/emailCampaigns/campaignId/sendNow' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/emailCampaigns/campaignId/sendNow",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/emailCampaigns/campaignId/sendNow"

	req, _ := http.NewRequest("POST", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/emailCampaigns/campaignId/sendNow")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/emailCampaigns/campaignId/sendNow"

response = requests.request("POST", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/emailCampaigns/campaignId/sendNow")
  .post(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/emailCampaigns/campaignId/sendNow");
var request = new RestRequest(Method.POST);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

Try the API to see results

Path Params

campaignId
int64
required

Id of the campaign

Response

Email campaign has been scheduled

Campaign could not be sent

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

You don't have enough credit to send your campaign. Please update your plan

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Campaign ID not found

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Send an email campaign to your test list

 

Header Auth

 Authentication is required for this endpoint.
posthttps://api.sendinblue.com/v3/emailCampaigns/campaignId/sendTest
curl --request POST \
  --url https://api.sendinblue.com/v3/emailCampaigns/campaignId/sendTest
var request = require("request");

var options = { method: 'POST',
  url: 'https://api.sendinblue.com/v3/emailCampaigns/campaignId/sendTest' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/emailCampaigns/campaignId/sendTest",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/emailCampaigns/campaignId/sendTest"

	req, _ := http.NewRequest("POST", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/emailCampaigns/campaignId/sendTest")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/emailCampaigns/campaignId/sendTest"

response = requests.request("POST", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/emailCampaigns/campaignId/sendTest")
  .post(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/emailCampaigns/campaignId/sendTest");
var request = new RestRequest(Method.POST);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

Try the API to see results

Path Params

campaignId
int64
required

Id of the campaign

Body Params

emailTo
array of strings

List of the email addresses of the recipients whom you wish to send the test mail. If left empty, the test mail will be sent to your entire test list.

Response

Test email has been sent successfully to all recipients

Test email could not be sent to the following email addresses

codeinteger

Response code

messagestring

Response message

unexistingEmailsarray
withoutListEmailsarray
blackListedEmailsarray

Campaign ID not found

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Export the recipients of a campaign

 

Header Auth

 Authentication is required for this endpoint.
posthttps://api.sendinblue.com/v3/emailCampaigns/campaignId/exportRecipients
curl --request POST \
  --url https://api.sendinblue.com/v3/emailCampaigns/campaignId/exportRecipients
var request = require("request");

var options = { method: 'POST',
  url: 'https://api.sendinblue.com/v3/emailCampaigns/campaignId/exportRecipients' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/emailCampaigns/campaignId/exportRecipients",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/emailCampaigns/campaignId/exportRecipients"

	req, _ := http.NewRequest("POST", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/emailCampaigns/campaignId/exportRecipients")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/emailCampaigns/campaignId/exportRecipients"

response = requests.request("POST", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/emailCampaigns/campaignId/exportRecipients")
  .post(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/emailCampaigns/campaignId/exportRecipients");
var request = new RestRequest(Method.POST);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

Try the API to see results

Path Params

campaignId
int64
required

Id of the campaign

Body Params

notifyURL
url

Webhook called once the export process is finished

recipientsType
string
required

Type of recipients to export for a campaign

Response

Recipient export request has been accepted

processIdinteger

Id of the process created

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Campaign ID not found

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Send the report of a campaigns

A PDF will be sent to the specified email addresses

 

Header Auth

 Authentication is required for this endpoint.
posthttps://api.sendinblue.com/v3/emailCampaigns/campaignId/sendReport
curl --request POST \
  --url https://api.sendinblue.com/v3/emailCampaigns/campaignId/sendReport
var request = require("request");

var options = { method: 'POST',
  url: 'https://api.sendinblue.com/v3/emailCampaigns/campaignId/sendReport' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/emailCampaigns/campaignId/sendReport",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/emailCampaigns/campaignId/sendReport"

	req, _ := http.NewRequest("POST", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/emailCampaigns/campaignId/sendReport")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/emailCampaigns/campaignId/sendReport"

response = requests.request("POST", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/emailCampaigns/campaignId/sendReport")
  .post(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/emailCampaigns/campaignId/sendReport");
var request = new RestRequest(Method.POST);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

Try the API to see results

Path Params

campaignId
int64
required

Id of the campaign

Body Params

language
string

Language of email content for campaign report sending.

email
object
required

Email sending credentials including subject, body, to, cc etc.

 
email.subject
string

Subject of the email message

email.to
array of strings

Email addresses of the recipients

email.contentType
string

Type of the message body

email.bcc
array of strings

Email addresses of the recipients in bcc

email.cc
array of strings

Email addresses of the recipients in cc

email.body
string

Body of the email message

Response

Report has been successfully sent to the defined recipients

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Campaign ID not found

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Update a campaign status

 

Header Auth

 Authentication is required for this endpoint.
puthttps://api.sendinblue.com/v3/emailCampaigns/campaignId/status
curl --request PUT \
  --url https://api.sendinblue.com/v3/emailCampaigns/campaignId/status
var request = require("request");

var options = { method: 'PUT',
  url: 'https://api.sendinblue.com/v3/emailCampaigns/campaignId/status' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/emailCampaigns/campaignId/status",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "PUT",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/emailCampaigns/campaignId/status"

	req, _ := http.NewRequest("PUT", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/emailCampaigns/campaignId/status")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Put.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/emailCampaigns/campaignId/status"

response = requests.request("PUT", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/emailCampaigns/campaignId/status")
  .put(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/emailCampaigns/campaignId/status");
var request = new RestRequest(Method.PUT);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

Try the API to see results

Path Params

campaignId
int64
required

Id of the campaign

Body Params

status
string

Response

The campaign status has been updated successfully

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Campaign ID not found

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Get your SMTP activity aggregated per day

 

Header Auth

 Authentication is required for this endpoint.
gethttps://api.sendinblue.com/v3/smtp/statistics/reports
curl --request GET \
  --url https://api.sendinblue.com/v3/smtp/statistics/reports
var request = require("request");

var options = { method: 'GET',
  url: 'https://api.sendinblue.com/v3/smtp/statistics/reports' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/smtp/statistics/reports",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/smtp/statistics/reports"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/smtp/statistics/reports")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/smtp/statistics/reports"

response = requests.request("GET", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/smtp/statistics/reports")
  .get()
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/smtp/statistics/reports");
var request = new RestRequest(Method.GET);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

{
  "reports": [
    {
      "date": "2017-04-30",
      "requests": 10756,
      "delivered": 10103,
      "hardBounces": 21,
      "softBounces": 137,
      "clicks": 1026,
      "uniqueClicks": 720,
      "opens": 5091,
      "uniqueOpens": 2318,
      "spamReports": 0,
      "blocked": 519,
      "invalid": 1,
      "unsubscribed": 0
    },
    {
      "date": "2017-05-01",
      "requests": 18812,
      "delivered": 17499,
      "hardBounces": 34,
      "softBounces": 254,
      "clicks": 1514,
      "uniqueClicks": 1090,
      "opens": 10089,
      "uniqueOpens": 4393,
      "spamReports": 0,
      "blocked": 920,
      "invalid": 2,
      "unsubscribed": 3
    }
  ]
}

Query Params

limit
int64

Number of documents returned per page

offset
int64

Index of the first document on the page

startDate
date

Mandatory if endDate is used. Starting date of the report (YYYY-MM-DD)

endDate
date

Mandatory if startDate is used. Ending date of the report (YYYY-MM-DD)

days
integer

Number of days in the past including today (positive integer). Not compatible with 'startDate' and 'endDate'

tag
string

Tag of the emails

Response

Aggregated report informations

reportsarray

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Get your SMTP activity aggregated over a period of time

 

Header Auth

 Authentication is required for this endpoint.
gethttps://api.sendinblue.com/v3/smtp/statistics/aggregatedReport
curl --request GET \
  --url https://api.sendinblue.com/v3/smtp/statistics/aggregatedReport
var request = require("request");

var options = { method: 'GET',
  url: 'https://api.sendinblue.com/v3/smtp/statistics/aggregatedReport' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/smtp/statistics/aggregatedReport",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/smtp/statistics/aggregatedReport"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/smtp/statistics/aggregatedReport")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/smtp/statistics/aggregatedReport"

response = requests.request("GET", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/smtp/statistics/aggregatedReport")
  .get()
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/smtp/statistics/aggregatedReport");
var request = new RestRequest(Method.GET);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

{
  "range": "2016-09-08|2017-04-28",
  "requests": 19887,
  "delivered": 18996,
  "hardBounces": 234,
  "softBounces": 1533,
  "clicks": 9987,
  "uniqueClicks": 8766,
  "opens": 17654,
  "uniqueOpens": 13688,
  "spamReports": 1,
  "blocked": 2,
  "invalid": 0,
  "unsubscribed": 2
}

Query Params

startDate
date

Mandatory if endDate is used. Starting date of the report (YYYY-MM-DD). Must be lower than equal to endDate

endDate
date

Mandatory if startDate is used. Ending date of the report (YYYY-MM-DD). Must be greater than equal to startDate

days
integer

Number of days in the past including today (positive integer). Not compatible with 'startDate' and 'endDate'

tag
string

Tag of the emails

Response

Aggregated report informations

rangestring

Time frame of the report

requestsinteger

Number of requests for the timeframe

deliveredinteger

Number of delivered emails for the timeframe

hardBouncesinteger

Number of hardbounces for the timeframe

softBouncesinteger

Number of softbounces for the timeframe

clicksinteger

Number of clicks for the timeframe

uniqueClicksinteger

Number of unique clicks for the timeframe

opensinteger

Number of openings for the timeframe

uniqueOpensinteger

Number of unique openings for the timeframe

spamReportsinteger

Number of complaint (spam report) for the timeframe

blockedinteger

Number of blocked contact emails for the timeframe

invalidinteger

Number of invalid emails for the timeframe

unsubscribedinteger

Number of unsubscribed emails for the timeframe

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Get all your SMTP activity (unaggregated events)

 

Header Auth

 Authentication is required for this endpoint.
gethttps://api.sendinblue.com/v3/smtp/statistics/events
curl --request GET \
  --url https://api.sendinblue.com/v3/smtp/statistics/events
var request = require("request");

var options = { method: 'GET',
  url: 'https://api.sendinblue.com/v3/smtp/statistics/events' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/smtp/statistics/events",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/smtp/statistics/events"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/smtp/statistics/events")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/smtp/statistics/events"

response = requests.request("GET", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/smtp/statistics/events")
  .get()
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/smtp/statistics/events");
var request = new RestRequest(Method.GET);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

{
  "events": [
    {
      "email": "john.smith@example.com",
      "date": "2017-03-12T12:30:00Z",
      "messageId": "<201798300811.5787683@example.domain.com>",
      "event": "deferred",
      "reason": "Error connection timeout",
      "tag": "OrderConfirmation",
      "from": "john@example.com"
    },
    {
      "email": "john.smith@example.com",
      "date": "2017-03-13T16:30:00Z",
      "messageId": "<201798300811.5787683@example.domain.com>",
      "event": "delivered",
      "tag": "OrderConfirmation",
      "from": "john@example.com"
    }
  ]
}

Query Params

limit
int64

Number limitation for the result returned

offset
int64

Beginning point in the list to retrieve from.

startDate
date

Mandatory if endDate is used. Starting date of the report (YYYY-MM-DD). Must be lower than equal to endDate

endDate
date

Mandatory if startDate is used. Ending date of the report (YYYY-MM-DD). Must be greater than equal to startDate

days
integer

Number of days in the past including today (positive integer). Not compatible with 'startDate' and 'endDate'

email
email

Filter the report for a specific email addresses

event
string

Filter the report for a specific event type

tags
string

Filter the report for tags (serialized and urlencoded array)

messageId
string

Filter on a specific message id

templateId
int64

Filter on a specific template id

Response

Email events report informations

eventsarray

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Get the list of SMTP templates

 

Header Auth

 Authentication is required for this endpoint.
gethttps://api.sendinblue.com/v3/smtp/templates
curl --request GET \
  --url https://api.sendinblue.com/v3/smtp/templates
var request = require("request");

var options = { method: 'GET',
  url: 'https://api.sendinblue.com/v3/smtp/templates' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/smtp/templates",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/smtp/templates"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/smtp/templates")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/smtp/templates"

response = requests.request("GET", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/smtp/templates")
  .get()
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/smtp/templates");
var request = new RestRequest(Method.GET);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

{
  "count": 2,
  "templates": [
    {
      "id": 5,
      "name": "ChristomasTimeTemplate",
      "subject": "Merry Christmas",
      "isActive": false,
      "testSent": false,
      "sender": {
        "name": "John",
        "email": "john.smith@example.com"
      },
      "replyTo": "replyto@domain.com",
      "toField": "",
      "tag": "Festival",
      "htmlContent": "HTML CONTENT 1",
      "createdAt": "2016-02-24T14:44:24Z",
      "modifiedAt": "2016-02-24T15:37:11Z"
    },
    {
      "id": 12,
      "name": "SummerSales2017Template",
      "subject": "Enjoy our summer Sales !",
      "isActive": true,
      "testSent": false,
      "sender": {
        "name": "John",
        "email": "john.smith@example.com"
      },
      "replyTo": "replyto@domain.com",
      "toField": "",
      "tag": "Summer",
      "htmlContent": "HTML CONTENT 2",
      "createdAt": "2016-02-25T11:53:26Z",
      "modifiedAt": "2016-02-25T11:53:26Z"
    }
  ]
}

Query Params

templateStatus
boolean

Filter on the status of the template. Active = true, inactive = false

limit
int64

Number of documents returned per page

offset
int64

Index of the first document in the page

Response

SMTP templates informations

countinteger

Count of smtp templates

templatesarray

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Create an smtp template

 

Header Auth

 Authentication is required for this endpoint.
posthttps://api.sendinblue.com/v3/smtp/templates
curl --request POST \
  --url https://api.sendinblue.com/v3/smtp/templates
var request = require("request");

var options = { method: 'POST',
  url: 'https://api.sendinblue.com/v3/smtp/templates' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/smtp/templates",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/smtp/templates"

	req, _ := http.NewRequest("POST", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/smtp/templates")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/smtp/templates"

response = requests.request("POST", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/smtp/templates")
  .post(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/smtp/templates");
var request = new RestRequest(Method.POST);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

Try the API to see results

Body Params

tag
string

Tag of the template

sender
object

Sender details including email and name (optional). For example {'name':'xyz' , 'email':'example@abc.com'}

 
sender.name
string

Name of the sender. If not passed, will be set to default

sender.email
email
required

Email of the sender

templateName
string
required

Name of the template

htmlContent
string

Body of the message (HTML version). The field must have more than 10 characters. REQUIRED if htmlUrl is empty

htmlUrl
url

Url which contents the body of the email message. REQUIRED if htmlContent is empty

subject
string
required

Subject of the template

replyTo
email

Email on which campaign recipients will be able to reply to

toField
string

To personalize the «To» Field. If you want to include the first name and last name of your recipient, add {FNAME} {LNAME}. These contact attributes must already exist in your SendinBlue account. If input parameter 'params' used please use {{contact.FNAME}} {{contact.LNAME}} for personalization

attachmentUrl
url

Absolute url of the attachment (no local file). Extension allowed: xlsx, xls, ods, docx, docm, doc, csv, pdf, txt, gif, jpg, jpeg, png, tif, tiff, rtf, bmp, cgm, css, shtml, html, htm, zip, xml, ppt, pptx, tar, ez, ics, mobi, msg, pub and eps

isActive
boolean

Status of template. isActive = true means template is active and isActive = false means template is inactive

Response

SMTP template created

idinteger

ID of the object created

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Returns the template informations

 

Header Auth

 Authentication is required for this endpoint.
gethttps://api.sendinblue.com/v3/smtp/templates/templateId
curl --request GET \
  --url https://api.sendinblue.com/v3/smtp/templates/templateId
var request = require("request");

var options = { method: 'GET',
  url: 'https://api.sendinblue.com/v3/smtp/templates/templateId' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/smtp/templates/templateId",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/smtp/templates/templateId"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/smtp/templates/templateId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/smtp/templates/templateId"

response = requests.request("GET", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/smtp/templates/templateId")
  .get()
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/smtp/templates/templateId");
var request = new RestRequest(Method.GET);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

{
  "id": 33,
  "name": "OrderConfirmation",
  "subject": "Order Confirmation : Thanks for your Purchase !",
  "isActive": true,
  "testSent": false,
  "sender": {
    "name": "John",
    "email": "john.smith@example.com"
  },
  "replyTo": "replyto@domain.com",
  "toField": "",
  "tag": "",
  "htmlContent": "HTML CONTENT 4",
  "createdAt": "2016-02-25T11:53:26Z",
  "modifiedAt": "2016-02-25T11:53:26Z"
}

Path Params

templateId
int64
required

id of the template

Response

Email template informations

idinteger

ID of the template

namestring

Name of the template

subjectstring

Subject of the template

isActiveboolean

Status of template (true=active, false=inactive)

testSentboolean

Status of test sending for the template (true=test email has been sent, false=test email has not been sent)

senderobject
sender.namestring

From email for the template

sender.emailstring

From email for the template

replyTostring

Email defined as the "Reply to" for the template

toFieldstring

Customisation of the "to" field for the template

tagstring

Tag of the template

htmlContentstring

HTML content of the template

createdAtstring

Creation UTC date-time of the template (YYYY-MM-DDTHH:mm:ss.SSSZ)

modifiedAtstring

Last modification UTC date-time of the template (YYYY-MM-DDTHH:mm:ss.SSSZ)

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Template ID not found

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Updates an smtp templates

 

Header Auth

 Authentication is required for this endpoint.
puthttps://api.sendinblue.com/v3/smtp/templates/templateId
curl --request PUT \
  --url https://api.sendinblue.com/v3/smtp/templates/templateId
var request = require("request");

var options = { method: 'PUT',
  url: 'https://api.sendinblue.com/v3/smtp/templates/templateId' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/smtp/templates/templateId",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "PUT",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/smtp/templates/templateId"

	req, _ := http.NewRequest("PUT", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/smtp/templates/templateId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Put.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/smtp/templates/templateId"

response = requests.request("PUT", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/smtp/templates/templateId")
  .put(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/smtp/templates/templateId");
var request = new RestRequest(Method.PUT);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

Try the API to see results

Path Params

templateId
int64
required

id of the template

Body Params

tag
string

Tag of the template

sender
object

Sender details including email and/or name. For example {'name':'xyz' , 'email':'example@abc.com'}

 
sender.name
string

Name of the sender

sender.email
email

Email of the sender

templateName
string

Name of the template

htmlContent
string

Required if htmlUrl is empty. Body of the message (HTML must have more than 10 characters)

htmlUrl
url

Required if htmlContent is empty. URL to the body of the email (HTML)

subject
string

Subject of the email

replyTo
email

Email on which campaign recipients will be able to reply to

toField
string

To personalize the «To» Field. If you want to include the first name and last name of your recipient, add {FNAME} {LNAME}. These contact attributes must already exist in your SendinBlue account. If input parameter 'params' used please use {{contact.FNAME}} {{contact.LNAME}} for personalization

attachmentUrl
url

Absolute url of the attachment (no local file). Extension allowed: xlsx, xls, ods, docx, docm, doc, csv, pdf, txt, gif, jpg, jpeg, png, tif, tiff, rtf, bmp, cgm, css, shtml, html, htm, zip, xml, ppt, pptx, tar, ez, ics, mobi, msg, pub and eps

isActive
boolean

Status of the template. isActive = false means template is inactive, isActive = true means template is active

Response

SMTP template updated

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Template ID not found

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Delete an inactive smtp template

 

Header Auth

 Authentication is required for this endpoint.
deletehttps://api.sendinblue.com/v3/smtp/templates/templateId
curl --request DELETE \
  --url https://api.sendinblue.com/v3/smtp/templates/templateId
var request = require("request");

var options = { method: 'DELETE',
  url: 'https://api.sendinblue.com/v3/smtp/templates/templateId' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/smtp/templates/templateId",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "DELETE",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/smtp/templates/templateId"

	req, _ := http.NewRequest("DELETE", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/smtp/templates/templateId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Delete.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/smtp/templates/templateId"

response = requests.request("DELETE", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/smtp/templates/templateId")
  .delete(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/smtp/templates/templateId");
var request = new RestRequest(Method.DELETE);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

Try the API to see results

Path Params

templateId
int64
required

id of the template

Response

Inactive smtp template has been deleted

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Template ID not found

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Send a template to your test list

 

Header Auth

 Authentication is required for this endpoint.
posthttps://api.sendinblue.com/v3/smtp/templates/templateId/sendTest
curl --request POST \
  --url https://api.sendinblue.com/v3/smtp/templates/templateId/sendTest
var request = require("request");

var options = { method: 'POST',
  url: 'https://api.sendinblue.com/v3/smtp/templates/templateId/sendTest' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/smtp/templates/templateId/sendTest",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/smtp/templates/templateId/sendTest"

	req, _ := http.NewRequest("POST", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/smtp/templates/templateId/sendTest")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/smtp/templates/templateId/sendTest"

response = requests.request("POST", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/smtp/templates/templateId/sendTest")
  .post(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/smtp/templates/templateId/sendTest");
var request = new RestRequest(Method.POST);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

Try the API to see results

Path Params

templateId
int64
required

Id of the template

Body Params

emailTo
array of strings

List of the email addresses of the recipients whom you wish to send the test mail. If left empty, the test mail will be sent to your entire test list.

Response

Test email has been sent successfully to all recipients

Test email could not be sent to the following email addresses

codeinteger

Response code

messagestring

Response message

unexistingEmailsarray
withoutListEmailsarray
blackListedEmailsarray

Template ID not found

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Send a template

This endpoint is deprecated. Prefer v3/smtp/email instead.

 

Header Auth

 Authentication is required for this endpoint.
posthttps://api.sendinblue.com/v3/smtp/templates/templateId/send
curl --request POST \
  --url https://api.sendinblue.com/v3/smtp/templates/templateId/send
var request = require("request");

var options = { method: 'POST',
  url: 'https://api.sendinblue.com/v3/smtp/templates/templateId/send' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/smtp/templates/templateId/send",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/smtp/templates/templateId/send"

	req, _ := http.NewRequest("POST", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/smtp/templates/templateId/send")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/smtp/templates/templateId/send"

response = requests.request("POST", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/smtp/templates/templateId/send")
  .post(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/smtp/templates/templateId/send");
var request = new RestRequest(Method.POST);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

Try the API to see results

Path Params

templateId
int64
required

Id of the template

Body Params

emailTo
array of strings
required

List of the email addresses of the recipients. For example, ['abc@example.com', 'asd@example.com'].

emailBcc
array of strings

List of the email addresses of the recipients in bcc

emailCc
array of strings

List of the email addresses of the recipients in cc

replyTo
email

Email address which shall be used by campaign recipients to reply back

attachmentUrl
url

Absolute url of the attachment (no local file). Extension allowed: xlsx, xls, ods, docx, docm, doc, csv, pdf, txt, gif, jpg, jpeg, png, tif, tiff, rtf, bmp, cgm, css, shtml, html, htm, zip, xml, ppt, pptx, tar, ez, ics, mobi, msg, pub and eps

attachment
array of objects

Pass the list of content (base64 encoded) and name of the attachment. For example, [{'content':'base64 encoded content 1', 'name':'attcahment1'}, {'content':'base64 encoded content 2', 'name':'attcahment2'}].

content
name
headers
object

Pass the set of headers that shall be sent along the mail headers in the original email. 'sender.ip' header can be set (only for dedicated ip users) to mention the IP to be used for sending transactional emails. For example, {'Content-Type':'text/html', 'charset':'iso-8859-1', 'sender.ip':'1.2.3.4'}

 
attributes
object

Pass the set of attributes to customize the template. For example, {'FNAME':'Joe', 'LNAME':'Doe'}

 
tags
array of strings

Tag your emails to find them more easily

Response

Email has been sent successfully to all recipients

messageIdstring

Message ID of the template Email sent

Email could not be sent to the following email addresses

codeinteger

Response code

messagestring

Response message

unexistingEmailsarray
withoutListEmailsarray
blackListedEmailsarray

Template ID not found

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Send a transactional email

 

Header Auth

 Authentication is required for this endpoint.
posthttps://api.sendinblue.com/v3/smtp/email
curl --request POST \
  --url https://api.sendinblue.com/v3/smtp/email
var request = require("request");

var options = { method: 'POST',
  url: 'https://api.sendinblue.com/v3/smtp/email' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/smtp/email",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/smtp/email"

	req, _ := http.NewRequest("POST", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/smtp/email")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/smtp/email"

response = requests.request("POST", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/smtp/email")
  .post(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/smtp/email");
var request = new RestRequest(Method.POST);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

Try the API to see results

Body Params

sender
object

Mandatory if 'templateId' is not passed. Pass name (optional) and email of sender from which emails will be sent. For example, {'name':'Mary from MyShop', 'email':'no-reply@myshop.com'}

 
sender.name
string

Name of the sender from which the emails will be sent

sender.email
email
required

Email of the sender from which the emails will be sent

to
array of objects
required

List of email addresses and names (optional) of the recipients. For example, [{'name':'Jimmy', 'email':'jimmy98@example.com'}, {'name':'Joe', 'email':'joe@example.com'}]

email
name
bcc
array of objects

List of email addresses and names (optional) of the recipients in bcc

email
name
cc
array of objects

List of email addresses and names (optional) of the recipients in cc

email
name
htmlContent
string

HTML body of the message ( Mandatory if 'templateId' is not passed, ignored if 'templateId' is passed )

textContent
string

Plain Text body of the message ( Ignored if 'templateId' is passed )

subject
string

Subject of the message. Mandatory if 'templateId' is not passed

replyTo
object

Email (required), along with name (optional), on which transactional mail recipients will be able to reply back. For example, {'email':'ann6533@example.com', 'name':'Ann'}.

 
replyTo.email
email
required

Email address in reply to

replyTo.name
string

Name in reply to

attachment
array of objects

Pass the absolute URL (no local file) or the base64 content of the attachment along with the attachment name (Mandatory if attachment content is passed). For example, [{'url':'https://attachment.domain.com/myAttachmentFromUrl.jpg', 'name':'My attachment 1'}, {'content':'base64 exmaple content', 'name':'My attachment 2'}]. Allowed extensions for attachment file: xlsx, xls, ods, docx, docm, doc, csv, pdf, txt, gif, jpg, jpeg, png, tif, tiff, rtf, bmp, cgm, css, shtml, html, htm, zip, xml, ppt, pptx, tar, ez, ics, mobi, msg, pub and eps ( Ignored if 'templateId' is passed )

url
content
name
headers
object

Pass the set of headers that shall be sent along the mail headers in the original email. 'sender.ip' header can be set (only for dedicated ip users) to mention the IP to be used for sending transactional emails. For example, {'Content-Type':'text/html', 'charset':'iso-8859-1', 'sender.ip':'1.2.3.4'}

 
templateId
int64

Id of the template

params
object

Pass the set of attributes to customize the template. For example, {'FNAME':'Joe', 'LNAME':'Doe'}.

 
tags
array of strings

Tag your emails to find them more easily

Response

SMTP email sent

messageIdstring

Message ID of the SMTP Email sent

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Delete hardbounces

Delete hardbounces. To use carefully (e.g. in case of temporary ISP failures)

 

Header Auth

 Authentication is required for this endpoint.
posthttps://api.sendinblue.com/v3/smtp/deleteHardbounces
curl --request POST \
  --url https://api.sendinblue.com/v3/smtp/deleteHardbounces
var request = require("request");

var options = { method: 'POST',
  url: 'https://api.sendinblue.com/v3/smtp/deleteHardbounces' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/smtp/deleteHardbounces",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/smtp/deleteHardbounces"

	req, _ := http.NewRequest("POST", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/smtp/deleteHardbounces")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/smtp/deleteHardbounces"

response = requests.request("POST", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/smtp/deleteHardbounces")
  .post(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/smtp/deleteHardbounces");
var request = new RestRequest(Method.POST);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

Try the API to see results

Body Params

startDate
date

Starting date (YYYY-MM-DD) of the time period for deletion. The hardbounces occurred after this date will be deleted. Must be less than or equal to the endDate

endDate
date

Ending date (YYYY-MM-DD) of the time period for deletion. The hardbounces until this date will be deleted. Must be greater than or equal to the startDate

contactEmail
email

Target a specific email address

Response

Hardbounces deleted

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Transactional SMS

 
Suggest Edits

Send the SMS campaign to the specified mobile number

 

Header Auth

 Authentication is required for this endpoint.
posthttps://api.sendinblue.com/v3/transactionalSMS/sms
curl --request POST \
  --url https://api.sendinblue.com/v3/transactionalSMS/sms
var request = require("request");

var options = { method: 'POST',
  url: 'https://api.sendinblue.com/v3/transactionalSMS/sms' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/transactionalSMS/sms",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/transactionalSMS/sms"

	req, _ := http.NewRequest("POST", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/transactionalSMS/sms")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/transactionalSMS/sms"

response = requests.request("POST", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/transactionalSMS/sms")
  .post(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/transactionalSMS/sms");
var request = new RestRequest(Method.POST);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

Try the API to see results

Body Params

sender
string
required

Name of the sender. Only alphanumeric characters. No more than 11 characters

recipient
string
required

Mobile number to send SMS with the country code

content
string
required

Content of the message. If more than 160 characters long, will be sent as multiple text messages

type
string

Type of the SMS

tag
string

Tag of the message

webUrl
url

Webhook to call for each event triggered by the message (delivered etc.)

Response

SMS has been sent successfully to the recipient

referencestring
messageIdinteger

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

You don't have enough credit to send your SMS. Please update your plan

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Get all the SMS activity (unaggregated events)

 

Header Auth

 Authentication is required for this endpoint.
gethttps://api.sendinblue.com/v3/transactionalSMS/statistics/events
curl --request GET \
  --url https://api.sendinblue.com/v3/transactionalSMS/statistics/events
var request = require("request");

var options = { method: 'GET',
  url: 'https://api.sendinblue.com/v3/transactionalSMS/statistics/events' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/transactionalSMS/statistics/events",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/transactionalSMS/statistics/events"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/transactionalSMS/statistics/events")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/transactionalSMS/statistics/events"

response = requests.request("GET", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/transactionalSMS/statistics/events")
  .get()
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/transactionalSMS/statistics/events");
var request = new RestRequest(Method.GET);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

{
  "events": [
    {
      "phoneNumber": "00911059469013",
      "date": "2015-05-20",
      "messageId": "1473139351170140",
      "event": "sent",
      "reason": "Recipient is currently unreachable",
      "tag": "cabWaiting"
    },
    {
      "phoneNumber": "00911059469013",
      "date": "2015-05-20",
      "messageId": "1473139351170140",
      "event": "delivered",
      "reason": "Recipient is currently unreachable",
      "tag": "cabRequest"
    }
  ]
}

Query Params

limit
int64

Number of documents per page

startDate
date

Mandatory if endDate is used. Starting date (YYYY-MM-DD) of the report

endDate
date

Mandatory if startDate is used. Ending date (YYYY-MM-DD) of the report

offset
int64

Index of the first document of the page

days
integer

Number of days in the past including today (positive integer). Not compatible with 'startDate' and 'endDate'

phoneNumber
string

Filter the report for a specific phone number

event
string

Filter the report for specific events

tags
string

Filter the report for specific tags passed as a serialized urlencoded array

Response

Sms events report informations

eventsarray

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Get your SMS activity aggregated over a period of time

 

Header Auth

 Authentication is required for this endpoint.
gethttps://api.sendinblue.com/v3/transactionalSMS/statistics/aggregatedReport
curl --request GET \
  --url https://api.sendinblue.com/v3/transactionalSMS/statistics/aggregatedReport
var request = require("request");

var options = { method: 'GET',
  url: 'https://api.sendinblue.com/v3/transactionalSMS/statistics/aggregatedReport' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/transactionalSMS/statistics/aggregatedReport",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/transactionalSMS/statistics/aggregatedReport"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/transactionalSMS/statistics/aggregatedReport")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/transactionalSMS/statistics/aggregatedReport"

response = requests.request("GET", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/transactionalSMS/statistics/aggregatedReport")
  .get()
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/transactionalSMS/statistics/aggregatedReport");
var request = new RestRequest(Method.GET);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

{
  "range": "2015-05-22|2017-11-29",
  "requests": 54,
  "delivered": 16,
  "hardBounces": 5,
  "softBounces": 26,
  "blocked": 4,
  "unsubscribed": 10,
  "replied": 8,
  "accepted": 6,
  "rejected": 14
}

Query Params

startDate
date

Mandatory if endDate is used. Starting date (YYYY-MM-DD) of the report

endDate
date

Mandatory if startDate is used. Ending date (YYYY-MM-DD) of the report

days
integer

Number of days in the past including today (positive integer). Not compatible with startDate and endDate

tag
string

Filter on a tag

Response

Aggregated SMS report informations

rangestring

Time frame of the report

requestsinteger

Number of requests for the timeframe

deliveredinteger

Number of delivered SMS for the timeframe

hardBouncesinteger

Number of hardbounces for the timeframe

softBouncesinteger

Number of softbounces for the timeframe

blockedinteger

Number of blocked contact for the timeframe

unsubscribedinteger

Number of unsubscription for the timeframe

repliedinteger

Number of answered SMS for the timeframe

acceptedinteger

Number of accepted for the timeframe

rejectedinteger

Number of rejected for the timeframe

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Get your SMS activity aggregated per day

 

Header Auth

 Authentication is required for this endpoint.
gethttps://api.sendinblue.com/v3/transactionalSMS/statistics/reports
curl --request GET \
  --url https://api.sendinblue.com/v3/transactionalSMS/statistics/reports
var request = require("request");

var options = { method: 'GET',
  url: 'https://api.sendinblue.com/v3/transactionalSMS/statistics/reports' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/transactionalSMS/statistics/reports",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/transactionalSMS/statistics/reports"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/transactionalSMS/statistics/reports")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/transactionalSMS/statistics/reports"

response = requests.request("GET", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/transactionalSMS/statistics/reports")
  .get()
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/transactionalSMS/statistics/reports");
var request = new RestRequest(Method.GET);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

{
  "reports": [
    {
      "date": "2017-04-30",
      "requests": 10756,
      "delivered": 10103,
      "hardBounces": 21,
      "softBounces": 137,
      "blocked": 1026,
      "unsubscribed": 720,
      "replied": 5091,
      "accepted": 2318,
      "rejected": 0
    },
    {
      "date": "2017-05-01",
      "requests": 18812,
      "delivered": 17499,
      "hardBounces": 34,
      "softBounces": 254,
      "blocked": 1514,
      "unsubscribed": 1090,
      "replied": 10089,
      "accepted": 4393,
      "rejected": 0
    },
    {
      "date": "2017-05-02",
      "requests": 14321,
      "delivered": 13427,
      "hardBounces": 16,
      "softBounces": 176,
      "blocked": 1646,
      "unsubscribed": 1170,
      "replied": 11563,
      "accepted": 4689,
      "rejected": 0
    }
  ]
}

Query Params

startDate
date

Mandatory if endDate is used. Starting date (YYYY-MM-DD) of the report

endDate
date

Mandatory if startDate is used. Ending date (YYYY-MM-DD) of the report

days
integer

Number of days in the past including today (positive integer). Not compatible with 'startDate' and 'endDate'

tag
string

Filter on a tag

Response

Aggregated SMS report informations

reportsarray

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

 
Suggest Edits

Get all the contacts

 

Header Auth

 Authentication is required for this endpoint.
gethttps://api.sendinblue.com/v3/contacts
curl --request GET \
  --url https://api.sendinblue.com/v3/contacts
var request = require("request");

var options = { method: 'GET', url: 'https://api.sendinblue.com/v3/contacts' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/contacts",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/contacts"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/contacts")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/contacts"

response = requests.request("GET", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/contacts")
  .get()
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/contacts");
var request = new RestRequest(Method.GET);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

{
  "contacts": [
    {
      "email": "contact1@example.com",
      "id": 247,
      "emailBlacklisted": true,
      "smsBlacklisted": true,
      "modifiedAt": "2017-05-01T17:05:03Z",
      "listIds": [
        43,
        58
      ],
      "attributes": {
        "SMS": "33058407250",
        "IDENTIFICATION": "1-3RHQ-259",
        "CIV": "MS",
        "LAST_NAME": "Brennon",
        "FIRST_NAME": "Meg",
        "DOB": "1986-05-02",
        "ADDRESS": "1 5th avenue",
        "ZIP_CODE": "44300",
        "CITY": "New-York",
        "ACTION_CODE": "17HH98CH"
      }
    },
    {
      "email": "33058407248@mailin-sms.com",
      "id": 245,
      "emailBlacklisted": true,
      "smsBlacklisted": false,
      "modifiedAt": "2017-05-01T17:05:03Z",
      "listIds": [
        43,
        61,
        58
      ],
      "attributes": {
        "SMS": "33058407248",
        "IDENTIFICATION": "1-78JS-432",
        "CIV": "MS",
        "LAST_NAME": "Press",
        "FIRST_NAME": "Sophia",
        "DOB": "1980-09-11",
        "ADDRESS": "5 Flower Street",
        "ZIP_CODE": "44119",
        "CITY": "Seattle",
        "ACTION_CODE": "17HU765"
      }
    }
  ],
  "count": 3
}

Query Params

limit
int64

Number of documents per page

offset
int64

Index of the first document of the page

modifiedSince
date-time

Filter (urlencoded) the contacts modified after a given UTC date-time (YYYY-MM-DDTHH:mm:ss.SSSZ). Prefer to pass your timezone in date-time format for accurate result.

Response

All contacts listed

contactsarray
countinteger

Number of contacts

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Create a contact

 

Header Auth

 Authentication is required for this endpoint.
posthttps://api.sendinblue.com/v3/contacts
curl --request POST \
  --url https://api.sendinblue.com/v3/contacts
var request = require("request");

var options = { method: 'POST',
  url: 'https://api.sendinblue.com/v3/contacts' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/contacts",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/contacts"

	req, _ := http.NewRequest("POST", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/contacts")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/contacts"

response = requests.request("POST", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/contacts")
  .post(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/contacts");
var request = new RestRequest(Method.POST);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

Try the API to see results

Body Params

email
email

Email address of the user. Mandatory if "sms" field is not passed in "attributes" parameter'

attributes
object

Pass the set of attributes and their values. These attributes must be present in your SendinBlue account. For eg. {'FNAME':'Elly', 'LNAME':'Roger'}

 
emailBlacklisted
boolean

Set this field to blacklist the contact for emails (emailBlacklisted = true)

smsBlacklisted
boolean

Set this field to blacklist the contact for SMS (smsBlacklisted = true)

listIds
array of integers

Ids of the lists to add the contact to

updateEnabled
boolean

Facilitate to update the existing contact in the same request (updateEnabled = true)

smtpBlacklistSender
array of strings

SMTP forbidden sender for contact. Use only for email Contact ( only available if updateEnabled = true )

Response

Contact created

idinteger

ID of the object created

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Retrieves contact informations

 

Header Auth

 Authentication is required for this endpoint.
gethttps://api.sendinblue.com/v3/contacts/email
curl --request GET \
  --url https://api.sendinblue.com/v3/contacts/email
var request = require("request");

var options = { method: 'GET',
  url: 'https://api.sendinblue.com/v3/contacts/email' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/contacts/email",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/contacts/email"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/contacts/email")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/contacts/email"

response = requests.request("GET", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/contacts/email")
  .get()
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/contacts/email");
var request = new RestRequest(Method.GET);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

{
  "email": "peggy.rain@example.com",
  "id": 42,
  "emailBlacklisted": false,
  "smsBlacklisted": false,
  "modifiedAt": "2017-05-02T16:40:31Z",
  "attributes": {
    "FIRST_NAME": "Peggy",
    "LAST_NAME": "Rain",
    "SMS": "3087433387669",
    "CIV": "1",
    "DOB": "1986-04-13",
    "ADDRESS": "987 5th avenue",
    "ZIP_CODE": "87544",
    "CITY": "New-York",
    "AREA": "NY"
  },
  "listIds": [
    40
  ],
  "statistics": {
    "messagesSent": [
      {
        "campaignId": 21,
        "eventTime": "2016-05-03T20:15:13Z"
      },
      {
        "campaignId": 42,
        "eventTime": "2016-10-17T10:30:01Z"
      }
    ],
    "opened": [
      {
        "campaignId": 21,
        "count": 2,
        "eventTime": "2016-05-03T21:24:56Z",
        "ip": "66.249.93.118"
      },
      {
        "campaignId": 68,
        "count": 1,
        "eventTime": "2017-01-30T13:56:40Z",
        "ip": "66.249.93.217"
      }
    ],
    "clicked": [
      {
        "campaignId": 21,
        "links": [
          {
            "count": 2,
            "eventTime": "2016-05-03T21:25:01Z",
            "ip": "66.249.93.118",
            "url": "https://url.domain.com/fbe5387ec717e333628380454f68670010b205ff/1/go?uid={EMAIL}&utm_source=sendinblue&utm_campaign=test_camp&utm_medium=email"
          }
        ]
      }
    ]
  }
}

Path Params

email
string
required

Email (urlencoded) of the contact

Response

Contact informations

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Contact's email not found

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Updates a contact

 

Header Auth

 Authentication is required for this endpoint.
puthttps://api.sendinblue.com/v3/contacts/email
curl --request PUT \
  --url https://api.sendinblue.com/v3/contacts/email
var request = require("request");

var options = { method: 'PUT',
  url: 'https://api.sendinblue.com/v3/contacts/email' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/contacts/email",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "PUT",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/contacts/email"

	req, _ := http.NewRequest("PUT", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/contacts/email")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Put.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/contacts/email"

response = requests.request("PUT", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/contacts/email")
  .put(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/contacts/email");
var request = new RestRequest(Method.PUT);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

Try the API to see results

Path Params

email
string
required

Email (urlencoded) of the contact

Body Params

attributes
object

Pass the set of attributes to be updated. These attributes must be present in your account. For eg. {'FNAME':'Ellie', 'LNAME':'Roger'}

 
emailBlacklisted
boolean

Set/unset this field to blacklist/allow the contact for emails (emailBlacklisted = true)

smsBlacklisted
boolean

Set/unset this field to blacklist/allow the contact for SMS (smsBlacklisted = true)

listIds
array of integers

Ids of the lists to add the contact to

unlinkListIds
array of integers

Ids of the lists to remove the contact from

smtpBlacklistSender
array of strings

SMTP forbidden sender for contact. Use only for email Contact

Response

Contact updated

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Contact's email not found

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Deletes a contact

 

Header Auth

 Authentication is required for this endpoint.
deletehttps://api.sendinblue.com/v3/contacts/email
curl --request DELETE \
  --url https://api.sendinblue.com/v3/contacts/email
var request = require("request");

var options = { method: 'DELETE',
  url: 'https://api.sendinblue.com/v3/contacts/email' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/contacts/email",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "DELETE",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/contacts/email"

	req, _ := http.NewRequest("DELETE", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/contacts/email")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Delete.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/contacts/email"

response = requests.request("DELETE", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/contacts/email")
  .delete(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/contacts/email");
var request = new RestRequest(Method.DELETE);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

Try the API to see results

Path Params

email
string
required

Email (urlencoded) of the contact

Response

Contact deleted

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Contact not found

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Get the campaigns statistics for a contact

 

Header Auth

 Authentication is required for this endpoint.
gethttps://api.sendinblue.com/v3/contacts/email/campaignStats
curl --request GET \
  --url https://api.sendinblue.com/v3/contacts/email/campaignStats
var request = require("request");

var options = { method: 'GET',
  url: 'https://api.sendinblue.com/v3/contacts/email/campaignStats' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/contacts/email/campaignStats",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/contacts/email/campaignStats"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/contacts/email/campaignStats")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/contacts/email/campaignStats"

response = requests.request("GET", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/contacts/email/campaignStats")
  .get()
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/contacts/email/campaignStats");
var request = new RestRequest(Method.GET);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

{
  "messagesSent": [
    {
      "campaignId": 21,
      "eventTime": "2016-05-03T20:15:13Z"
    },
    {
      "campaignId": 42,
      "eventTime": "2016-10-17T10:30:01Z"
    },
    {
      "campaignId": 45,
      "eventTime": "2016-11-09T11:45:02Z"
    }
  ],
  "opened": [
    {
      "campaignId": 21,
      "count": 2,
      "eventTime": "2016-05-03T21:24:56Z",
      "ip": "66.249.93.118"
    },
    {
      "campaignId": 45,
      "count": 1,
      "eventTime": "2017-01-30T13:56:40Z",
      "ip": "66.249.93.217"
    }
  ],
  "clicked": [
    {
      "campaignId": 21,
      "links": [
        {
          "count": 2,
          "eventTime": "2016-05-03T21:25:01Z",
          "ip": "66.249.93.118",
          "url": "https://url.domain.com/fbe5387ec717e333628380454f68670010b205ff/1/go?uid={EMAIL}&utm_source=sendinblue&utm_campaign=test_camp&utm_medium=email"
        }
      ]
    }
  ]
}

Path Params

email
string
required

Email address (urlencoded) of the contact

Response

Contact campaign statistics informations

messagesSentarray
hardBouncesarray
softBouncesarray
complaintsarray
unsubscriptionsobject
unsubscriptions.userUnsubscriptionarray

Contact has unsubscribed via the unsubscription link in the email

unsubscriptions.adminUnsubscriptionarray

Contact has been unsubscribed from the administrator

openedarray
clickedarray
transacAttributesarray

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Contact's email not found

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Lists all attributes

 

Header Auth

 Authentication is required for this endpoint.
gethttps://api.sendinblue.com/v3/contacts/attributes
curl --request GET \
  --url https://api.sendinblue.com/v3/contacts/attributes
var request = require("request");

var options = { method: 'GET',
  url: 'https://api.sendinblue.com/v3/contacts/attributes' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/contacts/attributes",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/contacts/attributes"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/contacts/attributes")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/contacts/attributes"

response = requests.request("GET", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/contacts/attributes")
  .get()
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/contacts/attributes");
var request = new RestRequest(Method.GET);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

{
  "attributes": [
    {
      "name": "LASTNAME",
      "category": "normal",
      "type": "text"
    },
    {
      "name": "FIRSTNAME",
      "category": "normal",
      "type": "text"
    },
    {
      "name": "DOB",
      "category": "normal",
      "type": "date"
    },
    {
      "name": "GENDER",
      "category": "category",
      "type": "text",
      "enumeration": [
        {
          "value": 1,
          "label": "Men"
        },
        {
          "value": 2,
          "label": "Women"
        },
        {
          "value": 3,
          "label": "Kid"
        }
      ]
    }
  ]
}

Response

Attributes listed

attributesarray

Listing of available contact attributes in your account

Suggest Edits

Creates contact attribute

 

Header Auth

 Authentication is required for this endpoint.
posthttps://api.sendinblue.com/v3/contacts/attributes/attributeCategory/attributeName
curl --request POST \
  --url https://api.sendinblue.com/v3/contacts/attributes/attributeCategory/attributeName
var request = require("request");

var options = { method: 'POST',
  url: 'https://api.sendinblue.com/v3/contacts/attributes/attributeCategory/attributeName' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/contacts/attributes/attributeCategory/attributeName",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/contacts/attributes/attributeCategory/attributeName"

	req, _ := http.NewRequest("POST", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/contacts/attributes/attributeCategory/attributeName")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/contacts/attributes/attributeCategory/attributeName"

response = requests.request("POST", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/contacts/attributes/attributeCategory/attributeName")
  .post(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/contacts/attributes/attributeCategory/attributeName");
var request = new RestRequest(Method.POST);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

Try the API to see results

Path Params

attributeCategory
string
required

Category of the attribute

attributeName
string
required

Name of the attribute

Body Params

value
string

Value of the attribute. Use only if the attribute's category is 'calculated' or 'global'

enumeration
array of objects

List of values and labels that the attribute can take. Use only if the attribute's category is "category". For example, [{'value':1, 'label':'male'}, {'value':2, 'label':'female'}]

value
label
type
string

Type of the attribute. Use only if the attribute's category is 'normal', 'category' or 'transactional' ( type 'boolean' is only available if the category is 'normal' attribute, type 'id' is only available if the category is 'transactional' attribute & type 'category' is only available if the category is 'category' attribute )

Response

Attribute created

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Updates contact attribute

 

Header Auth

 Authentication is required for this endpoint.
puthttps://api.sendinblue.com/v3/contacts/attributes/attributeCategory/attributeName
curl --request PUT \
  --url https://api.sendinblue.com/v3/contacts/attributes/attributeCategory/attributeName
var request = require("request");

var options = { method: 'PUT',
  url: 'https://api.sendinblue.com/v3/contacts/attributes/attributeCategory/attributeName' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/contacts/attributes/attributeCategory/attributeName",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "PUT",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/contacts/attributes/attributeCategory/attributeName"

	req, _ := http.NewRequest("PUT", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/contacts/attributes/attributeCategory/attributeName")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Put.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/contacts/attributes/attributeCategory/attributeName"

response = requests.request("PUT", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/contacts/attributes/attributeCategory/attributeName")
  .put(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/contacts/attributes/attributeCategory/attributeName");
var request = new RestRequest(Method.PUT);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

Try the API to see results

Path Params

attributeCategory
string
required

Category of the attribute

attributeName
string
required

Name of the existing attribute

Body Params

value
string

Value of the attribute to update. Use only if the attribute's category is 'calculated' or 'global'

enumeration
array of objects

List of the values and labels that the attribute can take. Use only if the attribute's category is "category". For example, [{'value':1, 'label':'male'}, {'value':2, 'label':'female'}]

value
label

Response

Attribute updated

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Attribute not found

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Deletes an attribute

 

Header Auth

 Authentication is required for this endpoint.
deletehttps://api.sendinblue.com/v3/contacts/attributes/attributeCategory/attributeName
curl --request DELETE \
  --url https://api.sendinblue.com/v3/contacts/attributes/attributeCategory/attributeName
var request = require("request");

var options = { method: 'DELETE',
  url: 'https://api.sendinblue.com/v3/contacts/attributes/attributeCategory/attributeName' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/contacts/attributes/attributeCategory/attributeName",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "DELETE",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/contacts/attributes/attributeCategory/attributeName"

	req, _ := http.NewRequest("DELETE", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/contacts/attributes/attributeCategory/attributeName")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Delete.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/contacts/attributes/attributeCategory/attributeName"

response = requests.request("DELETE", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/contacts/attributes/attributeCategory/attributeName")
  .delete(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/contacts/attributes/attributeCategory/attributeName");
var request = new RestRequest(Method.DELETE);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

Try the API to see results

Path Params

attributeCategory
string
required

Category of the attribute

attributeName
string
required

Name of the existing attribute

Response

Attribute deleted

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Attribute not found

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Get all the folders

 

Header Auth

 Authentication is required for this endpoint.
gethttps://api.sendinblue.com/v3/contacts/folders
curl --request GET \
  --url 'https://api.sendinblue.com/v3/contacts/folders?limit=10&offset=offset'
var request = require("request");

var options = { method: 'GET',
  url: 'https://api.sendinblue.com/v3/contacts/folders',
  qs: 
   { limit: '10',
     offset: 'offset' } };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/contacts/folders?limit=10&offset=offset",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/contacts/folders?limit=10&offset=offset"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/contacts/folders?limit=10&offset=offset")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/contacts/folders"

querystring = {"limit":"10","offset":"offset"}

response = requests.request("GET", url, params=querystring)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/contacts/folders?limit=10&offset=offset")
  .get()
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/contacts/folders?limit=10&offset=offset");
var request = new RestRequest(Method.GET);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

{
  "folders": [
    {
      "id": 42,
      "name": "Ninja_Form",
      "totalBlacklisted": 98,
      "totalSubscribers": 4567,
      "uniqueSubscribers": 4665
    },
    {
      "id": 29,
      "name": "Prestashop",
      "totalBlacklisted": 10,
      "totalSubscribers": 6543,
      "uniqueSubscribers": 6553
    }
  ],
  "count": 2
}

Query Params

limit
int64
required

Number of documents per page

offset
int64
required

Index of the first document of the page

Response

Folders informations

foldersarray
countinteger

Number of folders available in your account

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Create a folder

 

Header Auth

 Authentication is required for this endpoint.
posthttps://api.sendinblue.com/v3/contacts/folders
curl --request POST \
  --url https://api.sendinblue.com/v3/contacts/folders
var request = require("request");

var options = { method: 'POST',
  url: 'https://api.sendinblue.com/v3/contacts/folders' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/contacts/folders",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/contacts/folders"

	req, _ := http.NewRequest("POST", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/contacts/folders")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/contacts/folders"

response = requests.request("POST", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/contacts/folders")
  .post(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/contacts/folders");
var request = new RestRequest(Method.POST);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

Try the API to see results

Body Params

name
string

Name of the folder

Response

Folder created

idinteger

ID of the object created

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Returns folder details

 

Header Auth

 Authentication is required for this endpoint.
gethttps://api.sendinblue.com/v3/contacts/folders/folderId
curl --request GET \
  --url https://api.sendinblue.com/v3/contacts/folders/folderId
var request = require("request");

var options = { method: 'GET',
  url: 'https://api.sendinblue.com/v3/contacts/folders/folderId' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/contacts/folders/folderId",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/contacts/folders/folderId"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/contacts/folders/folderId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/contacts/folders/folderId"

response = requests.request("GET", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/contacts/folders/folderId")
  .get()
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/contacts/folders/folderId");
var request = new RestRequest(Method.GET);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

{
  "id": 1,
  "name": "Client_Folder",
  "totalBlacklisted": 987,
  "totalSubscribers": 16778,
  "uniqueSubscribers": 17765
}

Path Params

folderId
int64
required

id of the folder

Response

Folder details

idinteger

ID of the folder

namestring

Name of the folder

totalBlacklistedinteger

Number of blacklisted contacts in the folder

totalSubscribersinteger

Number of contacts in the folder

uniqueSubscribersinteger

Number of unique contacts in the folder

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Folder ID not found

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Update a contact folder

 

Header Auth

 Authentication is required for this endpoint.
puthttps://api.sendinblue.com/v3/contacts/folders/folderId
curl --request PUT \
  --url https://api.sendinblue.com/v3/contacts/folders/folderId
var request = require("request");

var options = { method: 'PUT',
  url: 'https://api.sendinblue.com/v3/contacts/folders/folderId' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/contacts/folders/folderId",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "PUT",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/contacts/folders/folderId"

	req, _ := http.NewRequest("PUT", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/contacts/folders/folderId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Put.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/contacts/folders/folderId"

response = requests.request("PUT", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/contacts/folders/folderId")
  .put(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/contacts/folders/folderId");
var request = new RestRequest(Method.PUT);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

Try the API to see results

Path Params

folderId
int64
required

Id of the folder

Body Params

name
string

Name of the folder

Response

Folder updated

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Folder ID not found

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Delete a folder (and all its lists)

 

Header Auth

 Authentication is required for this endpoint.
deletehttps://api.sendinblue.com/v3/contacts/folders/folderId
curl --request DELETE \
  --url https://api.sendinblue.com/v3/contacts/folders/folderId
var request = require("request");

var options = { method: 'DELETE',
  url: 'https://api.sendinblue.com/v3/contacts/folders/folderId' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/contacts/folders/folderId",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "DELETE",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/contacts/folders/folderId"

	req, _ := http.NewRequest("DELETE", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/contacts/folders/folderId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Delete.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/contacts/folders/folderId"

response = requests.request("DELETE", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/contacts/folders/folderId")
  .delete(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/contacts/folders/folderId");
var request = new RestRequest(Method.DELETE);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

Try the API to see results

Path Params

folderId
int64
required

Id of the folder

Response

Folder deleted

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Folder ID not found

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Get the lists in a folder

 

Header Auth

 Authentication is required for this endpoint.
gethttps://api.sendinblue.com/v3/contacts/folders/folderId/lists
curl --request GET \
  --url https://api.sendinblue.com/v3/contacts/folders/folderId/lists
var request = require("request");

var options = { method: 'GET',
  url: 'https://api.sendinblue.com/v3/contacts/folders/folderId/lists' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/contacts/folders/folderId/lists",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/contacts/folders/folderId/lists"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/contacts/folders/folderId/lists")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/contacts/folders/folderId/lists"

response = requests.request("GET", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/contacts/folders/folderId/lists")
  .get()
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/contacts/folders/folderId/lists");
var request = new RestRequest(Method.GET);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

{
  "lists": [
    {
      "id": 46,
      "name": "Reactiv",
      "totalSubscribers": 7655,
      "totalBlacklisted": 0
    },
    {
      "id": 41,
      "name": "NY_Area",
      "totalSubscribers": 3654,
      "totalBlacklisted": 23
    },
    {
      "id": 22,
      "name": "VIP_Customer",
      "totalSubscribers": 8753,
      "totalBlacklisted": 72
    }
  ],
  "count": 3
}

Path Params

folderId
int64
required

Id of the folder

Query Params

limit
int64

Number of documents per page

offset
int64

Index of the first document of the page

Response

Folder's Lists details

listsarray
countinteger

Number of lists in the folder

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Folder ID not found

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Get all the lists

 

Header Auth

 Authentication is required for this endpoint.
gethttps://api.sendinblue.com/v3/contacts/lists
curl --request GET \
  --url https://api.sendinblue.com/v3/contacts/lists
var request = require("request");

var options = { method: 'GET',
  url: 'https://api.sendinblue.com/v3/contacts/lists' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/contacts/lists",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/contacts/lists"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/contacts/lists")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/contacts/lists"

response = requests.request("GET", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/contacts/lists")
  .get()
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/contacts/lists");
var request = new RestRequest(Method.GET);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

{
  "lists": [
    {
      "id": 53,
      "name": "Spanish_Speakers",
      "totalSubscribers": 5432,
      "totalBlacklisted": 65,
      "folderId": 1
    },
    {
      "id": 50,
      "name": "Other",
      "totalSubscribers": 10976,
      "totalBlacklisted": 765,
      "folderId": 2
    }
  ],
  "count": 2
}

Query Params

limit
int64

Number of documents per page

offset
int64

Index of the first document of the page

Response

Lists informations

listsarray

Listing of all the lists available in your account

countinteger

Number of lists in your account

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Create a list

 

Header Auth

 Authentication is required for this endpoint.
posthttps://api.sendinblue.com/v3/contacts/lists
curl --request POST \
  --url https://api.sendinblue.com/v3/contacts/lists
var request = require("request");

var options = { method: 'POST',
  url: 'https://api.sendinblue.com/v3/contacts/lists' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/contacts/lists",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/contacts/lists"

	req, _ := http.NewRequest("POST", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/contacts/lists")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/contacts/lists"

response = requests.request("POST", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/contacts/lists")
  .post(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/contacts/lists");
var request = new RestRequest(Method.POST);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

Try the API to see results

Body Params

name
string
required

Name of the list

folderId
int64
required

Id of the parent folder in which this list is to be created

Response

List created

idinteger

ID of the object created

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Get the details of a list

 

Header Auth

 Authentication is required for this endpoint.
gethttps://api.sendinblue.com/v3/contacts/lists/listId
curl --request GET \
  --url https://api.sendinblue.com/v3/contacts/lists/listId
var request = require("request");

var options = { method: 'GET',
  url: 'https://api.sendinblue.com/v3/contacts/lists/listId' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/contacts/lists/listId",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/contacts/lists/listId"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/contacts/lists/listId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/contacts/lists/listId"

response = requests.request("GET", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/contacts/lists/listId")
  .get()
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/contacts/lists/listId");
var request = new RestRequest(Method.GET);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

{
  "id": 12,
  "name": "Newsletter_Weekly",
  "totalSubscribers": 6533,
  "totalBlacklisted": 63,
  "folderId": 1,
  "createdAt": "2016-02-26T11:56:08Z",
  "campaignStats": [
    {
      "campaignId": 15,
      "stats": {
        "uniqueClicks": 701,
        "clickers": 789,
        "complaints": 0,
        "delivered": 6632,
        "sent": 6645,
        "softBounces": 34,
        "hardBounces": 4,
        "uniqueViews": 3442,
        "unsubscriptions": 4,
        "viewed": 4322,
        "deferred": 0
      }
    },
    {
      "campaignId": 45,
      "stats": {
        "uniqueClicks": 654,
        "clickers": 788,
        "complaints": 1,
        "delivered": 4078,
        "sent": 4334,
        "softBounces": 18,
        "hardBounces": 2,
        "uniqueViews": 987,
        "unsubscriptions": 4,
        "viewed": 1555,
        "deferred": 0
      }
    }
  ],
  "dynamicList": false
}

Path Params

listId
int64
required

Id of the list

Response

List informations

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

List ID not found

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Update a list

 

Header Auth

 Authentication is required for this endpoint.
puthttps://api.sendinblue.com/v3/contacts/lists/listId
curl --request PUT \
  --url https://api.sendinblue.com/v3/contacts/lists/listId
var request = require("request");

var options = { method: 'PUT',
  url: 'https://api.sendinblue.com/v3/contacts/lists/listId' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/contacts/lists/listId",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "PUT",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/contacts/lists/listId"

	req, _ := http.NewRequest("PUT", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/contacts/lists/listId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Put.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/contacts/lists/listId"

response = requests.request("PUT", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/contacts/lists/listId")
  .put(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/contacts/lists/listId");
var request = new RestRequest(Method.PUT);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

Try the API to see results

Path Params

listId
int64
required

Id of the list

Body Params

name
string

Name of the list. Either of the two parameters (name, folderId) can be updated at a time.

folderId
int64

Id of the folder in which the list is to be moved. Either of the two parameters (name, folderId) can be updated at a time.

Response

List updated

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

List ID not found

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Delete a list

 

Header Auth

 Authentication is required for this endpoint.
deletehttps://api.sendinblue.com/v3/contacts/lists/listId
curl --request DELETE \
  --url https://api.sendinblue.com/v3/contacts/lists/listId
var request = require("request");

var options = { method: 'DELETE',
  url: 'https://api.sendinblue.com/v3/contacts/lists/listId' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/contacts/lists/listId",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "DELETE",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/contacts/lists/listId"

	req, _ := http.NewRequest("DELETE", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/contacts/lists/listId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Delete.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/contacts/lists/listId"

response = requests.request("DELETE", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/contacts/lists/listId")
  .delete(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/contacts/lists/listId");
var request = new RestRequest(Method.DELETE);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

Try the API to see results

Path Params

listId
int64
required

Id of the list

Response

List deleted

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

List ID not found

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Get the contacts in a list

 

Header Auth

 Authentication is required for this endpoint.
gethttps://api.sendinblue.com/v3/contacts/lists/listId/contacts
curl --request GET \
  --url https://api.sendinblue.com/v3/contacts/lists/listId/contacts
var request = require("request");

var options = { method: 'GET',
  url: 'https://api.sendinblue.com/v3/contacts/lists/listId/contacts' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.sendinblue.com/v3/contacts/lists/listId/contacts",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://api.sendinblue.com/v3/contacts/lists/listId/contacts"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://api.sendinblue.com/v3/contacts/lists/listId/contacts")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
import requests

url = "https://api.sendinblue.com/v3/contacts/lists/listId/contacts"

response = requests.request("GET", url)

print(response.text)
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sendinblue.com/v3/contacts/lists/listId/contacts")
  .get()
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://api.sendinblue.com/v3/contacts/lists/listId/contacts");
var request = new RestRequest(Method.GET);
IRestResponse response = client.Execute(request);
A binary file was returned

You couldn't be authenticated

{
  "contacts": [
    {
      "email": "alex.pain@example.com",
      "id": 45,
      "emailBlacklisted": false,
      "smsBlacklisted": true,
      "modifiedAt": "2017-05-12T12:30:00Z",
      "listIds": [
        12,
        9,
        20
      ],
      "listUnsubscribed": [
        1,
        2
      ],
      "attributes": {
        "LASTNAME": "Pain",
        "FIRSTNAME": "Alex",
        "DOB": "2010-12-31",
        "GENDER": "Kid"
      }
    },
    {
      "email": "john.smith@example.com",
      "id": 32,
      "emailBlacklisted": true,
      "smsBlacklisted": false,
      "modifiedAt": "2017-05-12T12:30:00Z",
      "listIds": [
        12
      ],
      "listUnsubscribed": [
        1
      ],
      "attributes": {
        "LASTNAME": "Smith",
        "FIRSTNAME": "John",
        "DOB": "1986-06-21",
        "GENDER": "Men"
      }
    },
    {
      "email": "helen.rose@example.com",
      "id": 65,
      "emailBlacklisted": true,
      "smsBlacklisted": false,
      "modifiedAt": "2017-05-12T12:30:00Z",
      "listIds": [
        12,
        9,
        20
      ],
      "listUnsubscribed": [
        1
      ],
      "attributes": {
        "LASTNAME": "Rose",
        "FIRSTNAME": "Helen",
        "DOB": "1988-11-02",
        "GENDER": "Women",
        "SMS": "3375599887766"
      }
    }
  ],
  "count": 17655
}

Path Params

listId
int64
required

Id of the list

Query Params

modifiedSince
date-time

Filter (urlencoded) the contacts modified after a given UTC date-time (YYYY-MM-DDTHH:mm:ss.SSSZ). Prefer to pass your timezone in date-time format for accurate result.

limit
int64

Number of documents per page

offset
int64

Index of the first document of the page

Response

Contact informations

contactsarray
countinteger

Number of contacts

bad request

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

List ID not found

codestring

Error code displayed in case of a failure

messagestring

Readable message associated to the failure

Suggest Edits

Add existing contacts to a list

 

Header Auth

 Authentication is required for this endpoint.
posthttps://api.sendinblue.com/v3/contacts/lists/listId/contacts/add