Skip to main content
Glama

wals.pro AI 4 weclapp

Preview write supply source

preview_write_supply_source
Read-onlyIdempotent

Validate and preview an article's supply source (Bezugsquelle) create or update.

Args: payload: Create requires supplierId (party id) and articleNumber (the SUPPLIER's own SKU, not yours); pricing via price+currency or raw articlePrices. On update, omitted fields carry over from the existing record. article_id: Owning article — the source is always linked into its supplySources[]. supply_source_id: Pass to update; omit to create. set_as_primary: Create defaults True, update False. An article's FIRST supply source is always forced primary. Returns: {ready_for_preview, normalized_payload, warnings[], will_set_as_primary, approval, execution}; ready_for_preview=False with validation_errors on a bad payload. when_to_use: First step of the two-step supply-source write. Field semantics, defaults, and footguns: get_schema(entity="articleSupplySource", detail="payload_guide"). preconditions: article_id must resolve; on update supply_source_id too. post_effects: No mutation; issues a payload-bound approval token. After the user explicitly confirms, call execute_approved with approval.token and execution.payload.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
payloadYes
article_idYes
correlation_idNo
set_as_primaryNo
supply_source_idNo
recovery_approval_tokenNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedInput schema / properties / recovery_approval_token
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "title": "Recovery Approval Token"
      +}
  2. First observed

TDQS

A4.8/5.0
Behavior5/5

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

Goes well beyond the annotations (readOnlyHint/idempotentHint/destructiveHint) by disclosing post_effects ('No mutation; issues a payload-bound approval token'), preconditions (article_id and, on update, supply_source_id must resolve), and non-obvious defaults (create defaults set_as_primary True, update False; the article's FIRST source is always forced primary). These are exactly the behavioral traits an agent cannot infer from structured fields.

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 purpose followed by clearly labeled Args/Returns/when_to_use/preconditions/post_effects blocks; nearly every line adds operational meaning. Minor waste: the Returns block partly duplicates the output schema, and the Args entries restate parameter names before adding value.

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?

For a nested-payload mutation-preview tool this is essentially complete: preconditions, defaults, the two-step approval flow, validation-failure signaling (ready_for_preview=False with validation_errors), and a delegation pointer to get_schema for deep field semantics. Nothing an agent needs to call it correctly is missing.

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 description coverage is 0%, so the description carries the burden, and it does so for the important parameters: payload's required supplierId/articleNumber (with the 'SUPPLIER's own SKU, not yours' footgun), pricing via price+currency vs raw articlePrices, update carry-over semantics, and set_as_primary defaults. It is silent on correlation_id and recovery_approval_token, leaving 2 of 6 parameters unexplained, which keeps it short of a 5.

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+resource pair — validate/preview a supply-source create or update — and the resource is narrow enough ('article's supply source (Bezugsquelle)') to separate it from preview_write_entity, preview_entity_action, and execute_approved. The description makes clear this is a non-mutating validation step, not the write itself.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly positions the tool as the 'First step of the two-step supply-source write' and names the follow-on action ('After the user explicitly confirms, call execute_approved with approval.token and execution.payload'). It also routes to get_schema for field semantics, so both the when and the where-else are covered.

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