Skip to main content
POST
/
api
/
v1
/
payments
/
{id}
/
refund
Refund a card payment
curl --request POST \
  --url http://localhost:7701/api/v1/payments/{id}/refund \
  --header 'Content-Type: application/json' \
  --header 'X-API-Key: <api-key>' \
  --data '{
  "amount": 5000
}'
{
  "status": "refunded",
  "transaction_id": "01hvxyz...",
  "amount": 15000,
  "refunded_amount": 5000,
  "message": "Refund processed successfully."
}

Authorizations

X-API-Key
string
header
required

Company API key. Send in the X-API-Key header.

Path Parameters

id
string<uuid>
required

Body

application/json
amount
integer

Refund amount in cents (omit for full refund)

Example:

5000

Response

Refund processed successfully

status
string
Example:

"refunded"

transaction_id
string
Example:

"01hvxyz..."

amount
integer
Example:

15000

refunded_amount
integer
Example:

5000

message
string
Example:

"Refund processed successfully."