Please note: This is an older API. We highly recommend to use the PUT Records API instead.
This API is designed to allow upload of a single data file directly into CustomerGauge for immediate processing (Mail queue) and email sending.
Depending on active rules and data types (usually order_date field) customer emails will be sent immediately.
This API will load emails into the "Mail queue", and may start immediate processing. Make sure you test this before bulk uploads!
Good to know
Please do not upload data larger than 2MB.
Maximum number of records:
Please do not upload more than 2,000 records.
Call interval / frequency:
Multiple upload calls made in quick succession will get queued, and periodically retried, but to obtain optimum performance we recommend allowing the previous upload to finish before attempting the next one. (Uploads can take anywhere between a few seconds and several minutes depending on the size and complexity of data.)
API response format:
Our APIs return data in either JSON or XML format (depending on request by .json or .xml).
Our Stream API accepts XML data only.
About this API
|Response formats||JSON (default), XML|
|Header||Authorization: api_key XXXXX|
Europe Production Server: https://api.eu.customergauge.com/v4.1/stream/transactional.json
US Production Server: https://api.us.customergauge.com/v4.1/stream/transactional.json
Australia Production Server: https://api.au.customergauge.com/v4.1/stream/transactional.json
How to call
You can call the Stream API by passing your XML data through an HTTP POST request.
POST Data Example Values
Please follow this structure to generate your XML data:
<?xml version='1.0' encoding='utf-8'?>
As many clients have different data fields, you can pick up a sample copy from your system, containing all possible fields.
1. Go to Data → Imports and click the link to go the legacy import screen.
2. Click on "Upload File"
3. Click on "Download Data Structure", followed by Transactional (XML).
4. Use the same structure as this sample file when calling our POST Stream/Transactional API.
curl -H "Authorization: api_key XXXXX" -X POST "https://api.eu.customergauge.com/v4.1/stream/transactional.json" -d "<?xml version='1.0' encoding='utf-8'?><records><record><Email>email@example.com</Email><FirstName>Lee</FirstName><LastName>Klameth</LastName></record></records>"
Data states if successful or not. Message reported on successful operation:
Message reported on failed operation:
"Message": "No data provided",
Not the API you're looking for?
APIs of the same family:
Similar API families: