Skip to main content
Glama
AmitGurbani

mcp-server-woocommerce

by AmitGurbani

create_order_refund

Create refunds for WooCommerce orders, full or partial, with automatic payment gateway processing or manual refunds.

Instructions

Create a refund for an order. Can refund full or partial amount. Set api_refund=true (default) to automatically refund via payment gateway, or false for manual refund.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
amountNoRefund amount (omit to refund full order total)
fieldsNoComma-separated fields to return in response
reasonNoReason for the refund
order_idYesOrder ID
api_refundNoAutomatically refund via payment gateway (default: true)
line_itemsNoSpecific line items to refund
Behavior4/5

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

With only openWorldHint=false in annotations, the description carries the burden of disclosing behavior. It accurately discloses that a refund is created and explains the automatic/manual behavior of api_refund. It omits potential side effects (e.g., order status changes), but the core behavior is transparent and non-contradictory.

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 three sentences long, front-loaded with the primary purpose, and every sentence adds value (purpose, amount flexibility, api_refund behavior). There is no redundancy or fluff, making it highly concise and well-structured.

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?

For a creation tool with 6 params, 1 required, and no output schema, the description covers the core functionality: what it does, amount scope, and the key api_refund option. While it lacks explicit mentions of prerequisites or side effects, the schema fully documents parameters and the description adds behavioral context, making it adequately complete for the tool's complexity.

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%, so the baseline is 3. The description reinforces the meaning of amount ('full or partial') and api_refund (automatic vs manual), but these are already documented in the schema. It adds minimal new information beyond the schema, so a 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's function: 'Create a refund for an order.' It distinguishes from sibling tools like delete_order_refund and list_order_refunds by focusing on creation. It also specifies key capabilities (full/partial amount) and a distinguishing feature (api_refund toggle), making the purpose unambiguous.

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?

The description provides context for usage: it explains how to perform a full or partial refund and how to choose between automatic and manual refunds via the api_refund flag. It doesn't explicitly name alternatives or exclusions, but the usage context is clear and practical.

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/AmitGurbani/mcp-server-woocommerce'

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