Skip to main content
POST
/
payment
/
open
/
institution
/
v1
/
pay
/
order
/
close
Cancel order
curl --request POST \
  --url https://openplatform.gateapi.io/payment/open/institution/v1/pay/order/close \
  --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": "35771760426090520"
}
'
{
  "status": "SUCCESS",
  "code": "000000",
  "data": {
    "result": "SUCCESS"
  },
  "errorMessage": ""
}
Cancel an order. Either merchant order number or prepayId is required.

Headers

X-GatePay-Certificate-ClientId
string
required

The clientId assigned when the merchant registers an application in the Gate merchant console.

Example:

"4186d0c6-6a35-55a9-8dc6-5312769dbff8"

X-GatePay-Timestamp
string
required

UTC timestamp in milliseconds when the request is generated. GatePay will not process requests where the difference from the receive time exceeds 10 seconds.

Example:

"1672905655498"

X-GatePay-Nonce
string
required

Random string. Must comply with HTTP header rules; recommended length is within 32 characters, composed of digits and letters.

Example:

"9578"

X-GatePay-Signature
string
required

Request signature. GatePay uses this signature to verify whether the request is valid.

X-GatePay-On-Behalf-Of
string
required

The institution account id being acted on behalf of (sub-account ID).

Example:

"2124538349"

Body

application/json
merchantTradeNo
string

Merchant order number, max 32 bytes.

prepayId
string

Prepay ID. Provide either this or merchantTradeNo.

Response

200 - application/json

Success

status
string

SUCCESS or FAIL.

code
string

Error code.

errorMessage
string

Error message.

data
object