Skip to main content
Glama

quote_purchase

Works out the final price and the breakdown of a purchase WITHOUT creating the order, and returns a quoteId: the fingerprint of THAT total. Hand it to prepare_payment to buy exactly what was shown here; if the total had changed, the purchase is refused instead of being created for a different amount. The quote reserves nothing and does not consume the discount code.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
slugYesSlug of the template to quote.
promoCodeNoSeller's discount code (optional).
codigoPromoNoDEPRECATED alias of `promoCode`: it still works, but use `promoCode` (it will be removed in a future round, no date yet). Seller's discount code (optional).

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
noteYesNotice that quoting neither creates nor reserves anything.
feeBpsYesFee in basis points.
quoteIdYesFingerprint of THIS total, to declare it in prepare_payment.
discountYesThe discount applied, or null if there is none.
templateYesThe quoted template.
totalUsdcYesTotal to pay in USDC (decimal string).
totalUnitsYesThe same total in USDC minimal units (digit string).
walletReadyYesThe account that would pay already has a wallet activated.
listPriceUsdcYesList price in USDC (decimal string).
platformFeeUsdcYesPlatform fee in USDC (decimal string).
sellerCanBePaidYesThe seller can already be paid.
sellerReceivesUsdcYesWhat the seller keeps in USDC (decimal string).
discountNotVerifiedNoOnly when the code's verification quota ran out: it was quoted at list price without validating it.
immediateDownloadConsentYesText of what is accepted when buying, in the language of the token.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed21 schema fields changed
    • changedInput schema / properties / codigoPromo / description
      Previous value: -"ALIAS RETIRADO de `promoCode`: sigue funcionando, pero usa `promoCode` (se quitará en una tanda futura, aún sin fecha). / DEPRECATED alias of `promoCode`. Código de descuento del vendedor (opcional)."New value: +"DEPRECATED alias of `promoCode`: it still works, but use `promoCode` (it will be removed in a future round, no date yet). Seller's discount code (optional)."
    • changedInput schema / properties / promoCode / description
      Previous value: -"Código de descuento del vendedor (opcional)."New value: +"Seller's discount code (optional)."
    • changedInput schema / properties / slug / description
      Previous value: -"Slug de la plantilla a cotizar."New value: +"Slug of the template to quote."
    • changedOutput schema / properties / discount / description
      Previous value: -"El descuento aplicado, o null si no hay ninguno."New value: +"The discount applied, or null if there is none."
    • changedOutput schema / properties / discount / properties / percent / description
      Previous value: -"Porcentaje de descuento."New value: +"Discount percentage."
    • changedOutput schema / properties / discount / properties / savingsUsdc / description
      Previous value: -"Lo que se ahorra en USDC (cadena decimal)."New value: +"What is saved in USDC (decimal string)."
    • changedOutput schema / properties / discountNotVerified / description
      Previous value: -"Solo cuando se agotó el tope de comprobaciones del código: se cotizó a precio de lista sin validarlo."New value: +"Only when the code's verification quota ran out: it was quoted at list price without validating it."
    • changedOutput schema / properties / feeBps / description
      Previous value: -"Comisión en puntos básicos."New value: +"Fee in basis points."
    • changedOutput schema / properties / immediateDownloadConsent / description
      Previous value: -"Texto de lo que se acepta al comprar, en el idioma del token."New value: +"Text of what is accepted when buying, in the language of the token."
    • changedOutput schema / properties / listPriceUsdc / description
      Previous value: -"Precio de lista en USDC (cadena decimal)."New value: +"List price in USDC (decimal string)."
    • changedOutput schema / properties / note / description
      Previous value: -"Aviso de que cotizar no crea ni reserva nada."New value: +"Notice that quoting neither creates nor reserves anything."
    • changedOutput schema / properties / platformFeeUsdc / description
      Previous value: -"Comisión de la plataforma en USDC (cadena decimal)."New value: +"Platform fee in USDC (decimal string)."
    • changedOutput schema / properties / quoteId / description
      Previous value: -"Huella de ESTE total, para declararlo en prepare_payment."New value: +"Fingerprint of THIS total, to declare it in prepare_payment."
    • changedOutput schema / properties / sellerCanBePaid / description
      Previous value: -"El vendedor ya puede cobrar."New value: +"The seller can already be paid."
    • changedOutput schema / properties / sellerReceivesUsdc / description
      Previous value: -"Lo que conserva el vendedor en USDC (cadena decimal)."New value: +"What the seller keeps in USDC (decimal string)."
    • changedOutput schema / properties / template / description
      Previous value: -"La plantilla cotizada."New value: +"The quoted template."
    • changedOutput schema / properties / template / properties / name / description
      Previous value: -"Nombre público de la plantilla."New value: +"Public name of the template."
    • changedOutput schema / properties / template / properties / slug / description
      Previous value: -"Slug de la plantilla."New value: +"Slug of the template."
    • changedOutput schema / properties / totalUnits / description
      Previous value: -"El mismo total en unidades mínimas de USDC (cadena de dígitos)."New value: +"The same total in USDC minimal units (digit string)."
    • changedOutput schema / properties / totalUsdc / description
      Previous value: -"Total a pagar en USDC (cadena decimal)."New value: +"Total to pay in USDC (decimal string)."
    • changedOutput schema / properties / walletReady / description
      Previous value: -"La cuenta que pagaría ya tiene wallet activada."New value: +"The account that would pay already has a wallet activated."
  2. First observed

TDQS

A4.5/5.0
Behavior5/5

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

With no annotations, the description carries full weight and does so well: it states no order is created, the quote reserves nothing, the discount code is not consumed, and the `quoteId` is a fingerprint of the quoted total. These are precise side-effect disclosures.

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?

Three sentences, front-loaded with the core function, followed by workflow integration and side-effect caveats. Every sentence carries useful information with 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?

The description covers what the tool does, what it returns, how it fits with `prepare_payment`, and its non-mutating behavior. An output schema exists, so return-value details are not required. No significant gaps remain.

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

Parameters3/5

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

Schema description coverage is 100%, so parameters are already well documented. The description adds workflow context around the discount code but does not need to repeat parameter meanings; baseline 3 is appropriate.

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?

Description states a specific action (compute final price and breakdown) and explicit scope: it does NOT create the order. It names the returned `quoteId` and ties it to `prepare_payment`, making the tool's role unambiguous and distinct from purchase-creation tools.

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?

Identifies the intended workflow: pass the `quoteId` to `prepare_payment` to purchase, and warns that a changed total will cause refusal rather than a mismatched order. It does not explicitly list exclusions, but the usage context is clear.

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