Skip to main content
Glama

Issue refund

issue_refund
DestructiveIdempotent

Refund a customer's ticket charge through the billing provider after confirmation. Safe to retry; each ticket and charge is refunded at most once.

Instructions

Refund a customer's charge for a ticket through the billing provider, after the user confirms. Safe to retry: one ticket and charge are refunded at most once. Amounts are in cents.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
charge_idYesFrom get_customer, e.g. ch_8812
ticket_idYes
amount_centsYese.g. 4900 for $49.00

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
refund_idYes
amount_centsYes
idempotency_keyYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A4.1/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=false, destructiveHint=true, idempotentHint=true, and openWorldHint=true, so the safety profile is covered structurally. The description nonetheless adds two pieces of real context: the confirmation requirement and the at-most-once refund guarantee per ticket/charge pair, which reinforces (and does not contradict) idempotentHint.

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?

Three short sentences, front-loaded with the action, followed by the idempotency guarantee and the unit convention. Every sentence carries information, though "through the billing provider" is closer to implementation detail than decision-relevant content.

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?

An output schema exists, so return values need not be explained, and annotations carry the mutation/destructiveness profile. The description covers the action, precondition, retry semantics, and amount units; only failure modes (e.g. already-refunded or invalid charge) are left unaddressed.

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 67% — charge_id and amount_cents are documented in the schema, ticket_id is not. The description's "Amounts are in cents" restates the unit already conveyed by amount_cents' example (4900 for $49.00), so it adds little beyond the schema. Baseline 3 is appropriate given the schema does most of the work.

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 (refund) and resource (a customer's charge for a ticket), and clarifies the path taken (through the billing provider). No sibling tool overlaps with refunding, so there is no ambiguity to resolve against search_tickets, get_ticket, get_customer, export_tickets, or add_internal_note.

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?

"After the user confirms" gives a clear precondition for invocation, which is exactly the kind of guidance an agent needs before calling an irreversible-feeling money operation. It stops short of naming any alternative or when-not-to-use condition, so it does not reach a full 5.

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