Suggest Edits

/identify

 
Suggest Edits

post

The Identify endpoint lets you create or update your users on the Marketing Automation platform, along with optional extra attributes of the users.

Attributes given in the identify call can be used as conditions (OR,IF…) on the Marketing Automation platform.
If the attributes given in the identify call have the exact same name that the attributes of your users' database on SendinBlue, the values passed in the identify call will replace the ones in the database.

To send the mobile number of a user use the reserved keyword mobile.

 

Header Auth

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

var options = { method: 'POST',
  url: 'https://in-automate.sendinblue.com/api/v2/identify' };

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://in-automate.sendinblue.com/api/v2/identify",
  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://in-automate.sendinblue.com/api/v2/identify"

	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://in-automate.sendinblue.com/api/v2/identify")

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://in-automate.sendinblue.com/api/v2/identify"

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

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

Request request = new Request.Builder()
  .url("https://in-automate.sendinblue.com/api/v2/identify")
  .post(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://in-automate.sendinblue.com/api/v2/identify");
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
required
attributes
object

This object will content all your custom fields. Add as many as needed. Keep in mind that those user properties will populate your database on the Marketing Automation platform to create rich scenarios

 

Response

User has been identified and successfully updated

bad request

codestring
messagestring
Suggest Edits

/trackEvent

 
Suggest Edits

post

The Track Event endpoint lets you capture events on your website, along with optional extra information about the event.

You can choose any value you want for the field event and pass any key-value in the field properties. Make sure not to use any reserved key (email or event) in the properties object.

 

Header Auth

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

var options = { method: 'POST',
  url: 'https://in-automate.sendinblue.com/api/v2/trackEvent' };

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://in-automate.sendinblue.com/api/v2/trackEvent",
  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://in-automate.sendinblue.com/api/v2/trackEvent"

	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://in-automate.sendinblue.com/api/v2/trackEvent")

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://in-automate.sendinblue.com/api/v2/trackEvent"

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

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

Request request = new Request.Builder()
  .url("https://in-automate.sendinblue.com/api/v2/trackEvent")
  .post(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://in-automate.sendinblue.com/api/v2/trackEvent");
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
required
event
string
required
properties
object

This object will content all your custom fields. Add as many as needed. Keep in mind that those user properties will populate your database on the Marketing Automation platform to create rich scenarios

 
eventdata
object

This object will content all additional data you want to send it has three filed id of type string contain a unique number and data which contain information which which one can be send in smtp template

 

Response

Event has been tracked successfully

bad request

codestring
messagestring
Suggest Edits

/trackPage

 
Suggest Edits

post

The Track Page endpoint lets you capture page views on your website, along with optional extra information about the viewed page.

You can choose any value you want for the field link and pass any key-value in the field properties. Make sure not to use any reserved key (email or page) in the properties object.

 

Header Auth

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

var options = { method: 'POST',
  url: 'https://in-automate.sendinblue.com/api/v2/trackPage' };

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://in-automate.sendinblue.com/api/v2/trackPage",
  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://in-automate.sendinblue.com/api/v2/trackPage"

	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://in-automate.sendinblue.com/api/v2/trackPage")

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://in-automate.sendinblue.com/api/v2/trackPage"

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

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

Request request = new Request.Builder()
  .url("https://in-automate.sendinblue.com/api/v2/trackPage")
  .post(null)
  .build();

Response response = client.newCall(request).execute();
var client = new RestClient("https://in-automate.sendinblue.com/api/v2/trackPage");
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
required
page
string
required
properties
object

This object will content all your custom fields. Add as many as needed. Keep in mind that those user properties will populate your database on the Marketing Automation platform to create rich scenarios

 

Response

Page has been tracked successfully

bad request

codestring
messagestring
Suggest Edits

Frequently Asked Questions

 

Why is the Tracker not part of the SendinBlue's main API?

For the same reason as the Google Analytics Script is not part of the Google Analytics API. The Tracker can be used on client side, which means the Tracker ID will also be stored on client side. Unlike for the API key this is not an issue at it doesn't allow anyone to retrieve sensitive data from you account.

For now we don't provide any Marketing Automation API (to edit your workflows for example), but the day we do it will for sure be part of the main API.