Skip to main content
POST
/
refund
Create Refund
curl --request POST \
  --url https://uat-api.clinkbill.com/api/refund \
  --header 'Content-Type: application/json' \
  --header 'X-API-KEY: <api-key>' \
  --header 'X-Timestamp: <api-key>' \
  --data '
{
  "orderId": "ord_xxxxx",
  "refundMerchantOrderId": "refund_ref_10001",
  "refundAmount": 19.99,
  "refundReasonType": 2,
  "remark": "Customer requested refund"
}
'
{
  "code": 200,
  "msg": "success",
  "data": {
    "createTime": 1754819711382,
    "refundId": "rfd_abc123xyz",
    "orderId": "order_def456uvw",
    "customerId": "cus_ghi789rst",
    "refundAmount": 19.99,
    "refundCurrency": "USD",
    "status": "success",
    "refundReason": "Customer Initiated Refund",
    "metadata": {
      "arn": "8377252556170253",
      "merchantReferenceId": "sample_id"
    },
    "paymentInstrumentId": "<string>"
  }
}

Authorizations

X-API-KEY
string
header
required

Your secret API key obtained from the Clink dashboard (Developers section)

X-Timestamp
string
header
required

Current timestamp in milliseconds since Unix epoch (required for request signing)

Body

application/json

Parameters required to create a refund by API

orderId
string
required

Unique identifier of the order to refund

refundMerchantOrderId
string
required

Merchant-provided unique refund order ID. Reusing the same value returns the existing refund.

refundAmount
number
required

Refund amount

Example:

19.99

refundReasonType
enum<integer>

Refund reason type: 0 duplicate payment, 1 fraudulent activity, 2 customer initiated refund, 3 other

Available options:
0,
1,
2,
3
remark
string

Refund remark, up to 500 characters

Maximum string length: 500

Response

Refund created successfully

code
integer<int32>

Response status code, 200 when success

Example:

200

msg
string

Brief description of what happened, 'success' when happy case

Example:

"success"

data
object