sessions_start_booking
Opens the booking sheet pre-filled and stops at confirm. The payment route.
When to use it
Whenever money is due — this is the payment route, and the only one.
When the session needs a waiver or form only the person can fill in.
As the fallback whenever
sessions_book_sessionrefuses.
Parameters
sessionstringrequiredThe scheduled session id, as returned by sessions_list_schedule. Pass it through verbatim — it is an opaque global id, not a number.
quantitynumberoptionalNumber of spots. Default 1.
discountCodestringoptionalDiscount code to apply.
giftCardCodestringoptionalGift-card code to apply.
passstringoptionalId of a pass or membership to cover the seat.
Returns
Every tool returns two things: text for the model to read, and a structuredContent object beside it for code that would rather branch on a field.
Confirmation that the sheet is open and pre-filled, the quote it is showing, and awaitingUserConfirmation: true. Nothing is booked and nothing is charged until the person confirms it themselves.
Example
Run this from any agent or script executing in the page.
const tools =
await document.modelContext.getTools();
const tool = tools.find(
(t) => t.name === 'sessions_start_booking',
);
const result = await document.modelContext
.executeTool(tool, {
"session": "<session id>",
"discountCode": "AUTUMN10"
});Opened the booking sheet for that session,
filled in. The sheet will show 21.60 CAD due
(total 21.60 CAD). Nothing is booked and nothing
is charged until the person confirms it…{
"url": "/@capital-bodywork/schedule/<id>?discount=AUTUMN10",
"awaitingUserConfirmation": true
}What the agent is told
The description the model reads when deciding whether to call this. It is the only thing that decides whether the tool fires at the right moment, so it is worth knowing what it says.