Check booking process
https://api-sandbox.worldota.net/api/b2b/v3/hotel/order/booking/finish/status/
- This call is required.
- As the booking process is made asynchronously, repeatedly request this call to know the status.
The call checks the booking process status.
Sandbox limitations
Not supported features:
- 3D Secure check.
- Cut-off logic.
Response
data_3ds
. The field isn’t supported.status
. The possible field values:ok
.processing
.error
.
Errors
- Not supported errors:
block
.charge
.3ds
.not_allowed
.
Result interpretation
The result is described in the status
response field. The possible field values:
ok
—the booking finishing has ended with success.processing
—the booking finishing is in progress. Request the status change every second until you get theok
orerror
value.error
— the booking finishing has ended with an error.⚠️Don’t forget that you might have thetimeout
,unknown
, and5xx
error.
Retry logic
During the maximum booking time request this call any time you like. The recommended time is once per 5 seconds.
Request example
curl --user '<KEY_ID>:<API_KEY>' 'https://api-sandbox.worldota.net/api/b2b/v3/hotel/order/booking/finish/status/' \
--header 'Content-Type: application/json' \
--data '{
"partner_order_id": "1c481611-6432-5157-03d6-6093g2b75gd1"
}'
Request body
Response
Response example
{
"data": {
"data_3ds": null,
"partner_order_id": "1c481611-6432-5157-03d6-6093g2b75gd1",
"percent": 100,
"prepayment": null
},
"debug": null,
"error": null,
"status": "ok"
}
Errors
The error
field has the value specified in the headers below.
block
The card funds can’t be frozen (blocked) for the booking payment.
charge
The card funds can’t be withdrawn for the booking payment due to:
- A failed freeze.
- Another reason.
3ds
The MD
field value is invalid.
soldout
The rate is no longer available as its rooms are sold out.
book_limit
The cut-off logic limit for the booking finishing is reached.
not_allowed
There is no permission to use this call for this contract:
- Contact the API support team.
- Tell the user the booking error has occurred.
When contacting the API support team, provide at least:
- The hotel name where the booking is in process.
- The
order_id
field with the value from the Create booking process call. - The
user
androoms
fields with the values from the Start booking process call.
This information will help to identify the request attempt.
provider
A technical error at the rate provider side.
order_not_found
The order with the partner_order_id
field value isn’t found. Try to change the value.
booking_finish_did_not_succeed
An attempt to request this call without a successful response from the Start booking process call.
timeout
, unknown
, and 5xx
An internal error. Continue to request this call until you get the following response:
- The
status
field has theok
value. - The
error
field has one of the values:3ds
.block
.book_limit
.booking_finish_did_not_succeed
.charge
.decoding_json
.endpoint_exceeded_limit
.endpoint_not_active
.endpoint_not_found
.incorrect_credentials
.invalid_auth_header
.invalid_params
.lock
.no_auth_header
.not_allowed
.not_allowed_host
.order_not_found
.overdue_debt
.provider
.soldout
.unexpected_method
.