Refunds
Create Refund
Initiate a refund for a successful payment
Initiate a refund for a previously successful payment intent.
Endpoint
POST /api/intents/{intent_id}/refund
Authentication: Required (API Key)
Request
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
intent_id | UUID | Yes | The payment intent ID to refund |
Body Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
amount | integer | Yes | Amount to refund (must be ≤ original amount - previous refunds) |
reason | string | No | Reason: fraud, customer_request, return, duplicate, other |
Example
Terminal
curl -X POST "https://app.infinic.com/api/intents/550e8400-e29b-41d4-a716-446655440000/refund" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"amount": 5000,
"reason": "customer_request"
}'
Response
{
"id": 789,
"intent_id": "550e8400-e29b-41d4-a716-446655440000",
"attempt_id": 456,
"amount": 5000,
"status": "initiated",
"created": "2024-01-15T10:30:00Z",
"reason": "customer_request"
}