Skip to main content
POST
/
v1
/
pay
/
address
/
refund
Refund (Direct Payment)
curl --request POST \
  --url https://openplatform.gateapi.io/v1/pay/address/refund \
  --header 'Content-Type: application/json' \
  --header 'X-GatePay-Certificate-ClientId: <x-gatepay-certificate-clientid>' \
  --header 'X-GatePay-Nonce: <x-gatepay-nonce>' \
  --header 'X-GatePay-Signature: <x-gatepay-signature>' \
  --header 'X-GatePay-Timestamp: <x-gatepay-timestamp>' \
  --data '
{
  "refundRequestId": "483902480932841787",
  "prepayId": "1665553233227833",
  "refundAmount": "20",
  "receiverId": 598816
}
'
{
  "refundRequestId": "483902480932841787",
  "prepayId": "1665553233227833",
  "orderAmount": "14.9",
  "refundAmount": "4.9"
}
API description:Initiate a refund for the direct address payment order, which is only applicable to the direct address payment order. If the provided parameters correspond to the converted payment order, an error message will be returned.

Headers

X-GatePay-Certificate-ClientId
string
required

Merchant client ID, obtained from GatePay platform

X-GatePay-Signature
string
required

HMAC-SHA256 signature for request validation

X-GatePay-Timestamp
string
required

Timestamp in milliseconds, must not differ from server time by more than 5 minutes

X-GatePay-Nonce
string
required

Random nonce for replay attack prevention

Body

application/json
refundRequestId
string
required

The merchant's refund request ID

prepayId
string
required

The ID of the corresponding payment order

refundAmount
string
required

The amount to be refunded

receiverId
string
required

The Gate user ID of the recipient of the refund for address payment

refundReason
string

The reason for the refund

Response

200 - application/json

SUCCESS

Response to request for refund of non-convert payment order

refundRequestId
string

Merchant's refund request id

prepayId
string

The id of the payment order to be refunded

orderAmount
string

The amount of the original payment order

refundAmount
string

The amount to be refunded