Skip to main content
Glama
mcp-server-razorpay

mcp-server-razorpay

by bugmagnet28

Create Refund

create_refund

Issue a full or partial refund for a Razorpay payment; omit the amount to refund the full payment.

Instructions

Create a full or partial refund for a Razorpay payment. Omit amount for full refund.

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": {
      "payment_id": "<payment_id>"
    },
    "name": "create_refund"
  }
}

Input Schema

NameRequiredDescriptionDefault
notesNo
speedNoRefund speed: normal (5-7 days) or optimum (instant if eligible)normal
amountNoAmount in paise to refund (omit for full refund)
receiptNoYour internal receipt reference
payment_idYesPayment ID to refund

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

B3.1/5.0
Behavior2/5

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

No annotations are supplied, so the description carries the full behavioral burden, and it discloses almost nothing: it does not say refunds are irreversible financial mutations, whether partial refunds can be repeated up to the original amount, what eligibility conditions apply, or what the caller gets back. For a money-moving write tool with zero annotation coverage this is a significant gap.

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?

Two short sentences, front-loaded with the operation and resource, with no filler. Minor deduction because the second sentence restates what the schema already says about omitting amount.

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

Completeness2/5

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

With five parameters, nested notes, an enum speed field, no annotations, and no output schema, the description should explain the mutation's consequences and return shape. It says nothing about irreversibility, expected response fields, or error conditions, leaving the agent under-informed for a financial write.

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 80%, so the schema already explains amount, speed, receipt, notes, and payment_id. The description's only parameter-related statement ('omit amount for full refund') duplicates the amount field's own description rather than adding meaning, so it lands at the high-coverage baseline.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ('Create a full or partial refund') scoped to 'a Razorpay payment', so the operation is unambiguous and distinct from fetch_refund or list_refunds_for_payment. It does not explicitly name a sibling to contrast with, so it stops short of a 5.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The one operational rule given is 'Omit amount for full refund,' which is usage guidance for a single case. There is no guidance on prerequisites (payment must be captured/paid), when a refund is refused, or how this relates to fetch_refund/list_refunds_for_payment, so usage must be inferred.

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