Get Unavailable Menu Components
Grubhub enables our integrating partners to reflect menu availability information. When utilizing this endpoint, Grubhub expects you to expose any items and/or options in the response payload. When refreshing menus, Grubhub calls this endpoint to retrieve the list of items/options and remove them from the resulting menu on Grubhub Marketplace.
In contrast, when a certain item is back in stock, Grubhub expects it to be removed from the response payload, which brings those items back to the menu on subsequent menu refreshes.
In order to properly utilize this endpoint, please add removed items and/or options from this endpoint, but retain the Show Menu endpoint with the items and/or options.
Request Endpoint
GET /locations/provider_location_id/unavailable_menu_componentsExample Response Body
{
"provider_id": "10017",
"updated_at": "2019-09-29T20:10:39.009",
"items": [
{
"universal_id": "2421",
"name": "Burger",
"date": "2019-09-19T10:00:00.000"
},
{
"universal_id": "5192",
"name": "Tuna Melt",
"date": "2019-09-19T10:01:00.000"
}
],
"options": [
{
"universal_id": "3422",
"name": "Lettuce",
"date": "2019-09-19T10:00:00.000"
},
{
"universal_id": "3922",
"name": "Cheese",
"date": "2019-09-19T10:01:00.000"
}
]
}
Example Response Schema
{
"type": "object",
"properties": {
"provider_id": {
"type": "string",
"description": "A unique string that identifies the location"
},
"localTimeStamp": {
"type": "string",
"description": "An iso8601 timestamp representing when this endpoint was last updated."
},
"items": {
"type": "array",
"items": [
{
"type": "object",
"properties": {
"universal_id": {
"type": "string",
"description": "The unique identifier that matches the universal_id within the menu."
},
"name": {
"type": "string",
"description": "The name of the item or option."
},
"date": {
"type": "string",
"description": "An iso8601 timestamp representing when this item/option was last updated."
}
},
"required": [
"universal_id",
"name",
"date"
]
}
]
},
"options": {
"type": "array",
"items": [
{
"type": "object",
"properties": {
"universal_id": {
"type": "string",
"description": "The unique identifier that matches the universal_id within the menu."
},
"name": {
"type": "string",
"description": "The name of the item or option."
},
"date": {
"type": "string",
"description": "An iso8601 timestamp representing when this item/option was last updated."
}
},
"required": [
"universal_id",
"name",
"date"
]
}
]
}
},
"required": [
"provider_id",
"localTimeStamp",
"items",
"options"
]
}
Response Parameters
| Name | Type | Description |
|---|---|---|
provider_id |
String | A unique string that identifies the location. |
updated_at |
String | An ISO8601 timestamp representing when this menu was last updated, in UTC. |
items |
Array of objects | A list of objects defining the items that are currently unavailable. |
options |
Array of objects | A list of objects defining the options that are currently unavailable. |
universal_id |
String | A unique string that identifies the item or option across all merchant’s locations. Required. |
name |
String | The name of the item or option. |
date |
String | An iso8601 timestamp representing when this item/option was last updated. |
Requirements
-
provider_id: This would be the
provider_location_idso we know which store we are doing the 86ing update for. -
universal_id: This would be the
universal_idfor items/options on the brand’s menu for said location. -
name: Optional field, beneficial when troubleshooting menu updates.
-
date: Optional field, beneficial when troubleshooting menu updates.
Additional Information
Once Unavailable Menu Components have been removed from the menu, Grubhub also removes the following:
- categories that have no more items
- option_groups that have no options left
- option_group defaults that reference unavailable options
- option group references to option_groups that are no longer available
- category item option_groups references that are no longer available