List refunds for payment
Returns all refunds for the specified payment, most recent first. Uses cursor-based pagination — pass cursor from a previous response to fetch the next page. Default page size is 20, maximum 100. Returns an empty list if the payment has no refunds.
Authorization
bearer In: header
Path Parameters
Response Body
application/json
curl -X GET "https://api.miracle.com/v1/payments/string/refunds"{
"data": [
{
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"tenantId": "f97df110-f4de-492e-8849-4a6af68026b0",
"livemode": true,
"paymentId": "472e651e-5a1e-424d-8098-23858bf03ad7",
"status": "pending",
"amount": {
"currency": "string",
"valueMinor": 0
},
"reason": "string",
"merchantReference": "string",
"statusReason": "string",
"items": [
{
"id": "string",
"productId": "string",
"label": "string",
"description": "string",
"imageUrl": "string",
"unitAmount": {
"currency": "string",
"valueMinor": 0
},
"quantity": 1,
"taxRate": 0,
"taxAmount": {
"currency": "string",
"valueMinor": 0
},
"metadata": {
"property1": "string",
"property2": "string"
}
}
],
"metadata": {
"property1": "string",
"property2": "string"
},
"createdAt": "string",
"updatedAt": "string"
}
],
"pagination": {
"nextCursor": "string",
"prevCursor": "string",
"hasMore": true,
"totalCount": 0
}
}Get refund by ID
Returns details for a single refund, including its current lifecycle status and link back to the originating payment. Soft-deleted refunds are not returned.
Generate settlement for merchant + period
Generates a new settlement for a merchant over a single-currency period. Aggregates payment, refund, chargeback, and fee data. To create an adjustment settlement that revises a previously finalized settlement, supply `linkedSettlementId`, `adjustmentDirection`, `adjustmentAmount`, and `adjustmentReason`.