Commerce
refundPayment
Refund Payment
Refund ONE settled payment (a paymentId from listPayments) back to the payer's card: in full, or a partial amountMinor.
Arguments
amountMinorintegeroptionalPartial refund in minor units (cents), e.g. 3500 = $35.00. Omit to refund everything still refundable.confirmbooleanrequiredMust be true: a refund moves money out and cannot be undone. Pass only after the user explicitly agrees to this refund.idempotencyKeystringrequiredYour key for THIS refund request. Reuse it to retry safely; use a new one for a new refund.paymentIdstringrequiredThe paymentId to refund (from listPayments).reasonstringoptionalWhy the money is going back. Kept on the ledger line.
Returns
Idempotent per idempotencyKey: reuse the SAME key when retrying one refund (the retry returns the refund already made), and a NEW key for a genuinely new refund.
Declared limits
amountMinor: greater than 0amountMinor: maximum 9007199254740991idempotencyKey: minimum length 1idempotencyKey: maximum length 200reason: maximum length 500
Ask for it
The Cloud routes these requests to this verb.
- refund that $70 payment
- give Heidi her money back
- refund half of the booking
Pair it with
The verbs that finish the job.