Skip to content
des sdk implemented in JAVA
Branch: master
Clone or download
Type Name Latest commit message Commit time
Failed to load latest commit information.
.github/ISSUE_TEMPLATE Update issue templates Aug 20, 2018
src/main/java/com/gxb/sdk/des 修复黑名单智能网关签名字符串拼接的bug Jul 26, 2018
.gitignore des-sdk Apr 25, 2018
pom.xml modify pom.xml 1.2.47 Oct 25, 2018


data exchange service sdk


dependency setting:

Added to the pom.xml

then add a repository to pom.xml



MerchantClient client = new MerchantClient(MERCHANT_PRIVATEKEY, MERCHANT_ACCOUNT, DES_SERVER_URL);

//2、data exchange
JSONObject param = doParam();
//create a trade request to obtain request id
String requestId = client.createDataExchangeRequest(productId, param);
//get the data results by request id
DataExchangeDto result = client.getResult(requestId);


DatasourceClient client = new DatasourceClient(DATASOURCE_PRIVATEKEY, DATASOURCE_ACCOUNT, DES_SERVER_URL);
//start the heartbeat thread
ScheduledExecutorService es = Executors.newScheduledThreadPool(1);
es.scheduleAtFixedRate(() -> {
    try {
    } catch (Exception e) {
        log.error(e.getMessage(), e);
}, 5, 30, TimeUnit.SECONDS);

//2、query api
@RequestMapping(value = "/query", method = RequestMethod.POST)
public Object queryData(@RequestBody DataRequestParam requestParam) {
    //decrypt param
    JSONObject param = client.decrypt(requestParam);
    //query data
    ResponseObject data = queryData(param);
    //encrypt data
    return client.encrypt(data,requestParam);

Dev Document

You can’t perform that action at this time.