Skip to main content
Glama

Update a checkout

update_checkout
DestructiveIdempotent

Sets the buyer, address, delivery option, payment method (cash on delivery: "cod") or a discount code. Only changed fields are sent. The whole checkout is re-priced and returned.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "store": "<store>",
      "checkoutId": "<checkoutId>"
    },
    "name": "update_checkout"
  }
}

Input Schema

NameRequiredDescriptionDefault
buyerNoThe shopper. The phone must be an Egyptian mobile (01XXXXXXXXX or +201XXXXXXXXX).
itemsNoLine items: one entry per product (and variant) with its quantity. 1 to 50 entries.
storeYesThe store, from find_stores or search_all_stores (its `store` field).
addressNoDelivery address in Egypt. governorate (Arabic or English name), city, area (district), street.
checkoutIdYesFrom create_checkout.
discountCodeNoEmpty string removes a code.
paymentMethodNoPayment method; cod is cash on delivery.
shippingOptionIdNoId of one of the delivery options listed in the checkout.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed15 schema fields changed
    • addedInput schema / properties / address / properties / area / description
      Added value: +"District id (from search_districts or resolve_district) or the district / neighbourhood name."
    • addedInput schema / properties / address / properties / building / description
      Added value: +"Building number, floor and apartment."
    • addedInput schema / properties / address / properties / city / description
      Added value: +"City within the governorate."
    • addedInput schema / properties / address / properties / governorate / description
      Added value: +"Egyptian governorate, Arabic or English name (for example Cairo)."
    • addedInput schema / properties / address / properties / notes / description
      Added value: +"Free-text delivery notes for the courier."
    • addedInput schema / properties / address / properties / street / description
      Added value: +"Street name."
    • addedInput schema / properties / buyer / properties / email / description
      Added value: +"Buyer's email address."
    • addedInput schema / properties / buyer / properties / name / description
      Added value: +"Buyer's full name."
    • addedInput schema / properties / buyer / properties / phone / description
      Added value: +"Egyptian mobile number, 01XXXXXXXXX or +201XXXXXXXXX."
    • addedInput schema / properties / items / description
      Added value: +"Line items: one entry per product (and variant) with its quantity. 1 to 50 entries."
    • addedInput schema / properties / items / items / properties / productId / description
      Added value: +"Product id (UUID) from search_products or get_product."
    • addedInput schema / properties / items / items / properties / quantity / description
      Added value: +"Number of units, 1 to 1000."
    • addedInput schema / properties / items / items / properties / variantId / description
      Added value: +"Variant id (UUID) of the product, for products that have variants."
    • addedInput schema / properties / paymentMethod / description
      Added value: +"Payment method; cod is cash on delivery."
    • addedInput schema / properties / shippingOptionId / description
      Added value: +"Id of one of the delivery options listed in the checkout."
  2. First observed

TDQS

A3.7/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=false, destructiveHint=true and idempotentHint=true, so the safety profile is covered. The description still adds real behavioral value beyond them: it clarifies that the call is a patch (only changed fields are sent) and that the entire checkout is re-priced and returned, which is a non-obvious side effect of mutating any field. It stops short of saying what is lost or whether an update can invalidate an existing shipping quote.

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 short sentences with zero filler, and the field enumeration is front-loaded ahead of the two behavioral facts. Nothing is repeated or padded.

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

Completeness3/5

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

The tool has 8 parameters including nested buyer, address and items objects, and no output schema; the description compensates for the missing output schema by stating the checkout is returned. However, it omits the 'items' parameter entirely from its field list, leaving the most structurally complex input undocumented in prose.

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 every parameter is already documented in the schema, establishing a baseline of 3. The description only restates the field list and repeats the 'cod' enum meaning, adding no syntax or format detail beyond the schema.

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

Purpose4/5

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

Names a specific verb ('Sets') and resource (checkout) and enumerates the mutable facets: buyer, address, delivery option, payment method, discount code. The phrase 'Only changed fields are sent' signals this is a partial update, which distinguishes it implicitly from create_checkout, but no sibling is named explicitly.

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

Usage Guidelines3/5

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

The partial-update phrasing ('Only changed fields are sent') implies when to reach for this tool rather than create_checkout, but that inference is left to the agent. There is no explicit when-to-use, when-not-to-use, or named alternative such as cancel_checkout or create_checkout.

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.