Skip to main content
POST
/
v1
/
pay
/
checkout
/
order
Place Checkout Order
curl --request POST \
  --url http://sandbox.mintlify.com/v1/pay/checkout/order \
  --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 '
{
  "merchantTradeNo": "163",
  "env": {
    "terminalType": "APP"
  },
  "merchantUserId": 123,
  "goods": {
    "goodsType": "02",
    "goodsName": "Sipariş Ödemesi - 177",
    "goodsDetail": "Sipariş No : 160"
  },
  "chain": "MATIC",
  "fullCurrType": "USDT_MATIC"
}
'
{
  "status": "SUCCESS",
  "code": "000000",
  "errorMessage": "",
  "data": {
    "prepayId": "65466648727916544",
    "orderAmount": "1",
    "surchargeAmount": "0",
    "currency": "USDT",
    "fiatCurrency": "",
    "fiatAmount": "",
    "terminalType": "APP",
    "expireTime": 1677573665219,
    "qrContent": "http://openplatform.gate.io/qr/GA0cskPehKxQpshvm3Goeve8dHpwCl6yCHLSWUYrLqo=",
    "location": "https://www.gate.com/cashier?prepayid=65466648727916544",
    "payCurrency": "USDT",
    "payAmount": "1",
    "chain": {
      "chain_type": "BSC",
      "address": "0x86608d3C9f979b98a3b2417216eD859d313E339D",
      "fullCurrType": "USDT_EOS"
    },
    "channelId": "123456",
    "goodsName": "charge",
    "inUsdt": "93.99"
  }
}

Headers

X-GatePay-Certificate-ClientId
string
required

Merchant client ID, obtained from GatePay platform

Example:

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

X-GatePay-Signature
string
required

HMAC-SHA256 signature for request validation

Example:

"672d5650dcc9bb22ebf25fa16c28d03c0e159d742a9176d4340a5da326d75dc8a2ec24c97fa6fc5d1533dd6e968863747e1d86a45e562cbe899f9ed7e9ca7f77"

X-GatePay-Timestamp
string
required

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

Example:

"1672905655498"

X-GatePay-Nonce
string
required

Random nonce for replay attack prevention

Example:

"9578"

Body

application/json

Checkout order creation parameters

merchantTradeNo
string
required

Merchant order number, must be unique

Required string length: 5 - 32
Example:

"163"

env
object
required
goods
object
required
merchantUserId
integer<int64>
required

Unique consumer ID from merchant's platform

Example:

123

chain
string
required

Selected chain name

Example:

"MATIC"

fullCurrType
string
required

Currency field containing chain name

Example:

"USDT_MATIC"

currency
string

Crypto currency in uppercase, e.g. USDT, BTC

Example:

"USDT"

orderAmount
string

Crypto order amount, max precision 6 digits

Example:

"118.75"

surchargeAmount
string

Surcharge, a fee borne by the consumer

Example:

"0"

toleranceAmount
string

Tolerance amount

fiatCurrency
string

Fiat currency in uppercase

Example:

"USD"

fiatAmount
string

Fiat order amount, max precision 2 digits

Example:

"100"

payCurrency
string

Payment currency for address payment

Example:

"USDT"

orderExpireTime
integer<int64>

Order expiration time in milliseconds

Example:

1677573665219

returnUrl
string<uri>

Return URL after successful payment

Maximum string length: 512
Example:

"https://lotkeys.com/tr/gate-payment-response"

cancelUrl
string<uri>

Return URL after failed payment

Maximum string length: 512
Example:

"https://lotkeys.com/tr/gate-payment-response"

channelId
string

Client name

Maximum string length: 32
Example:

"123456"

Response

200 - application/json

Order created successfully

status
enum<string>

Response status

Available options:
SUCCESS,
ERROR
Example:

"SUCCESS"

code
string

Response code, 000000 indicates success

Example:

"000000"

errorMessage
string

Error message, empty on success

Example:

""

data
object