Skip to main content
Glama

Cancel booking

cancel_booking
DestructiveIdempotent

Gives an unpaid hold up at once (nothing was charged), or cancels a confirmed booking with a refundable rate; the refund follows the rate terms and goes back to the card through Nuitee. Non-refundable rates cannot be cancelled online. Only call this when the guest asked for it. Needs the booking_secret; with the key that made it, the guest email works too.

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
booking_idYesbooking_id from prebook.
guest_emailNoWith the key that made the booking: the guest email used for it.
booking_secretNobooking_secret from prebook.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed6 schema fields changed
    • addedInput schema / properties / booking_id / maxLength
      Added value: +40
    • addedInput schema / properties / booking_id / minLength
      Added value: +1
    • addedInput schema / properties / booking_secret
      Added value: +{
      +  "description": "booking_secret from prebook.",
      +  "maxLength": 200,
      +  "minLength": 8,
      +  "type": "string"
      +}
    • changedInput schema / properties / guest_email / description
      Previous value: -"The guest email used for the booking."New value: +"With the key that made the booking: the guest email used for it."
    • addedInput schema / properties / guest_email / maxLength
      Added value: +200
    • changedInput schema / required
      Previous value: -[
      -  "booking_id",
      -  "guest_email"
      -]New value: +[
      +  "booking_id"
      +]
  2. First observed

TDQS

A4.6/5.0
Behavior5/5

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

Beyond the destructiveHint and idempotentHint annotations, it discloses the refund path (back to the card through Nuitee), that the refund follows the rate terms, and that unpaid holds are released with nothing charged. It also explains the credential model for authentication, which annotations do not cover at all.

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?

Three sentences, each carrying a distinct fact: the two cancellation modes, the refund mechanics and constraints, and the call precondition plus credentials. The most decision-relevant content (what happens per booking state) is front-loaded with no filler.

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?

With no output schema, the description covers outcomes well (hold release, refund routing, ineligible cases), so an agent knows what effect to expect. It leaves out what is returned or how long a refund takes, a small gap for a mutation tool with no response documentation.

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 already 100%, so the baseline would be 3. The description adds real meaning by explaining the either/or relationship between booking_secret and the guest email-plus-key combination, which the schema field descriptions only hint at.

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 names a specific verb and resource and splits the operation by booking state: releasing an unpaid hold at once versus cancelling a confirmed booking on a refundable rate. That distinction, plus the statement that non-refundable rates cannot be cancelled online, lets an agent tell this apart from siblings like get_booking or list_bookings without opening a schema.

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?

It gives an explicit precondition ('Only call this when the guest asked for it') and a clear exclusion for non-refundable rates, which is strong guidance for a destructive tool. It stops short of naming an alternative route for non-refundable bookings, so the agent has to work out what to do instead.

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