Empowering Restaurants through Integration

Follow

Accessing Restaurant Information

By partnering with us here at Grubhub, you get access to our restaurant and menu database. But that's a lot of data, and you don't want to download the entire dataset every time you need to display a list of restaurants or menu items. That's why the Grubhub API has several different methods to access information about restaurants.

We offer four methods to access restaurant information, each with their own purposes and advantages:

  • Hydra data feed
  • Availability summaries
  • Individual restaurant information
  • Individual menu item info

Hydra Feed

The Hydra data feed provides a full set of restaurants to you. This is the primary way you should get restaurant IDs and link them to whatever restaurant data in your system. The data comes as a ZIP-compressed file, so it takes less bandwidth than individual calls to the restaurant endpoints.

To use this feed, you'll need a Hydra-specifc user name and password. The request should look something like this:

GET /v2/{brand}/affiliate_network_feed/latest/json HTTP/1.1
Host: affiliate-feed.grubhub.com
X-HYDRA-AUTH: testuser|1ae3014c37e26ee563ae70f06cfd8bd27eb2f251648bbf8dc7b32c8cfa7ca080

This will return a ZIP-compressed JSON or XML file, depending on the specific endpoint used. The data that it contains will be a subset of the data returned by the restaurants endpoints, depending on the specifics on your integration contract.

Consult the [Hydra feed specifications] for more information.

Get Availability

With the data backbone from the Hydra feed, you can build a searchable interface to the delivery restaurants. However, you will need to check if a restaurant can fulfill diner orders at the time of the search. That's because not only do restaurants have different hours of operation and order cutoff windows where they stop taking orders before close, a restaurant can stop taking orders whenever they need to.

To get availability information, we have the GET /restaurants/availability_summaries, which can return current availability of up to 30 restaurants at a time.

Here's an example of what that looks like:

GET /restaurants/availability_summaries?ids=11402556&ids=296460 HTTP/1.1
Host: api-pp.grubhub.com
Authorization: Bearer XXXXXXXXXXXXXXX
Cache-Control: no-cache

On success, this is what you'll get back:

{
    "availability_summaries": [
        {
            "restaurant_id": "11402556",
            "open": true,
            "available_for_delivery": true,
            "available_for_pickup": true,
            "delivery_offered_to_diner_location": false,
            "restaurant_name": "Design Kitchen Too",
            "address": {
                "locality": "Holland",
                "region": "MI",
                "postal_code": "49423",
                "street_address": "10 E 10th St",
                "country": "USA"
            },
            "decimal_distance_in_miles": null,
            "logo": "https://dtyxqspugqu5z.cloudfront.net/logo/2556/11402556/20170301BackgroudTileopt1.png",
            "delivery_estimate": 30,
            "pickup_estimate": 15,
            "order_minimum": {
                "amount": 500,
                "currency": "USD"
            },
            "delivery_fee": {
                "amount": 0,
                "currency": "USD"
            },
            "delivery_cutoff": 15,
            "pickup_cutoff": 30,
            "available_hours": null,
            "available_hours_pickup": null,
            "cutoff_for_delivery": false,
            "cutoff_for_pickup": true
        },
        {
            "restaurant_id": "296460",
            "open": true,
            "available_for_delivery": true,
            "available_for_pickup": true,
            "delivery_offered_to_diner_location": false,
            "restaurant_name": "Chotchkie's",
            "address": {
                "locality": "Alamo",
                "region": "NV",
                "postal_code": "89001",
                "street_address": "6 Old Mill St",
                "country": "USA"
            },
            "decimal_distance_in_miles": null,
            "logo": "https://dtyxqspugqu5z.cloudfront.net/logo/6460/296460/20140819chotchkies_small.jpg",
            "delivery_estimate": 45,
            "pickup_estimate": 20,
            "order_minimum": {
                "amount": 1000,
                "currency": "USD"
            },
            "delivery_fee": {
                "amount": 300,
                "currency": "USD"
            },
            "delivery_cutoff": 15,
            "pickup_cutoff": 30,
            "available_hours": null,
            "available_hours_pickup": null,
            "cutoff_for_delivery": false,
            "cutoff_for_pickup": true
        }
    ]
}

As you'll see from some of the other restaurant information calls, this is a very lightweight method. You can and should call this for any restaurant displayed to diners.

Get Restaurant Information

The Hydra feed is an abbreviated collection of restaurant data designed to give you a link from your restaurant information to ours through the restaurant_id. In order to get the full details for any restaurant, you'll need to call GET /restaurants/{restaurant_id}.

When called without any query parameters, this method returns the full restaurant data set, including menu items and their choices. Here's an example, edited for length:

{
    "restaurant_availability": {
        "restaurant_id": "11402556",
        "delivery_fee": {
            "amount": 0,
            "currency": "USD"
        },
        "delivery_fee_estimate": {
            "amount": 0,
            "currency": "USD"
        },
        "delivery_fee_as_percentage": 0,
        "delivery_fee_taxable": true,
        "order_minimum": {
            "amount": 500,
            "currency": "USD"
        },
        "sales_tax": 10,
        "delivery_offered_to_diner_location": false,
        "open": true,
        "available_for_delivery": true,
        "available_for_pickup": true,
        "delivery_estimate": 30,
        "pickup_estimate": 15,
        "time_zone_id": "America/New_York",
        "time_zone_offset": -14400000,
        "delivery_cutoff": 15,
        "pickup_cutoff": 30,
        "available_hours": [
            {
                "day_of_week": 1,
                "time_ranges": [
                    "04:00-04:00"
                ]
            },
            {
                "day_of_week": 2,
                "time_ranges": [
                    "04:00-04:00"
                ]
            },
            {
                "day_of_week": 3,
                "time_ranges": [
                    "04:00-04:00"
                ]
            },
            {
                "day_of_week": 4,
                "time_ranges": [
                    "04:00-04:00"
                ]
            },
            {
                "day_of_week": 5,
                "time_ranges": [
                    "04:00-04:00"
                ]
            },
            {
                "day_of_week": 6,
                "time_ranges": [
                    "04:00-04:00"
                ]
            },
            {
                "day_of_week": 7,
                "time_ranges": [
                    "04:00-04:00"
                ]
            }
        ],
        "available_hours_pickup": [
            {
                "day_of_week": 1,
                "time_ranges": [
                    "04:00-04:00"
                ]
            },
            {
                "day_of_week": 2,
                "time_ranges": [
                    "04:00-04:00"
                ]
            },
            {
                "day_of_week": 3,
                "time_ranges": [
                    "04:00-04:00"
                ]
            },
            {
                "day_of_week": 4,
                "time_ranges": [
                    "04:00-04:00"
                ]
            },
            {
                "day_of_week": 5,
                "time_ranges": [
                    "04:00-04:00"
                ]
            },
            {
                "day_of_week": 6,
                "time_ranges": [
                    "04:00-04:00"
                ]
            },
            {
                "day_of_week": 7,
                "time_ranges": [
                    "04:00-04:00"
                ]
            }
        ],
        "min_delivery_fee": {
            "amount": 0,
            "currency": "USD"
        },
        "white_in": false,
        "cutoff_for_delivery": false,
        "cutoff_for_pickup": false,
        "blacked_out": false
    },
    "restaurant": {
        "id": "11402556",
        "name": "Design Kitchen Too",
        "address": {
            "locality": "Holland",
            "region": "MI",
            "postal_code": "49423",
            "street_address": "10 E 10th St",
            "country": "USA"
        },
        "cross_street_required": false,
        "pickup_offered": true,
        "latitude": "42.788227",
        "longitude": "-86.106622",
        "minimum_tip_percent": 10,
        "default_tip_percent": 20,
        "minimum_tip": {
            "amount": 200,
            "currency": "USD"
        },
        "logo": "https://dtyxqspugqu5z.cloudfront.net/logo/2556/11402556/20170301BackgroudTileopt1.png",
        "menu_category_list": [
            {
                "id": 1592853,
                "name": "Pizza",
                "menu_item_list": [
                    {
                        "id": "15609484",
                        "menu_category_name": "Pizza",
                        "name": "Cheese Pizza",
                        "description": "",
                        "price": {
                            "amount": 0,
                            "currency": "USD"
                        },
                        "tax": 10,
                        "minimum_cart_total": {
                            "amount": 0,
                            "currency": "USD"
                        },
                        "sequence": 1,
                        "minimum_price_variation": {
                            "amount": 100,
                            "currency": "USD"
                        },
                        "maximum_price_variation": {
                            "amount": 45100,
                            "currency": "USD"
                        },
                        "available": true,
                        "choice_category_list": [
                            {
                                "id": "5487579",
                                "name": "Choose a size",
                                "min_choice_options": 1,
                                "max_choice_options": 1,
                                "choice_option_list": [
                                    {
                                        "id": "21177046",
                                        "description": "Small",
                                        "price": {
                                            "amount": 100,
                                            "currency": "USD"
                                        },
                                        "choice_category_list": [],
                                        "price_changes": {},
                                        "sequence": 1
                                    },
                                    {
                                        "id": "21177047",
                                        "description": "Medium",
                                        "price": {
                                            "amount": 200,
                                            "currency": "USD"
                                        },
                                        "choice_category_list": [],
                                        "price_changes": {},
                                        "sequence": 2
                                    },
                                    {
                                        "id": "21177048",
                                        "description": "Large",
                                        "price": {
                                            "amount": 300,
                                            "currency": "USD"
                                        },
                                        "choice_category_list": [],
                                        "price_changes": {},
                                        "sequence": 3
                                    },
                                    {
                                        "id": "21177049",
                                        "description": "Jumbo-tron",
                                        "price": {
                                            "amount": 45000,
                                            "currency": "USD"
                                        },
                                        "choice_category_list": [],
                                        "price_changes": {},
                                        "sequence": 4
                                    }
                                ],
                                "variation_target": true,
                                "sequence": 0
                            },
                            {
                                "id": "5487580",
                                "name": "Would you like to add additional toppings?",
                                "min_choice_options": 0,
                                "choice_option_list": [
                                    {
                                        "id": "21177050",
                                        "description": "Pepperoni",
                                        "price": {
                                            "amount": 100,
                                            "currency": "USD"
                                        },
                                        "choice_category_list": [],
                                        "price_changes": {
                                            "21177046": {
                                                "amount": 100,
                                                "currency": "USD"
                                            },
                                            "21177047": {
                                                "amount": 200,
                                                "currency": "USD"
                                            },
                                            "21177048": {
                                                "amount": 300,
                                                "currency": "USD"
                                            },
                                            "21177049": {
                                                "amount": 400,
                                                "currency": "USD"
                                            }
                                        },
                                        "sequence": 1
                                    },
                                    {
                                        "id": "21177051",
                                        "description": "Sausage",
                                        "price": {
                                            "amount": 100,
                                            "currency": "USD"
                                        },
                                        "choice_category_list": [],
                                        "price_changes": {
                                            "21177046": {
                                                "amount": 100,
                                                "currency": "USD"
                                            },
                                            "21177047": {
                                                "amount": 200,
                                                "currency": "USD"
                                            },
                                            "21177048": {
                                                "amount": 300,
                                                "currency": "USD"
                                            },
                                            "21177049": {
                                                "amount": 400,
                                                "currency": "USD"
                                            }
                                        },
                                        "sequence": 2
                                    },
                                    {
                                        "id": "21177052",
                                        "description": "Green Peppers",
                                        "price": {
                                            "amount": 100,
                                            "currency": "USD"
                                        },
                                        "choice_category_list": [],
                                        "price_changes": {
                                            "21177046": {
                                                "amount": 100,
                                                "currency": "USD"
                                            },
                                            "21177047": {
                                                "amount": 200,
                                                "currency": "USD"
                                            },
                                            "21177048": {
                                                "amount": 300,
                                                "currency": "USD"
                                            },
                                            "21177049": {
                                                "amount": 400,
                                                "currency": "USD"
                                            }
                                        },
                                        "sequence": 3
                                    },
                                    {
                                        "id": "21177053",
                                        "description": "Red Peppers",
                                        "price": {
                                            "amount": 100,
                                            "currency": "USD"
                                        },
                                        "choice_category_list": [],
                                        "price_changes": {
                                            "21177046": {
                                                "amount": 100,
                                                "currency": "USD"
                                            },
                                            "21177047": {
                                                "amount": 200,
                                                "currency": "USD"
                                            },
                                            "21177048": {
                                                "amount": 300,
                                                "currency": "USD"
                                            },
                                            "21177049": {
                                                "amount": 400,
                                                "currency": "USD"
                                            }
                                        },
                                        "sequence": 4
                                    },
                                    {
                                        "id": "21177054",
                                        "description": "Black Olives",
                                        "price": {
                                            "amount": 100,
                                            "currency": "USD"
                                        },
                                        "choice_category_list": [],
                                        "price_changes": {
                                            "21177046": {
                                                "amount": 100,
                                                "currency": "USD"
                                            },
                                            "21177047": {
                                                "amount": 200,
                                                "currency": "USD"
                                            },
                                            "21177048": {
                                                "amount": 300,
                                                "currency": "USD"
                                            },
                                            "21177049": {
                                                "amount": 400,
                                                "currency": "USD"
                                            }
                                        },
                                        "sequence": 5
                                    },
                                    {
                                        "id": "21177055",
                                        "description": "Green Olives",
                                        "price": {
                                            "amount": 100,
                                            "currency": "USD"
                                        },
                                        "choice_category_list": [],
                                        "price_changes": {
                                            "21177046": {
                                                "amount": 100,
                                                "currency": "USD"
                                            },
                                            "21177047": {
                                                "amount": 200,
                                                "currency": "USD"
                                            },
                                            "21177048": {
                                                "amount": 300,
                                                "currency": "USD"
                                            },
                                            "21177049": {
                                                "amount": 400,
                                                "currency": "USD"
                                            }
                                        },
                                        "sequence": 6
                                    }
                                ],
                                "variation_target": false,
                                "item_variation_id": 5487579,
                                "sequence": 26
                            }
                        ],
                        "deleted": false
                    },
                    {
                        "id": "15609485",
                        "menu_category_name": "Pizza",
                        "name": "James's Pizza",
                        "description": "",
                        "price": {
                            "amount": 0,
                            "currency": "USD"
                        },
                        "tax": 10,
                        "minimum_cart_total": {
                            "amount": 0,
                            "currency": "USD"
                        },
                        "sequence": 2,
                        "minimum_price_variation": {
                            "amount": 777,
                            "currency": "USD"
                        },
                        "maximum_price_variation": {
                            "amount": 1444,
                            "currency": "USD"
                        },
                        "available": true,
                        "choice_category_list": [
                            {
                                "id": "5487574",
                                "name": "Select your size",
                                "min_choice_options": 1,
                                "max_choice_options": 1,
                                "choice_option_list": [
                                    {
                                        "id": "21177036",
                                        "description": "Small",
                                        "price": {
                                            "amount": 777,
                                            "currency": "USD"
                                        },
                                        "choice_category_list": [],
                                        "price_changes": {},
                                        "sequence": 1
                                    },
                                    {
                                        "id": "21177037",
                                        "description": "Large",
                                        "price": {
                                            "amount": 1444,
                                            "currency": "USD"
                                        },
                                        "choice_category_list": [],
                                        "price_changes": {},
                                        "sequence": 2
                                    }
                                ],
                                "variation_target": true,
                                "sequence": 0
                            },
                            {
                                "id": "5487575",
                                "name": "Select your toppings",
                                "min_choice_options": 0,
                                "choice_option_list": [
                                    {
                                        "id": "21177038",
                                        "description": "Peppers",
                                        "price": {
                                            "amount": 0,
                                            "currency": "USD"
                                        },
                                        "choice_category_list": [],
                                        "price_changes": {
                                            "21177036": {
                                                "amount": 100,
                                                "currency": "USD"
                                            },
                                            "21177037": {
                                                "amount": 200,
                                                "currency": "USD"
                                            }
                                        },
                                        "sequence": 1
                                    },
                                    {
                                        "id": "21177039",
                                        "description": "Onions",
                                        "price": {
                                            "amount": 0,
                                            "currency": "USD"
                                        },
                                        "choice_category_list": [],
                                        "price_changes": {
                                            "21177036": {
                                                "amount": 100,
                                                "currency": "USD"
                                            },
                                            "21177037": {
                                                "amount": 200,
                                                "currency": "USD"
                                            }
                                        },
                                        "sequence": 2
                                    },
                                    {
                                        "id": "21177040",
                                        "description": "Pepperoni",
                                        "price": {
                                            "amount": 0,
                                            "currency": "USD"
                                        },
                                        "choice_category_list": [],
                                        "price_changes": {
                                            "21177036": {
                                                "amount": 100,
                                                "currency": "USD"
                                            },
                                            "21177037": {
                                                "amount": 200,
                                                "currency": "USD"
                                            }
                                        },
                                        "sequence": 3
                                    }
                                ],
                                "variation_target": false,
                                "item_variation_id": 5487574,
                                "sequence": 23
                            }
                        ],
                    },
                    {
                        "id": "15609486",
                        "menu_category_name": "Pizza",
                        "name": "Meredith's Pizza",
                        "description": "",
                        "price": {
                            "amount": 0,
                            "currency": "USD"
                        },
                        "tax": 10,
                        "minimum_cart_total": {
                            "amount": 0,
                            "currency": "USD"
                        },
                        "sequence": 3,
                        "minimum_price_variation": {
                            "amount": 666,
                            "currency": "USD"
                        },
                        "maximum_price_variation": {
                            "amount": 999,
                            "currency": "USD"
                        },
                        "available": true,
                        "choice_category_list": [
                            {
                                "id": "5487576",
                                "name": "Select a Size",
                                "min_choice_options": 1,
                                "max_choice_options": 1,
                                "choice_option_list": [
                                    {
                                        "id": "21177041",
                                        "description": "small",
                                        "price": {
                                            "amount": 666,
                                            "currency": "USD"
                                        },
                                        "choice_category_list": [],
                                        "price_changes": {},
                                        "sequence": 1
                                    },
                                    {
                                        "id": "21177042",
                                        "description": "large",
                                        "price": {
                                            "amount": 999,
                                            "currency": "USD"
                                        },
                                        "choice_category_list": [],
                                        "price_changes": {},
                                        "sequence": 2
                                    }
                                ],
                                "variation_target": true,
                                "sequence": 0
                            },
                            {
                                "id": "5487577",
                                "name": "Select a Topping",
                                "min_choice_options": 0,
                                "choice_option_list": [
                                    {
                                        "id": "21177043",
                                        "description": "mushroom",
                                        "price": {
                                            "amount": 0,
                                            "currency": "USD"
                                        },
                                        "choice_category_list": [],
                                        "price_changes": {
                                            "21177041": {
                                                "amount": 100,
                                                "currency": "USD"
                                            },
                                            "21177042": {
                                                "amount": 200,
                                                "currency": "USD"
                                            }
                                        },
                                        "sequence": 1
                                    },
                                    {
                                        "id": "21177044",
                                        "description": "onion",
                                        "price": {
                                            "amount": 0,
                                            "currency": "USD"
                                        },
                                        "choice_category_list": [],
                                        "price_changes": {
                                            "21177041": {
                                                "amount": 100,
                                                "currency": "USD"
                                            },
                                            "21177042": {
                                                "amount": 200,
                                                "currency": "USD"
                                            }
                                        },
                                        "sequence": 2
                                    },
                                    {
                                        "id": "21177045",
                                        "description": "pepperoni",
                                        "price": {
                                            "amount": 0,
                                            "currency": "USD"
                                        },
                                        "choice_category_list": [],
                                        "price_changes": {
                                            "21177041": {
                                                "amount": 100,
                                                "currency": "USD"
                                            },
                                            "21177042": {
                                                "amount": 200,
                                                "currency": "USD"
                                            }
                                        },
                                        "sequence": 3
                                    }
                                ],
                                "variation_target": false,
                                "item_variation_id": 5487576,
                                "sequence": 24
                            }
                        ],
                    }
                ],
                "sequence": 2
            },
        ],
        "excluded_menu_item_count": 0,
        "cash_tip_allowed": false,
        "is_too_few": false,
        "too_few": false
    }
}

We cut about 15 categories from that list, so that can give you a sense of just how large a payload this method can deliver. You may not need that much information every time you call this method. We allow two query parameters in the request that limit the amount of returned information:

  • hideMenuItems=true
  • hideChoiceCategories=true

The first hides all menu item information -- the bulk of the contents of the above example -- while the second hides just the choices associated with those menu items.

Depending on how you architect your final application, you may use a combination of these or just one.

Get a Single Menu item

If you need to be more precise, you can request information for just a single menu item with GET /restaurants/{restaurant_id}/menu_items/{menu_item_id}. That returns an object that looks like this:

{
    "id": "15609443",
    "menu_category_name": "Sandwiches",
    "name": "Jumbo Dog",
    "description": "",
    "price": {
        "amount": 299,
        "currency": "USD"
    },
    "tax": 10,
    "minimum_cart_total": {
        "amount": 0,
        "currency": "USD"
    },
    "sequence": 2,
    "minimum_price_variation": {
        "amount": 299,
        "currency": "USD"
    },
    "maximum_price_variation": {
        "amount": 299,
        "currency": "USD"
    },
    "available": true,
    "choice_category_list": [
        {
            "id": "5487570",
            "name": "Choice of Sides ",
            "min_choice_options": 2,
            "max_choice_options": 2,
            "choice_option_list": [
                {
                    "id": "21177018",
                    "description": "French Fries",
                    "price": {
                        "amount": 0,
                        "currency": "USD"
                    },
                    "choice_category_list": [],
                    "price_changes": {},
                    "sequence": 1
                },
                {
                    "id": "21177019",
                    "description": "Sweet Potato Fries",
                    "price": {
                        "amount": 0,
                        "currency": "USD"
                    },
                    "choice_category_list": [],
                    "price_changes": {},
                    "sequence": 2
                },
                {
                    "id": "21177020",
                    "description": "Baked Potato",
                    "price": {
                        "amount": 0,
                        "currency": "USD"
                    },
                    "choice_category_list": [],
                    "price_changes": {},
                    "sequence": 3
                },
                {
                    "id": "21177021",
                    "description": "Mashed Potatoes",
                    "price": {
                        "amount": 0,
                        "currency": "USD"
                    },
                    "choice_category_list": [],
                    "price_changes": {},
                    "sequence": 4
                },
                {
                    "id": "21177022",
                    "description": "Green Beans",
                    "price": {
                        "amount": 0,
                        "currency": "USD"
                    },
                    "choice_category_list": [],
                    "price_changes": {},
                    "sequence": 5
                },
                {
                    "id": "21177023",
                    "description": "Carrots",
                    "price": {
                        "amount": 0,
                        "currency": "USD"
                    },
                    "choice_category_list": [],
                    "price_changes": {},
                    "sequence": 6
                },
                {
                    "id": "21177024",
                    "description": "Corn",
                    "price": {
                        "amount": 0,
                        "currency": "USD"
                    },
                    "choice_category_list": [],
                    "price_changes": {},
                    "sequence": 7
                },
                {
                    "id": "21177025",
                    "description": "Peas",
                    "price": {
                        "amount": 0,
                        "currency": "USD"
                    },
                    "choice_category_list": [],
                    "price_changes": {},
                    "sequence": 8
                }
            ],
            "variation_target": false,
            "sequence": 15
        }
    ],
}

This is a smaller, more manageable subset of the full menu list sent with a full restaurant payload. It works best for when a user selects a menu item and you need to display choices.