Skip to main content
Glama

Deporte Total

check_availability

Read-onlyIdempotent

Whether a product (or one of its variants) can be bought in a given quantity right now, and what that quantity costs: unit_price and total (unit price × quantity, calculated by the shop). When the customer asks how much several units cost, call it with that qty and say its total: never multiply yourself.

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": {
      "product_id": "<product_id>"
    },
    "name": "check_availability"
  }
}

Input Schema

NameRequiredDescriptionDefault
qtyNoHow many units
product_idYesThe id of the product, from search_products
session_idNoOnly if your client does not keep the MCP session (the Mcp-Session-Id header): the session_id that an earlier answer of this server gave you. It keeps the same cart between calls.
variant_idNoThe id of the variant (colour, size…), from get_product; 0 for a product without variants

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A3.9/5.0
Behavior4/5

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

Annotations already declare this to be a read-only, idempotent, non-destructive check. The description adds useful behavior beyond that: the shop calculates total as unit_price × quantity, and the agent must not multiply prices itself. It does not describe unavailable outcomes or error behavior.

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?

The description is two sentences and front-loads the core capability, with the second sentence giving a direct usage instruction. It is efficient overall, though the first sentence is dense with return-field details.

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?

For a four-parameter read-only tool without an output schema, the description explains the key return values (availability, unit_price, total) and the calculation rule. It is mostly complete, with minor gaps around unavailable-product behavior and the session_id parameter.

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 description coverage is 100%, so the schema already documents all four parameters. The description reinforces qty's purpose for total calculation but adds little beyond the schema's own definitions and does not explain session_id or variant_id behavior.

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?

The description clearly states the specific check performed: whether a product or variant can be bought in a given quantity right now, plus its unit price and total. It is distinct from search_products and get_product by its quantity-and-cost focus, though it does not explicitly name alternatives.

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?

It gives a clear usage trigger: when the customer asks how much several units cost, call it with that qty and use the returned total. It does not explicitly say when not to use it or name sibling alternatives like cart_add or get_product.

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