Skip to main content
Glama

Checkout

checkout_session

Use this when the customer has picked specific teas.co.uk products and wants to buy them straight away, for example from a product result. It puts exactly these items in a fresh basket at live prices and returns a secure link to pay on teas.co.uk; the basket built earlier is not used or changed. checkout_session holds items: each item needs an id from find_products and a quantity of 1 to 99, up to 20 items. offerId from the product feed is tried when an id is not found. Display fields (name, description, images, url, merchant_name, price) never change what is charged. Items that cannot be found are listed in unavailable and the rest go ahead; if none are found it returns an error. Nothing is charged until the customer pays on teas.co.uk. To check out the basket they built, use checkout_link.

Input Schema

NameRequiredDescriptionDefault
checkout_sessionYesThe products to buy: items lists each product id (from find_products) and quantity, up to 20 products.

Output Schema

NameRequiredDescriptionDefault
itemsYesNumber of items in the basket.
linesYes
deliveryYes
messagesYesAnything that could not be added or changed, in plain words.
subtotalNoPounds including VAT, before delivery.
basket_idNoPresent only when the host did not identify the user: pass it to later basket tools.
unavailableNoItems teas.co.uk could not add.
checkout_urlNoSecure link that opens this basket at teas.co.uk checkout.
how_it_worksNo
subtotal_textYes
link_valid_forNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed8 schema fields changed
    • addedInput schema / properties / checkout_session / description
      Added value: +"The products to buy: items lists each product id (from find_products) and quantity, up to 20 products."
    • addedInput schema / properties / checkout_session / properties / items / description
      Added value: +"Each product and how many, up to 20 products."
    • addedInput schema / properties / checkout_session / properties / items / items / properties / description / description
      Added value: +"Optional, for display only; not used."
    • addedInput schema / properties / checkout_session / properties / items / items / properties / images / description
      Added value: +"Optional image links, for display only; not used."
    • addedInput schema / properties / checkout_session / properties / items / items / properties / merchant_name / description
      Added value: +"Optional, for display only; not used."
    • addedInput schema / properties / checkout_session / properties / items / items / properties / name / description
      Added value: +"Optional product name for display; teas.co.uk uses its own."
    • addedInput schema / properties / checkout_session / properties / items / items / properties / quantity / description
      Added value: +"How many packs, 1 to 99."
    • addedInput schema / properties / checkout_session / properties / items / items / properties / url / description
      Added value: +"Optional product link, for display only; not used."
  2. First observed

TDQS

A4.7/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Goes well beyond the annotations by disclosing that nothing is charged until payment on teas.co.uk, that the earlier basket is neither consumed nor modified, that live prices override supplied display fields, and that partial failures are reported in 'unavailable' while the rest proceed, with an error only if nothing is found.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loads the trigger and the core behavior, then layers in failure modes and the sibling pointer. It is dense but largely earns its length; the sentence restating that display fields never change the charge partially duplicates schema text that already says 'for display only; not used.'

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With annotations (non-readonly, non-idempotent) and an output schema already present, the description supplies the missing operational context: partial-failure semantics, pricing behavior, and the no-charge guarantee. It stops short of noting session/link expiry or warning that retries create additional fresh sessions despite idempotentHint=false.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the baseline is 3, but the description adds genuine semantics: id must come from find_products, offerId is a fallback when an id is not found, display fields never affect the charge, and the 20-item cap and 1–99 quantity range govern the request. Some of this (display-only fields) merely echoes the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific action and resource ('puts exactly these items in a fresh basket... returns a secure link to pay') and explicitly contrasts with the sibling that checks out a pre-built basket. An agent can distinguish it from checkout_link and add_to_basket without opening a schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Names the triggering situation (customer picked specific products and wants to buy straight away, e.g. from a product result) and routes the alternative case explicitly ('To check out the basket they built, use checkout_link'). When-to-use and the alternative are both spelled out.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources