Skip to main content
Glama

update_cart

Modify an open cart before checkout. op: 'add' appends items, 'remove' drops items by 0-based index, 'set' replaces the full item list, 'clear' empties the cart. Merges customer details (name, email, phone) via the customer field. Call get_cart afterwards to confirm. Cannot modify a cart that already has a checkout in progress.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
opNo
itemsNo
cart_idYes
indicesNoItem indices to remove (0-based) when op='remove'
customerNo

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. First observed

TDQS

A4.4/5.0
Behavior4/5

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

With no annotations, the description carries the full burden. It discloses the effect of each operation (append, drop by 0-based index, replace full list, empty) and the customer merge behavior, plus the checkout-in-progress restriction. This gives the agent a solid behavioral model, though it doesn't cover edge cases like out-of-bounds indices or error returns.

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?

Four sentences, each with a distinct role: purpose, operation semantics, customer behavior, and usage guidance + constraint. No filler, front-loaded purpose.

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?

For a 5-parameter tool with no output schema and no annotations, the description explains the core behaviors and provides a verification step. It could elaborate on return values or prerequisites for items, but overall it is complete enough for an agent to use the tool correctly.

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 description coverage is only 20% (indices only). The description compensates by explaining the op enum values, that items are used for add/set, and that customer merges name/email/phone. This adds meaning beyond the raw schema for most parameters.

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?

The description states 'Modify an open cart before checkout' — a specific verb and resource, then details each op (add, remove, set, clear) and the customer merge. It distinguishes from siblings by scoping to open carts and excluding carts with checkout in progress.

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?

It gives clear usage context: 'before checkout' and the constraint 'Cannot modify a cart that already has a checkout in progress.' It also advises 'Call get_cart afterwards to confirm,' establishing a workflow. No explicit alternative tool names are mentioned, but the constraint provides a when-not.

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.

TDQS

A4.2/5.0
Disambiguation4/5

Most tools have distinct purposes, but the presence of three search tools (search_catalog, search_products, lookup_catalog) and legacy tools (create_order, submit_enquiry) creates minor overlap. Descriptions help differentiate, but an agent might initially confuse them.

Naming Consistency5/5

All 26 tool names follow a consistent verb_noun snake_case pattern (e.g., cancel_cart, configure_product). No mixed cases or irregular verbs are present.

Tool Count4/5

26 tools is slightly high for a blind shop, but the domain requires many operations (search, pricing, cart, checkout, recommendations, etc.). Some legacy tools could be removed, but the count is still reasonable.

Completeness5/5

The tool surface covers the full customer journey from product discovery (search, recommendations) to purchase (cart, checkout, payment) and post-purchase (orders, swatches, price match, delivery estimates). No obvious gaps for the stated purpose.

Resources