Skip to main content

Receiving a loyalty ledger through Braze

Learn how to use the Braze endpoint to retrieve loyalty ledger information of customer coupons.

Endpoint usage#

This endpoint contains the following built-in required properties:


Example with all built-in properties:

curl --location --request GET 'https://[YOUR_DEPLOYMENT][LOYALTY_PROGRAM_ID](/profile/[USER_ID]' \--header 'Authorization: Bearer [BEARER_TOKEN]'

Configuring Connected Content#

To trigger the Talon.One coupon creation you have to use Braze's Connected Content Feature. You can use it in every campaign message body or any canvas message body.

  1. Add the connected content tag to the body of your message and add the URL to the getLoyaltyPoints endpoint. You can access Braze attributes by using liquid tags. For example, {{${user_id}}} to pass the user id.


  2. Add the authorization header and the method (get) of the request. Follow this instructions to generate a session token.


  3. Add the save parameter at the end to store the Talon.One response as a Braze variable (in the below case, result).


  4. Use a liquid tag to show the value of the Total points of loyalty ledger in the message.


  5. Testing the campaign/canvas will give you the following result:

    Value of total points {{}}:


    Whole response {{result}}:


Code snippet:

{% connected_content
:headers {  "authorization": "Bearer q-8pnumpXXXXXXXXXXAxf9Bz-i22G1" }:method get:content_type application/json:save result%}
Total points: {{}}

Extracting the session token#

Once you are logged into your Talon.One deployment as an administrator, you can get your session token by following these steps:

  1. Open the console/developer settings of your browser.
  2. Navigate to cookie storage.
  3. Copy the value of the talonone-credentials cookie.
  4. Paste it into an online URL decoder.