How to apply Item Overloads
Introduction
Specific item attributes can be overridden depending on the item or grouping it is offered within.
This allows for customisation of how products are offered on ordering platforms, for example;
- Context-specific Pricing: Apply a surcharge on combo products which overrides the zero price default.
- Attribute adjustments: Modify other default values, such as the "visible" status of an item.
Format
An overload consists of an "overloads" array listing one or more objects, each with a "scopes" list of one or more PLU identifiers, alongside with one or more override properties e.g. "price"
{
"overloads": [
{
"scopes": ["PLU-123"],
"<property>": "<override value>"
}
]
}Supported Overload Values
Below are the values which can applied in the above structure;
| Property | Description |
|---|---|
price | Standard price override for any item within a Modifier Group productType:3) |
bundlePrice | Price override for any item within a Bundle Group productType:4 |
defaultQuantity | A default quantity of greater or equal to 1 is a "pre-selected" item |
min | Minimum selection quantity allowed |
max | Maximum selection quantity allowed |
multiMax | Maximum quantity of multiple selections of the same item |
name | Display name |
description | Description text |
nameTranslations | Localized names |
descriptionTranslations | Localized descriptions |
imageUrl | Product image |
visible | Visibility flag (enabled/disabled) |
Overloads Examples
1.Modifier Price Overload
The Avocado has a base price of 100 but it's price is overridden depending on the context in which it is selected:
- When included in the modifier group with PLU
FREE-TOP, its price is set to0. - When included in the product with PLU
POKEits price is set to50.
{
"productType": 2,
"plu": "AVO",
"price": 100,
"name": "Avocado",
"overloads": [
{
"scopes": [
"FREE-TOP"
],
"price": 0
},
{
"scopes": [
"POKE"
],
"price": 100
}
]
}2 Bundle Product Price Overload
The Ice Cream has a base price of 500. Its price can also be overridden depending on where it is included:
- When included in the bundle group with PLU
FREE-DESS, its price is set to0. - When included within the combo product with PLU
BRGR_COMBO, its price is set to450.
{
"productType": 1,
"plu": "IC",
"price": 500,
"name": "Ice Cream",
"overloads": [
{
"scopes": [
"FREE-DESS"
],
"bundlePrice": 0
},
{
"scopes": [
"BRGR_COMBO"
],
"price": 450
}
]
}3.Default Quantity Overload
The Chicken Tenders example below demonstrates how an item's default quantity can be overridden based on the context in which it is displayed.
When the Chicken Tenders are displayed within the modifier group with PLU CHK_MEAL, the defaultQuantity is set to 1. This means the item will be pre-selected with a quantity of one when displayed in that context.
{
"productType": 1,
"plu": "PROD-1",
"price": 500,
"defaultQuantity": 0,
"name": "Chicken Tenders",
"overloads": [
{
"scopes": [
"CHK_MEAL"
],
"defaultQuantity": 1
}
]
}Updated 11 days ago
