Skip to main content
Glama

request_refund

Request a manual refund review for a failed AI service payment. Provides a 48-hour ticket and operator notification for errors, timeouts, or wrong outputs.

Instructions

Open a MANUAL 48-hour refund review ticket for a service that FAILED (error, timeout, wrong output). Sends an email to the operator. DO NOT call this for unused-minute refunds on metered services (ai_call, voice_bridge) — those are returned automatically as an LNURL-withdraw link in the service's own response under refund.lnurl_withdraw, no manual ticket needed. If you call this on a metered payment that already has a pending LNURL refund, this tool will detect it and return the existing LNURL instead of creating a duplicate ticket.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
paymentIdYesThe payment ID from a failed service call
invoiceYesLightning address (e.g., user@wallet.com) or bolt11 invoice for the refund
emailNoOptional email address for follow-up
feedbackNoOptional description of what went wrong (max 2000 chars)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.6/5.0
Behavior5/5

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

No annotations are provided, so the description carries the full burden. It discloses that the tool sends an email to the operator, has a 48-hour review period, and detects pending LNURL refunds to avoid duplicates, offering thorough behavioral context.

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 description is concise and front-loaded with the main purpose in the first sentence. The remaining sentences add crucial usage guidelines and behavioral quirks without redundancy, but could be slightly more structured.

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?

Given no output schema and no annotations, the description provides comprehensive context: purpose, usage boundaries, alternative options, and unexpected behavior (duplicate detection). It fully equips the agent to use the tool correctly.

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 the schema already documents all four parameters fully. The description does not add new parameter-level meaning beyond what the schema provides, thus baseline score of 3 is 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 clearly states the tool opens a manual 48-hour refund review ticket for failed services, specifying the action and resource. It distinguishes from metered service refunds, providing clarity on scope.

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?

Explicitly states when to use (for failed services with error/timeout/wrong output) and when not to use (unused-minute refunds on metered services). Provides clear alternative: the LNURL withdraw link from the service's response, and explains duplicate detection behavior.

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