Create the refund
Create it withPOST /refunds. Name the intent, and set amountMinor for a partial refund or omit it to refund everything still refundable.
cURL
Watch the refund
Read it withGET /refunds/{refundId}. A finished refund reads succeeded or processedAs.
When a refund is refused
refund_payment_not_refundable: the intent has no succeeded card payment.refund_amount_exceeds_refundable: the amount is more than what remains.refund_in_progress: another refund of this payment is still pending. The error names it inpendingRefundId; wait for it to finish.refund_chargeback_open: the payer disputed the payment, so it cannot be refunded.refund_funds_unavailable: your wallet balance cannot cover the amount. Deposit funds and retry.
List refunds
GET /refunds lists your refunds newest first. Filter by paymentIntentId to see every refund of one payment.
cURL