sessions_open_product
Opens the purchase sheet for a product.
NavigationSessions pages only
When to use it
When the person wants to buy a pass or gift card rather than book a single session.
Parameters
productstringrequiredProduct id, as returned by sessions_list_products.
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 purchase sheet is open. Nothing is purchased.
Example
Run this from any agent or script executing in the page.
javascript
const tools =
await document.modelContext.getTools();
const tool = tools.find(
(t) => t.name === 'sessions_open_product',
);
const result = await document.modelContext
.executeTool(tool, {
"product": "<product id>"
});content
Opened that product on the page. Nothing has
been purchased.structuredContent
{
"url": "/@capital-bodywork/products/<id>"
}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.
sessions_open_product
Opens the purchase sheet for a pass, membership, gift card or physical product. Does not purchase anything — the person completes it.