Tracking Events (Non-shopify)
Use this apis if you are not using shopify.
Track Event API
Headers
Name
Type
Description
Request Body
Name
Type
Description
API Example
const moment = require('moment');
const requestBody = {
name: 'Add To Cart',
customerId: 'YOUR_APP_CUSTOMER_ID', // YOUR APP'S CUSTOMER ID
attributes: [
{ name: 'Order ID', value: 'SDFICSRDCVSSDSDG', type: 'string' },
{ name: 'Amount', value: 732.23, type: 'number' },
{ name: 'Order Time', value: '2020-01-20 19:14:15', type: 'date' }, // Date in YYYY-MM-DD HH:mm:ss format
{ name: 'Is Prepaid Order', value: true, type: 'boolean' }
]
};
// Call API
const request = require('request-promise');
request({
method: 'POST',
uri: 'https://dcqs-india.growlytics.in/rest-api/event',
headers: {
Accept: 'application/json',
'x-growlytics-key': '<GROWLYTICS-API-KEY>'
},
body: requestBody
});Terms & Considerations
Last updated
Was this helpful?
