Updates the refund that you specify by setting the values of the passed parameters. Any parameters that you don’t provide remain unchanged.
This request only accepts metadata
as an argument.
Parameters
- metadataobject
Set of key-value pairs 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
.
Returns
Returns the refund object if the update succeeds. This call raises an error if update parameters are invalid.
Response
{ "id": "re_1Nispe2eZvKYlo2Cd31jOCgZ", "object": "refund", "amount": 1000, "balance_transaction": "txn_1Nispe2eZvKYlo2CYezqFhEx", "charge": "ch_1NirD82eZvKYlo2CIvbtLWuY", "created": 1692942318, "currency": "usd", "destination_details": { "card": { "reference": "123456789012", "reference_status": "available", "reference_type": "acquirer_reference_number", "type": "refund" }, "type": "card" }, "metadata": { "order_id": "6735" }, "payment_intent": "pi_1GszsK2eZvKYlo2CfhZyoZLp", "reason": null, "receipt_number": null, "source_transfer_reversal": null, "status": "succeeded", "transfer_reversal": null}