Skip to main content
Glama
stupidprogrammer4

digikala-mcp

Add To Account Cart

add_to_account_cart
DestructiveIdempotent

Adds one unit to this account's cart using an approved add plan and session token. It revalidates price, stock, and caps before submitting and never resends a plan.

Instructions

Trusted backend: POST one unit with an approved add plan belonging to this account.

Requires explicit host approval. Revalidates price, stock and caps; never resends a plan.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
plan_idYes
session_tokenYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
cartNo
stateYes
reasonNo
plan_idYes
limits_exceededNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.5/5.0
Behavior4/5

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

Annotations already declare destructive and idempotent behavior, and the description corroborates with useful extra context: it revalidates price, stock and caps, and 'never resends a plan' explains the idempotency guarantee in concrete terms. It does not contradict destructiveHint=true, though the interplay between a one-unit POST and a destructive hint is left unexplained.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two tight, front-loaded sentences with no padding; the approval precondition and revalidation guarantee are stated early. The unexplained 'Trusted backend:' prefix is the only wasted token.

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?

An output schema exists, so return values need not be described, and the annotations carry the safety profile. The description covers the approval gate, the revalidation of price/stock/caps, and idempotency, which is most of what an agent needs for a cart mutation.

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% for two required parameters. The description gestures at plan_id via 'approved add plan belonging to this account,' but says nothing about session_token, the 32-hex plan_id format, or the unit cap implied by 'caps.' It does not compensate for the missing schema documentation.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb (POST one unit) and resource (account cart), and the phrase 'belonging to this account' distinguishes it from the sibling add_to_cart. However, the 'Trusted backend:' framing and 'approved add plan' jargon are not explained, so the operation is clear but the mechanics are opaque.

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

Usage Guidelines3/5

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

The line 'Requires explicit host approval' and 'with an approved add plan' implies a precondition and a plan-first workflow, which suggests prepare_account_cart_change as the preceding step. But it never names that alternative or states when to choose this tool over add_to_cart or update_account_cart_item, leaving the routing to inference.

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