Skip to main content
Glama

get_cart

Read-onlyIdempotent

Inspect the consenting buyer's existing basket before changing its lines; rechecks current prices and stock and returns item_id for update_cart_item or remove_cart_item. Use get_checkout for delivery, payment and contact choices, not this tool. OAuth scopes: cart:read. Read-only.

Input Schema

NameRequiredDescriptionDefault

No arguments

Output Schema

NameRequiredDescriptionDefault
emptyYes
itemsYes
currencyYes
subtotalYes
orderableYes
total_quantityYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.7/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, idempotentHint and destructiveHint=false, so the safety profile is covered; the description still adds real context beyond them, namely the cart:read OAuth scope, the fact that prices and stock are re-verified on each call, and that the response carries item_id consumed by the mutation siblings. It does not cover rate limits or failure modes, but the disclosure is well above the annotation baseline.

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?

Front-loaded with the action and purpose, then the downstream consumer, then the sibling exclusion, then the scope. Three compact clauses with no filler or repetition.

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?

An output schema exists so return values need not be enumerated, and the description still flags the one field that matters for chaining (item_id) plus auth scope and freshness semantics. Nothing an agent needs in order to call this correctly 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?

The tool takes zero parameters, so the schema-based baseline is 4; the description correctly adds nothing spurious about inputs and instead explains what the no-argument call yields.

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?

Names a specific verb and resource (inspect the existing basket/cart) and adds the important qualifier that it rechecks live prices and stock rather than returning cached data. It also explicitly routes the agent away from the sibling get_checkout, so the tool is distinguishable without opening any 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?

Gives both when-to-use ('before changing its lines', and its output feeds update_cart_item / remove_cart_item) and when-not-to-use ('Use get_checkout for delivery, payment and contact choices, not this tool'). It names the concrete alternatives and the condition that selects them.

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