Skip to main content
Glama

Cancel a booking

cancel_booking
DestructiveIdempotent

Cancel one of the traveler's Roomza bookings, inside its free-cancellation window only, with a full refund. Call it first without confirm: it says what would happen and changes nothing. Tell the traveler, and only after they agree call it again with confirm set to true. Outside the window it refuses and points the traveler to Roomza support. Requires connecting your Roomza account.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "booking_id": "<booking_id>"
    },
    "name": "cancel_booking"
  }
}

Input Schema

NameRequiredDescriptionDefault
confirmNotrue only after the traveler agrees
booking_idYesThe booking to cancel

Output Schema

NameRequiredDescriptionDefault
okYes
doneYesTrue once the booking is canceled; false for a preview or a refusal
messageYes
currencyYes
refundedYes
bookingIdYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.7/5.0
Behavior4/5

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

Annotations already flag destructive=true, idempotent=true and openWorldHint=true, and the description adds substantial context on top: the first call is a no-op preview, the operation is refund-bearing, it refuses outside the cancellation window, and it requires a connected Roomza account. It does not discuss partial failures or what the preview response contains, but the output schema covers returns.

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?

Five short sentences, front-loaded with the action and its constraint, then the call protocol, then the failure path and prerequisite. Nothing is redundant with the title or schema.

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 destructive, two-parameter mutation with an output schema, the description covers the safety protocol, the refund outcome, the refusal case, and the auth prerequisite. An agent has everything needed to invoke it correctly without guessing.

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 100%, so the baseline is 3, but the description adds workflow meaning to confirm beyond the schema's 'true only after the traveler agrees' by specifying the preview-then-confirm sequence. booking_id is only implicitly scoped to the traveler's own bookings, which is a small extra.

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 ('Cancel one of the traveler's Roomza bookings') plus the governing constraint (inside the free-cancellation window, full refund). No sibling tool cancels bookings, and the description makes the scope unmistakable.

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?

Gives an explicit two-step protocol: call first without confirm to preview, tell the traveler, then call again with confirm=true only after agreement. It also names the fallback path (Roomza support) for the out-of-window case, so the agent knows both when to use it and when it will not work.

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