Skip to main content
Glama

grocy_stock_product_by_barcode

Read-only

Retrieves stock details for a product by barcode to check current inventory levels in a Grocy instance.

Instructions

Stock details of a product by barcode. GET /api/stock/products/by-barcode/{barcode}.

Input Schema

NameRequiredDescriptionDefault
barcodeYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

C2.4/5.0
Behavior2/5

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

Annotations already declare readOnlyHint=true, destructiveHint=false and openWorldHint=true, so the safety profile is covered. The description adds only the raw endpoint path, which is implementation detail rather than behavior — it says nothing about what happens when the barcode is unknown, whether it scans external sources (relevant given openWorldHint), or what shape the response takes.

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 short sentences, front-loaded with the purpose and with zero filler. It is efficient, though the second sentence spends space on an endpoint path rather than on information the agent lacks.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

There is no output schema, so the description is the only place an agent could learn what 'stock details' comprises (amounts, best-before, location, price). With one undocumented parameter and no return-value context, the definition is under-specified for anything beyond a name-based guess.

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 coverage is 0%, so the description carries the full burden for the single required parameter, yet it only restates the name 'barcode' via the URL template. It gives no format guidance (EAN/UPC/GTIN, scannable code vs. internal product barcode) or hint about what a valid value looks like.

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

Purpose3/5

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

The description names the resource (stock details of a product) and the selector (by barcode), so the core action is recoverable. However, "stock details" is vague about what is returned, and nothing distinguishes it from the sibling grocy_barcode_lookup or grocy_stock_product, both of which plausibly overlap.

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?

There is no statement of when to use this tool versus grocy_barcode_lookup (which likely also resolves barcodes) or grocy_stock_product (which likely fetches the same data by product id). The agent is left to infer routing from tool names alone.

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