Skip to main content
Glama

⚠️ Stock: update

stock_update_stocks
Destructive

Update stock quantities for Avito listings. Set quantity to zero to mark items as out of stock and unavailable for order.

Instructions

⚠️ Updates the stock (quantity) of items across listings in the warehouse (update_stocks). Affects whether listings are available to order: quantity=0 marks a listing as "out of stock". Accepts an array of {item_id, quantity, external_id?}; quantity is an integer 0..999999. Returns success and errors for each listing. For current stock, use stock_get_stocks_info.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
dryRunNov0.7.0: if true — returns a preview of the HTTP request without calling the Avito API. Safe for inspecting exactly what would be done. Default: the value of AVITO_MCP_DRY_RUN_DEFAULT (usually false).
stocksYesArray of stock entries per listing; from 1 to 200 elements per request.
idempotencyKeyNov0.7.0: optional key for duplicate protection. A repeat call with the same key within AVITO_MCP_IDEMPOTENCY_TTL_SEC returns the cached result. The same key with different args returns a conflict error. Keys are stored as bounded SHA-256 fingerprints.
Behavior4/5

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

Annotations already indicate destructiveHint: true and readOnlyHint: false. Description adds behavioral context: 'Affects whether listings are available to order: quantity=0 marks a listing as out of stock.' Explains consequence of setting quantity to 0. No contradiction with annotations.

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?

Two sentences plus two short clarifications. Front-loaded with key action and effect. No unnecessary words. Perfectly concise.

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?

Tool has no output schema, but description mentions 'Returns success and errors for each listing.' Covers main parameters. Could detail idempotencyKey/dryRun but schema does. Adequate for a destructive mutation with 3 parameters and no nested objects.

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 coverage is 100%, so baseline is 3. Description adds minimal value beyond schema: summarizes parameters (item_id, quantity, external_id?) and constraint (quantity 0..999999). Reinforces quantity=0 meaning but schema already describes it.

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?

Description clearly states 'Updates the stock (quantity) of items across listings in the warehouse.' Verb 'updates' plus resource 'stock' and scope 'items across listings' make purpose explicit. Distinguishes from sibling tool stock_get_stocks_info by explicitly referencing it for current stock.

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?

Explicitly states when to use alternative: 'For current stock, use stock_get_stocks_info.' Also implies use for setting stock levels and explains effect of quantity=0. No explicit when-not-to-use, but guidance is strong.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/elchin92/avito-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server