This guide will help you quickly start using our REST API for managing customer data. Learn how to set up, authenticate, and make your first API calls, enabling you to manage user profiles, log events, and harness the full power of our Customer Data Platform.

With NotifyVisitors API, you can -

  • Track users and their event activities
  • Send personalized campaigns to each user for Push, Email, SMS
  • Schedule one time campaigns to targeted segments for Push, Email, SMS
  • Retrieve reports for all your campaigns

API Authentication

NotifyVisitors requires a Brand ID and API Key to be included in the header of each API call. Each NotifyVisitors account is automatically assigned a unique REST API key, which remains valid for the account's entire lifetime.

If your API key is accidentally compromised or shared with a third party, you can generate a new key and deactivate the compromised one from the Store Integration section.

curl --request POST \
  --url https://analytics.notifyvisitors.com/api/v1/user/create \
  --header 'accept: application/json' \
  --header 'content-type: application/json' \
  --header 'x-api-key: YOUR_API_KEY' \
  --header 'x-brand-id: YOUR_BRAND_ID' \
  --data '{"nv":[{"userID":"1234"",user_attributes":{name:'John', email:'[email protected]', mobile:'+919899999999'
  }}]}'

Note:

πŸ“˜

Note:

  • Replace YOUR_API_KEY with NotifyVisitors' API key.
  • Replace YOUR_BRAND_ID with NotifyVisitors' Brand id .

Getting API Key

Login to the NotifyVisitors account.
Navigate to the Settings > Store Integration section


API Authentication for Partner Apps

As a Partner App, when a client grants access to the NotifyVisitors, an access token is returned. This token must be included as an authorization bearer token in the header of each API call.

curl --request POST \
  --url https://analytics.notifyvisitors.com/api/v1/user/create \
  --header 'content-type: application/json' \
  --header 'Authorization: Bearer ACCESS_TOKEN' \
  --data '{"nv":[{"userID":"1234"",user_attributes":{name:'John', email:'[email protected]', mobile:'+919899999999'
  }}]}'

API RATE LIMIT

The default rate limits for following API endpoints is mentioned in the table below.

EndpointRate Limit
User API100 per minute
Event API500 per minute
Campaign API500 per minute
Reporting API50 per minute

An HTTP response code of 429 would be sent if you exceed these limits.
You will also get the following headers in the response for you to programmatically keep a track of the limits:

Header NameWhat It MeansSample Value
X-RateLimit-RemainingHow many more requests you can make in that minute499

πŸ“˜

CONTACT SUPPORT :

If you want to increase this limit, feel free to contact us on [email protected]

HOW TO SEND THE DATA

  • You can send the data in JSON format.

WHAT IS THE DATE FORMAT

The timestamps for the data will be in the following format :

πŸ“˜

yyyy-MM-ddTHH:mm:ss

2013-01-26T07:31+0000

HOW TO RECEIVE THE API RESPONSE

API Response is usually received in the following format or container: i.e. response.

This API response has the following properties:

Status: It will either be shown as an error as success depending upon the response of the server.

Data: It will contain the data for the requested resource.

Message: The said property will determine the reason for the corresponding status.

{
    "response" : {
        "data" : {
            ...
        },
        "message" : "success",
        "status" : "success"
    }
}

ERRORS

Errors will be shown using the standard HTTP error code syntax. Find the below description for the error codes :

400Invalid resource
401Invalid auth
404Invalid URL