To get full value of the Brandbassador we recommend a full integration. This will allow your ambassadors to create personalised discount codes, earn commission on sales generated and automatically withdraw gift card they have earned. It also allows you to track the revenue generated by the discount code being returned to Brandbassador when used in checkout to track the sale to the right user.

The User will also be rewarded in gift card that they should be able to withdraw in a set amount to spend in any currency.

This article explains how to allow for discount code creation through API, the first step in a successful integration. If you have already done this and need to set up tracking of sales please check this article

FIRST STEP: Allow discount code creation through API

We need you to set up an endpoint where we can send GET requests to create discount codes and gift cards. It just needs to accept the parameters (query strings) explained below, and return a HTTP 200 upon success. Success/error messages should be returned as JSON for our own logging purposes. 

In order for ambassadors to create discount codes and withdraw their gift cards, the Brandbassador system needs to programmatically create these through an API endpoint on the brands’ side. This enables the brand to automatically award users with gift cards, and enables the users to create customized discount codes like JOHN20OFF.

API endpoint example:

Needs to accept the following GET parameters in which all are required*

Example URL percent discount code:

Example URL gift card (set amount with currency):

When the code is created the webshop needs to return a status of "success" if ok or "status":0, "error" if error provide details like:

{"status" : "success"} - the code is created in the webshop and ready to use

{“status”:0, “error” : “Discount code already exists”} - if the code already exists in the webshop

{“status”:0, “error” : “Error description”} - if any other error


  • The discount code should not be case sensitive
  • Only A-Z and 0-9
  • VALUE format like 1000.00
  • Date standard yyyy-mm-dd
  • Value is total purchase value (not including shipping)

SECOND STEP - Insert your authentication code to connect Brandbassador

  1. Go to your Settings > Integrations in your Brandbassador platform, insert your discount code percentage and click 'Add Webshop' next to 'Custom Webshop'.
  2. Select the base currency of your webshop and click 'Save Currency'.If you have multiple webshop with different currencies you go through this flow once for each of your webshops.
  3. Insert the destination of your endpoint URL (i.e.
  4. You have now received your authentication key, which allows your webshopto communicate with the Brandbassador API.

To complete your integration you also have to implement the tracking to make sure ambassadors are given the commission, and revenue is tracked in the Brandbassador platform.

If you would like your ambassadors to also share a tracking link that doesn't give discount to the customer you need to set up to save the reference from the URL. This is not as secure tracking as discount codes, and is not necessary. But if you do want to set that up see how in this article.

We always recommend to test your Integration to make sure it is working as it should.

Did this answer your question?