refund_invoice
Process refunds for BTCPay invoices with flexible calculation methods including rate-based, fiat amount, or overpayment options.
Instructions
Refund a BTCPay invoice.
Args: invoice_id: The invoice ID to refund. refund_variant: Refund calculation method. Options: 'RateThen' (use rate at time of invoice, default), 'CurrentRate', 'Fiat' (refund exact fiat amount), 'OverpaidAmount' (refund only overpayment). payout_method_id: Optional payout method ID for the refund destination. subtract_percentage: Percentage to subtract from refund (0-100). Default: 0.
Returns the refund result with pull payment ID and amount.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| invoice_id | Yes | ||
| refund_variant | No | RateThen | |
| payout_method_id | No | ||
| subtract_percentage | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |