Skip to main content
Glama

Create a hosted checkout link

create_checkout_link

Assemble a cart and get a Stripe-hosted checkout URL the customer opens to pay; no card data passes through the agent. Item ids come from the search tools (diamond:<report>, setting:<slug>, jewelry:<slug>); a complete ring is one setting plus one diamond. Needs the shipping address (prices tax and shipping into the link). Expires after 24 hours. No credential needed. Without a production credential this tool runs in the sandbox: the link is simulated and no Stripe session is created. Pass env: "production" when the customer actually wants to buy — that returns a live, payable link.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
envNosandbox returns a simulated link and creates no Stripe session; production mints a live, payable Stripe Checkout link. Defaults to sandbox for anonymous callers and to the credential's environment otherwise. A sandbox credential is always sandbox.
itemsYesItems to buy; a complete ring is one setting plus one diamond
contextYesExplain in 15-25 words, in third person, why this tool is called and how it supports the user's goal. For analytics only. You MUST describe only the abstract purpose of the tool call. NEVER include, repeat, paraphrase, or infer personal, sensitive, or identifying information from the user request or tool results, including names, emails, phone numbers, IPs, IDs, or credentials. You MUST generalize specific entities into roles such as "a user", "the customer", or "an account". Example: "Retrieving a customer's recent orders to investigate a billing issue and help support determine the appropriate resolution."
llm_modelYesThe exact model identifier you (the assistant) are running as, taken from your system prompt or environment (e.g. "claude-opus-4-8", "gpt-5.2"). Used for analytics only. If you do not know your model identifier with certainty, pass "unknown" — never guess.
buyer_nameNoBuyer full name
buyer_emailNoBuyer email for the receipt; Stripe collects it on the payment page when omitted
conversation_idNoEcho the conversation_id from the server's previous response. The server provides it on the first call — never invent one, and do not issue parallel tool calls until you have it.
shipping_addressYesWhere the order ships; used to price tax and shipping into the link

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
urlYesThe Stripe-hosted checkout URL, when ready
statusYesready when a payable link was created; needs_input lists what is missing
messageYesHuman-readable outcome, including the link when ready
sandboxYesTrue when the link is simulated (sandbox): nothing is payable and no Stripe session was created. False means the link is live and payable.
tax_usdYesSales tax in US dollars for the given address
problemsYesWhat blocks the link when status is needs_input
total_usdYesTotal the buyer pays in US dollars
expires_atYesISO timestamp the link stops working
shipping_usdYesShipping in US dollars (0 = free insured FedEx)
subtotal_usdYesItems subtotal in US dollars

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changed
    • addedInput schema / properties / context
      Added value: +{
      +  "description": "Explain in 15-25 words, in third person, why this tool is called and how it supports the user's goal. For analytics only. You MUST describe only the abstract purpose of the tool call. NEVER include, repeat, paraphrase, or infer personal, sensitive, or identifying information from the user request or tool results, including names, emails, phone numbers, IPs, IDs, or credentials. You MUST generalize specific entities into roles such as \"a user\", \"the customer\", or \"an account\". Example: \"Retrieving a customer's recent orders to investigate a billing issue and help support determine the appropriate resolution.\"",
      +  "type": "string"
      +}
    • addedInput schema / properties / conversation_id
      Added value: +{
      +  "description": "Echo the conversation_id from the server's previous response. The server provides it on the first call — never invent one, and do not issue parallel tool calls until you have it.",
      +  "type": "string"
      +}
    • addedInput schema / properties / llm_model
      Added value: +{
      +  "description": "The exact model identifier you (the assistant) are running as, taken from your system prompt or environment (e.g. \"claude-opus-4-8\", \"gpt-5.2\"). Used for analytics only. If you do not know your model identifier with certainty, pass \"unknown\" — never guess.",
      +  "type": "string"
      +}
    • changedInput schema / required
      Previous value: -[
      -  "items",
      -  "shipping_address"
      -]New value: +[
      +  "items",
      +  "shipping_address",
      +  "context",
      +  "llm_model"
      +]
  2. Changed2 schema fields changed
    • addedInput schema / properties / env
      Added value: +{
      +  "description": "sandbox returns a simulated link and creates no Stripe session; production mints a live, payable Stripe Checkout link. Defaults to sandbox for anonymous callers and to the credential's environment otherwise. A sandbox credential is always sandbox.",
      +  "enum": [
      +    "production",
      +    "sandbox"
      +  ],
      +  "type": "string"
      +}
    • changedOutput schema / properties / sandbox / description
      Previous value: -"True on a sandbox credential: the link is simulated and nothing is payable"New value: +"True when the link is simulated (sandbox): nothing is payable and no Stripe session was created. False means the link is live and payable."
  3. Added

TDQS

A4.7/5.0
Behavior5/5

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

Discloses several non-obvious behaviors beyond the annotations: no card data passes through the agent, the link expires after 24 hours, no credential is needed, and sandbox mode simulates the link without creating a Stripe session. These are meaningful side-effect and environment semantics that annotations (readOnlyHint=false, destructiveHint=false) do not cover.

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

Conciseness5/5

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

Five sentences, front-loaded with the core purpose, and each subsequent sentence adds a distinct fact (item source, cart rule, shipping need, expiry, sandbox/production behavior). No filler.

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

Completeness5/5

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

Covers everything an agent needs to call correctly: item id source and composition, required shipping input, env flag semantics, expiry, credential requirements, and the safety note about card data. The output schema handles return-value documentation, so nothing is missing.

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. The description adds mild reinforcement: "a complete ring is one setting plus one diamond" and "Needs the shipping address (prices tax and shipping into the link)", clarifying the relationship between items and shipping_address. Most param detail already lives in the schema, so the added value is limited but present.

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 verb and resource: "Assemble a cart and get a Stripe-hosted checkout URL the customer opens to pay." It clarifies scope (hosted checkout, no card data through the agent) and distinguishes itself from the search siblings by noting item ids come from them.

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

Usage Guidelines4/5

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

Gives clear context for when to call: build a cart from search tool ids, require a complete ring as one setting plus one diamond, and provide the shipping address for tax/shipping pricing. It also specifies the env condition (pass "production" only when the customer actually wants to buy). It does not name an explicit alternative or when-not-to-use, though the purpose is sufficiently distinct from siblings.

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