Skip to main content
Glama

stock_history

Retrieve recent stock journal entries for purchases, usage, openings, and corrections. Filter by product and time range to verify amounts or locate transaction IDs for reversal.

Instructions

What has been bought, used, opened or corrected recently.

Grocy's stock journal, newest first. Use it to answer "what did we get through this week", to check a suspicious amount, or to find the transaction_id of something that needs undoing.

Args: days: How far back to look. Defaults to a month. product: Optional — restrict to one product. limit: Maximum rows returned, newest first. Defaults to 100.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
daysNo
limitNo
productNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.4/5.0
Behavior4/5

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

With no annotations, the description carries the behavioral disclosure burden. It communicates read-only journal semantics, newest-first ordering, and the availability of transaction_id in results. It does not fully describe the response structure, but for a simple query tool this is adequate.

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?

The description is compact and well-structured: purpose first, then use cases, then parameter descriptions. Every sentence contributes value and nothing is redundant with the schema.

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 tool with no output schema and no annotations, it explains what the tool returns conceptually, when to use it, how results are ordered, and all parameter meanings. Minor gaps remain around exact return fields and product value format, but no major behavior is hidden.

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?

The input schema has 0% description coverage, so the description must define the parameters itself. It explains days as a lookback window, product as an optional filter, and limit as a row cap with newest-first ordering. It could specify whether product expects an ID or name, but the essentials are covered.

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 opens with a specific verb and resource: it is the stock journal showing what has been bought, used, opened, or corrected. It clearly establishes this as a historical audit tool, distinguishable from siblings like list_stock and consume_product.

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?

Concrete usage contexts are provided: answering 'what did we get through this week', investigating suspicious amounts, and locating transaction_ids for undo operations. It does not explicitly name sibling alternatives or give when-not-to-use guidance, but the intended scenarios are clear.

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