InvoicesPayments and statements

Record a refund

POST
/v1/customers/{id}/refunds

Records money handed back out of credit this customer holds with you. Refused when it is more than they have. ResellerHQ does not collect payment from your customers: you take the money however you already do, and record it here. Send an Idempotency-Key header so a retry can never record the refund twice.

Authorization

apiKey
headerAuthorizationBearer <token>

An API key from the Developers page. rhq_test_ keys reach the sandbox, rhq_live_ keys the live side.

Path Parameters

id*string

Header Parameters

Idempotency-Key?string

A value unique to this request, such as a UUID. A retry with the same key within 24 hours returns the first outcome instead of running again.

Length8 <= length <= 200

Request Body

application/json
  1. body
amount*integer
Range0 < value
currency*string

ISO 4217 currency code

Value in"USD""EUR""GBP""CAD""AUD""NZD""CHF""SEK""NOK""DKK""PLN""INR""SGD""HKD""AED""ZAR""BRL""MXN"
method*string

How the money moved, outside this platform

Value in"bank_transfer""cash""card""other"
reference?string
Length1 <= length <= 200

Response Body

Created

application/json
  1. response

Created

id*string
number*string

Counts up from RFD-0001 across your account, with no gaps

customerId*string
amount*integer

Minor units of the invoice's currency

Range0 <= value
currency*string

ISO 4217 currency code

Value in"USD""EUR""GBP""CAD""AUD""NZD""CHF""SEK""NOK""DKK""PLN""INR""SGD""HKD""AED""ZAR""BRL""MXN"
method*string

How the money moved, outside this platform

Value in"bank_transfer""cash""card""other"
reference*string|null
createdAt*string
Formatdate-time
curl -X POST "https://example.com/v1/customers/cus_01K6XJ4Q8ZT3M9R5V2B7WDHNCA/refunds" \  -H "Idempotency-Key: 2f1c9a52-7d0e-4a8e-9a53-0c1f6f3f2b11" \  -H "Content-Type: application/json" \  -d '{    "amount": 500,    "currency": "USD",    "method": "bank_transfer"  }'
{  "id": "rfd_01K6XJ4Q8ZT3M9R5V2B7WDHNCA",  "number": "RFD-0001",  "customerId": "cus_01K6XJ4Q8ZT3M9R5V2B7WDHNCA",  "amount": 2878,  "currency": "USD",  "method": "bank_transfer",  "reference": null,  "createdAt": "2026-10-07T11:04:31.000Z"}