Cancel Booking
cancel_bookingCancels a confirmed booking. A booking on the business's Advocate calendar that takes no payment through Advocate takes the cancel_token confirm_booking returned, and nothing was paid through it. A paid booking takes the cancel_token from its payment receipt. Within 60 minutes of paying, or before the business's refund window, the full refund is requested; report it as full only after the payment ledger confirms it. After that window the deposit is forfeited under the booking's policy. A pending refund means cancellation is complete while refund verification or retry continues. A paid booking's token is held only by the agent that paid. The token of a booking that takes no payment through Advocate is held by the agent that confirmed it and sits in the customer's emailed receipt. If such a booking is already cancelled (by an earlier call, the customer's emailed link, or the business), the answer is status already_cancelled with refund no_payment, and nothing changes. Cancelling a paid booking twice answers the error already_cancelled with its refund state.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| slug | Yes | Business slug identifier | |
| cancel_token | Yes | The cancel_token from confirm_booking, or from the payment receipt of a paid booking | |
| reservation_id | Yes | The reservation's id |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| refund | Yes | no_payment: a booking that takes no payment through Advocate, nothing was paid through it; full: the payment ledger confirms the refund; none: deposit was forfeited; pending: cancellation is complete and refund verification or retry is pending | |
| status | Yes | already_cancelled: a booking that takes no payment through Advocate and was cancelled before this call; nothing changed | |
| currency | Yes | ||
| pending_cents | Yes | ||
| refunded_cents | Yes | ||
| reservation_id | Yes |