Skip to content

Retrieve a refund

GET/v1/refunds/{id}

Send your API key as a bearer token in the Authorization header. Secret API key: Authorization: Bearer ctp_live_sk_…. A publishable key (ctp_…_pk_…) is accepted by these operations only, which serve reference data: getRate, listAssets, listNetworks (each marked x-publishable-key: true). Every other operation refuses it with 403 publishable_key_not_allowed, whatever Origin the request carries: that header binds browsers, not other clients, and nothing on this API relies on it.

Name Type Description
id required string At most 100 characters.
Terminal window
curl "https://api.ctpeway.com/v1/refunds/{id}" \
-H "Authorization: Bearer $CTPEWAY_API_KEY"
Field Type Description
id string
status string One of pending, completed, failed.
payment_id string
invoice_id optional string
payout_id optional string
network string
asset string
asset_id string
contract optional string
decimals integer
amount string Base units of asset, the asset of the refunded payment. A whole number written as a string of digits.
destination string
reason string
tx_hash optional string
failure_code optional string
created_at string (date-time)
completed_at optional string (date-time)
failed_at optional string (date-time)
livemode boolean
simulated boolean true: the refund of a simulated payment (test mode). It was played, not paid: no payout, no transaction, and tx_hash is a sim_… placeholder.
failure_message optional string What failure_code means, in a sentence for a person. Absent for codes that need no explanation.
{
"id": "string",
"status": "pending",
"payment_id": "string",
"invoice_id": "string",
"payout_id": "string",
"network": "string",
"asset": "string",
"asset_id": "string",
"contract": "string",
"decimals": 0,
"amount": "1000000",
"destination": "string",
"reason": "string",
"tx_hash": "string",
"failure_code": "string",
"created_at": "2026-01-01T00:00:00.000Z",
"completed_at": "2026-01-01T00:00:00.000Z",
"failed_at": "2026-01-01T00:00:00.000Z",
"livemode": true,
"simulated": true,
"failure_message": "string"
}

The values are placeholders generated from the schema. They show the shape, not real data.

A failed request answers with the error format described under Errors.

Besides the codes any endpoint can return, this endpoint can answer with these code values: