Closed wangcb closed 6 months ago
支付宝pc转二维码文档:https://opendocs.alipay.com/open/08ayiq?pathHash=a2d4e097 下面是支付宝文档返回的协议然后转二维码 AlipayClient alipayClient = new DefaultAlipayClient("https://openapi.alipay.com/gateway.do","app_id","your private_key","json","GBK","alipay_public_key","RSA2"); AlipayUserAgreementPageSignRequest request = new AlipayUserAgreementPageSignRequest(); request.setBizContent(参考上面的bizContent); //pageExecute get方式,生成url AlipayUserAgreementPageSignResponse response = alipayClient.pageExecute(request,"get"); //生成的url地址去除https://openapi.alipay.com/gateway.do signParams = response.getBody().replace("https://openapi.alipay.com/gateway.do?",""); //生成唤起客户端。把signParams使用 UTF-8 字符集整体做一次 encode return 'alipays://platformapi/startapp?appId=60000157&appClearTop=false&startMultApp=YES&sign_params='+ encode(signParams);
AlipayClient alipayClient = new DefaultAlipayClient("https://openapi.alipay.com/gateway.do","app_id","your private_key","json","GBK","alipay_public_key","RSA2"); AlipayUserAgreementPageSignRequest request = new AlipayUserAgreementPageSignRequest(); request.setBizContent(参考上面的bizContent); //pageExecute get方式,生成url AlipayUserAgreementPageSignResponse response = alipayClient.pageExecute(request,"get"); //生成的url地址去除https://openapi.alipay.com/gateway.do signParams = response.getBody().replace("https://openapi.alipay.com/gateway.do?",""); //生成唤起客户端。把signParams使用 UTF-8 字符集整体做一次 encode return 'alipays://platformapi/startapp?appId=60000157&appClearTop=false&startMultApp=YES&sign_params='+ encode(signParams);
支付宝pc转二维码文档:https://opendocs.alipay.com/open/08ayiq?pathHash=a2d4e097 下面是支付宝文档返回的协议然后转二维码
AlipayClient alipayClient = new DefaultAlipayClient("https://openapi.alipay.com/gateway.do","app_id","your private_key","json","GBK","alipay_public_key","RSA2"); AlipayUserAgreementPageSignRequest request = new AlipayUserAgreementPageSignRequest(); request.setBizContent(参考上面的bizContent); //pageExecute get方式,生成url AlipayUserAgreementPageSignResponse response = alipayClient.pageExecute(request,"get"); //生成的url地址去除https://openapi.alipay.com/gateway.do signParams = response.getBody().replace("https://openapi.alipay.com/gateway.do?",""); //生成唤起客户端。把signParams使用 UTF-8 字符集整体做一次 encode return 'alipays://platformapi/startapp?appId=60000157&appClearTop=false&startMultApp=YES&sign_params='+ encode(signParams);