Skip to main content
Glama
botwallet-co

BotWallet MCP Server

botwallet_cancel_paylink

Cancel a pending payment request before it is paid or expires. Use this tool to stop payment processing by providing the request ID.

Instructions

Cancel a pending payment request. Only pending paylinks can be cancelled — paid or expired paylinks cannot.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
request_idYesPayment request ID to cancel

Implementation Reference

  • The handler function for botwallet_cancel_paylink which calls ctx.sdk.cancelPaymentRequest.
    async handler(args, ctx) {
      try {
        const { request_id } = args as { request_id: string };
        const result = await ctx.sdk.cancelPaymentRequest({ request_id });
        return formatResult(result);
      } catch (e) {
        return formatToolError(e);
      }
    },
  • Input schema definition for botwallet_cancel_paylink.
    inputSchema: z.object({
      request_id: z.string().describe('Payment request ID to cancel'),
    }),
  • The full ToolDefinition for botwallet_cancel_paylink.
    const cancelPaylink: ToolDefinition = {
      name: 'botwallet_cancel_paylink',
      description: 'Cancel a pending payment request. Only pending paylinks can be cancelled — paid or expired paylinks cannot.',
      inputSchema: z.object({
        request_id: z.string().describe('Payment request ID to cancel'),
      }),
      async handler(args, ctx) {
        try {
          const { request_id } = args as { request_id: string };
          const result = await ctx.sdk.cancelPaymentRequest({ request_id });
          return formatResult(result);
        } catch (e) {
          return formatToolError(e);
        }
      },
    };
Behavior3/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It effectively communicates the precondition (only pending paylinks are cancellable) and implies a mutation action ('Cancel'), but lacks details on permissions, rate limits, error conditions, or what happens upon cancellation. It adds some context but is incomplete for a mutation tool.

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 description is two sentences with zero waste—the first states the purpose, and the second provides critical usage constraints. It is front-loaded with essential information and appropriately sized for the tool's complexity.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given no annotations and no output schema, the description is incomplete for a mutation tool. It covers the purpose and usage constraints well but lacks details on behavioral aspects like permissions, side effects, or return values. However, it is adequate for basic understanding, aligning with a minimum viable score.

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%, with the parameter 'request_id' well-documented in the schema. The description does not add any additional meaning or clarification about the parameter beyond what the schema provides, so it meets the baseline score of 3 for high schema coverage.

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 clearly states the specific action ('Cancel') and resource ('a pending payment request'), distinguishing it from siblings like botwallet_cancel_payment (which likely cancels a different type of payment) and botwallet_get_paylink (which retrieves information). It precisely defines the tool's function without being tautological.

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?

The description explicitly states when to use this tool ('Only pending paylinks can be cancelled') and when not to use it ('paid or expired paylinks cannot'), providing clear context and exclusions. This directly addresses usage scenarios without needing to reference alternatives.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/botwallet-co/mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server