API

Deal

A store's deals: list, create, get, update or delete one.

Operations

Every route this entity exposes. Each route links to its own reference on this page.

Method Route SDK operation Returns
POST /v1/stores/{storeId}/deals create OK
GET /v1/stores/{storeId}/deals list OK
GET /v1/stores/{storeId}/deals/{id} load OK
DELETE /v1/stores/{storeId}/deals/{id} remove No Content
PUT /v1/stores/{storeId}/deals/{id} update OK

Examples

One example per SDK, generated from the API model. The argument names are the parameters and fields of this entity, and the values are placeholders. The examples are not compiled or executed.

Golang

Construct client as shown in the Golang setup, then call the operations:

deals, err := client.Deal(nil).List(map[string]any{"store_id": "example"}, nil)
if err != nil {
    panic(err)
}
fmt.Println(deals)
deal, err := client.Deal(nil).Load(map[string]any{"id": "example_id", "store_id": "example"}, nil)
if err != nil {
    panic(err)
}
fmt.Println(deal)
created, err := client.Deal(nil).Create(map[string]any{"store_id": "example"}, nil)
if err != nil {
    panic(err)
}
fmt.Println(created)
updated, err := client.Deal(nil).Update(map[string]any{"id": "example_id", "store_id": "example", "discounts": []any{}}, nil)
if err != nil {
    panic(err)
}
fmt.Println(updated)
removed, err := client.Deal(nil).Remove(map[string]any{"id": "example_id", "store_id": "example"}, nil)
if err != nil {
    panic(err)
}
fmt.Println(removed)

Lua

Construct client as shown in the Lua setup, then call the operations:

local deals, err = client:Deal():list({ store_id = "example" })
local deal, err = client:Deal():load({ id = "example_id", store_id = "example" })
local created, err = client:Deal():create({ store_id = "example" })
local updated, err = client:Deal():update({ id = "example_id", store_id = "example", discounts = {} })
local removed, err = client:Deal():remove({ id = "example_id", store_id = "example" })

PHP

Construct client as shown in the PHP setup, then call the operations:

$deals = $client->Deal()->list(["store_id" => "example"]);
$deal = $client->Deal()->load(["id" => "example_id", "store_id" => "example"]);
$created = $client->Deal()->create(["store_id" => "example"]);
$updated = $client->Deal()->update(["id" => "example_id", "store_id" => "example", "discounts" => []]);
$client->Deal()->remove(["id" => "example_id", "store_id" => "example"]);

Python

Construct client as shown in the Python setup, then call the operations:

deals = client.Deal().list({"store_id": "example"})
deal = client.Deal().load({"id": "example_id", "store_id": "example"})
created = client.Deal().create({ "store_id": "example" })
updated = client.Deal().update({"id": "example_id", "store_id": "example", "discounts": []})
client.Deal().remove({"id": "example_id", "store_id": "example"})

Ruby

Construct client as shown in the Ruby setup, then call the operations:

deals = client.Deal.list({ "store_id" => "example" })
deal = client.Deal.load({ "id" => "example_id", "store_id" => "example" })
created = client.Deal.create({ "store_id" => "example" })
updated = client.Deal.update({ "id" => "example_id", "store_id" => "example", "discounts" => [] })
client.Deal.remove({ "id" => "example_id", "store_id" => "example" })

TypeScript

Construct client as shown in the TypeScript setup, then call the operations:

const deals = await client.Deal().list({ store_id: "example" })
const deal = await client.Deal().load({ id: "example_id", store_id: "example" })
const created = await client.Deal().create({ store_id: "example" })
const updated = await client.Deal().update({ id: "example_id", store_id: "example", discounts: [] })
await client.Deal().remove({ id: "example_id", store_id: "example" })

Fields

Field Type Required Description
discounts array No A list of flat and percent discounts
id string No Id
meals array No A list of type meals deals
n_for_n array No A list of n_for_n promotions
n_for_price_n array No A list of n_for_price_n promotions

create

POST /v1/stores/{storeId}/deals

Operation ID: POST/v1/stores/{storeId}/deals.

Authentication: oauth2 (AccessToken).

Parameters

Parameter In Type Required Description
storeId path string Yes Store Identifier

Request body

application/json

Property Type Required Description
discounts array of object No A list of flat and percent discounts
discounts[].availability array of enum: MO, TU, WE, TH, FR, SA, ... Yes
discounts[].id string Yes Deal ID (controlled by partners)
discounts[].items array of string Yes Array of item ids
discounts[].schedule object Yes
discounts[].schedule.end_date string No The date at which the menu ceases to be available, in YYYY-MM-DD format eg 2024-12-01 leave empty always visible
discounts[].schedule.end_time string Yes The time at which the menu ceases to be available, in 24-hour HH:MM format, for example “08:30”, “23:00”
discounts[].schedule.start_date string No The date at which the menu becomes available, in YYYY-MM-DD format eg 2024-01-01 leave empty always visible
discounts[].schedule.start_time string Yes The time at which the menu becomes available, in 24-hour HH:MM format, for example “08:30”, “23:00”
discounts[].subcategory_id string Yes Pass the ref id of subcategory it mapped with deals
discounts[].type enum: flat, percent Yes Deals Type
discounts[].value number Yes Either Percent or Flat value
meals array of object No A list of type meals deals
meals[].availability array of enum: MO, TU, WE, TH, FR, SA, ... No
meals[].contains_alcohol boolean No This is to specify if the item contains alcohol content or not
meals[].contains_tobacco boolean No This is to specify if the item contains tobacco content or not
meals[].description string No Item Description
meals[].dietary_labels array of enum: VEGAN, VEGETARIAN, GLUTEN_FREE, NON-VEGETARIAN No
meals[].fulfillment_modes array of enum: DELIVERY, COLLECTION No
meals[].id string Yes Deal ID (controlled by partners)
meals[].image string No Image that should be displayed along side this item. If the field is missing - any existing image will be removed.
meals[].is_tax_included boolean No Setting to true assumes tax is included in the price. Otherwise you will be able to set tax_percentage.
meals[].name string Yes Deal Name
meals[].name_localized string No Second Language Name
meals[].number_of_servings number No Describes the Number of servings for a item
meals[].nutrition_info object No
meals[].nutrition_info.lower_range number Yes The lower range of the energy content.
meals[].nutrition_info.upper_range number Yes The upper range of the energy content.
meals[].price integer Yes Menu item price value, represented in the lowest currency unit, such as pence, paise, cents, yen, etc.
meals[].schedule object Yes
meals[].schedule.end_date string No The date at which the menu ceases to be available, in YYYY-MM-DD format eg 2024-12-01 leave empty always visible
meals[].schedule.end_time string Yes The time at which the menu ceases to be available, in 24-hour HH:MM format, for example “08:30”, “23:00”
meals[].schedule.start_date string No The date at which the menu becomes available, in YYYY-MM-DD format eg 2024-01-01 leave empty always visible
meals[].schedule.start_time string Yes The time at which the menu becomes available, in 24-hour HH:MM format, for example “08:30”, “23:00”
meals[].selections array of object Yes
meals[].selections[].max_permitted number No Maximum quantity allowed (inclusive). max_permitted cannot be less than min_permitted.
meals[].selections[].min_permitted number No Minimum quantity allowed (inclusive) -- Cannot be negative.
meals[].selections[].modifier_group_id string Yes Modifier Group reference ID
meals[].selections[].modifiers array of object Yes
meals[].selections[].modifiers[].max_permitted number No Maximum quantity allowed (inclusive). max_permitted cannot be less than min_permitted.
meals[].selections[].modifiers[].min_permitted number No Minimum quantity allowed (inclusive) -- Cannot be negative.
meals[].selections[].modifiers[].modifier_id string Yes Modifier reference ID
meals[].selections[].modifiers[].price integer No Override price for the modifier, represented in the lowest currency unit, such as pence, paise, cents, yen, etc.
meals[].selections[].modifiers[].selections array of any No Nested selections for the modifier groups
meals[].selections[].modifiers[].show_online boolean No Show the modifier online or not praticular item
meals[].sequence integer No The sequence field orders items for display or application. It's a numeric value indicating the preferred order, with lower values shown first.
meals[].show_online boolean No Enable or Disable whether this category shown on Foodhub platform.
meals[].subcategory_id string Yes Pass the ref id of subcategory it mapped with deals
meals[].tax_percentage integer No This will only work when tax included is false.
meals[].type enum: n-for-n, n-for-price-n, meals, flat, percent No Deals Type
n_for_n array of object No A list of n_for_n promotions
n_for_n[].availability array of enum: MO, TU, WE, TH, FR, SA, ... No
n_for_n[].buy_qty integer Yes Buy N Item. only for n-for-n and n-for-price-n types
n_for_n[].contains_alcohol boolean No This is to specify if the item contains alcohol content or not
n_for_n[].contains_tobacco boolean No This is to specify if the item contains tobacco content or not
n_for_n[].description string No Item Description
n_for_n[].dietary_labels array of enum: VEGAN, VEGETARIAN, GLUTEN_FREE, NON-VEGETARIAN No
n_for_n[].free_qty integer Yes Get Free N Item.only for n-for-n type
n_for_n[].fulfillment_modes array of enum: DELIVERY, COLLECTION No
n_for_n[].id string Yes Deal ID (controlled by partners)
n_for_n[].image string No Image that should be displayed along side this item. If the field is missing - any existing image will be removed.
n_for_n[].is_tax_included boolean No Setting to true assumes tax is included in the price. Otherwise you will be able to set tax_percentage.
n_for_n[].name string Yes Deal Name
n_for_n[].name_localized string No Second Language Name
n_for_n[].number_of_servings number No Describes the Number of servings for a item
n_for_n[].nutrition_info object No
n_for_n[].nutrition_info.lower_range number Yes The lower range of the energy content.
n_for_n[].nutrition_info.upper_range number Yes The upper range of the energy content.
n_for_n[].price integer No Menu item price value, represented in the lowest currency unit, such as pence, paise, cents, yen, etc.
n_for_n[].schedule object Yes
n_for_n[].schedule.end_date string No The date at which the menu ceases to be available, in YYYY-MM-DD format eg 2024-12-01 leave empty always visible
n_for_n[].schedule.end_time string Yes The time at which the menu ceases to be available, in 24-hour HH:MM format, for example “08:30”, “23:00”
n_for_n[].schedule.start_date string No The date at which the menu becomes available, in YYYY-MM-DD format eg 2024-01-01 leave empty always visible
n_for_n[].schedule.start_time string Yes The time at which the menu becomes available, in 24-hour HH:MM format, for example “08:30”, “23:00”
n_for_n[].selections array of object Yes
n_for_n[].selections[].max_permitted number No Maximum quantity allowed (inclusive). max_permitted cannot be less than min_permitted.
n_for_n[].selections[].min_permitted number No Minimum quantity allowed (inclusive) -- Cannot be negative.
n_for_n[].selections[].modifier_group_id string Yes Modifier Group reference ID
n_for_n[].selections[].modifiers array of object Yes
n_for_n[].selections[].modifiers[].max_permitted number No Maximum quantity allowed (inclusive). max_permitted cannot be less than min_permitted.
n_for_n[].selections[].modifiers[].min_permitted number No Minimum quantity allowed (inclusive) -- Cannot be negative.
n_for_n[].selections[].modifiers[].modifier_id string Yes Modifier reference ID
n_for_n[].selections[].modifiers[].price integer No Override price for the modifier, represented in the lowest currency unit, such as pence, paise, cents, yen, etc.
n_for_n[].selections[].modifiers[].selections array of any No Nested selections for the modifier groups
n_for_n[].selections[].modifiers[].show_online boolean No Show the modifier online or not praticular item
n_for_n[].sequence integer No The sequence field orders items for display or application. It's a numeric value indicating the preferred order, with lower values shown first.
n_for_n[].show_online boolean No Enable or Disable whether this category shown on Foodhub platform.
n_for_n[].subcategory_id string Yes Pass the ref id of subcategory it mapped with deals
n_for_n[].tax_percentage integer No This will only work when tax included is false.
n_for_price_n array of object No A list of n_for_price_n promotions
n_for_price_n[].availability array of enum: MO, TU, WE, TH, FR, SA, ... No
n_for_price_n[].buy_qty integer Yes Buy N Item. only for n-for-n and n-for-price-n types
n_for_price_n[].contains_alcohol boolean No This is to specify if the item contains alcohol content or not
n_for_price_n[].contains_tobacco boolean No This is to specify if the item contains tobacco content or not
n_for_price_n[].description string No Item Description
n_for_price_n[].dietary_labels array of enum: VEGAN, VEGETARIAN, GLUTEN_FREE, NON-VEGETARIAN No
n_for_price_n[].free_qty integer Yes Get Free N Item.only for n-for-n type
n_for_price_n[].fulfillment_modes array of enum: DELIVERY, COLLECTION No
n_for_price_n[].id string Yes Deal ID (controlled by partners)
n_for_price_n[].image string No Image that should be displayed along side this item. If the field is missing - any existing image will be removed.
n_for_price_n[].is_tax_included boolean No Setting to true assumes tax is included in the price. Otherwise you will be able to set tax_percentage.
n_for_price_n[].name string Yes Deal Name
n_for_price_n[].name_localized string No Second Language Name
n_for_price_n[].number_of_servings number No Describes the Number of servings for a item
n_for_price_n[].nutrition_info object No
n_for_price_n[].nutrition_info.lower_range number Yes The lower range of the energy content.
n_for_price_n[].nutrition_info.upper_range number Yes The upper range of the energy content.
n_for_price_n[].price integer Yes Menu item price value, represented in the lowest currency unit, such as pence, paise, cents, yen, etc.
n_for_price_n[].schedule object Yes
n_for_price_n[].schedule.end_date string No The date at which the menu ceases to be available, in YYYY-MM-DD format eg 2024-12-01 leave empty always visible
n_for_price_n[].schedule.end_time string Yes The time at which the menu ceases to be available, in 24-hour HH:MM format, for example “08:30”, “23:00”
n_for_price_n[].schedule.start_date string No The date at which the menu becomes available, in YYYY-MM-DD format eg 2024-01-01 leave empty always visible
n_for_price_n[].schedule.start_time string Yes The time at which the menu becomes available, in 24-hour HH:MM format, for example “08:30”, “23:00”
n_for_price_n[].selections array of object Yes
n_for_price_n[].selections[].max_permitted number No Maximum quantity allowed (inclusive). max_permitted cannot be less than min_permitted.
n_for_price_n[].selections[].min_permitted number No Minimum quantity allowed (inclusive) -- Cannot be negative.
n_for_price_n[].selections[].modifier_group_id string Yes Modifier Group reference ID
n_for_price_n[].selections[].modifiers array of object Yes
n_for_price_n[].selections[].modifiers[].max_permitted number No Maximum quantity allowed (inclusive). max_permitted cannot be less than min_permitted.
n_for_price_n[].selections[].modifiers[].min_permitted number No Minimum quantity allowed (inclusive) -- Cannot be negative.
n_for_price_n[].selections[].modifiers[].modifier_id string Yes Modifier reference ID
n_for_price_n[].selections[].modifiers[].price integer No Override price for the modifier, represented in the lowest currency unit, such as pence, paise, cents, yen, etc.
n_for_price_n[].selections[].modifiers[].selections array of any No Nested selections for the modifier groups
n_for_price_n[].selections[].modifiers[].show_online boolean No Show the modifier online or not praticular item
n_for_price_n[].sequence integer No The sequence field orders items for display or application. It's a numeric value indicating the preferred order, with lower values shown first.
n_for_price_n[].show_online boolean No Enable or Disable whether this category shown on Foodhub platform.
n_for_price_n[].subcategory_id string Yes Pass the ref id of subcategory it mapped with deals
n_for_price_n[].tax_percentage integer No This will only work when tax included is false.
n_for_price_n[].type enum: n-for-n, n-for-price-n, meals, flat, percent No Deals Type

Responses

200: OK
404: Not Found

application/json

Property Type Required Description
error string Yes 404 Not Found is the status code that indicates a server could not find a client-requested webpage

list

GET /v1/stores/{storeId}/deals

Operation ID: GET/v1/stores/{storeId}/deals.

Authentication: oauth2 (AccessToken).

Parameters

Parameter In Type Required Description
storeId path string Yes Store Identifier

Responses

200: OK

application/json

Property Type Required Description
data array of object No
data[].discounts array of object No A list of flat and percent discounts
data[].discounts[].availability array of enum: MO, TU, WE, TH, FR, SA, ... Yes
data[].discounts[].id string Yes Deal ID (controlled by partners)
data[].discounts[].items array of string Yes Array of item ids
data[].discounts[].schedule object Yes
data[].discounts[].schedule.end_date string No The date at which the menu ceases to be available, in YYYY-MM-DD format eg 2024-12-01 leave empty always visible
data[].discounts[].schedule.end_time string Yes The time at which the menu ceases to be available, in 24-hour HH:MM format, for example “08:30”, “23:00”
data[].discounts[].schedule.start_date string No The date at which the menu becomes available, in YYYY-MM-DD format eg 2024-01-01 leave empty always visible
data[].discounts[].schedule.start_time string Yes The time at which the menu becomes available, in 24-hour HH:MM format, for example “08:30”, “23:00”
data[].discounts[].subcategory_id string Yes Pass the ref id of subcategory it mapped with deals
data[].discounts[].type enum: flat, percent Yes Deals Type
data[].discounts[].value number Yes Either Percent or Flat value
data[].meals array of object No A list of type meals deals
data[].meals[].availability array of enum: MO, TU, WE, TH, FR, SA, ... No
data[].meals[].contains_alcohol boolean No This is to specify if the item contains alcohol content or not
data[].meals[].contains_tobacco boolean No This is to specify if the item contains tobacco content or not
data[].meals[].description string No Item Description
data[].meals[].dietary_labels array of enum: VEGAN, VEGETARIAN, GLUTEN_FREE, NON-VEGETARIAN No
data[].meals[].fulfillment_modes array of enum: DELIVERY, COLLECTION No
data[].meals[].id string Yes Deal ID (controlled by partners)
data[].meals[].image string No Image that should be displayed along side this item. If the field is missing - any existing image will be removed.
data[].meals[].is_tax_included boolean No Setting to true assumes tax is included in the price. Otherwise you will be able to set tax_percentage.
data[].meals[].name string Yes Deal Name
data[].meals[].name_localized string No Second Language Name
data[].meals[].number_of_servings number No Describes the Number of servings for a item
data[].meals[].nutrition_info object No
data[].meals[].nutrition_info.lower_range number Yes The lower range of the energy content.
data[].meals[].nutrition_info.upper_range number Yes The upper range of the energy content.
data[].meals[].price integer Yes Menu item price value, represented in the lowest currency unit, such as pence, paise, cents, yen, etc.
data[].meals[].schedule object Yes
data[].meals[].schedule.end_date string No The date at which the menu ceases to be available, in YYYY-MM-DD format eg 2024-12-01 leave empty always visible
data[].meals[].schedule.end_time string Yes The time at which the menu ceases to be available, in 24-hour HH:MM format, for example “08:30”, “23:00”
data[].meals[].schedule.start_date string No The date at which the menu becomes available, in YYYY-MM-DD format eg 2024-01-01 leave empty always visible
data[].meals[].schedule.start_time string Yes The time at which the menu becomes available, in 24-hour HH:MM format, for example “08:30”, “23:00”
data[].meals[].selections array of object Yes
data[].meals[].selections[].max_permitted number No Maximum quantity allowed (inclusive). max_permitted cannot be less than min_permitted.
data[].meals[].selections[].min_permitted number No Minimum quantity allowed (inclusive) -- Cannot be negative.
data[].meals[].selections[].modifier_group_id string Yes Modifier Group reference ID
data[].meals[].selections[].modifiers array of object Yes
data[].meals[].selections[].modifiers[].max_permitted number No Maximum quantity allowed (inclusive). max_permitted cannot be less than min_permitted.
data[].meals[].selections[].modifiers[].min_permitted number No Minimum quantity allowed (inclusive) -- Cannot be negative.
data[].meals[].selections[].modifiers[].modifier_id string Yes Modifier reference ID
data[].meals[].selections[].modifiers[].price integer No Override price for the modifier, represented in the lowest currency unit, such as pence, paise, cents, yen, etc.
data[].meals[].selections[].modifiers[].selections array of any No Nested selections for the modifier groups
data[].meals[].selections[].modifiers[].show_online boolean No Show the modifier online or not praticular item
data[].meals[].sequence integer No The sequence field orders items for display or application. It's a numeric value indicating the preferred order, with lower values shown first.
data[].meals[].show_online boolean No Enable or Disable whether this category shown on Foodhub platform.
data[].meals[].subcategory_id string Yes Pass the ref id of subcategory it mapped with deals
data[].meals[].tax_percentage integer No This will only work when tax included is false.
data[].meals[].type enum: n-for-n, n-for-price-n, meals, flat, percent No Deals Type
data[].n_for_n array of object No A list of n_for_n promotions
data[].n_for_n[].availability array of enum: MO, TU, WE, TH, FR, SA, ... No
data[].n_for_n[].buy_qty integer Yes Buy N Item. only for n-for-n and n-for-price-n types
data[].n_for_n[].contains_alcohol boolean No This is to specify if the item contains alcohol content or not
data[].n_for_n[].contains_tobacco boolean No This is to specify if the item contains tobacco content or not
data[].n_for_n[].description string No Item Description
data[].n_for_n[].dietary_labels array of enum: VEGAN, VEGETARIAN, GLUTEN_FREE, NON-VEGETARIAN No
data[].n_for_n[].free_qty integer Yes Get Free N Item.only for n-for-n type
data[].n_for_n[].fulfillment_modes array of enum: DELIVERY, COLLECTION No
data[].n_for_n[].id string Yes Deal ID (controlled by partners)
data[].n_for_n[].image string No Image that should be displayed along side this item. If the field is missing - any existing image will be removed.
data[].n_for_n[].is_tax_included boolean No Setting to true assumes tax is included in the price. Otherwise you will be able to set tax_percentage.
data[].n_for_n[].name string Yes Deal Name
data[].n_for_n[].name_localized string No Second Language Name
data[].n_for_n[].number_of_servings number No Describes the Number of servings for a item
data[].n_for_n[].nutrition_info object No
data[].n_for_n[].nutrition_info.lower_range number Yes The lower range of the energy content.
data[].n_for_n[].nutrition_info.upper_range number Yes The upper range of the energy content.
data[].n_for_n[].price integer No Menu item price value, represented in the lowest currency unit, such as pence, paise, cents, yen, etc.
data[].n_for_n[].schedule object Yes
data[].n_for_n[].schedule.end_date string No The date at which the menu ceases to be available, in YYYY-MM-DD format eg 2024-12-01 leave empty always visible
data[].n_for_n[].schedule.end_time string Yes The time at which the menu ceases to be available, in 24-hour HH:MM format, for example “08:30”, “23:00”
data[].n_for_n[].schedule.start_date string No The date at which the menu becomes available, in YYYY-MM-DD format eg 2024-01-01 leave empty always visible
data[].n_for_n[].schedule.start_time string Yes The time at which the menu becomes available, in 24-hour HH:MM format, for example “08:30”, “23:00”
data[].n_for_n[].selections array of object Yes
data[].n_for_n[].selections[].max_permitted number No Maximum quantity allowed (inclusive). max_permitted cannot be less than min_permitted.
data[].n_for_n[].selections[].min_permitted number No Minimum quantity allowed (inclusive) -- Cannot be negative.
data[].n_for_n[].selections[].modifier_group_id string Yes Modifier Group reference ID
data[].n_for_n[].selections[].modifiers array of object Yes
data[].n_for_n[].selections[].modifiers[].max_permitted number No Maximum quantity allowed (inclusive). max_permitted cannot be less than min_permitted.
data[].n_for_n[].selections[].modifiers[].min_permitted number No Minimum quantity allowed (inclusive) -- Cannot be negative.
data[].n_for_n[].selections[].modifiers[].modifier_id string Yes Modifier reference ID
data[].n_for_n[].selections[].modifiers[].price integer No Override price for the modifier, represented in the lowest currency unit, such as pence, paise, cents, yen, etc.
data[].n_for_n[].selections[].modifiers[].selections array of any No Nested selections for the modifier groups
data[].n_for_n[].selections[].modifiers[].show_online boolean No Show the modifier online or not praticular item
data[].n_for_n[].sequence integer No The sequence field orders items for display or application. It's a numeric value indicating the preferred order, with lower values shown first.
data[].n_for_n[].show_online boolean No Enable or Disable whether this category shown on Foodhub platform.
data[].n_for_n[].subcategory_id string Yes Pass the ref id of subcategory it mapped with deals
data[].n_for_n[].tax_percentage integer No This will only work when tax included is false.
data[].n_for_price_n array of object No A list of n_for_price_n promotions
data[].n_for_price_n[].availability array of enum: MO, TU, WE, TH, FR, SA, ... No
data[].n_for_price_n[].buy_qty integer Yes Buy N Item. only for n-for-n and n-for-price-n types
data[].n_for_price_n[].contains_alcohol boolean No This is to specify if the item contains alcohol content or not
data[].n_for_price_n[].contains_tobacco boolean No This is to specify if the item contains tobacco content or not
data[].n_for_price_n[].description string No Item Description
data[].n_for_price_n[].dietary_labels array of enum: VEGAN, VEGETARIAN, GLUTEN_FREE, NON-VEGETARIAN No
data[].n_for_price_n[].free_qty integer Yes Get Free N Item.only for n-for-n type
data[].n_for_price_n[].fulfillment_modes array of enum: DELIVERY, COLLECTION No
data[].n_for_price_n[].id string Yes Deal ID (controlled by partners)
data[].n_for_price_n[].image string No Image that should be displayed along side this item. If the field is missing - any existing image will be removed.
data[].n_for_price_n[].is_tax_included boolean No Setting to true assumes tax is included in the price. Otherwise you will be able to set tax_percentage.
data[].n_for_price_n[].name string Yes Deal Name
data[].n_for_price_n[].name_localized string No Second Language Name
data[].n_for_price_n[].number_of_servings number No Describes the Number of servings for a item
data[].n_for_price_n[].nutrition_info object No
data[].n_for_price_n[].nutrition_info.lower_range number Yes The lower range of the energy content.
data[].n_for_price_n[].nutrition_info.upper_range number Yes The upper range of the energy content.
data[].n_for_price_n[].price integer Yes Menu item price value, represented in the lowest currency unit, such as pence, paise, cents, yen, etc.
data[].n_for_price_n[].schedule object Yes
data[].n_for_price_n[].schedule.end_date string No The date at which the menu ceases to be available, in YYYY-MM-DD format eg 2024-12-01 leave empty always visible
data[].n_for_price_n[].schedule.end_time string Yes The time at which the menu ceases to be available, in 24-hour HH:MM format, for example “08:30”, “23:00”
data[].n_for_price_n[].schedule.start_date string No The date at which the menu becomes available, in YYYY-MM-DD format eg 2024-01-01 leave empty always visible
data[].n_for_price_n[].schedule.start_time string Yes The time at which the menu becomes available, in 24-hour HH:MM format, for example “08:30”, “23:00”
data[].n_for_price_n[].selections array of object Yes
data[].n_for_price_n[].selections[].max_permitted number No Maximum quantity allowed (inclusive). max_permitted cannot be less than min_permitted.
data[].n_for_price_n[].selections[].min_permitted number No Minimum quantity allowed (inclusive) -- Cannot be negative.
data[].n_for_price_n[].selections[].modifier_group_id string Yes Modifier Group reference ID
data[].n_for_price_n[].selections[].modifiers array of object Yes
data[].n_for_price_n[].selections[].modifiers[].max_permitted number No Maximum quantity allowed (inclusive). max_permitted cannot be less than min_permitted.
data[].n_for_price_n[].selections[].modifiers[].min_permitted number No Minimum quantity allowed (inclusive) -- Cannot be negative.
data[].n_for_price_n[].selections[].modifiers[].modifier_id string Yes Modifier reference ID
data[].n_for_price_n[].selections[].modifiers[].price integer No Override price for the modifier, represented in the lowest currency unit, such as pence, paise, cents, yen, etc.
data[].n_for_price_n[].selections[].modifiers[].selections array of any No Nested selections for the modifier groups
data[].n_for_price_n[].selections[].modifiers[].show_online boolean No Show the modifier online or not praticular item
data[].n_for_price_n[].sequence integer No The sequence field orders items for display or application. It's a numeric value indicating the preferred order, with lower values shown first.
data[].n_for_price_n[].show_online boolean No Enable or Disable whether this category shown on Foodhub platform.
data[].n_for_price_n[].subcategory_id string Yes Pass the ref id of subcategory it mapped with deals
data[].n_for_price_n[].tax_percentage integer No This will only work when tax included is false.
data[].n_for_price_n[].type enum: n-for-n, n-for-price-n, meals, flat, percent No Deals Type
404: Not Found

application/json

Property Type Required Description
error string Yes 404 Not Found is the status code that indicates a server could not find a client-requested webpage

load

GET /v1/stores/{storeId}/deals/{id}

Operation ID: GET/v1/stores/{storeId}/deals/{id}.

Authentication: oauth2 (AccessToken).

Parameters

Parameter In Type Required Description
storeId path string Yes Store Identifier
id path string Yes

Responses

200: OK

application/json

Property Type Required Description
data object No
data.discounts array of object No A list of flat and percent discounts
data.discounts[].availability array of enum: MO, TU, WE, TH, FR, SA, ... Yes
data.discounts[].id string Yes Deal ID (controlled by partners)
data.discounts[].items array of string Yes Array of item ids
data.discounts[].schedule object Yes
data.discounts[].schedule.end_date string No The date at which the menu ceases to be available, in YYYY-MM-DD format eg 2024-12-01 leave empty always visible
data.discounts[].schedule.end_time string Yes The time at which the menu ceases to be available, in 24-hour HH:MM format, for example “08:30”, “23:00”
data.discounts[].schedule.start_date string No The date at which the menu becomes available, in YYYY-MM-DD format eg 2024-01-01 leave empty always visible
data.discounts[].schedule.start_time string Yes The time at which the menu becomes available, in 24-hour HH:MM format, for example “08:30”, “23:00”
data.discounts[].subcategory_id string Yes Pass the ref id of subcategory it mapped with deals
data.discounts[].type enum: flat, percent Yes Deals Type
data.discounts[].value number Yes Either Percent or Flat value
data.meals array of object No A list of type meals deals
data.meals[].availability array of enum: MO, TU, WE, TH, FR, SA, ... No
data.meals[].contains_alcohol boolean No This is to specify if the item contains alcohol content or not
data.meals[].contains_tobacco boolean No This is to specify if the item contains tobacco content or not
data.meals[].description string No Item Description
data.meals[].dietary_labels array of enum: VEGAN, VEGETARIAN, GLUTEN_FREE, NON-VEGETARIAN No
data.meals[].fulfillment_modes array of enum: DELIVERY, COLLECTION No
data.meals[].id string Yes Deal ID (controlled by partners)
data.meals[].image string No Image that should be displayed along side this item. If the field is missing - any existing image will be removed.
data.meals[].is_tax_included boolean No Setting to true assumes tax is included in the price. Otherwise you will be able to set tax_percentage.
data.meals[].name string Yes Deal Name
data.meals[].name_localized string No Second Language Name
data.meals[].number_of_servings number No Describes the Number of servings for a item
data.meals[].nutrition_info object No
data.meals[].nutrition_info.lower_range number Yes The lower range of the energy content.
data.meals[].nutrition_info.upper_range number Yes The upper range of the energy content.
data.meals[].price integer Yes Menu item price value, represented in the lowest currency unit, such as pence, paise, cents, yen, etc.
data.meals[].schedule object Yes
data.meals[].schedule.end_date string No The date at which the menu ceases to be available, in YYYY-MM-DD format eg 2024-12-01 leave empty always visible
data.meals[].schedule.end_time string Yes The time at which the menu ceases to be available, in 24-hour HH:MM format, for example “08:30”, “23:00”
data.meals[].schedule.start_date string No The date at which the menu becomes available, in YYYY-MM-DD format eg 2024-01-01 leave empty always visible
data.meals[].schedule.start_time string Yes The time at which the menu becomes available, in 24-hour HH:MM format, for example “08:30”, “23:00”
data.meals[].selections array of object Yes
data.meals[].selections[].max_permitted number No Maximum quantity allowed (inclusive). max_permitted cannot be less than min_permitted.
data.meals[].selections[].min_permitted number No Minimum quantity allowed (inclusive) -- Cannot be negative.
data.meals[].selections[].modifier_group_id string Yes Modifier Group reference ID
data.meals[].selections[].modifiers array of object Yes
data.meals[].selections[].modifiers[].max_permitted number No Maximum quantity allowed (inclusive). max_permitted cannot be less than min_permitted.
data.meals[].selections[].modifiers[].min_permitted number No Minimum quantity allowed (inclusive) -- Cannot be negative.
data.meals[].selections[].modifiers[].modifier_id string Yes Modifier reference ID
data.meals[].selections[].modifiers[].price integer No Override price for the modifier, represented in the lowest currency unit, such as pence, paise, cents, yen, etc.
data.meals[].selections[].modifiers[].selections array of any No Nested selections for the modifier groups
data.meals[].selections[].modifiers[].show_online boolean No Show the modifier online or not praticular item
data.meals[].sequence integer No The sequence field orders items for display or application. It's a numeric value indicating the preferred order, with lower values shown first.
data.meals[].show_online boolean No Enable or Disable whether this category shown on Foodhub platform.
data.meals[].subcategory_id string Yes Pass the ref id of subcategory it mapped with deals
data.meals[].tax_percentage integer No This will only work when tax included is false.
data.meals[].type enum: n-for-n, n-for-price-n, meals, flat, percent No Deals Type
data.n_for_n array of object No A list of n_for_n promotions
data.n_for_n[].availability array of enum: MO, TU, WE, TH, FR, SA, ... No
data.n_for_n[].buy_qty integer Yes Buy N Item. only for n-for-n and n-for-price-n types
data.n_for_n[].contains_alcohol boolean No This is to specify if the item contains alcohol content or not
data.n_for_n[].contains_tobacco boolean No This is to specify if the item contains tobacco content or not
data.n_for_n[].description string No Item Description
data.n_for_n[].dietary_labels array of enum: VEGAN, VEGETARIAN, GLUTEN_FREE, NON-VEGETARIAN No
data.n_for_n[].free_qty integer Yes Get Free N Item.only for n-for-n type
data.n_for_n[].fulfillment_modes array of enum: DELIVERY, COLLECTION No
data.n_for_n[].id string Yes Deal ID (controlled by partners)
data.n_for_n[].image string No Image that should be displayed along side this item. If the field is missing - any existing image will be removed.
data.n_for_n[].is_tax_included boolean No Setting to true assumes tax is included in the price. Otherwise you will be able to set tax_percentage.
data.n_for_n[].name string Yes Deal Name
data.n_for_n[].name_localized string No Second Language Name
data.n_for_n[].number_of_servings number No Describes the Number of servings for a item
data.n_for_n[].nutrition_info object No
data.n_for_n[].nutrition_info.lower_range number Yes The lower range of the energy content.
data.n_for_n[].nutrition_info.upper_range number Yes The upper range of the energy content.
data.n_for_n[].price integer No Menu item price value, represented in the lowest currency unit, such as pence, paise, cents, yen, etc.
data.n_for_n[].schedule object Yes
data.n_for_n[].schedule.end_date string No The date at which the menu ceases to be available, in YYYY-MM-DD format eg 2024-12-01 leave empty always visible
data.n_for_n[].schedule.end_time string Yes The time at which the menu ceases to be available, in 24-hour HH:MM format, for example “08:30”, “23:00”
data.n_for_n[].schedule.start_date string No The date at which the menu becomes available, in YYYY-MM-DD format eg 2024-01-01 leave empty always visible
data.n_for_n[].schedule.start_time string Yes The time at which the menu becomes available, in 24-hour HH:MM format, for example “08:30”, “23:00”
data.n_for_n[].selections array of object Yes
data.n_for_n[].selections[].max_permitted number No Maximum quantity allowed (inclusive). max_permitted cannot be less than min_permitted.
data.n_for_n[].selections[].min_permitted number No Minimum quantity allowed (inclusive) -- Cannot be negative.
data.n_for_n[].selections[].modifier_group_id string Yes Modifier Group reference ID
data.n_for_n[].selections[].modifiers array of object Yes
data.n_for_n[].selections[].modifiers[].max_permitted number No Maximum quantity allowed (inclusive). max_permitted cannot be less than min_permitted.
data.n_for_n[].selections[].modifiers[].min_permitted number No Minimum quantity allowed (inclusive) -- Cannot be negative.
data.n_for_n[].selections[].modifiers[].modifier_id string Yes Modifier reference ID
data.n_for_n[].selections[].modifiers[].price integer No Override price for the modifier, represented in the lowest currency unit, such as pence, paise, cents, yen, etc.
data.n_for_n[].selections[].modifiers[].selections array of any No Nested selections for the modifier groups
data.n_for_n[].selections[].modifiers[].show_online boolean No Show the modifier online or not praticular item
data.n_for_n[].sequence integer No The sequence field orders items for display or application. It's a numeric value indicating the preferred order, with lower values shown first.
data.n_for_n[].show_online boolean No Enable or Disable whether this category shown on Foodhub platform.
data.n_for_n[].subcategory_id string Yes Pass the ref id of subcategory it mapped with deals
data.n_for_n[].tax_percentage integer No This will only work when tax included is false.
data.n_for_price_n array of object No A list of n_for_price_n promotions
data.n_for_price_n[].availability array of enum: MO, TU, WE, TH, FR, SA, ... No
data.n_for_price_n[].buy_qty integer Yes Buy N Item. only for n-for-n and n-for-price-n types
data.n_for_price_n[].contains_alcohol boolean No This is to specify if the item contains alcohol content or not
data.n_for_price_n[].contains_tobacco boolean No This is to specify if the item contains tobacco content or not
data.n_for_price_n[].description string No Item Description
data.n_for_price_n[].dietary_labels array of enum: VEGAN, VEGETARIAN, GLUTEN_FREE, NON-VEGETARIAN No
data.n_for_price_n[].free_qty integer Yes Get Free N Item.only for n-for-n type
data.n_for_price_n[].fulfillment_modes array of enum: DELIVERY, COLLECTION No
data.n_for_price_n[].id string Yes Deal ID (controlled by partners)
data.n_for_price_n[].image string No Image that should be displayed along side this item. If the field is missing - any existing image will be removed.
data.n_for_price_n[].is_tax_included boolean No Setting to true assumes tax is included in the price. Otherwise you will be able to set tax_percentage.
data.n_for_price_n[].name string Yes Deal Name
data.n_for_price_n[].name_localized string No Second Language Name
data.n_for_price_n[].number_of_servings number No Describes the Number of servings for a item
data.n_for_price_n[].nutrition_info object No
data.n_for_price_n[].nutrition_info.lower_range number Yes The lower range of the energy content.
data.n_for_price_n[].nutrition_info.upper_range number Yes The upper range of the energy content.
data.n_for_price_n[].price integer Yes Menu item price value, represented in the lowest currency unit, such as pence, paise, cents, yen, etc.
data.n_for_price_n[].schedule object Yes
data.n_for_price_n[].schedule.end_date string No The date at which the menu ceases to be available, in YYYY-MM-DD format eg 2024-12-01 leave empty always visible
data.n_for_price_n[].schedule.end_time string Yes The time at which the menu ceases to be available, in 24-hour HH:MM format, for example “08:30”, “23:00”
data.n_for_price_n[].schedule.start_date string No The date at which the menu becomes available, in YYYY-MM-DD format eg 2024-01-01 leave empty always visible
data.n_for_price_n[].schedule.start_time string Yes The time at which the menu becomes available, in 24-hour HH:MM format, for example “08:30”, “23:00”
data.n_for_price_n[].selections array of object Yes
data.n_for_price_n[].selections[].max_permitted number No Maximum quantity allowed (inclusive). max_permitted cannot be less than min_permitted.
data.n_for_price_n[].selections[].min_permitted number No Minimum quantity allowed (inclusive) -- Cannot be negative.
data.n_for_price_n[].selections[].modifier_group_id string Yes Modifier Group reference ID
data.n_for_price_n[].selections[].modifiers array of object Yes
data.n_for_price_n[].selections[].modifiers[].max_permitted number No Maximum quantity allowed (inclusive). max_permitted cannot be less than min_permitted.
data.n_for_price_n[].selections[].modifiers[].min_permitted number No Minimum quantity allowed (inclusive) -- Cannot be negative.
data.n_for_price_n[].selections[].modifiers[].modifier_id string Yes Modifier reference ID
data.n_for_price_n[].selections[].modifiers[].price integer No Override price for the modifier, represented in the lowest currency unit, such as pence, paise, cents, yen, etc.
data.n_for_price_n[].selections[].modifiers[].selections array of any No Nested selections for the modifier groups
data.n_for_price_n[].selections[].modifiers[].show_online boolean No Show the modifier online or not praticular item
data.n_for_price_n[].sequence integer No The sequence field orders items for display or application. It's a numeric value indicating the preferred order, with lower values shown first.
data.n_for_price_n[].show_online boolean No Enable or Disable whether this category shown on Foodhub platform.
data.n_for_price_n[].subcategory_id string Yes Pass the ref id of subcategory it mapped with deals
data.n_for_price_n[].tax_percentage integer No This will only work when tax included is false.
data.n_for_price_n[].type enum: n-for-n, n-for-price-n, meals, flat, percent No Deals Type
404: Not Found

application/json

Property Type Required Description
error string Yes 404 Not Found is the status code that indicates a server could not find a client-requested webpage

remove

DELETE /v1/stores/{storeId}/deals/{id}

Operation ID: DELETE/v1/stores/{storeId}/deals/{id}.

Authentication: oauth2 (AccessToken).

Parameters

Parameter In Type Required Description
storeId path string Yes Store Identifier
id path string Yes

Responses

204: No Content
404: Not Found

application/json

Property Type Required Description
error string Yes 404 Not Found is the status code that indicates a server could not find a client-requested webpage

update

PUT /v1/stores/{storeId}/deals/{id}

Operation ID: PUT/v1/stores/{storeId}/deals/{id}.

Authentication: oauth2 (AccessToken).

Parameters

Parameter In Type Required Description
storeId path string Yes Store Identifier
id path string Yes

Responses

200: OK
404: Not Found

application/json

Property Type Required Description
error string Yes 404 Not Found is the status code that indicates a server could not find a client-requested webpage