parent
d9fe632590
commit
de045fa8ab
|
@ -601,11 +601,11 @@ public class ApiService {
|
|||
ResponseEntity<String> response = restTemplate.postForEntity(linkUrl + "?access_token=" + token, requestEntity, String.class);
|
||||
if (response.getStatusCode().is2xxSuccessful()) {
|
||||
String responseBody = response.getBody() != null ? response.getBody() : "请求成功 → 无响应内容";
|
||||
logger.info("提交接口调用成功,响应成功信息:{}", responseBody);
|
||||
logger.info("提交接口调用成功,,请求体:{}\n响应成功信息:{}", requestBody, responseBody);
|
||||
return "提交接口 → 响应成功: " + responseBody;
|
||||
} else {
|
||||
String errorBody = response.getBody() != null ? response.getBody() : "请求失败 → 无响应内容";
|
||||
logger.info("提交接口调用失败,响应失败信息:{}", errorBody);
|
||||
logger.info("提交接口调用失败,请求体:{}\n响应失败信息:{}", requestBody, response);
|
||||
return "提交接口 → 响应失败: " + errorBody;
|
||||
}
|
||||
} catch (Exception e) {
|
||||
|
|
Loading…
Reference in New Issue