curl --request POST \
--url https://openplatform.gateapi.io/payment/open/institution/v2/standard/order/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-On-Behalf-Of: <x-gatepay-on-behalf-of>' \
--header 'X-GatePay-Signature: <x-gatepay-signature>' \
--header 'X-GatePay-Timestamp: <x-gatepay-timestamp>' \
--data '
{
"prepayId": "1991810932510167040",
"refundRequestId": "lux202511x093726",
"refundAmount": "0.018",
"refundReason": "test"
}
'{
"status": "SUCCESS",
"code": "000000",
"errorMessage": "",
"data": {
"refundRequestId": "lux202511x093725",
"refundGateId": "35803047115358215",
"prepayId": "1991810932510167040",
"orderAmount": "1.1",
"refundAmount": "0.018",
"errMsg": "",
"orderCurrency": "USDT",
"payCurrency": "USDT",
"payAmount": "0.018"
}
}Create a refund for a paid order. The order must be in paid status.
curl --request POST \
--url https://openplatform.gateapi.io/payment/open/institution/v2/standard/order/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-On-Behalf-Of: <x-gatepay-on-behalf-of>' \
--header 'X-GatePay-Signature: <x-gatepay-signature>' \
--header 'X-GatePay-Timestamp: <x-gatepay-timestamp>' \
--data '
{
"prepayId": "1991810932510167040",
"refundRequestId": "lux202511x093726",
"refundAmount": "0.018",
"refundReason": "test"
}
'{
"status": "SUCCESS",
"code": "000000",
"errorMessage": "",
"data": {
"refundRequestId": "lux202511x093725",
"refundGateId": "35803047115358215",
"prepayId": "1991810932510167040",
"orderAmount": "1.1",
"refundAmount": "0.018",
"errMsg": "",
"orderCurrency": "USDT",
"payCurrency": "USDT",
"payAmount": "0.018"
}
}The clientId assigned when the merchant registers an application in the Gate merchant console.
"4186d0c6-6a35-55a9-8dc6-5312769dbff8"
Request signature. GatePay uses this signature to verify whether the request is valid.
UTC timestamp in milliseconds when the request is generated. GatePay will not process requests where the difference from the receive time exceeds 10 seconds.
"1672905655498"
Random string. Must comply with HTTP header rules; recommended length is within 32 characters, composed of digits and letters.
"9578"
The institution account id being acted on behalf of (sub-account ID).
"2124538349"
Merchant refund ID; unique, max 32 bytes.
32Order ID; order must be in paid status to refund.
Refund amount.
Refund reason.
Refund style: 1 same channel, 2 specified.
Refund pay channel: 1 Gate 2 Web3.
Refund to user id; required for Gate.
Refund chain; required for Web3.
Who bears refund: 1 merchant 2 user.
Refund memo.
Refund amount type: 1 full 2 partial.
Whether to notify.
Whether refund is limited.
Refund currency.
Fund statement ID for refund.
Refund source: 0 order 1 flow.