Tests
The test module allows for creating test orders to validate different components of an integration.
Paths
Create Transmission Test
POST /pos/v1/merchant/{merchant_id}/test/transmissionA transmission test order is a simple order that flows through the entire Grubhub order processing system. This is typically the last step in a go-live process for a new restaurant.
These orders will contain a the lowest-priced menu item not requiring modifiers found on the menu for the given merchant. All line items in this order will be sent with zero cost, so that no actual charges will accrue.
Test orders only exist within the POS ecosystem; they will not show up in the Grubhub for Restaurants app or on any accounting sheet.
Create Menu Test
POST /pos/v1/merchant/{merchant_id}/test/menuA menu test order enables testing of menu mapping and insertion of a variety of items to the POS. This is typically used for validating a new brand's menu mapping in a lab environment, or performing a comprehensive pre-live validation in the restaurant.
Unlike transmission tests, there is no need to confirm menu test orders, although doing so will have no negative impact.
Create test delivery
POST /merchant/{merchant_id}/test/deliveryGenerates a test delivery event in order to make sure that your delivery status webhook functions properly. The delivery will contain information from the referenced order but will not affect that order or create real-life delivery events.
To configure a delivery webhook for your POS integration, contact your Grubhub account representative.
Creates order with JIT flag triggered
POST /merchant/{merchant_id}/test/jiteventGenerates a test order event in order to make sure that your functionality that triggers JIT event functions properly. The order will contain information from the referenced order but will not affect that order or create real-life delivery events.
To configure a JIT event webhook for your POS integration, contact your Grubhub account representative.
Models
Delivery Status
Status of the delivery. Most of these statuses will only return for Grubhub-managed deliveries. This will return one of the following strings:
- ANTICIPATED - This order has been set to be fulfilled at a future time, so it has not begun preparation.
- ESTIMATED - This order has not yet been checked out by the diner, so it has not even been paid for. The numbers given are an estimate provided so that the diner can make a decision with complete information.
- COMMITTED - The restaurant has accepted the order and is starting to prepare the food.
- ASSIGNED - A trip offer has been sent to prospective couriers. Once a courier accepts the offer, they will arrive at the restaurant close to the promised fulfillment time to pick up the food.
- PICKUP_READY - The restaurant has completed preparing the food, so the driver should be there soon to pick it up and deliver it to the diner.
- IN_TRANSIT - The driver has picked up the food and is on their way to deliver it to the diner.
- DELIVERED - The driver has handed the food off to the diner and thus completed the delivery.
- CANCELED - The delivery order has been canceled and will not be taken to the diner. This delivery can be considered finished.
string
- ESTIMATED
- COMMITTED
- ASSIGNED
- IN_TRANSIT
- DELIVERED
- CANCELED
- PICKUP_READY
- REJECTED
- ANTICIPATED
Line
A line item for the order
Line Group
A group of line items. Currently, the entire order is within one line group; as group ordering features are rolled out, orders will include multiple line groups.
Line Sub Option
Sub options applied to an option. Not currently supported.
LineOption
Options applied to a line item.
Menu Test Request
Request for a menu test.
Status
The status of an order as it passes through the Grubhub fulfillment flow.
- ANTICIPATED denotes a future order, which may be cancelled by diner.
- RESTAURANT_CONFIRMABLE is pending confirmation of receipt by the restaurant. These are effectively new ASAP orders. ANTICIPATED orders will automatically become RESTAURANT_CONFIRMABLE at the promise time, less the restaurant's configured pickup or delivery prep time.
- DINER_CONFIRMABLE is a status held for future use.
- CONFIRMED denotes that the order was received by restaurant, even if the restaurant is unable to fulfill it.
- REJECTED is an error status. For example, if an order is unable to be inserted to the POS, due to menu item mismatch, restaurant offline, etc., the status should be updated to REJECTED. This is not to be used when the order was successfully transmitted, but the restaurant is unable to fulfill it for operational reasons. In that scenario, a Change Request should be submitted to cancel the order.
- CANCELLED means that a cancellation request by the diner or restaurant has been processed by Grubhub Customer Care.
- PICKUP_READY indicates that the food is prepared and ready for pickup by the diner or a Grubhub delivery courier.
- OUT_FOR_DELIVERY means the food is on the way to the diner.
- FULFILLED denotes that the food has been delivered to or picked up by the diner.
- UNKNOWN is provided for error handling of strings unmappable to known enumeration values.
Deprecated statuses will be provided when including a legacyStatus query parameter set to TRUE when polling orders. Similarly, legacy statuses will be translated when passed into the order status update endpoint. Confirmation of legacy status translation should be tested with individual integrations.
string
- ANTICIPATED
- RESTAURANT_CONFIRMABLE
- DINER_CONFIRMABLE
- CONFIRMED
- REJECTED
- CANCELLED
- PICKUP_READY
- OUT_FOR_DELIVERY
- FULFILLED
- UNKNOWN
Transmission Test Request
Request body for creating a transmission test.