DEPRECATED — use /v1/hotel_cancel_preview and /v1/hotel_cancel_commit. Cancel a hotel booking and get a refund when eligible. Preview and commit in one call — POST /v1/hotel_cancel_preview plus /v1/hotel_cancel_commit is the two-step form, which shows the customer the refund before anything is cancelled. `refund_amount` is what the CUSTOMER gets back; all amounts are customer-facing only. Returning the money outlives this call: poll the `operation` handle with POST /v1/hotel_cancel_status. Every call here needs API authentication (an API key or a Bearer token); this is about which mode identifies the booking. Call get_booking first, then send booking_ref and the selected booked_item_id. Guests must send last_name; an owning credential may omit it. The deprecated `provider`, `order_id`, `provider_reference` and `provider_booking_id` are accepted until 2027-04-30 where the request declares them; a request that sends one is answered with `Deprecation` and `Sunset` headers.
Call get_booking first. Use booking_ref and the selected booked_item_id for every servicing action. last_name is required for guest lookup; an owning credential may omit it. The deprecated provider, order_id, provider_reference and provider_booking_id are accepted until 2027-04-30 where the request declares them; a request that sends one is answered with Deprecation and Sunset headers. A 409 item_selection_required returns safe items to choose from.
Request
- Base URLhttps://api.gojinko.com
- URLhttps://api.gojinko.com/v1/hotel_cancel
- Auth
- API key in header X-API-Key
- or HTTP bearer
Request body
Example request
{
"booking_ref": "JNK-A0AUR2",
"booked_item_id": "itm_aaaaaaaaaaaaafhuxsdxpbzrbfz5hm3a",
"last_name": "Doe",
"intent": {
"user_intent": "find a cheap flight to Tokyo"
}
}Response
Cancel a hotel booking and get a refund when eligible. Preview and commit in one call — POST /v1/hotel_cancel_preview plus /v1/hotel_cancel_commit is the two-step form, which shows the customer the refund before anything is cancelled. refund_amount is what the CUSTOMER gets back; all amounts are customer-facing only. Returning the money outlives this call: poll the operation handle with POST /v1/hotel_cancel_status. Every call here needs API authentication (an API key or a Bearer token); this is about which mode identifies the booking. Call get_booking first, then send booking_ref and the selected booked_item_id. Guests must send last_name; an owning credential may omit it. The deprecated provider, order_id, provider_reference and provider_booking_id are accepted until 2027-04-30 where the request declares them; a request that sends one is answered with Deprecation and Sunset headers.
Example response
{
"booking_ref": "JNK-A0AUR2",
"booking_reference": "JNK-A0AUR2",
"status": "cancelled",
"operation": "svc_01J7ZR5Q2KME8V4T",
"refund_amount": {
"value": 41250,
"currency": "USD",
"decimal_places": 2,
"display": "USD 412.50"
},
"customer_refund_amount": {
"value": 41250,
"currency": "USD",
"decimal_places": 2,
"display": "USD 412.50"
},
"penalty_amount": {
"value": 41250,
"currency": "USD",
"decimal_places": 2,
"display": "USD 412.50"
},
"cancelled_at": "2026-06-01T12:34:56Z"
}Changes
No recorded changes to this operation across all 1 revision of this API.