---
title: "Order ready for preparation (async)"
method: POST
path: "/order-ready-for-preparation-async"
tags: ["Order Webhooks", "publicly-accessible"]
---

# Order ready for preparation (async)

`POST /order-ready-for-preparation-async`

## Request

- Base URL: `https://uk.api.just-eat.io`
- URL: `https://uk.api.just-eat.io/order-ready-for-preparation-async`
- Auth: none declared
- TypeScript: <https://skmtc.dev/just-eat/apis/just-eat-api/docs/order-ready-for-preparation-async/post.ts> (a function with typed inputs; its response is checked against the schema)

This webhook will be invoked when we have determined that an order is ready for preparation. Upon receiving the request, you should perform any preparation-related activities, such as sending the order to the POS system / kitchen screen.
**NOTE:** This version of the webhook is asynchronous, and we expect a response in two parts:
  1. We expect an immediate `202` response from this webhook to denote that you have received the request;
  2. Following that, we expect an [async callback](#section/Async-Webhooks) - indicating either success or failure of the operation. The body for the async callbacks are as below:
  
  **Success callback**
  ```
  {
        "status": "Success",
        "message": "Order successfully sent to POS",
        "data": {}
  }
  ```
  **Failure callback**
  ```
  {
        "status": "Failure",
        "message": "{errorMessage}",   // e.g. "The POS is currently in use"
        "data": {}
  }
  ```

## Request body

- OrderReadyForPreparation
  - `OrderId` string
  - `Currency` string
  - `TotalPrice` number
  - `Fulfilment` object
    - `Method` 'Delivery' | 'Collection'
    - `CustomerDueDate` string, date-time
    - `CustomerDueAsap` boolean
    - `PrepareFor` string, date-time
    - `PreparationTime` string, timespan
    - `Address` object
      - `Lines` string[]
      - `City` string
      - `PostalCode` string
      - `Geolocation` Location: GeoLocation object containing latitude and longitude values.
        - `Latitude` number, double, required: This should represent the latitude of the driver's location.
        - `Longitude` number, double, required: This should represent the longitude of the driver's location.
        - `Speed` number, double: This should represent the travel speed of the driver.
        - `Heading` number, double: This should represent the degree of heading direction, for example, 0 is north, 90 is east.
        - `Accuracy` number, double: This should represent the accuracy of driver's location.
    - `PhoneNumber` string
  - `Payment` object
    - `Lines` object[]
      - `Type` 'card' | 'cash' | 'credit' | 'other'
      - `Value` number
      - `Paid` boolean
  - `Customer` object
    - `Id` string
    - `Name` string
  - `Items` ItemV2[]
    - `Reference` string
    - `Name` string
    - `Quantity` integer
    - `UnitPrice` integer
    - `Items` ItemV2[]
  - `PriceBreakdown` object
    - `Discount` number
    - `Tips` number
    - `Taxes` number
    - `Items` number
    - `Fees` object
      - `Delivery` number
      - `ServiceCharge` number
      - `Other` number
  - `CustomerNotes` object
  - `PlacedDate` string, date-time
  - `Restaurant` object
    - `Id` string
    - `Reference` string
    - `Name` string
    - `Address` object
      - `Lines` string[]
      - `City` string
      - `PostalCode` string
      - `Geolocation` Location: GeoLocation object containing latitude and longitude values.
        - `Latitude` number, double, required: This should represent the latitude of the driver's location.
        - `Longitude` number, double, required: This should represent the longitude of the driver's location.
        - `Speed` number, double: This should represent the travel speed of the driver.
        - `Heading` number, double: This should represent the degree of heading direction, for example, 0 is north, 90 is east.
        - `Accuracy` number, double: This should represent the accuracy of driver's location.
    - `PhoneNumber` string
  - `IsTest` boolean

## Response `202`

Upon successful receipt of this event, a `202` status code should be returned, indicating the request has been accepted. You should then later respond with the result of processing this request, via the [callback URL](#section/Async-Webhooks) endpoint.

## Other responses

- `400`: Should the initial validation of the order fail, return a `400` status code. NOTE: In this instance we do not also expect a failure callback via the async callback URL.

---

[API](https://skmtc.dev/just-eat/apis/just-eat-api.md) - [All operations](https://skmtc.dev/just-eat/apis/just-eat-api/llms.txt) - [OpenAPI document](https://skmtc.dev/just-eat/apis/just-eat-api/revisions/4b25c7d97a53?raw)
