Skip to main content
Glama

Set Cart Quantity

set_cart_quantity
DestructiveIdempotent

Update the quantity of a specific item in your active shopping cart by providing the item name and desired amount. Adjust item counts directly to prepare for checkout.

Instructions

Use this to overwrite the quantity of a named live cart line.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
quantityYes
item_nameYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
okYes
messageYes

Schema Changelog

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

  1. First observedv1.1.1

TDQS

A3.9/5.0
Behavior3/5

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

Annotations already declare destructiveHint=true, readOnlyHint=false, idempotentHint=true, and openWorldHint=true. The description adds the 'live cart line' context and reinforces the destructive overwrite behavior, but it does not go much beyond what the annotations already communicate.

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?

A single, direct sentence with no filler. The key action is front-loaded and every word contributes to meaning.

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, the existing output schema, and the annotations covering destructive/idempotent behavior, the description is mostly complete. It could be slightly richer about the 'live cart line' concept, but nothing critical is missing for a basic call.

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

Parameters2/5

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

Schema description coverage is 0%, so the description must compensate for the lack of parameter documentation. It loosely maps 'named' to item_name and 'quantity' to quantity, but it does not clarify constraints such as the 1-50 quantity range, exact-match requirements, or what happens if the named line does not exist. This is only minimal compensation.

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 uses a specific verb ('overwrite') and a specific resource ('quantity of a named live cart line'), clearly distinguishing it from sibling tools like add_to_cart or remove_from_cart. The phrasing makes the tool's core action unmistakable.

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?

'Overwrite the quantity of a named live cart line' gives clear context that this tool is for modifying an existing cart line. It does not explicitly name alternatives or state when not to use it, but the context is sufficient for an agent to infer the intended use.

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

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/thebuilderscollective/lazada-community-mcp'

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