API For Price Query

Introduction

If you want to define the price of the token, you need to provide the API according to this interface document.

If your token can obtain a quotation in the following ways, you can not provide this API. These include: Binance/Kucoin/Mexc/OKX/Gate.

API Definition

Path: GET API defined by merchant

Head Parameters:

ElementMandatoryData TypeRemarks
appIdYstringPartner unique ID
timestampYstringUTC time with 13 digit to represent time in milliseconds, expiration period is 5 minutes
signYstringSHA1(appId + appSecret + timestamp), perform SHA1 hash calculation on the concatenated string of the three parameters to generate hexadecimal characters,the sign method can refer here

Body Parameters:

ElementMandatoryData TypeRemarks
cryptoYstringCrypto for querying the price

Format of the response:

0000 represents success, 9999 represents failure, the price unit is USDT, and the network fee unit is the token passed

Success:

{
    "data": {
        "price": "454.46585",//usdt
        "networkList": [
            {
                "network": "ONQ",
                "networkFee": "4.659" //usdt
            },
            {
                "network": "YIIW",
                "networkFee": "6.82733"
            }
        ]
    },
    "success": true,
    "returnCode": "0000",
    "returnMsg": "tygmwt",
}

Fail:

{
    "data": null,
    "success": false,
    "returnCode": "9999",
    "returnMsg": "ruenxecpowswbbprxhwjty"
}