Booking blocks
Three blocks specifically for the Bookings feature. Require a service catalog entry + a connected Google Calendar account.
offer_slots
Fetches available slots for a service and sends them as an interactive list. Each row’s id encodes the slot time so the runtime can extract it on the customer’s tap.
Config:
- Service ID — which service to fetch slots for (literal or
{{run.selectedServiceId}}) - Google Calendar account ID — which connected account to write to
- Days ahead — how far out to look
- Body / Header / Footer / Button text — the wa_list shell
- Empty text — what to send if no slots are available
confirm_booking
Creates the Booking row + the Google Calendar event from the slot the customer picked.
Reads ctx.run.selectedSlot (stashed by the runtime when the customer picks a
row in offer_slots).
On success — sends the configured success text (with {{run.bookingSummary}}
variable available).
cancel_booking_picker
Lists the customer’s upcoming CONFIRMED bookings as a wa_list. The customer taps the
one they want to cancel → runtime calls bookingService.cancel → Google event is
deleted → conversation gets a cancellation summary.
Empty + error handling
Both offer_slots and cancel_booking_picker send a configured empty / error text
and end the run when there’s nothing to show (no slots, no upcoming bookings, lookup
failed). The flow doesn’t park indefinitely.
See Bookings → Flow blocks for a worked-example flow that uses all three.