|
|
|
@ -2,6 +2,7 @@ package com.ms.api.task;
|
|
|
|
|
|
|
|
|
|
import cn.hutool.core.date.DateUtil;
|
|
|
|
|
import cn.hutool.core.util.ObjectUtil;
|
|
|
|
|
import com.alibaba.fastjson.JSONObject;
|
|
|
|
|
import com.doudian.open.api.token_refresh.TokenRefreshRequest;
|
|
|
|
|
import com.doudian.open.api.token_refresh.TokenRefreshResponse;
|
|
|
|
|
import com.doudian.open.api.token_refresh.param.TokenRefreshParam;
|
|
|
|
@ -100,6 +101,7 @@ public class RefreshTokenTaskService extends TaskBaseService {
|
|
|
|
|
TokenRefreshParam param = request.getParam();
|
|
|
|
|
param.setRefreshToken(oldRefreshToken);
|
|
|
|
|
param.setGrantType("refresh_token");
|
|
|
|
|
log.info("TokenRefreshParam: " + JSONObject.toJSONString(param));
|
|
|
|
|
TokenRefreshResponse response = request.execute();
|
|
|
|
|
String newAccessToken = response.getData().getAccessToken();
|
|
|
|
|
String newRefreshToken = response.getData().getRefreshToken();
|
|
|
|
|