Braze to Open Loyalty
Updating Open Loyalty Member Attributes from Braze
Outbound Updates: Modifying Open Loyalty Members
This guide explains how to automatically update member data in Open Loyalty based on user behavior in Braze. We achieve this by using Braze Webhooks to send API requests to Open Loyalty's Member API.
This is commonly used to:
Add Labels to a member in Open Loyalty (e.g., "VIP", "Churn Risk").
Update custom attributes based on Braze engagement.
Sync segmentation status between platforms.
Prerequisites
API Token
A permanent Open Loyalty token (X-AUTH-TOKEN) with permission to modify members.
Tenant Code
Your Open Loyalty Tenant Code.
Matching IDs
The user's external_id in Braze must match their loyaltyCardNumber (or another default identifier - email, phone, member ID) in Open Loyalty.
Integration Overview
This integration uses Braze Webhooks to send data to Open Loyalty. When a user enters a specific segment in Braze, we trigger a webhook that sends a PATCH request to the Open Loyalty Member API. This updates the member's Labels (custom attributes), which can then be used to define segments within Open Loyalty.
Prerequisites
Open Loyalty API Token
A permanent token (X-AUTH-TOKEN) with permission to modify members.
Tenant ID
Your Open Loyalty Tenant ID (e.g., KHO).
Matching IDs
The user's external_id in Braze must match their loyaltyCardNumber in Open Loyalty.
Setting up the integration
Define the Update Logic
Decide what triggers the update and what data you want to change. In this guide, we will add a Label (Custom Attribute) to a member profile.
Trigger: A user enters a specific Segment in Braze (e.g., "High Spenders").
Action: Add the label
braze_vipto their Open Loyalty profile.
Configure Braze Webhook Campaign
You can trigger this update via a Webhook Campaign or a Webhook component within a Braze Canvas.
In Braze, create a new Webhook Campaign (or use a Webhook within a Canvas).
Click on Compose Webhook
Webhook URL: Construct the URL using your Open Loyalty instance, Tenant ID, and the Braze Liquid variable for the user ID.
Format: Sample format
https://<YOUR_OL_INSTANCE>/api/<TENANT_ID>/member/loyaltyCardNumber={{${user_id}}}Request Method:
PATCHRequest Headers:
Content-Type:application/jsonX-AUTH-TOKEN:<YOUR_PERMANENT_TOKEN>User-Agent: Braze
Request Body: Select
Raw textand paste the payload. You can customize thekeyandvalueto match your segment strategy.
Testing the Setup
Trigger the Webhook: Manually add a test user to the target Braze segment or click "Send Test" in the webhook composer (you will need to supply a valid user ID).
Verify in Braze: Check the Message Activity Log to ensure the webhook returned a
200 OKstatus.401 Error: Checks your API Token.
404 Error: The user ID found in Braze does not exist in Open Loyalty.
Verify in Open Loyalty:
Log in to the Open Loyalty Admin Panel.
Navigate to Members > All Members and search for the test user.
Check the Labels or Custom Attributes section to confirm the new key-value pair exists.
Success: You should see the new label (e.g.,
braze_brazeSegmentId: "optedIn").Optional: If you created a Segment in Open Loyalty based on this label, confirm the user now appears in that segment.
Last updated
Was this helpful?

