Versions Compared

Key

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

...

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", //
OfferCombo         "menuSelections": [
          {
            "externalReferenceId": "51056", // item constant plu
            "id": "item_1862", // item Sanity id
            "menuSelections": [],
            "price": {
                "amount": 2495, // normal price
                "currency": "SAR"
          },
            "quantity": 1,
            "type": "Item"
          }
        ]
      }
    ]
  }
]

Reward with a combo

Code Block
"cart": {
 
      "menuSelections": [
            {
                "externalReferenceId": "83508351", // reward   plu
           "id": "43b4cf07-79c9-4aff-98d1-bce9cf2d890f", //reward sanity  id
            "menuSelections": [
    
               {
     
                  "externalReferenceId": "100598350", // combo plu
                     "id": "item_185243b4cf07-79c9-4aff-98d1-bce9cf2d890f", //combo sanity id
                     "menuSelections": [],
                        "price": {
                            "amountexternalReferenceId": 0"10059",
                            "currencyid": "SARitem_1852",
                        } "menuSelections": [],
                        "quantityprice": 1,{
                            "typeamount": "Item"0,
                            "currency": "SAR"
   },                     {},
                        "externalReferenceIdquantity": "80007"1,
                        "idtype": "4f99db1e-128a-4e53-b23b-dffc0fedf636",Item"
                        "menuSelections": []},
                    {
   "price": {                             "amount": 0,
 "externalReferenceId": "80007",
                          "currencyid": "SAR"4f99db1e-128a-4e53-b23b-dffc0fedf636",
                        }"menuSelections": [],
                        "quantityprice": 1, {
                            "typeamount": "Item"0,
                    },        "currency": "SAR"
           {             },
           "externalReferenceId": "80001",            "quantity": 1,
           "id": "16f482db-2f13-4476-88d3-d2eec26057f3",            "type": "Item"
           "menuSelections": [],        },
                "price": {    {
                        "amountexternalReferenceId": 0"80001",

                           "currencyid": "SAR"16f482db-2f13-4476-88d3-d2eec26057f3",
                        }"menuSelections": [],
                        "quantityprice": 1,{
                        "type": "Item"   "amount": 0,
                },              "currency": "SAR"
      {                         "externalReferenceId": "141139"},
                        "idquantity": "141139"1,
                        "menuSelectionstype": [],"Item"
                    },
   "price": {                {
                 "amount       "externalReferenceId": 0"141139",
                            "currencyid": "SAR141139",
                        }"menuSelections": [],
                        "quantityprice": 1,{
                            "typeamount": "Item"0,
                       }     "currency": "SAR"
          ],              },
  "price": {                     "amountquantity": 01,
                        "currencytype": "SARItem"
                    },
                "quantity": 1],
                "typeprice": "Reward"{
            }    "amount": 300, // original price ]of combo
      },

Offer with a combo

Code Block
"cart": {         "menuSelectionscurrency": "SAR"
[              {   },
             "externalReferenceId    "quantity": "8167"1,
                 "idtype": "d90a7113-0620-44d9-b678-743330a2f207",Combo"
                "menuSelections": [}
              ],
     {         "price": {
              "externalReferenceIdamount": "80003"0, // final price of the     reward
              "idcurrency": "ce847c79-9eb5-4be3-8a1e-842919aa5ba0",SAR"
              },
          "menuSelections": [],   "quantity": 1,
                    "price"type": {"Reward"
            }
        ]
      "amount},

Offer with a combo

Code Block
"cart": 0,{
  "menuSelections": [
    {
      "externalReferenceId": "8351", // offer   plu
      "currencyid": "SAR"
     43b4cf07-79c9-4aff-98d1-bce9cf2d890f", //offer sanity id
        "menuSelections": [
        },    {
                    "quantityexternalReferenceId": 1"8167", // combo  plu
                    "typeid": "Item"
  d90a7113-0620-44d9-b678-743330a2f207", //combo sanity id
                 },"menuSelections": [
                    {
                        "externalReferenceId": "14253880003",
                        "id": "142538",ce847c79-9eb5-4be3-8a1e-842919aa5ba0",
                        "menuSelections": [],
                        "price": {
                            "amount": 0,
                            "currency": "SAR"
                        },
                        "quantity": 1,
                        "type": "Item"
                    },
                ],    {
            "price": {               "externalReferenceId": "142538",
     "amount": 500,
                    "currencyid": "SAR142538",
                },        "menuSelections": [],
       "quantity": 1,                 "typeprice": "Offer"{
              }         ]     },

Offer with a picker

Code Block
"cart": {"amount": 0,
                            "currency": "SAR"
                        },
                        "quantity": 1,
                        "type": "Item"
                    }
                ],
                "price": {
                    "amount": 500, //price of the combo
                    "currency": "SAR"
                },
                ],
                "price": {
                "amount": 100, // final price of the offer
                "currency": "SAR"
                },
                "quantity": 1,
                "type": "Offer"
            }
        ]
    },

Offer with a picker

Code Block
"cart": {
  "menuSelections": [
    {
      "externalReferenceId": "8351", // offer plu
      "id": "43b4cf07-79c9-4aff-98d1-bce9cf2d890f", //offer sanity id
        "menuSelections": [
            {
                "externalReferenceId": "8168", //combo plu
                "id": "3318d2c2-99d3-40f9-92d2-1798d9c5e987", //combo sanity id
                "menuSelections": [
                    {
                        "externalReferenceId": "816820001",
                        "id": "3318d2c2-99d3-40f9-92d2-1798d9c5e987",item_61936",
                        "menuSelections": [],
                        "price": {
                            "externalReferenceIdamount": "20001"0,
                            "idcurrency": "item_61936SAR",
                        "menuSelections": []},
                        "pricequantity": {1,
                            "amount": 0,"type": "Item"
                    },
        "currency": "SAR"           {
             },           "externalReferenceId": "80002",
            "quantity": 1,           "id": "865a632f-e2f7-4e2b-8fcc-9281aa3f5868",
            "type": "Item"           "menuSelections": [],
        },                "price": {
   {                         "externalReferenceIdamount": "80002"0,
                            "idcurrency": "865a632f-e2f7-4e2b-8fcc-9281aa3f5868",SAR"
                        "menuSelections": [],
           },
            "price": {                "quantity": 1,
           "amount": 0,            "type": "Item"
               "currency": "SAR"    },
                    },{
                        "quantityexternalReferenceId": 1"80008",
                        "typeid": "Item"04462c22-bf58-4eee-842a-213e3d17a072",
                        },"menuSelections": [],
                        "price": {
   {                         "externalReferenceIdamount": "80008"0,
                            "idcurrency": "04462c22-bf58-4eee-842a-213e3d17a072",SAR"
                        "menuSelections": []},
                        "pricequantity": {
   1,
                        "amounttype": 0,
           "Item"
                "currency": "SAR"    },
                    },{
                        "quantityexternalReferenceId": 1"142538",
                        "typeid": "Item142538",
                      },  "menuSelections": [],
                        "price": {
                            "externalReferenceIdamount": "142538"0,
                            "idcurrency": "142538SAR",
                        "menuSelections": [],
},
                       "price": {   "quantity": 1,
                        "amounttype": 0,"Item"
                    }
       "currency": "SAR"        ],
                },
"price": {
                       "quantityamount": 1500, //price of the combo
                    "typecurrency": "ItemSAR"
                    }
 },
              ],
 
              "price": {
                    "amount": 1000100, // final price of the offer
              "currency": "SAR"
 
              },
                "quantity": 1,
                "type": "Offer"
            }
        ]
    },