Skip to main content
Glama

Cancel a phone number

cancel_phone_number
DestructiveIdempotent

IRREVERSIBLE: Cancel a phone number

Cancels a number bought through the marketplace, with a 30 day grace period: the number is released at the carrier straight away but stays usable on the account until cancelationEndDate, and the record is kept rather than deleted. Only marketplace numbers can be cancelled here; a number that was imported by other means is rejected with 400. Cancelling twice is rejected with 409. This does not refund the setup charge or the month already paid for.

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": {
      "phoneNumberId": "<phoneNumberId>"
    },
    "name": "cancel_phone_number"
  }
}

Input Schema

NameRequiredDescriptionDefault
confirmNoLeave out on the first call. EchoCall then answers with a confirmation value. Ask the user for a clear yes, then repeat the call with the same arguments and this value.
phoneNumberIdYesIdentifier of the phone number.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.4/5.0
Behavior5/5

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

Annotations already flag destructiveHint=true and idempotentHint=true, yet the description adds the details that actually matter: a 30-day grace period, immediate carrier release but continued usability until cancelationEndDate, record retained not deleted, and no refund. That is exactly the beyond-annotations context an agent needs before an irreversible action.

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?

The warning is front-loaded and every sentence carries new information about cost, timing, or failure modes. Minor redundancy in leading with "IRREVERSIBLE" and then restating the tool title, which the agent already has.

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 no output schema, the description covers outcome, timing window, state retention, and error cases, and even hints at the returned cancelationEndDate. Nothing needed to call it safely appears missing.

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 coverage is 100%, and the confirm-echo two-step flow is fully documented in the schema's own parameter description, so the description need not repeat it. The description adds no meaning about phoneNumberId or confirm, so the baseline 3 applies.

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?

Specific verb and resource ("Cancel a phone number") plus a hard scope restriction: "Only marketplace numbers can be cancelled here." The restriction plus the 400/409 rejection cases let an agent separate this from revoke/update siblings without opening another 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 states clearly when the tool applies (marketplace-purchased numbers) and when it fails (imported numbers → 400, already cancelled → 409), which is genuine routing guidance. It stops short of naming an alternative tool for the imported-number case, leaving the agent to infer where those should go.

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.