3. Loyalty: Update and create information

Add the loyalty information of you customers

You can create or update a customer's loyalty information through the dedicated POST API endpoint that accepts an array of objects as the request body.

https://api.jericommerce.com/v1/programs/{programId}/integrations/api

It's important to know that the user should exist on the API before you can add loyalty information.

You can add both the customer and loyalty information in the same API request, but you should ensure to preserve the order by adding the customer information first.

The loyalty information should have a customer already created

Here a body example to update a customer:

1[
2  {
3    "email": "string",
4    "feature": "loyalty",
5    "payload": {
6      "loyaltyCustomerId": "string",
7      "balance": number,
8      "memberSince": IsoDate,
9      "tierStatus": "string"
10    }
11  }
12]

Payload properties

loyaltyCustomerId

Is the external reference of this loylaty information, useful when you need to associate this information with another database.
Is mandatory for each request.

balance

One of the most important properties is the customer balance. Our API doesn't calculate any value here, but simply updates the value with the value provided in the request.
It is a mandatory field, should be a number format and should always be greater than 0.

memberSince

Is the date when the customer was registered on your loyalaty program.
The required field should be in ISO string format.
The field is mandatory and required for each call.

tierStatus

Dependence on the loyalty program could have a tiered status or not, so you could add the name of the tier here.
The optional string property could be the desired value.

Related Guides
No items found.

Topics

Integrations