Skip to main content
Glama

update_cart_item

DestructiveIdempotent

Update the quantity of an item in the cart. Set quantity to zero to remove the item.

Instructions

Set exact cart quantity; zero removes the product. No charge.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
quantityYes
product_idYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Behavior4/5

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

The description adds valuable behavioral context beyond annotations: it confirms that setting quantity to zero removes the product (aligning with destructiveHint=true) and mentions 'No charge', indicating the operation does not incur a financial transaction. Annotations already provide idempotentHint and destructiveHint, so the description complements them well without contradiction.

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?

The description is extremely concise at two short sentences. The first sentence is front-loaded with the core action. Every word contributes essential information, achieving high efficiency with no filler.

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?

Given the tool's simplicity (2 parameters, clear behavior) and the presence of an output schema (though not shown), the description covers the main usage aspects: exact quantity setting, deletion, and cost. It lacks explicit mention that the cart item must already exist, but the name implies it. Overall, it is sufficiently complete for a well-understood domain.

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 coverage is 0%, meaning the description bears the burden of explaining parameters. It partially does so by stating 'Set exact cart quantity', which relates to the 'quantity' parameter but does not explicitly describe its range or validation. The 'product_id' parameter is not mentioned. This adds some value but is incomplete.

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 clearly states the tool's action: 'Set exact cart quantity', and specifies a key behavior: 'zero removes the product'. This distinguishes it from sibling tools like add_to_cart (which may add or increment) and clear_cart (which removes all items). The purpose is unambiguous.

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

Usage Guidelines2/5

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

The description does not explicitly guide when to use this tool versus alternatives such as add_to_cart or clear_cart. It assumes the agent knows that an existing cart item must be targeted. No when-not-to-use or prerequisite information is provided.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/shi-kirill/pyaterochka-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server