Skip to main content
Glama

applica_aggiornamento_prezzi

Writes approved new prices directly to the database, updates the WooCommerce lookup table, and invalidates site cache so correct prices appear online.

Instructions

Scrive i nuovi prezzi (lista approvata, stessa forma dell'output di calcola_aggiornamento_prezzi: ogni elemento serve id e prezzo_regolare_nuovo). Scrittura diretta sul DB, aggiorna anche la lookup table di WooCommerce, e invalida la cache del sito (altrimenti il prezzo nuovo non si vedrebbe online pur essendo corretto nel DB).

Input Schema

NameRequiredDescriptionDefault
aggiornamentiYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.3/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does substantial work: it discloses that this writes directly to the DB, also touches the WooCommerce lookup table, and invalidates the site cache, including the reason ('altrimenti il prezzo nuovo non si vedrebbe online'). It omits permissions, atomicity/partial-failure behavior, and reversibility, which keeps it below a 5 for a mutation tool.

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 write action and the input requirement are front-loaded, and the parenthetical on cache invalidation earns its place by explaining non-obvious side-effect behavior. The nested parentheses in the first clause make the opening slightly harder to parse than ideal.

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 mutation tool with no annotations and no output schema, this covers the critical operational facts an agent needs: input shape, downstream WooCommerce propagation, and cache consequences. Missing only failure/rollback semantics and what the call returns on success or partial failure.

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?

Schema coverage is 0% and the single parameter is an untyped array with additionalProperties, so the description must compensate — and it does by naming the required per-element keys `id` and `prezzo_regolare_nuovo` and by pointing to calcola_aggiornamento_prezzi as the canonical shape. It still leaves element types and number formatting unspecified.

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 specific verb and resource ('scrive i nuovi prezzi') and ties the input to the output of the sibling calcola_aggiornamento_prezzi, so the agent can tell it apart from that calculator and from the cache-purge tool without opening any schema. The scope (direct DB write plus WooCommerce lookup and cache invalidation) is concrete and unambiguous.

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?

The description establishes the pipeline: the argument must be the approved list produced by calcola_aggiornamento_prezzi, which implies calculate-then-approve-then-apply. It does not state explicit exclusions (e.g. when to prefer prepara_modifica_prezzo_prodotto instead), so it falls short of a full when/when-not statement.

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