Cancel Booking
cancel_bookingUse this when the user wants to cancel a booking previously made through this server (its booking_id, or the ZST-… reference from Zestli's emails and pages), or some parts of it. Cancelling takes two calls with the user's answer in between. First call with preview=true: nothing is cancelled; it returns the refund the user would get now (refund_amount_minor, refund_currency, refund_rule, any cancellation_fee_minor, and per part refund_parts, including a together discount taken back) and a preview_id. Operator-run experiences refund by their published cancellation tiers measured to the booked start time, often partial and 0 after the start; other suppliers refund in full or less the fee shown at checkout. A card only authorized, never charged (such as a request the operator has not accepted) previews not_charged with no refund amount: cancelling releases the authorization and refunds nothing because nothing was taken. The user agrees to the previewed refund, not just to cancelling: a request to cancel is not agreement to an amount they have not seen. Once they confirm that refund, a call without preview, with the same booking_id, segment_ids and the preview_id, cancels, refunds exactly that amount (0 moves no money) and reports it. DESTRUCTIVE and not reversible. If the refund changed since the preview, the call is refused with the new figures and a new preview_id: show them and ask again. If a leg fails or the refund is not confirmed, the message says what to do next.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"request": "<request>"
},
"name": "cancel_booking"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| request | Yes | Input for cancelling a confirmed booking. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| status | Yes | ||
| message | No | ||
| booking_id | Yes | ||
| error_code | No | ||
| is_sandbox | No | ||
| preview_id | No | ||
| not_charged | No | ||
| refund_rule | No | ||
| needs_review | No | ||
| refund_parts | No | ||
| refund_outcome | No | ||
| refund_currency | No | ||
| refund_initiated | No | ||
| already_cancelled | No | ||
| cancelled_part_ids | No | ||
| refund_amount_minor | No | ||
| cancellation_fee_minor | No |