# Hermoso: refund_woocommerce_order · Hermoso developer docs

> Machine-readable twin of https://hermoso.ai/docs/reference/workspace/refund_woocommerce_order/. Generated from the shipped page. Do not edit by hand.
> Full agent guide: https://hermoso.ai/llms.txt · MCP: https://app.hermoso.ai/mcp

[Docs](https://hermoso.ai/docs/) / [Tool reference](https://hermoso.ai/docs/reference/) / [Workspace & account](https://hermoso.ai/docs/reference/workspace/) / refund_woocommerce_order

# `refund_woocommerce_order`

Refund a WooCommerce order destructive

Area: WooCommerce · [Workspace & account](https://hermoso.ai/docs/reference/workspace/). Generated from the running MCP server, like the rest of the [tool reference](https://hermoso.ai/docs/reference/).

## Description

Refund a WooCommerce order: full:true (everything still refundable), lineItems [{ lineItemId, quantity }] and/or amount (a sum of money, e.g. a goodwill refund). By default the money goes back through the order's payment gateway; apiRefund:false only RECORDS the refund in WooCommerce, for money returned by hand (an order paid by bank transfer, cheque or cash on delivery can only be recorded). Refunded items go back into stock unless restock:false. Without confirm:true NOTHING is refunded and the reply shows the amount: show the user, get a yes, then call again with confirm:true and confirmAmount set to that exact amount. Retrying the same confirmed refund never refunds twice. Free.

## Parameters

Parameter Type Description

`id` required `string` the order number

`full` `boolean`

`lineItems` `object[]`

`lineItems[].lineItemId` required `string` the line id from list_woocommerce_orders with id, or its SKU

`lineItems[].quantity` `number`

`amount` `string` refund this much money instead, e.g. "10.00"

`reason` `string`

`apiRefund` `boolean` default true: through the payment gateway

`restock` `boolean` default true for refunded lines

`confirm` `boolean`

`confirmAmount` `string` the amount the preview showed

`idempotencyKey` `string` only to repeat an identical refund on purpose: any new text

## Example call

Every required parameter is shown, filled from the schema where it gives a value and otherwise with a placeholder naming the type. Replace the placeholders with real values. The same call works on the MCP server, the CLI and `POST https://app.hermoso.ai/v1/tools/refund_woocommerce_order`.

**MCP** (`tools/call`)

`{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"refund_woocommerce_order","arguments":{"id":"<string>"}}}`
**CLI**

`hermoso call refund_woocommerce_order --json '{"id":"<string>"}'`

## Credits

Credits are spent only on two things: running an AI model (image, video, voice, text, planning, post-production) and Ad Spy research. See [Credits & costs](https://hermoso.ai/docs/credits/).

## Related tools

- [update_woocommerce_order](https://hermoso.ai/docs/reference/workspace/update_woocommerce_order/) Update a WooCommerce order
- [get_woocommerce_stock](https://hermoso.ai/docs/reference/workspace/get_woocommerce_stock/) Get WooCommerce stock
- [list_woocommerce_orders](https://hermoso.ai/docs/reference/workspace/list_woocommerce_orders/) List WooCommerce orders
- [set_woocommerce_stock](https://hermoso.ai/docs/reference/workspace/set_woocommerce_stock/) Set or adjust WooCommerce stock

[All 143 Workspace & account tools](https://hermoso.ai/docs/reference/workspace/) · [tools.json](https://hermoso.ai/docs/reference/tools.json)
