Skip to main content
Glama

ERP: Stock recount

erp_stock_recount
Destructive

Set the stock of ONE catalog item to what was actually counted (a stocktake / «перерахував, є 14»): 'quantity' is the counted amount in the item's base unit. 'item' and 'warehouse' as in erp_stock_adjust (several matches → refused with candidates; ask, never guess). 'reason' goes to the stock history. Proposed write: the person confirms a line naming the item, the warehouse and before → after. CONFIRMATION: this tool is PROPOSED, never performed directly. You get status='confirmation_required' with an action_id and a plan_token, and the write happens only after confirm_action.

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": {
      "item": "<item>",
      "quantity": "<quantity>"
    },
    "name": "erp_stock_recount"
  }
}

Input Schema

NameRequiredDescriptionDefault
itemYes
reasonNo
quantityYes
warehouseNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.7/5.0
Behavior5/5

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

Annotations declare a destructive write, and the description goes well beyond them: it discloses that nothing is performed directly, that a 'confirmation_required' status with action_id and plan_token is returned, and that the actual write only occurs in confirm_action. It also reveals the confirmation line shows before → after, so the agent understands prior stock is overwritten, and it explains the refusal-with-candidates 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?

Front-loaded with the core action, then matching rules, then the confirmation protocol — a logical order with little waste. The parenthetical user-phrase example and the mixed-language quote are slightly noisy, but they plausibly aid recognition of real user requests.

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?

There is no output schema, yet the description conveys the response shape (status='confirmation_required', action_id, plan_token) and the two-step write lifecycle, plus failure behavior on ambiguous matches. Nothing an agent needs in order to invoke and follow through correctly is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 0%, so the description must carry the load and it does: 'quantity' is the counted amount in the item's base unit, 'reason' is written to stock history, and 'item'/'warehouse' follow the matcher semantics of erp_stock_adjust including the ambiguous-match refusal. All four parameters gain meaning not present in the bare 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?

States a precise verb and resource (set the stock of ONE catalog item to the counted amount) and frames it as a stocktake, which separates it from a delta-style adjustment. The reference to erp_stock_adjust anchors the contrast without requiring the sibling schema to be opened.

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?

Gives clear operating guidance: the counted amount is absolute, ambiguous item/warehouse matches are refused with candidates and must be asked about, never guessed. It also spells out the required confirmation path. It does not explicitly state when to prefer erp_stock_adjust over a recount, so it stops short of full alternative-routing guidance.

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