Skip to main content
Glama

Withdraw from a contract

request_withdrawal
DestructiveIdempotent

Electronic withdrawal (Paragraph 356a BGB), two steps. Step 1: withdrawal = {order_id (ord_...) or order_number, buyer: {email, name (optional)}, statement (optional)} returns a summary with a request id (wrq_..., valid 30 min) and expires_at; nothing is declared and the shop is not contacted yet. Step 2, only after the buyer explicitly confirmed: withdrawal_id = wrq_... + confirm = true declares the withdrawal; the result carries the reference (wdr_...) and received_at (receipt confirmation), and the shop sends a confirmation of receipt by e-mail. Works even while ordering is paused (consumer right). meta.idempotency-key is required.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "request_withdrawal"
  }
}

Input Schema

NameRequiredDescriptionDefault
metaNo
confirmNoStep 2: true, only after the buyer explicitly confirmed.
withdrawalNoStep 1: {order_id | order_number, buyer: {email, name?}, statement?}.
order_tokenNoOptional order token from complete_checkout.
withdrawal_idNoStep 2: request id (wrq_...) from step 1.

Output Schema

NameRequiredDescriptionDefault
ucpYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.5/5.0
Behavior5/5

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

Beyond the destructive/idempotent annotations, it discloses that step 1 declares nothing and does not contact the shop, that the request id expires after 30 minutes, that the shop sends an e-mail confirmation of receipt, and that an idempotency key is mandatory. These are exactly the side-effect and timing details an agent cannot get from the annotations.

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?

Content is front-loaded with the two-step split and every clause carries information (validity window, prefixes, e-mail receipt, ordering-pause behavior). The long semicolon-chained sentences are dense and would read better as separated step bullets, but nothing is redundant.

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 two-phase, nested-object mutation with an output schema, the definition covers preconditions, side effects, identifier lifecycles, and result markers. An agent has everything needed to run the flow correctly without consulting anything else.

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?

The description supplies identifier formats (ord_..., wrq_..., wdr_) and clarifies which parameters belong to which step, including that confirm is only for step 2 and that meta.idempotency-key is required despite no required fields in the schema. This meaningfully extends the 80% schema coverage.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The definition names a specific legal action (electronic withdrawal under Paragraph 356a BGB) and lays out the two-step mechanism, so an agent immediately knows this is not a generic cancel/update operation. It never explicitly contrasts itself with siblings such as cancel_cart or cancel_checkout, leaving the boundary to be inferred from the 'consumer right' framing.

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?

Sequencing guidance is explicit: step 1 is a non-binding preview, step 2 requires 'confirm = true' only 'after the buyer explicitly confirmed'. It also flags that the tool works while ordering is paused. It stops short of naming which sibling to use when the buyer merely wants to cancel a cart or checkout.

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