Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Benjamin Reynolds (Deactivated) recording → Targeted Coupons Through Braze-20220322_123641-Meeting Recording.mp4

CBA Offers Sanity config

Use Required assignment ruleset

...

Find here documentation on Sanity rulesets

CBA Offers Braze config

Body request

Code Block
languagejson
{
  "couponId": "0526d543-3871-4e9c-bec5-327ebcd3f1db",
  "tokenId": "tester",
  "userId": "{{${user_id}}}",
  "expiresOn": "2020-08-11T08:59:59.000Z"
}

...

Loyalty Offers Assignment (New Loyalty Offers Platform)

Sanity Setup

  • Create a template offer (e.g. template offer for Braze Offers in BK UK)

    • this offer can be used for all future Braze Offer Assignments

    • save the Loyalty Engine ID of the template offer to input into Braze after

      Image Added
    • under Mechanics ensure a config offer as added under Config Offer and under the Required Rules drop down the Date Band toggle is turned on

      • it does not make a difference which config offer is within the template offer in Sanity - it just needs to be added so the offer can be Published

        Image Added

  • Create a Config Offer (e.g. config offer for for BK UK)

    • you will need a different Config Offer created for each offer you would like to assign using Braze

    • save the Loyalty Engine ID of the template offer to input into Braze after

      Image Added
    • within this config offer, in the Mechanics dropdown under Benefits you will need to link the offer benefits (e.g. Picker or Offer Combo)

      Image Added
    • Make sure to add the config offer to the list of Live Config Offers in the Loyalty Offers UI in Sanity, so the offer shows in the app to the user after it is assigned

      Image Added

Braze Configuration

Body request

Code Block
languagejson
{
  "userId": "{{${user_id}}}",
  "templateId": "31860003-2e04-4b2e-9008-a6aa33f69da9",
  "source": "braze-test",
  "rank": 123456, (optional)
  "configId": "Loyalty engine id of config offer",
  "ruleParams": {
    "startDate": "yyyy-mm-dd",
    "endDate": "yyyy-mm-dd"
  }
}
  • Replace templateId with the Loyalty Engine ID of the Template Offer used for Braze Offers

  • Replace configId with the Loyalty Ending ID of the offer you want to assign using Braze

  • source should be braze in Production; braze-test in lower environments (Dev, Staging)

  • userId -> leave as is

  • startDate and endDate-> required fields; the endDate must be set after the startDate - this represents the duration of time the offer assignment will be available for

  • rank field (optional) determines the sequence priority of the assigned personalized offer. The lower the number, the higher the priority (i.e. 1 would rank at the top)

Request headers

Webhook URL
Info

the Hot path should be used for any user triggered campaigns that should happen in realtime

  • ie: T-Mobile Tuesdays, sign up bonuses

the Cold path should be used for any marketer triggered campaigns that can be processed over time

  • ie: mass offers assignments, mass points updates

Example of Hot Webhook URL in Production:

Code Block
https://prod-bk-loyalty-middleware.rbictg.com/bulk-action/hot/create-offer

Example of the Cold Webhook URL in Production:

Code Block
https://prod-bk-loyalty-middleware.rbictg.com/bulk-action/cold/create-offer

If you would like to test in Staging the Offer assignment first, just replace prod with staging in the Webhook URL

Content-type
Code Block
languagejson
Content-Type: application/json
X-Region
Code Block
x-region: gb
Info

x-region is the 2-character ISO country code string of that market (e.g. gb = United Kingdom, ch = Switzerland)

X-Api-Key
Code Block
x-api-key: BaHC4VILjv73xQYdEIuLo4uD0kjvBli3qqQ4amb3
Note

Please reach out to Lopes da Costa, Valentina or another PM to get you access to the API Key in Production for your brand

...

Other resources

...