Skip to main content
Glama

Cancel order

o2c_cancel_order
Destructive

Cancel an order that has not shipped. Once anything has shipped the order cannot be cancelled — bill it and issue a credit instead. Cancellation is not a way to make a mistake disappear; the order stays visible as cancelled. Effects: order.status -> cancelled; committed value released.

Input Schema

NameRequiredDescriptionDefault
reasonYesWhy it was cancelled. Kept as pattern memory.
order_idYesThe order. An existing order id.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.5/5.0
Behavior4/5

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

Annotations already declare destructive=true and idempotent=false, so the safety profile is known. The description adds meaningful behavior beyond that: the status becomes cancelled, committed value is released, and the cancellation remains visible rather than erasing the order. It does not cover permissions, reversal behavior, or response details, which keeps it from a 5.

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?

The eligibility condition is front-loaded, followed by the alternative path and the state effects. Every sentence contributes operational guidance without repeating schema or annotation details.

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-parameter destructive mutation with full schema coverage and no output schema, the description covers the key decision criteria and state effects. It gives the agent enough to decide correctly between cancelling, billing, and crediting.

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 description coverage is 100%, so both order_id and reason are already documented in the schema. The description adds no additional parameter-level meaning, making the baseline 3 appropriate.

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?

The description gives a specific verb and resource ("Cancel an order") and immediately qualifies the eligible state ("that has not shipped"). It distinguishes this action from the shipped-order path by naming the alternative: bill it and issue a credit.

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?

It explicitly states when the tool applies and when it does not: once anything has shipped, the order cannot be cancelled. It also names the correct alternative in that case, so the agent does not have to infer routing from sibling names.

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.