🆕 #3138 【微信支付】增加接查询结算账户修改申请状态的接口

This commit is contained in:
Chiva Chen
2023-09-29 16:30:52 +08:00
committed by GitHub
parent d470e9a693
commit 85c46ebf70
4 changed files with 101 additions and 1 deletions

View File

@@ -71,4 +71,15 @@ public interface Applyment4SubService {
*/
String modifySettlement(String subMchid, ModifySettlementRequest request) throws WxPayException;
/**
* 查询结算账户修改申请状态
* 文档详见https://pay.weixin.qq.com/docs/partner/apis/modify-settlement/sub-merchants/get-application.html
* 接口链接https://api.mch.weixin.qq.com/v3/apply4sub/sub_merchants/{sub_mchid}/application/{application_no}
*
* @param subMchid
* @param applicationNo
* @return
* @throws WxPayException
*/
SettlementApplicationResult settlementApplication(String subMchid, String applicationNo) throws WxPayException;
}

View File

@@ -63,4 +63,11 @@ public class Applyment4SubServiceImpl implements Applyment4SubService {
encryptFiled(request);
return payService.postV3WithWechatpaySerial(url, GSON.toJson(request));
}
@Override
public SettlementApplicationResult settlementApplication(String subMchid, String applicationNo) throws WxPayException {
String url = String.format("%s/v3/apply4sub/sub_merchants/%s/application/%s", this.payService.getPayBaseUrl(), subMchid, applicationNo);
String result = payService.getV3(url);
return GSON.fromJson(result, SettlementApplicationResult.class);
}
}