Pre-Cancel Order
About 230 wordsLess than 1 minute
2026-03-27
POST Pre-Cancel Order
This API is used to pre-cancel an order, returning the cancellation penalty and a confirmation ID (ConfirmID).
⚠️ Note:
- This API does NOT actually cancel the order
- Two APIs must be called to complete the cancellation process:
- Pre-cancel (this API)
- Confirm cancel (next step API)
Important Notes
- The returned
ConfirmIDis a key parameter for confirming cancellation - The
ConfirmIDis valid for at least: 10 minutes - If the
ConfirmIDexpires, this API must be called again to obtain a newConfirmID
Endpoint
POST /booking/HotelBookingCancel?$format=jsonRequest Parameters
{
"BookingID": "15442173799",
"ConfirmID": null
}| Field | Type | Required | Description |
|---|---|---|---|
| BookingID | String | Yes | Booking ID |
| ConfirmID | String | No | Cancellation confirmation ID (null for pre-cancel) |
Request Example
curl --location --request POST '{{domain}}/booking/HotelBookingCancel?$format=json' \
--header 'Authorization: PHT apikey={{api_key}},signature={{signature}},timestamp={{timestamp}}' \
--header 'api_key: {{api_key}}' \
--header 'Content-Type: application/json' \
--data-raw '{
"BookingID":"15442173799",
"ConfirmID": null
}'Response Example
{
"Success": {
"BookingID": "15442173799",
"ConfirmID": "DCC251023174704250",
"Currency": "USD",
"Amount": 0
}
}Response Parameters
| Field | Type | Required | Description |
|---|---|---|---|
| BookingID | String | Yes | Booking ID |
| ConfirmID | String | Yes | Cancellation confirmation ID (valid for 10 minutes) |
| Currency | String | Yes | Currency |
| Amount | Decimal | Yes | Cancellation penalty |