Sample - Stripe API
POST/v1/payment_records/{id}/report_refund

Report a refund

Report that the most recent payment attempt on the specified Payment Record was refunded.

  • RetriesRetries up to 2×, 500ms backoff, 30s timeout.
  • IdempotentThe SDK sends Idempotency-Key, so a retried request is only applied once.

1 parameter · 7 body fields
idstringrequired
The ID of the Payment Record.
amountobjectoptional
A positive integer in the [smallest currency unit](https://docs.stripe.com/currencies#zero-decimal) representing how much of this payment to refund. Can refund only up to the remaining, unrefunded amount of the payment.
expandarray<string>optional
Specifies which fields in the response should be expanded.
initiated_atintegeroptional
When the reported refund was initiated. Measured in seconds since the Unix epoch.
metadataobjectoptional
Set of [key-value pairs](https://docs.stripe.com/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
outcomestringrequired
The outcome of the reported refund.
Allowed:refunded
processor_detailsobjectrequired
Processor information for this refund.
refundedobjectoptional
Information about the payment attempt refund.

2 status codes
200Successful response.
amountobjectrequired
A representation of an amount of money, consisting of an amount and a currency.
amount_authorizedobjectrequired
A representation of an amount of money, consisting of an amount and a currency.
amount_canceledobjectrequired
A representation of an amount of money, consisting of an amount and a currency.
amount_failedobjectrequired
A representation of an amount of money, consisting of an amount and a currency.
amount_guaranteedobjectrequired
A representation of an amount of money, consisting of an amount and a currency.
amount_refundedobjectrequired
A representation of an amount of money, consisting of an amount and a currency.
amount_requestedobjectrequired
A representation of an amount of money, consisting of an amount and a currency.
applicationstringoptional
ID of the Connect application that created the PaymentRecord.
createdintegerrequired
Time at which the object was created. Measured in seconds since the Unix epoch.
customer_detailsobjectoptional
Customer information for this payment.
customer_presencestringoptional
Indicates whether the customer was present in your checkout flow during this payment.
Allowed:off_sessionon_session
descriptionstringoptional
An arbitrary string attached to the object. Often useful for displaying to users.
idstringrequired
Unique identifier for the object.
latest_payment_attempt_recordstringoptional
ID of the latest Payment Attempt Record attached to this Payment Record.
livemodebooleanrequired
If the object exists in live mode, the value is `true`. If the object exists in test mode, the value is `false`.
metadataobjectrequired
Set of [key-value pairs](https://docs.stripe.com/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
objectstringrequired
String representing the object's type. Objects of the same type share the same value.
Allowed:payment_record
payment_method_detailsobjectoptional
Information about the Payment Method debited for this payment.
processor_detailsobjectrequired
Processor information associated with this payment.
reported_bystringrequired
Indicates who reported the payment.
Allowed:selfstripe
shipping_detailsobjectoptional
Shipping information for this payment.
defaultError response.
errorobjectrequired

Error handling

Any other status is an error: Error response.