Skip to main content
Glama

Set Alphamega cart quantities

cart_set
DestructiveIdempotent

Set exact product quantities in a logged-in Alphamega cart, replacing current amounts or removing items with 0, then return per-product results and the updated cart.

Instructions

Set the quantity of one or more products in the user's real cart on alphamega.com.cy. Quantities are absolute, not increments: 2 means the cart will hold exactly 2, and 0 removes the product. Products not listed are left untouched. Returns per-product results (the shop may cap or reject a quantity) and the resulting cart. Requires the user to be logged in (see cart_login).

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": {
      "items": "<items>"
    },
    "name": "cart_set"
  }
}

Input Schema

NameRequiredDescriptionDefault
itemsYesProducts and the exact quantities the cart should hold.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.0

TDQS

A4.3/5.0
Behavior3/5

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

Annotations already declare destructiveHint=true, idempotentHint=true, and openWorldHint=true, and the description reinforces these by explaining that 0 removes a product and quantities are absolute (hence idempotent). It also adds useful context beyond annotations: unlisted products are untouched, and the shop may cap or reject quantities, which the schema does not state. Good value added, though it could say more about partial-application behavior on rejection.

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 tight sentences, front-loaded with the primary action and semantics, followed by side effects, return shape, and prerequisite. No filler sentences; each one carries distinct information.

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?

Covers the mutation semantics, side effects on unlisted products, the possibility of partial capping/rejection with per-product results, the resulting cart return, and the login prerequisite. For a single-array-parameter mutation with no output schema, nothing essential 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?

Schema coverage is 100%, so the baseline is 3, but the description adds real meaning: it makes the absolute-quantity semantics and the 0-removes convention unmistakable at the tool level, and introduces the unlisted-products-untouched rule that the schema does not encode. That is meaningful semantics beyond the input schema.

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 ("Set the quantity") and resource ("products in the user's real cart on alphamega.com.cy"), with scope immediately clear from the first sentence. An agent can distinguish this from cart_view, cart_clear, or cart_open 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 Guidelines4/5

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

Establishes the login prerequisite and points to `cart_login` explicitly, and clarifies the absolute-vs-increment semantics that decide how to call it. It does not explicitly contrast with siblings like `cart_clear` (for emptying) or `cart_view`, so routing guidance is clear but not exhaustive.

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