# Understanding the OTA reservations process

Although retrieving and acknowledging reservations using OTA endpoints is a simple 2-step process,
it is important to consider certain corner cases while implementing the system to create a high-reliability service.

The following sections capture a few common implementation scenarios and outline the steps to handle unexpected events.

### Retrieving reservations successfully (Ideal conditions)

The following 2 process flow diagrams show the steps to retrieve and acknowledge new, modified, or cancelled reservations that do not change and when all systems are functioning optimally.

Click on the diagram to see it in full screen. To return to the topic, click the browser's back button.

|  |  |  |
|  --- | --- | --- |
| [![Retrieve and acknowledge new reservations](/assets/newreservations-ota.a6f30a89290d3d212f803e301f32b27ad08e642ee451fad25357fd43a4ff24e2.5761a12f.png)](/assets/newreservations-ota.a6f30a89290d3d212f803e301f32b27ad08e642ee451fad25357fd43a4ff24e2.5761a12f.png) |  | [![Retrieve and acknowledge modified/cancelled reservations](/assets/modifycancelreservationsota.5a9fc1c144acb80707fbed7c8368e56fece24dfdeb7e9ce4424de79494b82167.5761a12f.png)](/assets/modifycancelreservationsota.5a9fc1c144acb80707fbed7c8368e56fece24dfdeb7e9ce4424de79494b82167.5761a12f.png) |
| 1. Provider calls the `OTA_HotelResNotif` endpoint within the [timeout period](/connectivity/docs/reservations-api/reservations-overview#introducing-the-reservations-fallback-mechanism) to retrieve all reservations made since the last `GET` call.  2. Booking.com returns an `OTA_HotelResNotifRQ` object with the reservations details.  3. Provider integrates booking into their system and updates inventory.  4. Provider calls the `POST OTA_HotelResNotif` endpoint to acknowledge processing the reservations.  5. Booking.com returns a successful `OTA_HotelResNotifRS` message.  6. Provider implements a short delay and begins the cycle again. We recommend leaving 20 seconds between `GET OTA_HotelResNotif` calls. |  | 1. Provider calls the `OTA_HotelResModifyNotif` endpoint within the [timeout period](/connectivity/docs/reservations-api/reservations-overview#introducing-the-reservations-fallback-mechanism) to retrieve modified/cancelled reservations made since the last `GET` call.  2. Booking.com returns an `OTA_HotelResModifyNotifRQ` object with the reservations details. 3. Provider integrates reservation changes into their system and updates inventory, if necessary.  4. Provider calls the `POST OTA_HotelResModifyNotif` endpoint within the timeout period.  5. Booking.com returns a successful `OTA_HotelResModifyNotifRS` message.  6. Provider implements a short delay and begins the cycle again. We recommend leaving 20 seconds between `GET OTA_HotelResModifyNotif` calls. |


### Encountering a modification or cancellation while acknowledging a new reservation

The following process flow diagrams show the steps to retrieve and acknowledge a new reservation that was modified or cancelled before you could acknowledge.

You can follow the same steps with the exception of the endpoints to retrieve and acknowledge a modified reservation that was once again modified or cancelled before you could acknowledge.
The only change is in the endpoint. Instead of using `OTA_HotelResNotif`, you must use the `OTA_HotelResModifyNotif` endpoint.

Click on the diagram to see it in full screen. To return to the topic, click the browser's back button.

|  |  |  |
|  --- | --- | --- |
| [![Encountering modification while acknowledging new reservations](/assets/acknewresevationsmodifota.d2052e074c34ecbd055859883236609eb12b902c6b6cf46e782de129944ae510.5761a12f.png)](/assets/acknewresevationsmodifota.d2052e074c34ecbd055859883236609eb12b902c6b6cf46e782de129944ae510.5761a12f.png) |  | [![Encountering cancellation while acknowledging new reservations](/assets/acknewresevationotacancel.b2a779c07c96a32b7e79eec180ac4735296a65ffaf01dd249dd2ec4299c42085.5761a12f.png)](/assets/acknewresevationotacancel.b2a779c07c96a32b7e79eec180ac4735296a65ffaf01dd249dd2ec4299c42085.5761a12f.png) |
| 1. Provider calls the `OTA_HotelResNotif` endpoint within the [timeout period](/connectivity/docs/reservations-api/reservations-overview#introducing-the-reservations-fallback-mechanism) to retrieve all reservations made since the last `GET` call.  2. Booking.com returns an `OTA_HotelResNotifRQ` object with the reservations details. 3. Provider integrates reservation changes into their system and updates inventory.  4. Provider acknowledges processing the reservation.  5. Booking.com returns a successful `OTA_HotelResNotifRS` message. Make sure to call the `OTA_HotelResModifyNotif` endpoint to retrieve the reservation modification details. |  | 1. Provider calls the `OTA_HotelResNotif` endpoint within the [timeout period](/connectivity/docs/reservations-api/reservations-overview#introducing-the-reservations-fallback-mechanism) to retrieve all reservations made since the last `GET` call.   2. Booking.com returns an `OTA_HotelResNotifRQ` object with the reservations details. 3. Provider integrates reservation changes into their system and updates inventory.  4. Provider acknowledges processing the reservation by calling the `POST OTA_HotelResNotif` endpoint.  5. Booking.com returns a successful `OTA_HotelResNotifRS` message. Make sure to call the `OTA_HotelResModifyNotif` endpoint to retrieve the reservation modification details. |


### Encountering a cancellation while acknowledging a modified reservation

The following process diagram shows the steps to retrieve a modified reservation that was then cancelled right after you acknowledge processing it.

You must enable a feature to see the 409 error
The following steps are applicable only when you enable the feature: *OTA hotel reservation response token* (`ota_res_response_token`) using the [Provider portal](https://connect.booking.com/feature_management).
If you do not enable this feature, then you can follow the steps outlined in the [previous section](/connectivity/docs/reservations-api/reservations-process-ota#encountering-a-modification-or-cancellation-while-acknowledging-a-new-reservation).

Click on the diagram to see it in full screen. To return to the topic, click the browser's back button.

|  |  |  |
|  --- | --- | --- |
| [![Encountering a cancellation while acknowledging a modified reservation](/assets/ackmodifycancelresevations409ota.8fcef97b51e841f375447d3f1d647cd9f8a9e339744966b7860df5e58657d595.5761a12f.png)](/assets/ackmodifycancelresevations409ota.8fcef97b51e841f375447d3f1d647cd9f8a9e339744966b7860df5e58657d595.5761a12f.png) |  |  |
| 1. Provider calls the `OTA_HotelResModifyNotif` endpoint within the timeout period.   2. Booking.com returns an `OTA_HotelResNotifRQ` object with the reservations details. 3. Provider integrates reservation changes into their system and updates inventory, if necessary.  4. Provider calls the `POST OTA_HotelResModifyNotif` endpoint to acknowledge the reservation.  5. Booking.com returns a `409 error`.  6. Provider calls the `GET OTA_HotelResModifyNotif` endpoint with the specific reservation ID and hotel ID to get the latest changes.  7. Booking.com returns the modified reservation message with two `ResID_Value`(s).  8. Provider acknowledges the changes by providing both the `ResID_Value`(s). For more information, see [Acknowledging modified or cancelled reservation.](/connectivity/docs/reservations-api/acknowleding-modif-cancel-reservations-ota)  9. Booking returns a successful `OTA_HotelResModifyNotifRS` message.  |  |  |


### Encountering a 500 error response while retrieving or acknowledging reservations

The following 2 process flow diagrams show the steps to retrieve and acknowledge new, modified or cancelled reservations when Booking.com systems aren't functioning optimally.

Click on the diagram to see it in full screen. To return to the topic, click the browser's back button.

|  |  |  |
|  --- | --- | --- |
| [![Get a 500 error response while retrieving and acknowledging new reservations](/assets/otaretrievenew500error.c4897bdab8fcecb86a6ea2fb06175cb633da14a0228f410e0d0b6af0f1a865c3.5761a12f.png)](/assets/otaretrievenew500error.c4897bdab8fcecb86a6ea2fb06175cb633da14a0228f410e0d0b6af0f1a865c3.5761a12f.png) |  | [![Get a 500 error response while retrieving and acknowledging modified/cancelled reservations](/assets/otaretrievemodifycancel500error.62f1e0cbe6c3857a99004119df9f71daf9e11e4bfa6d2ba6997e4d875a6d1a77.5761a12f.png)](/assets/otaretrievemodifycancel500error.62f1e0cbe6c3857a99004119df9f71daf9e11e4bfa6d2ba6997e4d875a6d1a77.5761a12f.png) |
| 1. Provider calls the `GET OTA_HotelResNotif` endpoint.  2. Booking.com servers are temporarily unavailable. Provider gets an `HTTP 500` error.  3. Provider calls the `GET OTA_HotelResNotif` endpoint again or until a successful response.  4. Booking.com returns an `OTA_HotelResNotifRQ` object with the reservations details. 5. Provider integrates booking into their system and updates inventory.  6. Provider calls the `POST OTA_HotelResNotif` endpoint.  7. Booking.com servers are temporarily unavailable. Provider gets an `HTTP 500` error.  8. Provider calls the `POST OTA_HotelResNotif` endpoint  again or until a successful response.  9. Booking.com returns a successful `OTA_HotelResNotifRS` message. |  | 1. Provider calls the `OTA_HotelResModifyNotif` endpoint within the timeout period.  2. Booking.com servers are temporarily unavailable and so the Providers get an `HTTP 500` error.  3. Provider calls the `GET OTA_HotelResModifyNotif` endpoint again or until a successful response.  4. Booking.com returns an `OTA_HotelResModifyNotifRQ` object with the reservations details. 5. Provider integrates reservation changes into their system and updates inventory.  6. Provider calls the `POST OTA_HotelResNotif` endpoint.  7. Booking.com servers are temporarily unavailable. Provider gets an `HTTP 500` error.  8. Provider calls the `POST OTA_HotelResModifyNotif` endpoint again or until a successful response.  9. Booking.com returns a successful `OTA_HotelResModifyNotifRS` message. |


### Encountering system outage while retrieving or acknowledging reservations

The following 2 process flow diagrams show the steps that lead to Booking.com systems triggering the fallback mechanism while retrieving or acknowledging new reservations.

Click on the diagram to see it in full screen. To return to the topic, click the browser's back button.

|  |  |  |
|  --- | --- | --- |
| [![Experience system outage while retrieving new reservations](/assets/timeoutpullreservationsota.f6fa9ce5200cc3823d4111325db7f45a74fa4e737e2d7c62c0455521b2027176.5761a12f.png)](/assets/timeoutpullreservationsota.f6fa9ce5200cc3823d4111325db7f45a74fa4e737e2d7c62c0455521b2027176.5761a12f.png) | [![Experience system outage while acknowledging modified/cancelled reservations](/assets/timeoutackreservationsota.042af077a51e5ce81436382256cf643e4decca85ad0eb0d28ac3d4b2981dc33a.5761a12f.png)](/assets/timeoutackreservationsota.042af077a51e5ce81436382256cf643e4decca85ad0eb0d28ac3d4b2981dc33a.5761a12f.png) |  |
| 1. Provider calls the `OTA_HotelResNotif` endpoint within the [timeout period](/connectivity/docs/reservations-api/reservations-overview#introducing-the-reservations-fallback-mechanism) to retrieve all reservations made since the last `GET` call.  2. Booking.com servers are temporarily unavailable. Provider gets an `HTTP 500` error.  3. Booking.com experiences extended system outage.  4. Provider calls the `OTA_HotelResNotif` endpoint again. 5. Booking.com systems are still unavailable. Provider gets a `HTTP 500` error.  6. Fallback mechanism is triggered and Booking.com sends the reservations directly to the property through email.  | 1. Provider calls the `OTA_HotelResNotif` endpoint within the [timeout period](/connectivity/docs/reservations-api/reservations-overview#introducing-the-reservations-fallback-mechanism) to retrieve all reservations made since the last `GET` call.  2. Booking.com returns an `OTA_HotelResNotifRQ` object with the reservations details.  3. Provider integrates booking into their system and updates inventory.  4. Provider calls the `POST OTA_HotelResNotif` endpoint to acknowledge processing the reservations.  5. Booking.com experiences system outage before acknowledging reservations. Provider gets a `HTTP 500` error  6. Fallback mechanism is triggered and Booking.com sends the reservations directly to the property through email.  |  |


#### Quick Actions

→ To retrieve new reservations using the OTA solution, see [Retrieving new reservations.](/connectivity/docs/reservations-api/retrieving-new-reservations-ota) 
→ To acknowledge new reservations using the OTA solution, see [Acknowledging new reservations.](/connectivity/docs/reservations-api/acknowledging-new-reservations-ota) 

→ To retrieve modified or cancelled reservations using the OTA solution, see [Retrieving modified or cancelled reservations.](/connectivity/docs/reservations-api/retrieving-modifcancel-reservations-ota) 
→ To acknowledge modified or cancelled reservations using the OTA solution, see [Acknowledging modified or cancelled reservations.](/connectivity/docs/reservations-api/acknowleding-modif-cancel-reservations-ota)