Versions Compared

Key

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

...

Rewards are an item benefit that can be redeemed in exchange for points (and sometimes money + points). Read more about it here: /wiki/spaces/HELP/pages/4921819186 .

Reward with an item

"cart": [ { "menuSelections": [ {
Expand
titleRBI Partner API
Code Block
Info

Oracle documentation: https://docs.oracle.com/en/industries/food-beverage/simphony/19.7/simcg/c_discounts_automatic_discount_rules.htm

Online

  • 0 Priced reward item - discount it 100%.

    • discounts have a discount ID.

    • each offer / reward has a unique discount ID

In Restaurant

  • 0 priced reward item - pre select and offer and reward. discount it 100%.

Next steps:

  • Send all offer and reward information to Oracle team. Multiple different discounts that can be used (100% discount off, item price substitution)

  • Talk with TRX team about Rewards with prices + loyalty points (using item price substitution discount)

  • Have internal discussion and setup a call with Oracle team to validate

  • Understand if there are any implications to analytics (understanding the difference between offers and rewards)

Reward with an item

Expand
titleRBI Partner API
Code Block
"cart": [
  {
    "menuSelections": [
      {
        "id": "7ee7338a-a016-47c6-aef6-3783d40c003e", // Reward Sanity id
        "externalReferenceId": "123", // Reward constant plu defined in Sanity
        "quantity": 1,
        "price": {
          "amount": 0,
          "currency": "SAR",
        }
        "type": "Reward", 
        "menuSelections": [
          {
            "externalReferenceId": "51056", // item constant plu
            "id": "item_1862", // item Sanity id
            "menuSelections": [],
            "price": {
                "amount": 2495, // normal price
                "currency": "SAR"
          },
            "quantity": 1,
            "type": "Item"
          }
        ]
      }
    ]
  }
]
Expand
titleOracle TS Gen 2 (Commit call)
Code Block
{
    "header": {
        "orgShortName": "{{OrgShortName}}",
        "locRef": "{{LocRef}}",
        "rvcRef": {{RvcRef}},
        "idempotencyId": "{{$guid}}",
        "orderTypeRef": 9,
        "checkEmployeeRef": {{check_employee_ref}}
    },
    "menuItems": [],
    "comboMeals": [
        {
            "comboMealId": 51002003, // Cheeseburger reward
            "comboItem": {
                "menuItemId": 51002003, // Cheeseburger reward PLU
                "definitionSequence": 1,
                "quantity": 1
            },
            "mainItem": {
                "menuItemId": 1002003, // A la carte cheeseburger
                "definitionSequence": 1,
                "quantity": 1
            },
            "sideItems": []
        }
    ],
    "tenders": [
        {
            "tenderId": 901 // payment method ID. Pay at Counter for this example.
        }
    ]
}
Info

In Oracle, we use a separate combo for reward items so that we can set up a different price (0) vs the single item ALC. Alternatively, we could create a new priceSequence set to 0 for each definitionSequence , and then re-use the single item.

Note

Oracle can only handle up to 10,000 combos.

Reward with an item + premium modifier

Expand
titleRBI Partner API
Code Block
"cart": [
  {
    "menuSelections": [
      {
        "id": "7ee7338a-a016-47c6-aef6-3783d40c003e", // Reward Sanity id
        "externalReferenceId": "123", // Reward constant plu defined in Sanity
        "quantity": 1,
        "price": {
          "amount": 0,
          "currency": "SAR",
        }
        "type": "Reward", 
        "menuSelections": [
          {
            "externalReferenceId": "51056", // item constant plu
            "id": "item_1862", // item Sanity id
            "menuSelections": [],
            "price": {
                "amount": 2495, // normal price
                "currency": "SAR"
          },
            "quantity": 1,
            "type": "Item"
          }
        ]
      }
    ]
  }
]
Expand
titleOracle TS Gen 2 (Commit call)
Code Block
{
    "header": {
        "orgShortName": "{{OrgShortName}}",
        "locRef": "{{LocRef}}",
        "rvcRef": {{RvcRef}},
        "idempotencyId": "{{$guid}}",
        "orderTypeRef": 9,
        "checkEmployeeRef": {{check_employee_ref}},
        "language": "es-ES",
        "Accept-Language": "es-ES"
    },
    "menuItems": [],
    "comboMeals": [
        {
            "comboMealId": 51002003, // Cheeseburger reward
            "comboItem": {
                "menuItemId": 51002003, // Cheeseburger reward
                "definitionSequence": 1,
                "quantity": 1
            },
            "mainItem": {
                "menuItemId": 1002003, // Cheeseburger ALC
                "definitionSequence": 1,
                "quantity": 1,
                "condiments": [
                    {
                        "condimentId": 9011005, // Add bacon. Premium modifier (extra cost)
                        "priceSequence": 2,
                        "quantity": 2
                    }
                ]
            },
            "sideItems": []
        }
    ],
    "tenders": [
        {
            "tenderId": 901
        }
    ]
}

Reward with a combo

Expand
titleRBI Partner API
Code Block
"cart": {
  "menuSelections": [
    {
      "externalReferenceId": "8351", // reward plu
      "id": "43b4cf07-79c9-4aff-98d1-bce9cf2d890f", //reward sanity id
        "menuSelections": [
            {
                "externalReferenceId": "8350", // combo plu
                "id": "43b4cf07-79c9-4aff-98d1-bce9cf2d890f", //combo sanity id
                "menuSelections": [
                    {
                        "externalReferenceId": "10059",
                        "id": "item_1852",
                        "menuSelections": [],
                        "price": {
                            "amount": 0,
                            "currency": "SAR"
                        },
                        "quantity": 1,
                        "type": "Item"
                    },
                    {
                        "externalReferenceId": "80007",
                        "id": "4f99db1e-128a-4e53-b23b-dffc0fedf636",
                        "menuSelections": [],
                        "price": {
                            "amount": 0,
                            "currency": "SAR"
                        },
                        "quantity": 1,
                        "type": "Item"
                    },
                    {
                        "externalReferenceId": "80001",
                        "id": "16f482db-2f13-4476-88d3-d2eec26057f3",
                        "menuSelections": [],
                        "price": {
                            "amount": 0,
                            "idcurrency": "7ee7338a-a016-47c6-aef6-3783d40c003e", // Reward Sanity idSAR"
                       "externalReferenceId": "123", // Reward constant plu defined in Sanity },
                        "quantity": 1,
        "price": {                "amounttype": 0,"Item"
          "currency": "SAR",         },
         "type": "Reward",          "menuSelections":{
[           {             "externalReferenceId": "51056141139", // item constant plu
                        "id": "item_1862141139",
// item Sanity id                        "menuSelections": [],
                        "price": {
                            "amount": 2495, // normal price0,
                            "currency": "SAR"
          },             "quantity": 1},
             "type           "quantity": "Item"1,
          }         ]     "type": "Item"
}     ]   } ]
Expand
titleOracle TS Gen 2 (Commit call)
Code Block
{     "header": {     }
   "orgShortName": "{{OrgShortName}}",         "locRef": "{{LocRef}}",  ],
      "rvcRef": {{RvcRef}},         "idempotencyIdprice": "{{$guid}}",
        "orderTypeRef": 9,
        "checkEmployeeRefamount": {{check_employee_ref}}
    }, 300, // original price of combo
     "menuItems": [],     "comboMeals": [    "currency": "SAR"
   {             "comboMealId": 51002003},
  // Cheeseburger reward             "comboItemquantity": {1,
                 "menuItemIdtype": 51002003, // Cheeseburger reward PLU "Combo"
                 }
           "definitionSequence": 1,  ],
              "quantityprice": 1{
            },  "amount": 0, // final price of the reward
    "mainItem": {         "currency": "SAR"
      "menuItemId": 1002003, // A la carte cheeseburger  },
              "definitionSequencequantity": 1,

               "quantitytype": 1"Reward"
            },
        ]
    "sideItems": []},
Expand
titleOracle TS Gen 2 (Commit call)
Code Block
languagejson
{
    "header": {
        "orgShortName": "{{OrgShortName}}",
    ],    "locRef": "tenders": [{{LocRef}}",
        "rvcRef": {
  {{RvcRef}},
        "idempotencyId": "tenderId": 901 // payment method ID. Pay at Counter for this example.{{$guid}}",
        "orderTypeRef": 9,
        "checkEmployeeRef": {{check_employee_ref}},
        ]
}
Info

In Oracle, we use a separate combo for reward items so that we can set up a different price (0) vs the single item ALC. Alternatively, we could create a new priceSequence set to 0 for each definitionSequence , and then re-use the single item.

Note

Oracle can only handle up to 10,000 combos.

Reward with an item + premium modifier

Expand
titleRBI Partner API
Code Block
"cart": [
  {"language": "es-ES",
        "Accept-Language": "es-ES"        
    },
    "menuItems": [],
    "menuSelectionscomboMeals": [
        {
            "idcomboMealId": "7ee7338a-a016-47c6-aef6-3783d40c003e"51001504, //Whopper with Cheese Combo Reward
  Sanity id         "externalReferenceIdcomboItem": "123", // Reward constant plu defined in Sanity{
                "menuItemId": 51001504, //Whopper with Cheese Combo Reward
                "quantitydefinitionSequence": 1,
        "price": {
          "amountquantity": 1
0,           "currency": "SAR" },
        }    "mainItem": {
     "type": "Reward",          "menuSelectionsmenuItemId": [1001003, // Whopper with cheese  ALC
    {             "externalReferenceIddefinitionSequence": "51056"1,
// item constant plu             "idquantity": "item_1862", // item Sanity id 1
            },
            "menuSelectionssideItems": [],
               "price": {
                    "amountmenuItemId": 24951013201, //Small pepsi
 normal price                 "currency": "SARdefinitionSequence":  1,
        },             "quantity": 1,
            "type": "Item"   },
       }         ]{
      }     ]   } ]
Expand
titleOracle TS Gen 2 (Commit call)
Code Block
{     "headermenuItemId": { 2102002, //Small fries
          "orgShortName": "{{OrgShortName}}",         "locRefdefinitionSequence": "{{LocRef}}",1,
          "rvcRef": {{RvcRef}},         "idempotencyIdquantity": "{{$guid}}",
  1
     "orderTypeRef": 9,         "checkEmployeeRef": {{check_employee_ref}},
  
     "language": "es-ES",      ]
  "Accept-Language": "es-ES"     },

   "menuItems": [],
    "comboMealstenders": [
        {
            "comboMealIdtenderId": 51002003, //901
Cheeseburger reward       }
     "comboItem": ]
}

Reward with a combo + premium modifier

Expand
titleRBI Partner API
Code Block
{
    "payload": {
          "menuItemIdnumber": 51002003"5848",
// Cheeseburger reward      "fees": [
           "definitionSequence": 1, {
                "quantitytotal": 1{
            },          "amount": 19,
  "mainItem": {                 "menuItemIdcurrency": 1002003, // Cheeseburger ALC
 "EUR"
              "definitionSequence": 1  },
                "quantitytype": 1,"BAG_FEE"
            }
   "condiments": [    ],
        "serviceMode": "DELIVERY",
      {  "channel": "WHITELABEL_DELIVERY",
            "callbackUrl": "https://euw3-staging-bk-partners-api.rbictg.com/api/v1/orders/15c3dbe1-5165-404b-8858-088239d14014/price/callback",
        "condimentIdid": 9011005, // Add bacon. Premium modifier (extra cost)"15c3dbe1-5165-404b-8858-088239d14014",
        "storeId": "12349",
        "cart": {
            "menuSelections": [
   "priceSequence": 2,            {
            "quantity": 2       "externalReferenceId": "948351",
            }        "quantity": 1,
       ]             },
"menuSelections": [
           "sideItems": []         }   {
 ],
    "tenders": [         {             "tenderIdexternalReferenceId": 901"502617",
        }     ] }

Reward with a combo

Expand
titleRBI Partner API
Code Block
"cart": {
  "menuSelections": [     {       "externalReferenceIdquantity": "8351", // reward plu1,
              "id": "43b4cf07-79c9-4aff-98d1-bce9cf2d890f", //reward sanity id             "menuSelections": [
            {                 "externalReferenceId": "8350", // combo{
plu
                "id": "43b4cf07-79c9-4aff-98d1-bce9cf2d890f", //combo sanity id                 "menuSelectionsexternalReferenceId": [ "502633",
                       {             "quantity": 1,
          "externalReferenceId": "10059",                         "idmenuSelections": "item_1852",[
                             "menuSelections": [],          {
              "price": {                             "amountexternalReferenceId": 0"528232",
                            "currency": "SAR"                "quantity": 1,
                   },                         "quantityprice": {
  1,                         "type": "Item"                    "amount": }90,
                     {                           "externalReferenceIdcurrency": "80007EUR",
                        "id": "4f99db1e-128a-4e53-b23b-dffc0fedf636",                   },
     "menuSelections": [],                         "price": {            "id": "8ba0df7b35df",
               "amount": 0,                             "currencytype": "SARItemOptionModifier"
                        },                }
        "quantity": 1,                         "type": "Item" ],
                   },                     {
          "price": {
             "externalReferenceId": "80001",                         "id": "16f482db-2f13-4476-88d3-d2eec26057f3"amount": 0,
                        "menuSelections": [],               "currency": "EUR"
             "price": {                      },
      "amount": 0,                             "currencyid": "SARitem_11107",
                        },            "type": "Item"
           "quantity": 1,                    },
    "type": "Item"                     },      {
              {
                        "externalReferenceId": "141139942258",
                        "id": "141139",             "quantity": 1,
           "menuSelections": [],                         "price": {
                                "amount": 0,       "amount": 0,
                    "currency": "SAR"                   "currency": "EUR"
    },                         "quantity": 1,      },
                  "type": "Item"                 "id": "item_11126",
  }                 ],                 "pricetype": {"Item"
                "amount": 300, // original price of combo          },
      "currency": "SAR"                  },       {
          "quantity": 1,                  "type": "Combo"      "externalReferenceId": "527646",
          }               ],               "pricequantity": {1,
              "amount": 0, // final price of the reward               "currencyprice": "SAR"
    {
         },               "quantity": 1,               "typeamount": "Reward"0,
            }         ]     },
Expand
titleOracle TS Gen 2 (Commit call)
Code Block
languagejson
{
    "header": {         "orgShortNamecurrency": "{{OrgShortName}}",EUR"
               "locRef": "{{LocRef}}",         "rvcRef": {{RvcRef}},         "idempotencyId": "{{$guid}}",
           "orderTypeRef": 9,               "checkEmployeeRef": {{check_employee_ref}},         "languageid": "es-ES9aac0a46-5a73-431d-937c-8848ca01ac86",
          "Accept-Language": "es-ES"               },     "menuItems": [],     "comboMealstype": ["Item"
        {             "comboMealId": 51001504, //Whopper with Cheese Combo Reward     }
       "comboItem": {                 "menuItemId": 51001504, //Whopper with],
Cheese Combo Reward                 "definitionSequence": 1,        "price": {
       "quantity": 1             },             "mainItemamount": {875,
                "menuItemId": 1001003, // Whopper with cheese ALC          "currency": "EUR"
     "definitionSequence": 1,                 "quantity": 1    },
        },             "sideItems": [      "id": "a2e73fd9-5f3d-4afc-9585-43ebd7bbc6dc",
         {                     "menuItemIdtype": 1013201, //Small pepsi"Combo"
                      "definitionSequence": 1, }
                   "quantity": 1 ],
                },    "price": {
           {                     "menuItemId"amount": 2102002450,
//Small   fries                     "definitionSequencecurrency": 1,"EUR"
                    "quantity": 1},
                 }   "id": "024f9096-e3ee-45fc-8f76-d75e272ff9e9",
        ]         }   "type": "Reward"
],     "tenders": [         { }
           "tenderId": 901]
        }
    ]}
}

Reward with a combo + premium modifier

Expand
titleRBI Partner API
code
Expand
titleOracle TS Gen 2 (Commit call)
Code Block
{
    "header": {
        "orgShortName": "{{OrgShortName}}",
        "locRef": "{{LocRef}}",
        "rvcRef": {{RvcRef}},
        "idempotencyId": "{{$guid}}",
        "orderTypeRef": 9,
        "checkEmployeeRef": {{check_employee_ref}},
        "language": "es-ES",
        "Accept-Language": "es-ES"
    },
    "menuItems": [],
    "comboMeals": [
        {
            "comboMealId": 51001504, // Whopper Cheese combo reward
            "comboItem": {
                "menuItemId": 51001504, //// Whopper Cheese combo reward
                "definitionSequence": 1,
                "quantity": 1
            },
            "mainItem": {
                "menuItemId": 1001003, // whopper cheese
                "definitionSequence": 1,
                "quantity": 1,
                "condiments": [
                    {
                        "condimentId": 9011005, // Add bacon. Premium modifier (extra cost)
                        "priceSequence": 2,
                        "quantity": 2
                    }
                ]
            },
            "sideItems": [
                {
                    "menuItemId": 1013201, // Small fries
                    "definitionSequence": 1,
                    "quantity": 1
                },
                {
                    "menuItemId": 2000008, // Icy mango. Premium drink (extra cost)
                    "definitionSequence": 1,
                    "quantity": 1
                }
            ]
        }
    ],
    "tenders": [
        {
            "tenderId": 901
        }
    ]
}

...

Expand
titleRBI Partner API
Code Block
languagejson
/{
    "payload": {
        "number": "5807",
        "fees": [
            {
                "total": {
                    "amount": 19,
                    "currency": "EUR"
                },
                "type": "BAG_FEE"
            }
        ],
        "serviceMode": "DELIVERY",
        "channel": "WHITELABEL_DELIVERY",
        "callbackUrl": "https://euw3-staging-bk-partners-api.rbictg.com/api/v1/orders/781f28e9-d6bb-4c8e-9ea6-e65a2e7c3764/price/callback",
        "id": "781f28e9-d6bb-4c8e-9ea6-e65a2e7c3764",
        "orderDiscounts": [
            {
                "plu": "948348",
                "type": "percentage",
                "value": 50
            }
        ],
        "storeId": "12349",
        "cart": {
            "menuSelections": [
                {
                    "externalReferenceId": "948348",
                    "quantity": 1,
                    "menuSelections": [
                        {
                            "externalReferenceId": "502633",
                            "quantity": 1,
                            "price": {
                                "amount": 0,
                                "currency": "EUR"
                            },
                            "id": "item_11107",
                            "type": "Item"
                        }
                    ],
                    "price": {
                        "amount": 645,
                        "currency": "EUR"
                    },
                    "id": "fbdead97-5acb-4d1c-a5fe-5794ece61aaa",
                    "type": "Reward"
                }
            ]
        }
    }
}

...