NAV
java

Cheezee Pay API

Description

Cheezee Pay supports the use of its WaaS service through REST API, including functions such as receiving and sending coins for more than 20 mainstream blockchains and over 1000 types of tokens. Third-party apps can imagine it as an Alipay or WeChat payment interface, making it easier to develop cryptocurrency-related applications based on Cheezee Pay, such as cryptocurrency exchanges, hedge funds, payment platforms, mortgage lending platforms, cloud computing power, mining pool wallets, and so on. Third-party developers can also store digital assets in Cheezee Pay, fully utilizing Cheezee Pay's world-leading hot-cold separation and global private key distribution storage to ensure asset security.

In addition to REST API, Cheezee Pay also provides a web-based management interface at https://merchant.cheezeebit.com, which facilitates manual sending and receiving by management personnel, configuration of risk control strategies, as well as low-amount reminders, statistical reports, and other functions. The following are screenshots of the web management interface:

How to open an account

Users can contact through TelegramSteven open

Will the return value in the interface change

Due to the rapid development of the blockchain itself and Cheezee Pay's own business, it is difficult for Cheezee Pay to ensure that the existing return fields can fully meet customers' needs. Therefore, while ensuring forward compatibility (old fields cannot be deleted and their meaning will not change), Cheezee Pay will add new fields to the return value. Access parties need to maintain compatibility with such changes

The default user agent needs to be added to the API interface request header

User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/93.0.4577.63 Safari/537.36

URL obj = new URL(url);
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
con.setRequestProperty("User-Agent", "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/93.0.4577.63 Safari/537.36");

About Data Format

Interface interaction mode, request and response data types using Json

API Signature Authentication

Cheezee Pay uses RSA signatures for verification. After you open an account in Cheezee Pay, you can generate a public-private key pair at http://www.metools.info/code/c80.html. If you have any questions, you can also contact our staff to assist you. You can enter your public key API Key through the Cheezee Pay management interface (path: Merchant Backstage-API-API Settings-API Key), as shown below. Please keep the API Secret properly and do not disclose it to anyone to avoid asset loss! Cheezee Pay's API requests, except for public APIs, require the interface to use the RSA private key to sign all interface request parameters when requesting. You can refer to the signature and verification code examples on the right:

private static final String DATA = "data";

    // Generate signature
    public static String getSign(Map<String, Object> params, String privateKey) throws Exception {
        params.remove("sign");
        String textContent = getContent(params);
        System.out.println(textContent);
        return sign(textContent, privateKey);
    }

    // Verify the signature
    public static boolean verifySign(Map<String, Object> params, String publickey) throws
            Exception {
        String platSign= (String)params.remove("platSign");

        String textContent = getContentNew(params);
        System.out.println("Signature Verification:"+textContent);
        return verifySign(textContent, platSign, publickey);
    }

    // The string for the reception signature
    private static String getContent(Map<String, Object> params) {
        List<String> paramNameList = new ArrayList(params.keySet());
        Collections.sort(paramNameList);
        StringBuilder stringBuilder = new StringBuilder();
        Iterator var3 = paramNameList.iterator();

        while(var3.hasNext()) {
            String name = (String)var3.next();
            if (params.get(name) != null && !"payeeAccountInfos".equals(name)) {
                if (name.equals("agentOrderBatch")) {
                    //stringBuilder.append(JSON.toJSONString(params.get(name)));
                } else {
                    stringBuilder.append(params.get(name));
                }
            }
        }

        return stringBuilder.toString();
    }

    //Spell the string of the signature to be verified
    public static String getContentNew(Map<String, Object> params) {
        List<String> paramNameList = new ArrayList<>(params.keySet());
        Collections.sort(paramNameList);
        StringBuilder stringBuilder = new StringBuilder();
        for (String name : paramNameList) {
            if(ObjectUtil.isNotEmpty(params.get(name))) {
                if ("data".equals(name)) {
                    Object dataValue = params.get(name);
                    if (dataValue instanceof Map) {
                        stringBuilder.append(getContentNew((Map<String, Object>)dataValue));
                    } else {
                        stringBuilder.append(params.get(name));
                    }
                } else if ("payeeAccountInfos".equals(name)){
                    //payeeAccountInfos is a string that participates in the signature. 
                    //It is an array that does not participate in the signature.
                    Object dataValue = params.get(name);
                    if (dataValue instanceof String) {
                        stringBuilder.append(params.get(name));
                    }
                }else{
                    if (params.get(name) != null ) {
                        stringBuilder.append(params.get(name));
                    }
                }
            }
        }
        return stringBuilder.toString();
    }

    // Generate a signature using a private key
    public static String sign(String textContent, String privateKeyStr) {
        Sign sign = SecureUtil.sign(SignAlgorithm.SHA256withRSA, privateKeyStr, (String)null);
        byte[] data = textContent.getBytes(StandardCharsets.UTF_8);
        byte[] signed = sign.sign(data);
        String signedStr = Base64.encode(signed);
        return signedStr;
    }

    // Use public key to verify signature
    public static boolean verifySign(String textContent, String signStr, String publicKeyStr) {
        Sign sign = SecureUtil.sign(SignAlgorithm.SHA256withRSA, (String)null, publicKeyStr);
        byte[] data = textContent.getBytes(StandardCharsets.UTF_8);
        boolean verifyResult = sign.verify(data, Base64.decode(signStr));
        return verifyResult;
    }

Test

In order to better focus on the maintenance of mainstream public chains, the test environment only supports GETH. If you have special testing requirements for public chains that are not in this list, please contact our customer service personnel.

Get test coins.

GETH(ETH Test coins.)- Goerli Testnet

Browser:https://goerli.etherscan.io/

Link to apply for test coins (for reference only):https://goerli-faucet.pk910.de/

Crypto Payin

Crypto Payin Order

Map<String, Object> map = new HashMap<String, Object>();
// For ERC20 without orders id ----
//        map.put("merchantsId", "Your merchant ID on our platform");
//        map.put("customerMerchantsId", "User ID in your own business");//
//        map.put("moneyUnit", "Currency");
//        map.put("netWork", "Currency chain");

// For TRC20 with orders id----
map.put("merchantsId", "Your merchant ID on our platform");
map.put("customerMerchantsId", "User ID in your own business");//
map.put("moneyUnit", "Currency");
map.put("chargeMoney", "Amount to be paid");
map.put("merchantsOrderId", "Order ID for your payment business");
map.put("netWork", "Currency chain");
map.put("orderVersion", "v1.0");


String platSign = RSAUtil.getSign(map , privateKey);
map.put("platSign",platSign);

String returnObj = CheesehubRsaAndHttpUtils.doPostJsonSetTimeout("https://{Platform domain name.}/business/createCollectionOrder", JSON.toJSONString(map));
JSONObject jsonObject = JSONObject.parseObject(returnObj);
System.out.println("returnObj:"+returnObj);
if("000000".equals(jsonObject.getString("code"))){
    ObjectMapper objectMapper = new ObjectMapper();
    Map<String, Object> map1 = objectMapper.readValue(returnObj, Map.class);
    if(RSAUtil.verifySign(map1 , platpublicKey)){
        System.out.println("pass");
    }else {
        System.out.println("no pass");
    }
}else{
/**
 * {"success":false,"code":"999999","msg":"Failed to create third-party payment order! null","data":null}
 * {"success":false,"code":"NF00001","msg":"The order already exists. Please do not create it again!","data":null}
 */
    System.out.println("no pass");
}  

Success Response Demo:

{
  "success": true,
  "code": "000000",
  "msg": "Successful",
  "data": {
    "orderId": "***Platform payment order number***",
    "addressList": [
      {
        "netWork": "***Chain that supports payment transaction currency***",
        "address": "***Address***"
      },
      {
        "netWork": "***Chain that supports payment transaction currency***",
        "address": "***Address***"
      }
    ],
    "url": "***url***?key=urlData"
  }
}

The urlData has a JSON structure like this:

{
  "orderId": "Order number",
  "customerMerchantsId": "Merchant user UID",
  "merchantsId": "Merchant UID",
  "chargeMoney": "Coin recharge amount",
  "moneyUnit": "Coin recharge currency",
  "merchantsOrderId": "Merchant order number",
  "market": "Exchange rate",
  "type": "v1.0",
  "num": "Quantity",
  "addressList": [
    {
      "netWork": "Chain that supports payment transaction currency",
      "address": "Address"
    },
    {
      "netWork": "Chain that supports payment transaction currency",
      "address": "Address"
    }
  ]
}

Fail Response Demo:

{
  "success": false,
  "code": "errorCode",
  "msg": "errorMessage",
  "data": null
}

HTTP Request

The domain has a test environment and a production environment, which have different domain names. Please pay attention.

POST https://{domain}/business/createCollectionOrder

Parameters

Parameter Default type length Description
customerMerchantsId true String 32 Merchant user ID.
merchantsId true String 32 Merchant ID.
platSign true String 255 Signature.
chargeMoney true String ######.######## Payment amount.new BigDecimal("0.0").stripTrailingZeros().toPlainString()
moneyUnit true String 10 Coin recharge currency.
merchantsOrderId false String 32 Merchant payment order number (required for v1.0 v3.0 and v5.0 mode, not required for v2.0 v4.0 and v6.0 mode).
netWork true String 32 Coin recharge currency chain.
orderVersion true String 2 v1.0, v2.0, v3.0, v4.0, v5.0, v6.0 (if this field is not passed, the cashier version is determined based on the merchant backend configuration).
timeStamp false String 32 Timestamp (optional, in milliseconds).
remark false String 32 Note (optional, in JSON format).

Response

Field type Description
success Boolean true false
code String code
msg String msg
data Object (data)
platSign String platSign

data

Field type Description
orderId String Platform order number.
addressList JSON Array Address array (see details in addressList).
url String Cashier address.

addressList

Field type Description
address String Address
netWork String Chain

Crypto Payin Notification

LOG.info("==============PayAsynchronous1.1===================");
HttpServletRequest request = this.getRequest();
request.setCharacterEncoding("UTF-8");
BufferedReader reader = new BufferedReader(new InputStreamReader(request.getInputStream()));
String str = "";
String wholeStr = "";
while((str = reader.readLine()) != null){//
wholeStr += str;
}
LOG.info("encode:"+wholeStr);
JSONObject postJson= JSON.parseObject(wholeStr);
// Payment order
String orderId = postJson.getString("orderId");
// Your merchant order number
String merchantsOrderId = postJson.getString("merchantsOrderId");
String data = postJson.getString("data");
// Parsing
JSONObject dataJosn = JSONObject.parseObject(data);
// Status: 1 transaction completed, 2 order exception, 3 in transaction, 4 transaction timeout
String status = dataJosn.getString("status");
// Payment amount
String amount = dataJosn.getString("amount");
String customerMerchantsId = dataJosn.getString("customerMerchantsId");
// Order exchange rate
String currentRate = dataJosn.getString("currentRate");
// Exchange rate type: 1 fixed rate, 2 floating rate
String rechargeRateType = dataJosn.getString("rechargeRateType");
// Exchange rate update time UTC time format: yyyy-MM-ddTHH:mm:ss.SSSZ
String exchangeRateDate = dataJosn.getString("exchangeRateDate");
// Order creation time UTC time format: yyyy-MM-ddTHH:mm:ss.SSSZ
String orderCreatedTime = dataJosn.getString("orderCreatedTime");
// Order completion time UTC time format: yyyy-MM-ddTHH:mm:ss.SSSZ
String orderCompletedTime = dataJosn.getString("orderCompletedTime");
LOG.info(merchantsOrderId + "coboPay-postJson:" + dataJosn);

Request

Note: data is a JSON string

{
  "orderId": "Platform payment order number",
  "merchantsOrderId": "Merchant payment order number",
  "data": {
    "orderId": "Platform payment order number",
    "merchantsOrderId": "Merchant payment order number",
    "status": "Payment order status",
    "amount": "Payment order amount",
    "symbol": "Currency for payment transaction order",
    "customerMerchantsId": "Merchant user ID",
    "netWork": "Chain",
    "side": "Asynchronous notification business type",
    "receiveAddress": "Receiving address",
    "currentRate": "0.888",
    "rechargeRateType": "2",
    "exchangeRateDate": "2022-07-12T09:15:34.617Z",
    "orderCreatedTime": "2022-07-12T09:15:34.617Z",
    "orderCompletedTime": "2022-07-12T09:15:34.617Z"
  }
}

Success Response Demo:

{
  "code": "200"
}

Fail Response Demo:

{
  "code": "errorCode"
}

The domain has a test environment and a production environment, which have different domain names. Please note..

HTTP Request

POST https://{Merchant's address for receiving asynchronous callbacks}

Parameters

Parameter Default type length Description
orderId true String 32 Platform payment order number.
merchantsOrderId true String 32 Merchant payment order number.
status true String 2 Payment order status: 1 transaction completed, 2 order exception, 3 in transaction, 4 transaction timeout.
amount true String ######.###################### Payment order amount. new BigDecimal("0.0").stripTrailingZeros().toPlainString()
symbol true String 10 Payment currency.
customerMerchantsId true String 32 Merchant user ID.
netWork true String 10 Chain.
side true String 10 Asynchronous notification business type (tripartite: collection order), if the merchant uses one interface to receive all types of asynchronous callbacks, use it to determine the business.
receiveAddress true String 10 Receiving address.
currentRate true String ######.###################### Order exchange rate. new BigDecimal("0.0").stripTrailingZeros().toPlainString()
rechargeRateType true String 1 Exchange rate type: 1 fixed rate, 2 floating rate.
exchangeRateDate true String 24 Exchange rate update time UTC time format: yyyy-MM-ddTHH:mm:ss.SSSZ
orderCreatedTime true String 24 Order creation time UTC time format: yyyy-MM-ddTHH:mm:ss.SSSZ
orderCompletedTime true String 24 Order completion time UTC time format: yyyy-MM-ddTHH:mm:ss.SSSZ

Response

Field type Description
code Integer 200

Note

After the merchant receives the notification from Cheezee Pay, it is recommended to call the Cheezee Pay transaction query interface according to the specific Id field in it to confirm the correctness of the transaction again.

For messages of successful transactions, Cheezee Pay adopts a policy of at least one successful push (except for confirmation number change notifications). If the merchant does not return {"code":"200"}, Cheezee Pay will consider the push failed and continue to push for a period of time (the push interval gradually increases, and after the total number of pushes exceeds 14 times, it is marked as push failure and will no longer be pushed. If you need to push again, please contact the staff).

For messages in transaction confirmation, Cheezee Pay will only push once when the block confirmation number changes and will not repeatedly push relying on the merchant's return result.

For transactions that have reached the confirmation threshold and have a status of "success", Cheezee Pay will not continue to push the chain confirmation number change of this transaction.

Due to unpredictable reasons such as network delay, callbacks may be repeated multiple times. Please pay attention to using the id field as a unique key for transactions and use the database read-write lock mechanism reasonably to prevent duplicate postings.

HTTPS protocol should be used as much as possible to prevent man-in-the-middle attacks. And for the callback message content of Cheezee Pay, use RSA for signature verification.

Crypto Payin Query

Map<String, Object> map = new HashMap<String, Object>();
map.put("orderType", "Order type");
map.put("merchantsId", "Merchant ID");
map.put("pageIndex", "Page index");
map.put("orderId", "Number per page");

String platSign = RSAUtil.getSign(map , privateKey);
map.put("platSign",platSign);

String returnObj = CheesehubRsaAndHttpUtils.doPostJsonSetTimeout("https://{domain}/business/queryOrderPage", JSON.toJSONString(map));
JSONObject jsonObject = JSONObject.parseObject(returnObj);
System.out.println("returnObj:"+returnObj);
if("000000".equals(jsonObject.getString("code"))){
    ObjectMapper objectMapper = new ObjectMapper();
    Map<String, Object> map1 = objectMapper.readValue(returnObj, Map.class);
    if(RSAUtil.verifySign(map1 , platpublicKey)){
        System.out.println("pass");
        JSONObject pageData = jsonObject.getJSONObject("data");
        JSONArray records = pageData.getJSONArray("records");
        Integer pageIndex = pageData.getInteger("pageIndex");
        Integer pageSize = pageData.getInteger("pageSize");
        Integer totalPages = pageData.getInteger("totalPages");
        Integer totalCount = pageData.getInteger("totalCount");
    }else {
        System.out.println("no pass");
    }
}else{
    jsonObject.getBoolean("success");
    jsonObject.getString("code");
    jsonObject.getString("msg");
}

Success Response Demo:

{
  "success": true,
  "code": "000000",
  "msg": "success",
  "data": {
    "records": [
      {
        "id": "Order ID",
        "coboBusinessId": "Transaction hash",
        "merchantsOrderId": "Merchant order number",
        "customerId": "Platform user ID",
        "merchantsId": "Merchant ID",
        "customerMerchantsId": "Merchant user ID",
        "chargeMoney": "Collection amount",
        "moneyUnit": "Collection currency",
        "fee": "Collection fee",
        "netWork": "Chain",
        "receiveAddress": "Receipt address",
        "sendAddress": "Sending address",
        "status": "Order status: 1 payment completed, 2 no order payment, 3 in payment, 4 order expired",
        "pushStatus": "Push status: 1 notification in progress, 2 notification completed, 3 notification failed",
        "createTime": "Creation time",
        "businessTime": "Completion time"
      }
    ],
    "totalPages": "Total pages",
    "totalCount": "Total quantity",
    "pageSize": "Number per page",
    "pageIndex": "Page index"
  },
  "platSign": "Signature"
}

Fail Response Demo:

{
  "success": false,
  "code": "errorCode",
  "msg": "errorMessage",
  "data": null
}

The domain has a test environment and a production environment, which have different domain names. Please note..

HTTP Request

POST https://{domain}/business/queryOrderPage

Parameters

Parameter required Default type length Description
platSign true String 255 Signature
orderType true String 30 Order type: collection - collection order
merchantsId true String 32 Merchant ID
pageIndex true 1 Integer Page index
pageSize true 10 Integer Number per page
orderId false String Order ID
orderStatus false Integer Order status: 1 payment completed, 2 no order payment, 3 in payment, 4 order expired
createTimeStart false String Order creation time (start) - format yyyy-MM-dd HH:mm:ss
createTimeEnd false String Order creation time (end) - format yyyy-MM-dd HH:mm:ss
finishTimeStart false String Order completion time (start) - format yyyy-MM-dd HH:mm:ss
finishTimeEnd false String Order completion time (end) - format yyyy-MM-dd HH:mm:ss

Response

Field type Description
success Boolean true false
code String code
msg String msg
data Object data
platSign String platSign

Crypto Payout

Crypto Payout Order

Map<String, Object> map = new HashMap<String, Object>();
map.put("merchantsId", "Merchant ID");
map.put("merchantsOrderNo", "Merchant Order Number");
map.put("currency", "Payment Currency");
map.put("amount", "Payment Amount");
map.put("network", "Currency Network");
map.put("address", "Payment Address");
map.put("timeStamp", "Timestamp");
map.put("remark", "Remarks");

String platSign = RSAUtil.getSign(map , privateKey);
map.put("platSign",platSign);

String returnObj = CheesehubRsaAndHttpUtils.doPostJsonSetTimeout("https://{domain}/business/paymentOrder", JSON.toJSONString(map));
JSONObject jsonObject = JSONObject.parseObject(returnObj);
System.out.println("returnObj:"+returnObj);
if("000000".equals(jsonObject.getString("code"))){
    ObjectMapper objectMapper = new ObjectMapper();
    Map<String, Object> map1 = objectMapper.readValue(returnObj, Map.class);
    if(RSAUtil.verifySign(map1 , platpublicKey)){
        System.out.println("pass");
    }else {
        System.out.println("no pass");
    }
}else{
    System.out.println("no pass");
}

Success Response Demo:

{
    "success": true,
    "code": "000000",
    "msg": "success",
    "data": {
        "orderId": "TB2022111118525243000000068",
        "orderStatus": 2
    },
    "platSign": "myR5cpH6/DUYF74Xp74XMgLS53uhTLN4L7pI686jJdvgaB4hagoi5K0tAyEq5leZfAzkmKs0jTwoAh/KdxiIpetTuszi/wuKOM7JJj9igQmp7rsOSQNwb/WLplpOkOjyUrFm2KqgWPVLJXDwziu6QNmd7f50L//BJFCWkHTVCNU="
}

Fail Response Demo:

{
  "success": false,
  "code": "errorCode",
  "msg": "errorMessage",
  "data": null
}

There are different domain names for the test environment and the production environment. Please pay attention..

HTTP Request

POST https://{domain}/business/paymentOrder

Parameters

Parameter Default type length Description
platSign true String 255 Secret key for signature
merchantsId true String 32 Merchant ID
merchantsOrderNo true String 32 Merchant Order Number
currency true String 10 Payment Currency
amount true String ######.######## Payment Amount new BigDecimal("0.0").stripTrailingZeros().toPlainString()
network true String 10 Currency Network
address true String 10 Payment Address
timeStamp false String 20 Timestamp
remark false String # Remarks in JSON string format. If the format is incorrect, it will not be saved.

Response

Field type Description
success Boolean true false
code String code
msg String msg
data Object data
platSign String platSign

Crypto Payout Notification

LOG.info("==============Pay1.1===================");
HttpServletRequest request = this.getRequest();
request.setCharacterEncoding("UTF-8");
BufferedReader reader = new BufferedReader(new InputStreamReader(request.getInputStream()));
String str = "";
String wholeStr = "";
while((str = reader.readLine()) != null){
wholeStr += str;
}
LOG.info("encode:"+wholeStr);
JSONObject postJson= JSON.parseObject(wholeStr);
// Payment Order Number
String orderId = postJson.getString("orderId");
// Your Merchant Order Number
String merchantsOrderId = postJson.getString("merchantsOrderId");
String data = postJson.getString("data");
// Parsing
JSONObject dataJosn = JSONObject.parseObject(data);
// Payment Order Number
String businessOrderId = dataJosn.getString("orderId");
// Order Status: 2 Withdrawal Confirmation, 3 Completed, 4 Failed, 5 Rejected, 6 In Transaction
String status = dataJosn.getString("status");
// Handling Fee
String mentionPoundage = dataJosn.getString("mentionPoundage");
// Handling Fee Currency
String mentionPoundageUnit = dataJosn.getString("mentionPoundageUnit");
// Network
String netWork = dataJosn.getString("netWork");
// Payment Received Amount
String mentionMoney = dataJosn.getString("mentionMoney");
LOG.info(merchantsOrderId+"coboPay-postJson:" + dataJosn);  

Request

Note: data is a JSON string

{
  "orderId": "Platform payment order number",
  "data": {
    "orderId": "Platform payment order number",
    "status": "Order status",
    "side": "payment",
    "customerMerchantsId": "Merchant user ID",
    "symbol": "Payment currency",
    "amount": "Payment amount",
    "receiveAddress": "Payment address",
    "mentionMoney": "Amount received by the payee",
    "mentionPoundage": "Commission",
    "mentionPoundageUnit": "Commission currency",
    "netWork": "Chain",
    "merchantsOrderId":"Merchant order number"
  }
}

Success Response Demo:

{
  "code": "200"
}

Fail Response Demo:

{
  "code": "errorCode"
}

The domain has a test environment and a production environment, which have different domain names. Please note...

HTTP Request

POST https://{}

Parameters

Parameter Default type length Description
orderId true String 32 Platform order number.
status true String 2 Transaction status: 2 withdrawal confirmation, 3 completed, 4 failed, 5 rejected, 6 in transaction.
side true String 10 Asynchronous notification business type (payment: collection order), if the merchant uses one interface to receive all types of asynchronous callbacks, use it to determine the business.
customerMerchantsId true String 32 Merchant user ID.
symbol true String 10 Currency.
amount true String ######.###################### Order initiation amount. new BigDecimal("0.0").stripTrailingZeros().toPlainString()
receiveAddress true String 255 Address.
mentionMoney true String ######.###################### Amount received.
mentionPoundage true String ######.###################### Commission.
mentionPoundageUnit true String ######.###################### Commission currency.
netWork true String 10 Chain.
merchantsOrderId true String Merchant order number.

Response

Field type Description
code Integer 200

Crypto Payout Query

Map<String, Object> map = new HashMap<String, Object>();
map.put("orderType", "Order type");
map.put("merchantsId", "Merchant ID");
map.put("pageIndex", "Page index");
map.put("orderId", "Number per page");

String platSign = RSAUtil.getSign(map , privateKey);
map.put("platSign",platSign);

String returnObj = CheesehubRsaAndHttpUtils.doPostJsonSetTimeout("https://{}/business/queryOrderPage", JSON.toJSONString(map));
JSONObject jsonObject = JSONObject.parseObject(returnObj);
System.out.println("returnObj:"+returnObj);
if("000000".equals(jsonObject.getString("code"))){
    ObjectMapper objectMapper = new ObjectMapper();
    Map<String, Object> map1 = objectMapper.readValue(returnObj, Map.class);
    if(RSAUtil.verifySign(map1 , platpublicKey)){
        System.out.println("pass");
        JSONObject pageData = jsonObject.getJSONObject("data");
        JSONArray records = pageData.getJSONArray("records");
        Integer pageIndex = pageData.getInteger("pageIndex");
        Integer pageSize = pageData.getInteger("pageSize");
        Integer totalPages = pageData.getInteger("totalPages");
        Integer totalCount = pageData.getInteger("totalCount");
    }else {
        System.out.println("no pass");
    }
}else{
    jsonObject.getBoolean("success");
    jsonObject.getString("code");
    jsonObject.getString("msg");
}

Success Response Demo JSON:

{
  "success": true,
  "code": "000000",
  "msg": "success",
  "data": {
    "records": [
      {
        "id": "Order ID",
        "coboBusinessId": "Transaction hash",
        "merchantsOrderNo": "Merchant order number",
        "merchantsId": "Merchant ID",
        "mentionMoney": "Payment amount",
        "moneyUnit": "Payment currency",
        "mentionPoundage": "Commission for payment",
        "mentionPoundageUnit": "Commission currency for payment",
        "netWork": "Chain",
        "receiveAddress": "Payment address",
        "status": "Order status: -1 in payment, -2 payment failed, 3 payment completed, 5 audit rejected, 8 under review",
        "pushStatus": "Push status: 1 not notified, 2 notification successful, 3 notification failed",
        "startTimes": "Creation time",
        "endTimes": "End time"
      }
    ],
    "totalPages": "Total pages",
    "totalCount": "Total count",
    "pageSize": "Number per page",
    "pageIndex": "Page index"
  },
  "platSign": "Signature"
}

Fail Response Demo:

{
  "success": false,
  "code": "errorCode",
  "msg": "errorMessage",
  "data": null
}

The domain has a test environment and a production environment, which have different domain names. Please note...

HTTP Request

POST https://{domain}/business/queryOrderPage

Parameters

Parameter required Default type length Description
platSign true String 255 Signature
orderType true String 30 Order type: payment for collection orders
merchantsId true String 32 Merchant ID
pageIndex true 1 Integer Page index
pageSize true 10 Integer Number per page
orderId false String Order ID
orderStatus false Integer Order status: -1 in payment, -2 payment failed, 3 payment completed, 5 audit rejected, 8 under review
createTimeStart false String Order creation time - start format yyyy-MM-dd HH:mm:ss
createTimeEnd false String Order creation time - end format yyyy-MM-dd HH:mm:ss
finishTimeStart false String Order completion time - start format yyyy-MM-dd HH:mm:ss
finishTimeEnd false String Order completion time - end format yyyy-MM-dd HH:mm:ss

Response

Field type Description
success Boolean true false
code String code
msg String msg
data Object data
platSign String platSign

P2P Payin

P2P Payin Order

Map<String, Object> map = new HashMap<String, Object>();
map.put("customerMerchantsId", "Unique identifier of the user under the merchant, passed in by the cashier API");
map.put("takerType", "Fixed as 2, merchant user");
map.put("legalCoin", "Legal tender currency");
map.put("merchantsId", "Merchant ID");
map.put("dealAmount", "Legal tender amount");
map.put("tradeType", "Trading type: 2 for selling");
map.put("merchantOrderId", "Merchant order number - unique");
map.put("merchantHomePage", "merchant Home Page");
map.put("language", "zh_hk Chinese, VI Vietnamese, en English, Indonesia Indonesian");
map.put("payWayName", "payWayName:[IMPS]  [UPI]  [Bank Transfer(India)] [Paytm]");
String platSign = RSAUtil.getSign(map , privateKey);
map.put("platSign",platSign);

String returnObj = CheesehubRsaAndHttpUtils.doPostJsonSetTimeout("https://{domain}/business/c2c/entrustOrder/cashier", JSON.toJSONString(map));
JSONObject jsonObject = JSONObject.parseObject(returnObj);
System.out.println("returnObj:"+returnObj);
if("000000".equals(jsonObject.getString("code"))){
    ObjectMapper objectMapper = new ObjectMapper();
    Map<String, Object> map1 = objectMapper.readValue(returnObj, Map.class);
    if(RSAUtil.verifySign(map1 , platpublicKey)){
        System.out.println("pass");
    }else {
        System.out.println("no pass");
    }
}else{
    System.out.println("no pass");
}  

Success Response Demo:

{
  "success": true,
  "code": "000000",
  "msg": "success",
  "data": {
    "orderId": "Payment order number",
    "type": "0 for new order, 1 for existing order",
    "url": "Cashier path"
  },
  "platSign": "Verification signature"
}

Fail Response Demo:

{
  "success": false,
  "code": "errorCode",
  "msg": "errorMessage",
  "data": null
}

The domain has a test environment and a production environment, which have different domain names. Please note..

HTTP Request

POST https://{domain}/business/c2c/entrustOrder/cashier

Parameters

Parameter Default type length Description
platSign true String 255 Signature
customerMerchantsId true String 32 Unique identifier of the user under the merchant, passed in by the cashier API
legalCoin true String 10 Legal tender currency, currently supports INR IDR
coin true String 10 Fixed: USDT
merchantsId true String 32 Merchant ID
dealAmount true Integer 10 Legal tender amount
tradeType true Integer 2 Fixed: 2
takerType true Integer 2 Fixed: 2
merchantOrderId true String 32 Merchant order number - unique
language true String 32 zh_hk Chinese;VI Vietnamese;en English;Indonesia Indonesian
merchantHomePage false String 32 Merchant homepage (not required)
pushAddress true String 64 Notification callback address
payWayName false String 32 payWayName (not required) [IMPS] [UPI] [Bank Transfer(India)] [Paytm]

Response

Field type Description
success Boolean true false
code String code
msg String msg
data Object data
platSign String platSign

P2P Payin Notification

LOG.info("==============Pay1.1===================");
HttpServletRequest request = this.getRequest();
request.setCharacterEncoding("UTF-8");
BufferedReader reader = new BufferedReader(new InputStreamReader(request.getInputStream()));
String str = "";
String wholeStr = "";
while((str = reader.readLine()) != null){
wholeStr += str;
}
LOG.info("encode:"+wholeStr);
JSONObject postJson= JSON.parseObject(wholeStr);
// Quick collection order
String orderId = postJson.getString("orderId");
// Your merchant order number
String merchantsOrderId = postJson.getString("merchantsOrderId");
String data = postJson.getString("data");
//Parse
JSONObject dataJosn = JSONObject.parseObject(data);
//Status: 4 for success, 5 for failure, 6 for failure (user has not operated for 6 hours), 7 for failure (price not accepted), 9 for failure (refund)
String status = dataJosn.getString("status");
//Cryptocurrency
String coin = dataJosn.getString("coin");
//Merchant user ID
String customerMerchantsId = dataJosn.getString("customerMerchantsId");
//Legal tender amount
String dealAmount = dataJosn.getString("dealAmount");
//Cryptocurrency quantity
String dealQuantity = dataJosn.getString("dealQuantity");
//Advertisement order number
String entrustOrderId = dataJosn.getString("entrustOrderId");
//Commission currency
String feeCoin = dataJosn.getString("feeCoin");
//Creation time in milliseconds
String gmtCreate = dataJosn.getString("gmtCreate");
//End time in milliseconds
String gmtEnd = dataJosn.getString("gmtEnd");
//Legal tender currency
String legalCoin = dataJosn.getString("legalCoin");
//Platform order number
String orderId = dataJosn.getString("orderId");
//Unit price
String price = dataJosn.getString("price");
//C2C
String side = dataJosn.getString("side");
//Merchant commission
String takerFee = dataJosn.getString("takerFee");
//User platform ID
String takerId = dataJosn.getString("takerId");
//Order taker nickname
String takerName = dataJosn.getString("takerName");
//Quick collection 2
String tradeType = dataJosn.getString("tradeType");
//Payment method name
String payWayName = dataJosn.getString("payWayName");

request JSON:

{
  "merchantsOrderId": "Merchant order number",
  "orderId": "Platform order number",
  "merchantId": "Merchant ID",
  "data": {
    "orderId": "Platform withdrawal order number",
    "status": "Order status",
    "coin": "Cryptocurrency",
    "dealAmount": "Legal tender amount",
    "dealQuantity": "Cryptocurrency quantity",
    "entrustOrderId": "Advertisement order number",
    "feeCoin": "Commission currency",
    "legalCoin": "Legal tender currency",
    "orderId": "Platform order number",
    "price": "Unit price",
    "takerFee": "Merchant commission",
    "takerId": "User platform ID",
    "takerName": "Order taker nickname",
    "tradeType": "Quick collection 2",
    "payWayName": "Payment method name",
    "side": "C2C",
    "customerMerchantsId": "Merchant user ID"
  }
}

Success Response Demo:

{
  "code": "200"
}

Fail Response Demo:

{
  "code": "errorCode"
}

The domain has a test environment and a production environment, which have different domain names. Please note...

HTTP Request

POST https://{Merchant's address to receive asynchronous callbacks.}

Parameters

Parameter Default type length Description
orderId true String 32 Platform order number.
merchantsOrderId true String 32 Merchant order number.
merchantId true String 10 Merchant ID
status true String 2 4 for success, 5 for failure, 6 for failure (user has not operated for 6 hours), 7 for failure (price not accepted), 9 for failure (refund)
coin true String 10 Cryptocurrency
customerMerchantsId true String 32 Merchant user ID
dealAmount true String 40 Legal tender transaction amount
dealQuantity true String 40 Settlement quantity of cryptocurrency
entrustOrderId true String 40 Advertisement order number
feeCoin true String 10 Commission currency
gmtCreate true Date 10 Creation time in milliseconds
gmtEnd true Date 10 End time in milliseconds
legalCoin true String 10 Legal tender currency
orderId true String 40 Platform order number
payWayName true String 64 Payment method
price true String 40 Unit price
side true String 10 Business type C2C
takerFee true String 40 Merchant commission
tradeType true String 2 Quick collection 2
takerId true String 40 Order taker ID
takerName true String 64 Order taker nickname
payWayName true String 64 Payment method name

Response

Field type Description
code Integer 返回码 200 成功

Exchange Rate Verification Interface

LOG.info("==============Pay1.1===================");
HttpServletRequest request = this.getRequest();
request.setCharacterEncoding("UTF-8");
BufferedReader reader = new BufferedReader(new InputStreamReader(request.getInputStream()));
String str = "";
String wholeStr = "";
while((str = reader.readLine()) != null){
wholeStr += str;
}
LOG.info("encode:"+wholeStr);
JSONObject postJson= JSON.parseObject(wholeStr);
//Platform order number
String orderId = postJson.getString("orderId");
//Your merchant order number
String merchantOrderId = postJson.getString("merchantOrderId");
//Cheezee platform advertisement number
String entrustOrderId = postJson.getString("entrustOrderId");
//Cryptocurrency USDT
String coin = postJson.getString("coin");
//Legal tender INR
String legalCoin = postJson.getString("legalCoin");
//Number of cryptocurrency transactions
String dealQuantity = postJson.getString("dealQuantity");
//Legal tender amount
String dealAmount = postJson.getString("dealAmount");
//Fixed: 2
String tradeType = postJson.getString("tradeType");
//Unit price (price)
String price = postJson.getString("price");
//Creation time
String gmtCreate = postJson.getString("gmtCreate");
//Merchant ID
String merchantId = postJson.getString("merchantId");
//Type, for example: Quick collection 2
String orderType = postJson.getString("orderType");
//Merchant user ID
String customerMerchantsId = postJson.getString("customerMerchantsId");
//Signature
String platSign = postJson.getString("platSign");

Success Response Demo:

{
  "merchantOrderId": "Merchant Order Number",
  "orderId": "Platform order number",
  "merchantId": "Merchant ID",
  "entrustOrderId": "Advertisement number",
  "coin": "Cryptocurrency name",
  "legalCoin": "Legal tender name",
  "dealQuantity": "Number of cryptocurrency transactions",
  "dealAmount": "Legal tender amount",
  "tradeType": "Fixed 2",
  "price": "Unit price (fixed exchange rate, price)",
  "gmtCreate": "Start time",
  "orderType": "Quick collection type: 2",
  "customerMerchantsId": "Merchant user ID",
  "platSign": "Signature"
}

Fail Response Demo:

{
  "success": false,
  "code": "errorCode",
  "msg": "errorMessage",
  "data": null
}

The domain has a test environment and a production environment, which have different domain names. Please note...

HTTP Request

POST https://{Merchant's address to receive exchange rate verification.}

Parameters

Parameter Default type length Description
orderId true Long 32 Platform order number
entrustOrderId true Long 32 Advertisement number
merchantOrderId true String 32 Merchant order number
coin true String 32 Cryptocurrency name
legalCoin true String 32 Legal tender name
dealQuantity true String 32 Number of cryptocurrency transactions
dealAmount true String 32 Legal tender amount
tradeType true Integer 32 Fixed 2
price true String 32 Unit price (price)
gmtCreate true Date - Start time
merchantId true String 32 Merchant ID
orderType true Integer 2 Quick collection type 2
customerMerchantsId true String 32 Merchant user ID
platSign true String 32 Signature

Response

Field type Description
code Integer 200

Notice of change of large amount payment bank card

This interface is provided by merchant. When the large amount payment bank card changes, the platform requests this interface.

When receiving an HTTP request, please respond with httpcode=200 (HTTP response status code)

HTTP Request

POST https://{Notification address}

Parameters

Field type Description
id string Unique ID
name string Payee Name
accountNumber string Bank card number
ifscCode string IFSC
bankName string Bank name
branchName string Branch name
status int Bank card status
0 online、 1 offline
operationType int Operation type
0Add 、1Edit、 2Online、 3Offline、 4Delete
operationTime long Trigger time (timestamp: milliseconds)
platSign string sign

Response

An HTTP response status code of 200 represents successful notification, and other codes represent failed notification.

Notification message example

{
    "id": "25",
    "name": "Sachin Pujeri",
    "accountNumber": "41459877630",
    "ifscCode": "SBIN0000899",
    "bankName": "State Bank of India",
    "branchName": "sagar Bank",
    "status": 0,
    "operationType": 0,
    "operationTime": 1705128180000,
    "platSign": "EcCs7GlN1UzEAflgpyJ4lKIHe9+lS/gdkcEvWI+nSlcvvz1c+Dg4Zi8sFmpYaoOMGxS3/BY66FGq2TXzVGhAciq2kFmwZFtYbFvr7xPTaNf/n0Ru7ZtV/jo3uBnfc9/JI6XlEWlIbPtGsVpH7CLhzghdqIT+YbPEdhX2ZKETFTTfIj6PzctY9eOsZ51YbHYnXv0jTWn1hdPoDofAF9RmoNaXK4FGYibQBSvVA6w4rM6hCXlbTeHdMc4askrZlrHeG3uhyD34VlXs74cdzAZ+oROMXBcgXR4ObsJVDFz9tsJH92iaxlKTF0lEFZa/To5ezLpHvTOAK0uY/K6IxvOAAg=="
}

large amount payment bank card query

Map<String, Object> map = new HashMap<String, Object>();
map.put("merchantsId", "merchant id");
map.put("pageIndex", "Number of pages");

String platSign = RSAUtil.getSign(map , privateKey);
map.put("platSign",platSign);

String returnObj = CheesehubRsaAndHttpUtils.doPostJsonSetTimeout("https://{domain}/business/largeAmountPaymentBankCard/query", JSON.toJSONString(map));
JSONObject jsonObject = JSONObject.parseObject(returnObj);
System.out.println("returnObj:"+returnObj);
if("000000".equals(jsonObject.getString("code"))){
    ObjectMapper objectMapper = new ObjectMapper();
    Map<String, Object> map1 = objectMapper.readValue(returnObj, Map.class);
    if(RSAUtil.verifySign(map1 , platpublicKey)){
        System.out.println("pass");
        JSONObject pageData = jsonObject.getJSONObject("data");
        JSONArray records = pageData.getJSONArray("records");
        Integer pageIndex = pageData.getInteger("pageIndex");
        Integer pageSize = pageData.getInteger("pageSize");
        Integer totalPages = pageData.getInteger("totalPages");
        Integer totalCount = pageData.getInteger("totalCount");
    }else {
        System.out.println("no pass");
    }
}else{
    jsonObject.getBoolean("success");
    jsonObject.getString("code");
    jsonObject.getString("msg");
}

Example of successful response:

{
    "success": true,
    "code": "000000",
    "msg": "success",
    "data": {
        "records": [
            {
                "id": "Unique ID",
                "name": "Payee Name",
                "accountNumber": "Bank card number",
                "ifscCode": "IFSC",
                "bankName": "Bank name",
                "branchName": "Branch name",
                "status": "Bank card status 0 online 1 offline"
            }
        ],
        "totalPages": "total pages",
        "totalCount": "total count",
        "pageSize": "page size",
        "pageIndex": "page index"
    },
    "platSign": "sign"
}

Example of failure response:

{
  "success": false,
  "code": "errorCode",
  "msg": "errorMessage",
  "data": null
}

The domain has a test environment and a production environment, which have different domain names. Please note...

HTTP Request

POST https://{domain}/business/largeAmountPaymentBankCard/query

Parameters

Field required Default type Description
platSign true string sign
merchantsId true string merchant id
pageIndex false 1 int Number of pages
accountNumber false string Bank card number
status false int Bank card status 0 online 1 offline

Response

Field type Description
success boolean true false
code string code
msg string msg
data object data
platSign string sign

data

Field type Description
records List<Record> Bank card information
totalPages int total pages
totalCount int The total amount
pageIndex int Number of pages
pageSize int Quantity per page

Record

Field type Description
id string Unique ID
name string Payee Name
accountNumber string Bank card number
ifscCode string IFSC
bankName string Bank name
branchName string Branch name
status int Bank card status 0 online 1 offline

P2P Payout

P2P Payout Order

JSONObject map = new JSONObject();
map.put("customerMerchantsId", "123456788");
map.put("takerType", "2");
map.put("legalCoin", "INR");
map.put("merchantsId", "000001");
map.put("dealAmount", "500");
map.put("tradeType", "1");
map.put("coin", "USDT");
map.put("language", "zh_hk");
map.put("takerName", "name");

//UPI
map.put("payeeAccountType", "[UPI]");
map.put("payeeAccountTypeName", "UPI");
JSONArray array= new JSONArray();
JSONObject obj = new JSONObject();
obj.put("field","UPI_FIELD1");
obj.put("type","text");
obj.put("required",true);
obj.put("value","***Name***");
array.add(obj);
JSONObject obj2 = new JSONObject();
obj.put("field","UPI_FIELD2");
obj.put("type","text");
obj.put("required",true);
obj.put("value","***UPI ID***");
array.add(obj2);
//UPI


String platSign = RSAUtil.getSign(map , privateKey);
//The payeeAccountInfos parameter is not involved in signature generation and verification.
map.put("payeeAccountInfos", array);
map.put("platSign",platSign);

String returnObj = CheesehubRsaAndHttpUtils.doPostJsonSetTimeout("https://{domain}/business/c2c/entrustOrder/buyCashier", JSON.toJSONString(map));
JSONObject jsonObject = JSONObject.parseObject(returnObj);
System.out.println("returnObj:"+returnObj);
if("000000".equals(jsonObject.getString("code"))){
    ObjectMapper objectMapper = new ObjectMapper();
    Map<String, Object> map1 = objectMapper.readValue(returnObj, Map.class);
    if(RSAUtil.verifySign(map1 , platpublicKey)){
        System.out.println("pass");
    }else {
        System.out.println("no pass");
    }
}else{
    System.out.println("no pass");
}  


//PhonePe
map.put("payeeAccountType", "[PhonePe]");
map.put("payeeAccountTypeName", "PhonePe");
JSONArray array= new JSONArray();
JSONObject obj = new JSONObject();
obj.put("field","PHONE_PE_FIELD1");
obj.put("type","text");
obj.put("required",true);
obj.put("value","***Full name***");
array.add(obj);
JSONObject obj2 = new JSONObject();
obj2.put("field","PHONE_PE_FIELD2");
obj2.put("type","text");
obj2.put("required",true);
obj2.put("value","***Phone number***");
array.add(obj2);
//PhonePe

//Paytm
map.put("payeeAccountType", "[Paytm]");
map.put("payeeAccountTypeName", "Paytm");
JSONArray array= new JSONArray();
JSONObject obj = new JSONObject();
obj.put("field","PAYTM_FIELD1");
obj.put("type","text");
obj.put("required",true);
obj.put("value","***Name***");
array.add(obj);
JSONObject obj2 = new JSONObject();
obj2.put("field","PAYTM_FIELD2");
obj2.put("type","text");
obj2.put("required",true);
obj2.put("value","***Account***");
array.add(obj2);
//Paytm

//Bank Transfer(India)
map.put("payeeAccountType", "[Bank Transfer(India)]");
map.put("payeeAccountTypeName", "Bank Transfer(India)");
JSONArray array= new JSONArray();
JSONObject obj = new JSONObject();
obj.put("field","BANK_TRANSFER_INDIA_FIELD1");
obj.put("type","text");
obj.put("required",true);
obj.put("value","***Account holder name***");
array.add(obj);
JSONObject obj2 = new JSONObject();
obj2.put("field","BANK_TRANSFER_INDIA_FIELD2");
obj2.put("type","text");
obj2.put("required",true);
obj2.put("value","***Account no***");
array.add(obj2);
JSONObject obj3 = new JSONObject();
obj3.put("field","BANK_TRANSFER_INDIA_FIELD3");
obj3.put("type","text");
obj3.put("required",true);
obj3.put("value","***IFSC code***");
array.add(obj3);
JSONObject obj4 = new JSONObject();
obj4.put("field","BANK_TRANSFER_INDIA_FIELD4");
obj4.put("type","text");
obj.put("required",true);
obj4.put("value","***Account Type***");
array.add(obj4);
JSONObject obj5 = new JSONObject();
obj5.put("field","BANK_TRANSFER_INDIA_FIELD5");
obj5.put("type","text");
obj5.put("required",true);
obj5.put("value","***Bank name***");
array.add(obj5);
JSONObject obj6 = new JSONObject();
obj6.put("field","BANK_TRANSFER_INDIA_FIELD6");
obj6.put("type","text");
obj6.put("required",true);
obj6.put("value","***Branch name***");
array.add(obj6);
//Bank Transfer(India)


//IMPS
map.put("payeeAccountType", "[IMPS]");
map.put("payeeAccountTypeName", "IMPS");
JSONArray array= new JSONArray();
JSONObject obj = new JSONObject();
obj.put("field","IMPS_FIELD1");
obj.put("type","text");
obj.put("required",true);
obj.put("value","***Account Name***");
array.add(obj);
JSONObject obj2 = new JSONObject();
obj2.put("field","IMPS_FIELD2");
obj2.put("type","text");
obj2.put("required",true);
obj2.put("value","***Bank account number***");
array.add(obj2);
JSONObject obj3 = new JSONObject();
obj3.put("field","IMPS_FIELD3");
obj3.put("type","text");
obj3.put("required",true);
obj3.put("value","***IFSC code***");
array.add(obj3);
JSONObject obj4 = new JSONObject();
obj4.put("field","IMPS_FIELD4");
obj4.put("type","text");
obj.put("required",true);
obj4.put("value","***Account Type***");
array.add(obj4);
JSONObject obj5 = new JSONObject();
obj5.put("field","IMPS_FIELD5");
obj5.put("type","text");
obj5.put("required",true);
obj5.put("value","***Bank name***");
array.add(obj5);
JSONObject obj6 = new JSONObject();
obj6.put("field","IMPS_FIELD6");
obj6.put("type","text");
obj6.put("required",true);
obj6.put("value","***Branch name***");
array.add(obj6);
//IMPS

Success Response Demo JSON:

{
  "success": true,
  "code": "000000",
  "msg": "success",
  "data": {
    "orderId": "***orderId***"
  },
  "platSign": "Sign"
}

Fail Response Demo:

{
  "success": false,
  "code": "errorCode",
  "msg": "errorMessage",
  "data": null
}

The domain has a test environment and a production environment, which have different domain names. Please note...

HTTP Request

POST https://{domain}/business/c2c/entrustOrder/buyCashier

Parameters

Parameter Default type length Description
platSign true String 255 Signature
customerMerchantsId true String 32 Unique identifier of the user's merchant, passed in the Cashier API
legalCoin true String 10 Legal tender name, currently supports INR and IDR
coin true String 10 Fixed: USDT
merchantsId true String 32 Merchant ID
dealAmount true Integer 10 Legal tender amount
tradeType true Integer 2 Fixed: 1
takerType true Integer 2 Fixed: 2
takerName true String 32 User name, for example: jack wang
merchantOrderId true String 32 Merchant order number - unique
language true String 32 zh_hk Chinese; VI Vietnamese; en English; Indonesia Indonesian
payeeAccountType true String 32 Payment method, for example: [Bank Transfer(India)]
payeeAccountTypeName true String 32 Payment method name, for example: Bank Transfer(India)
payeeAccountInfos true array 32 Payment method info array The payeeAccountInfos parameter is not involved in signature generation and verification.
pushAddress true String 64 Notification callback address
payeeAccountInfos
The payeeAccountInfos parameter is not involved in signature generation and verification.
Parameter Default type length Description
field true String 64 Parameter name, for example: Name
type true String 64 Type, for example: text
required true String 64 Whether it is required, for example: true
value true String 64 Value

Response

Field type Description
success Boolean true false
code String code
msg String msg
data Object data
platSign String sign

P2P Payout Notification

LOG.info("==============Pay1.1===================");
HttpServletRequest request = this.getRequest();
request.setCharacterEncoding("UTF-8");
BufferedReader reader = new BufferedReader(new InputStreamReader(request.getInputStream()));
String str = "";
String wholeStr = "";
while((str = reader.readLine()) != null){//
wholeStr += str;
}
LOG.info("encode:"+wholeStr);
JSONObject postJson= JSON.parseObject(wholeStr);
// Quick withdrawal order
String orderId = postJson.getString("orderId");
// Your merchant order number
String merchantsOrderId = postJson.getString("merchantsOrderId");
String data = postJson.getString("data");
// Parsing
JSONObject dataJosn = JSONObject.parseObject(data);
// Status: 4 successful, 5 failed, 7 failed (price not accepted), 9 failed (refund)
String status = dataJosn.getString("status");
// Cryptocurrency
String coin = dataJosn.getString("coin");
// Merchant user ID
String customerMerchantsId = dataJosn.getString("customerMerchantsId");
// Legal tender amount
String dealAmount = dataJosn.getString("dealAmount");
// Number of cryptocurrencies
String dealQuantity = dataJosn.getString("dealQuantity");
// Advertisement number
String entrustOrderId = dataJosn.getString("entrustOrderId");
// Fee currency
String feeCoin = dataJosn.getString("feeCoin");
// Creation time in milliseconds
String gmtCreate = dataJosn.getString("gmtCreate");
// End time in milliseconds
String gmtEnd = dataJosn.getString("gmtEnd");
// Legal tender unit
String legalCoin = dataJosn.getString("legalCoin");
// Platform order number
String orderId = dataJosn.getString("orderId");
// Unit price
String price = dataJosn.getString("price");
// C2C
String side = dataJosn.getString("side");
// Merchant fee
String takerFee = dataJosn.getString("takerFee");
// User platform ID
String takerId = dataJosn.getString("takerId");
// Taker's nickname
String takerName = dataJosn.getString("takerName");
// Quick withdrawal 1
String tradeType = dataJosn.getString("tradeType");
// Payment method name
String payWayName = dataJosn.getString("payWayName");

Request JSON:

{
  "merchantsOrderId": "Merchant Order Number",
  "orderId": "Platform Order Number",
  "merchantId": "Merchant ID",
  "data": {
    "orderId": "Platform Withdrawal Order Number",
    "status": "Order Status",
    "coin": "Cryptocurrency",
    "dealAmount": "Legal Tender Amount",
    "dealQuantity": "Number of Cryptocurrencies",
    "entrustOrderId": "Advertisement Number",
    "feeCoin": "Fee Currency",
    "legalCoin": "Legal Tender Unit",
    "price": "Unit Price",
    "takerFee": "Merchant Fee",
    "takerId": "User Platform ID",
    "takerName": "Taker's Nickname",
    "tradeType": "Quick Withdrawal 1",
    "payWayName": "Payment Method Name",
    "side": "C2C",
    "customerMerchantsId": "Merchant User ID"
  }
}

Success Response Demo:

{
  "code": "200"
}

Fail Response Demo:

{
  "code": "errorCode"
}

The domain has a test environment and a production environment, which have different domain names. Please pay attention...

HTTP Request

POST https://{The address where the merchant accepts asynchronous callbacks}

Parameters

Parameter Default type length Description
orderId true String 32 Platform order number.
merchantsOrderId true String 32 Merchant order number.
merchantId true String 10 Merchant ID.
status true String 2 3 successful, 4 successful, 5 failed, 7 failed (price not accepted), 9 failed (refund).
coin true String 10 Cryptocurrency unit.
customerMerchantsId true String 32 Merchant user ID.
dealAmount true String 40 Legal tender trading amount.
dealQuantity true String 40 Number of cryptocurrencies for settlement.
entrustOrderId true String 40 Advertisement number.
feeCoin true String 10 Fee unit.
gmtCreate true Date 10 Creation time in milliseconds.
gmtEnd true Date 10 End time in milliseconds.
legalCoin true String 10 Legal tender unit.
orderId true String 40 Platform order number.
payWayName true String 64 Payment method.
price true String 40 Unit price.
side true String 10 Business type C2C.
takerFee true String 40 Merchant fee.
tradeType true String 2 Quick withdrawal 1.
takerId true String 40 Taker's ID.
takerName true String 64 Taker's nickname.
payWayName true String 64 Payment method name.

Response

Field type Description
code Integer 200

Exchange Rate Verification Interface

LOG.info("==============Pay1.1===================");
HttpServletRequest request = this.getRequest();
request.setCharacterEncoding("UTF-8");
BufferedReader reader = new BufferedReader(new InputStreamReader(request.getInputStream()));
String str = "";
String wholeStr = "";
while((str = reader.readLine()) != null){//
wholeStr += str;
}
LOG.info("encode:"+wholeStr);
JSONObject postJson= JSON.parseObject(wholeStr);
// Platform order number
String orderId = postJson.getString("orderId");
// Your merchant order number
String merchantOrderId = postJson.getString("merchantOrderId");
// Cheezee platform advertisement number
String entrustOrderId = postJson.getString("entrustOrderId");
// Cryptocurrency - USDT
String coin = postJson.getString("coin");
// Legal tender - INR
String legalCoin = postJson.getString("legalCoin");
// Number of cryptocurrencies for settlement
String dealQuantity = postJson.getString("dealQuantity");
// Legal tender trading amount
String dealAmount = postJson.getString("dealAmount");
// Fixed: 1
String tradeType = postJson.getString("tradeType");
// Unit price
String price = postJson.getString("price");
// Creation time
String gmtCreate = postJson.getString("gmtCreate");
// Merchant ID
String merchantId = postJson.getString("merchantId");
// Type, for example: 1 Quick withdrawal
String orderType = postJson.getString("orderType");
// Merchant user ID
String customerMerchantsId = postJson.getString("customerMerchantsId");
// Signature
String platSign = postJson.getString("platSign");

Request JSON:

{
  "merchantOrderId": "Merchant Order Number",
  "orderId": "Platform Order Number",
  "merchantId": "Merchant ID",
  "entrustOrderId": "Advertisement Number",
  "coin": "Cryptocurrency Name",
  "legalCoin": "Legal Tender Name",
  "dealQuantity": "Number of Cryptocurrencies for Settlement",
  "dealAmount": "Legal Tender Trading Amount",
  "tradeType": "Fixed Value: 1",
  "price": "Unit Price (Fixed Exchange Rate)",
  "gmtCreate": "Start Time",
  "orderType": "Quick Withdrawal Type: 1",
  "customerMerchantsId": "Merchant User ID",
  "platSign": "Signature"
}

Success Response Demo:

{
  "code": "200"
}

Fail Response Demo:

{
  "code": "errorCode"
}

The domain has a test environment and a production environment, which have different domain names. Please pay attention...

HTTP Request

POST https://{The URL address where the merchant accepts exchange rate verification}

Parameters

Parameter Default type length Description
orderId true Long 32 Platform order number
entrustOrderId true Long 32 Advertisement number
merchantOrderId true String 32 Merchant order number
coin true String 32 Cryptocurrency name
legalCoin true String 32 Legal tender name
dealQuantity true String 32 Number of cryptocurrencies for settlement
dealAmount true String 32 Legal tender trading amount
tradeType true Integer 32 Fixed value: 1
price true String 32 Unit price (Fixed exchange rate)
gmtCreate true Date - Start time
merchantId true String 32 Merchant ID
orderType true Integer 2 Quick withdrawal type: 1
customerMerchantsId true String 32 Merchant user ID
platSign true String 32 Signature

Response

Field type Description
code Integer 200

Errors Code

The Payment API uses the following error codes:

Error Code Meaning
400 Bad Request - Your request is invalid.
401 Unauthorized - Your API key is incorrect.
403 Forbidden - The requested cat is only hidden from administrators.
404 Not Found -- The specified cat cannot be found.
405 Method Not Allowed -- You attempted to access the cat using an invalid method.
406 Not Acceptable - Your requested format is not json.
410 Gone - The requested cat has been removed from our servers.
418 I'm a teapot
429 Too Many Requests -- You have requested too many cats! Slow down!
500 Internal Server Error -- We had a problem with our server. Try again later.
503 Service Unavailable -- We're temporarily offline for maintenance. Please try again later.
000000 Success.
NF00001 Cannot be empty.
999999 Unknown error.
AS00002 Insufficient asset balance.
000001 No access permission.
ad0001 Address does not exist.
666666 Please check the parameters!
555555 Temporarily unable to withdraw coins, please contact the platform!
333333 Tron Chain Format verification failed!
100001 Merchant has closed business
100003 Merchant has closed
100002 Merchant currency has stopped operations
100004 Merchant currency has stopped
100005 The merchant has not enabled this currency
100006 Incorrect operation type
100007 User not found
100008 User account not found
100009 User address not found
100010 The order already exists and the order number cannot be repeated
800000 Invalid amount number
800001 The amount must be greater than or equal to the minimum deposit amount
800002 The amount must be greater than or equal to the minimum withdrawal amount
800003 Failed to change the balance.
C0667 field cannot be empty
A0400 User request parameter error
A0410 Required parameter is empty in the request
A0441 User payment timeout
A0442 Confirmation of order timeout
A0443 Order has been closed
A0445 Matching failed
A0446 Cancellation failed
A0452 Transaction closed
A0458 User is closed
A0465 User is abnormal and cannot trade
A0466 Order fiat currency precision exceeds the limit
A0467 Failed to place order
A0468 Order matching failed
A0469 Order does not exist
A0470 User has exceeded the maximum number of daily cancellations
A0471 Merchant not found
A0472 Merchant requires user identification, but user is not verified
A0473 User is prohibited from quick withdrawal
A0474 User is prohibited from quick collection
A0475 User places an order, but merchant fails to verify the exchange rate
A0477 Order cannot be modified to this payment method
A0478 Failed to modify payment method
A0479 Failed to confirm receipt
A0480 Merchant prohibits quick collection
A0481 Merchant prohibits quick withdrawal
A0485 Digital currency precision exceeds the limit
A0486 Minimum transaction amount in fiat currency exceeds the limit
A0487 Maximum transaction amount in fiat currency exceeds the limit
A0488 Exchange rate not found
A0490 Current operation only supports USDT
A0491 Order fiat currency must be greater than 0
A0494 There are ongoing orders, current operation failed
A0495 Failed to place order
A0496 Failed to place order, price is too high
A0497 Merchant order number cannot be duplicated
A0541 Quick withdrawal, matching failed
A0542 Quick withdrawal, price rejected, order failed
A0543 Market is closed
A0544 Configuration missing, please contact customer service
A0601 Insufficient account balance
A0659 Order is less than the minimum quantity
A0660 Order exceeds the maximum quantity
A0664 Quick withdrawal order cannot use this interface
A0665 Quick collection order cannot use this interface
A0669 Digital currency is required
A0670 Fiat currency is required
A0672 Exchange rate exception
A0673 Order digital currency precision exceeds the limit
A0675 Transaction amount is less than the minimum limit
A0676 Transaction amount exceeds the maximum limit
A0680 Table does not exist
A0681 name is null
A0682 utr is null
A0683 utr length is not 12
A0684 utr is not number