Closed xhw357972897 closed 1 year ago
"yansongda/pay": "~3.2.0"
发放代金券批次API请求错误
` Pay::config($config);
$allPlugins = Pay::wechat()->mergeCommonPlugins([SendPlugin::class]); $params = [ 'stock_id' => 17******985, 'out_request_no' => time(), 'appid' => 'wx1f*********690', 'stock_creator_mchid' => '1614*****08', 'openid' => 'ogOC********dArDM',//'123123',//$third['openid'], ]; $result = Pay::wechat()->pay($allPlugins, $params);`
object(Yansongda\Supports\Collection)#75 (1) { ["items":protected] => array(3) { ["code"] => string(11) "PARAM_ERROR" ["detail"] => array(2) { ["location"] => string(12) "uri_template" ["value"] => string(0) "" } ["message"] => string(117) "输入源“/uri_template/stock_id”映射到字段“批次id”必填性规则校验失败,此字段为必填项" } }
2023-04-10T11:30:26.395735+08:00 > yansongda.pay.INFO > [AbstractProvider] 准备请求支付服务商 API {"radar":{"Yansongda\Pay\Request":{"url":"https://api.mch.weixin.qq.com/v3/certificates","method":"GET","headers":{"Host":["api.mch.weixin.qq.com"],"Accept":["application/json, text/plain, application/x-gzip"],"User-Agent":["yansongda/pay-v3"],"Content-Type":["application/json; charset=utf-8"],"Authorization":["WECHATPAY2-SHA256-RSA2048 mchid=\"1614*08\",nonce_str=\"86ZCv9k6iaAOtej2XGjlMyzt3EpIqH0D\",timestamp=\"1681097426\",serial_no=\"62DFD5C268FD2A3C5C996477DD301E58C7702A68\",signature=\"AmmXReBUpChFQ3DlTTo3fghdLPQqHGtrRPRK5JdZXsBDBjt5fRPmLq6NzhrYlldqrhV7Ccjr4v40F4jcxPseY/12gUPjQQj3LstteIGzF8SLR0LCR0aeTLAHSQPOORSHacGNUUFATEecYgfSDlC8TfnYfl++RE6ztsUjfU/Uh7rmzjbMa4qoXKoW/4hpk+WklwCWyNRaN14nAn8kyavVQ2SZmeVBBs8Lbiy5SxCYsecnSO7pp5Xpvc1oQ1PeyGKDM5MbJqy6HP4TGnz220nwab/19LlOguOeJgUgIlU+wrsXjS46iPuHwFm5sYSCoIW/RK34LqMGf8q1j1nWPA//FA==\""]},"body":""}},"params":{"stock_id":17**985,"out_request_no":1681097426,"appid":"wx1f*****690","stock_creator_mchid":"1614*08","openid":"ogOC****dArDM"},"payload":null,"direction":null,"destination":null,"destination_origin":null}
2023-04-10T11:30:26.529928+08:00 > yansongda.pay.INFO > [AbstractProvider] 请求支付服务商 API 成功 {"response":{"GuzzleHttp\Psr7\Response":[]},"rocket":{"radar":{"Yansongda\Pay\Request":{"url":"https://api.mch.weixin.qq.com/v3/certificates","method":"GET","headers":{"Host":["api.mch.weixin.qq.com"],"Accept":["application/json, text/plain, application/x-gzip"],"User-Agent":["yansongda/pay-v3"],"Content-Type":["application/json; charset=utf-8"],"Authorization":["WECHATPAY2-SHA256-RSA2048 mchid=\"1614*08\",nonce_str=\"86ZCv9k6iaAOtej2XGjlMyzt3EpIqH0D\",timestamp=\"1681097426\",serial_no=\"62DFD5C268FD2A3C5C996477DD301E58C7702A68\",signature=\"AmmXReBUpChFQ3DlTTo3fghdLPQqHGtrRPRK5JdZXsBDBjt5fRPmLq6NzhrYlldqrhV7Ccjr4v40F4jcxPseY/12gUPjQQj3LstteIGzF8SLR0LCR0aeTLAHSQPOORSHacGNUUFATEecYgfSDlC8TfnYfl++RE6ztsUjfU/Uh7rmzjbMa4qoXKoW/4hpk+WklwCWyNRaN14nAn8kyavVQ2SZmeVBBs8Lbiy5SxCYsecnSO7pp5Xpvc1oQ1PeyGKDM5MbJqy6HP4TGnz220nwab/19LlOguOeJgUgIlU+wrsXjS46iPuHwFm5sYSCoIW/RK34LqMGf8q1j1nWPA//FA==\""]},"body":""}},"params":{"stock_id":17**985,"out_request_no":1681097426,"appid":"wx1f*****690","stock_creator_mchid":"1614*08","openid":"ogOC****dArDM"},"payload":null,"direction":null,"destination":{"GuzzleHttp\Psr7\Response":[]},"destination_origin":{"GuzzleHttp\Psr7\Response":[]}}}
2023-04-10T11:30:26.530655+08:00 > yansongda.pay.INFO > [wechat][LaunchPlugin] 插件装载完毕 {"rocket":{"Yansongda\Pay\Rocket":{"radar":{"url":"https://api.mch.weixin.qq.com/v3/marketing/favor/users/ogOC********dArDM/coupons","method":"POST","headers":{"Host":["api.mch.weixin.qq.com"],"Accept":["application/json, text/plain, application/x-gzip"],"User-Agent":["yansongda/pay-v3"],"Content-Type":["application/json; charset=utf-8"],"Authorization":["WECHATPAY2-SHA256-RSA2048 mchid=\"161408\",nonce_str=\"nAnSwvI46CZH5tTBJd6nrlxiaq0nnYD4\",timestamp=\"1681097426\",serial_no=\"62DFD5C268FD2A3C5C996477DD301E58C7702A68\",signature=\"SJuoPXWq5jXzoRSeqzvl8VW7Zqk8iOkmjtnmNaZksCFE0VPJnQ9zLzYow8uQN3hl//yjnVhL1eeW/6N5rfPsaqi4OsX3eWC1sE6XOgoC3W+YxJZhHaMUx/R1qdmDuifhKVREgDyfDZ/QopWqlMfzs8fjytKkQxnrTp+nrpLVE854zE/qv8Ntm0eRLT17FLenrX/kFHEbPyZOOtOXmVz0RV7QMzx/x7Kxu5WhfeKRr8kqGwAWyfa6dpA8NUpVP4D6R+FrY4rkiUCBL80hgzrRyCQYg6lNEJbefGhUmha5T258DbSlMQHM5e09WEq9vPVgbEvBy/0c22GPD5jZkDEtBw==\""]},"body":"{\"stock_creator_mchid\":\"161408\"}"},"params":{"stock_id":17**985,"out_request_no":1681097426,"appid":"wx1f****690","stock_creator_mchid":"161408","openid":"ogOC****dArDM"},"payload":{"stock_creator_mchid":"1614*****08"},"direction":null,"destination":{"code":"PARAM_ERROR","detail":{"location":"uri_template","value":""},"message":"输入源“/uri_template/stock_id”映射到字段“批次id”必填性规则校验失败,此字段为必填项"},"destination_origin":{}}}}
涉及到 异步通知、同步通知 的问题,请贴出来
是有 bug,今天晚些时候我处理下
看了下,代金券的有一些都有点儿问题。这周我都统一检查下吧
看了下,代金券的有一些都有点儿问题。 这周我都统一检查下吧
好的期待新的版本
包版本号
"yansongda/pay": "~3.2.0"
问题描述
发放代金券批次API请求错误
你的代码
` Pay::config($config);
报错详情
object(Yansongda\Supports\Collection)#75 (1) { ["items":protected] => array(3) { ["code"] => string(11) "PARAM_ERROR" ["detail"] => array(2) { ["location"] => string(12) "uri_template" ["value"] => string(0) "" } ["message"] => string(117) "输入源“/uri_template/stock_id”映射到字段“批次id”必填性规则校验失败,此字段为必填项" } }
sdk 日志
2023-04-10T11:30:26.395735+08:00 > yansongda.pay.INFO > [AbstractProvider] 准备请求支付服务商 API {"radar":{"Yansongda\Pay\Request":{"url":"https://api.mch.weixin.qq.com/v3/certificates","method":"GET","headers":{"Host":["api.mch.weixin.qq.com"],"Accept":["application/json, text/plain, application/x-gzip"],"User-Agent":["yansongda/pay-v3"],"Content-Type":["application/json; charset=utf-8"],"Authorization":["WECHATPAY2-SHA256-RSA2048 mchid=\"1614*08\",nonce_str=\"86ZCv9k6iaAOtej2XGjlMyzt3EpIqH0D\",timestamp=\"1681097426\",serial_no=\"62DFD5C268FD2A3C5C996477DD301E58C7702A68\",signature=\"AmmXReBUpChFQ3DlTTo3fghdLPQqHGtrRPRK5JdZXsBDBjt5fRPmLq6NzhrYlldqrhV7Ccjr4v40F4jcxPseY/12gUPjQQj3LstteIGzF8SLR0LCR0aeTLAHSQPOORSHacGNUUFATEecYgfSDlC8TfnYfl++RE6ztsUjfU/Uh7rmzjbMa4qoXKoW/4hpk+WklwCWyNRaN14nAn8kyavVQ2SZmeVBBs8Lbiy5SxCYsecnSO7pp5Xpvc1oQ1PeyGKDM5MbJqy6HP4TGnz220nwab/19LlOguOeJgUgIlU+wrsXjS46iPuHwFm5sYSCoIW/RK34LqMGf8q1j1nWPA//FA==\""]},"body":""}},"params":{"stock_id":17**985,"out_request_no":1681097426,"appid":"wx1f*****690","stock_creator_mchid":"1614*08","openid":"ogOC****dArDM"},"payload":null,"direction":null,"destination":null,"destination_origin":null}
2023-04-10T11:30:26.529928+08:00 > yansongda.pay.INFO > [AbstractProvider] 请求支付服务商 API 成功 {"response":{"GuzzleHttp\Psr7\Response":[]},"rocket":{"radar":{"Yansongda\Pay\Request":{"url":"https://api.mch.weixin.qq.com/v3/certificates","method":"GET","headers":{"Host":["api.mch.weixin.qq.com"],"Accept":["application/json, text/plain, application/x-gzip"],"User-Agent":["yansongda/pay-v3"],"Content-Type":["application/json; charset=utf-8"],"Authorization":["WECHATPAY2-SHA256-RSA2048 mchid=\"1614*08\",nonce_str=\"86ZCv9k6iaAOtej2XGjlMyzt3EpIqH0D\",timestamp=\"1681097426\",serial_no=\"62DFD5C268FD2A3C5C996477DD301E58C7702A68\",signature=\"AmmXReBUpChFQ3DlTTo3fghdLPQqHGtrRPRK5JdZXsBDBjt5fRPmLq6NzhrYlldqrhV7Ccjr4v40F4jcxPseY/12gUPjQQj3LstteIGzF8SLR0LCR0aeTLAHSQPOORSHacGNUUFATEecYgfSDlC8TfnYfl++RE6ztsUjfU/Uh7rmzjbMa4qoXKoW/4hpk+WklwCWyNRaN14nAn8kyavVQ2SZmeVBBs8Lbiy5SxCYsecnSO7pp5Xpvc1oQ1PeyGKDM5MbJqy6HP4TGnz220nwab/19LlOguOeJgUgIlU+wrsXjS46iPuHwFm5sYSCoIW/RK34LqMGf8q1j1nWPA//FA==\""]},"body":""}},"params":{"stock_id":17**985,"out_request_no":1681097426,"appid":"wx1f*****690","stock_creator_mchid":"1614*08","openid":"ogOC****dArDM"},"payload":null,"direction":null,"destination":{"GuzzleHttp\Psr7\Response":[]},"destination_origin":{"GuzzleHttp\Psr7\Response":[]}}}
2023-04-10T11:30:26.530655+08:00 > yansongda.pay.INFO > [wechat][LaunchPlugin] 插件装载完毕 {"rocket":{"Yansongda\Pay\Rocket":{"radar":{"url":"https://api.mch.weixin.qq.com/v3/marketing/favor/users/ogOC********dArDM/coupons","method":"POST","headers":{"Host":["api.mch.weixin.qq.com"],"Accept":["application/json, text/plain, application/x-gzip"],"User-Agent":["yansongda/pay-v3"],"Content-Type":["application/json; charset=utf-8"],"Authorization":["WECHATPAY2-SHA256-RSA2048 mchid=\"161408\",nonce_str=\"nAnSwvI46CZH5tTBJd6nrlxiaq0nnYD4\",timestamp=\"1681097426\",serial_no=\"62DFD5C268FD2A3C5C996477DD301E58C7702A68\",signature=\"SJuoPXWq5jXzoRSeqzvl8VW7Zqk8iOkmjtnmNaZksCFE0VPJnQ9zLzYow8uQN3hl//yjnVhL1eeW/6N5rfPsaqi4OsX3eWC1sE6XOgoC3W+YxJZhHaMUx/R1qdmDuifhKVREgDyfDZ/QopWqlMfzs8fjytKkQxnrTp+nrpLVE854zE/qv8Ntm0eRLT17FLenrX/kFHEbPyZOOtOXmVz0RV7QMzx/x7Kxu5WhfeKRr8kqGwAWyfa6dpA8NUpVP4D6R+FrY4rkiUCBL80hgzrRyCQYg6lNEJbefGhUmha5T258DbSlMQHM5e09WEq9vPVgbEvBy/0c22GPD5jZkDEtBw==\""]},"body":"{\"stock_creator_mchid\":\"161408\"}"},"params":{"stock_id":17**985,"out_request_no":1681097426,"appid":"wx1f****690","stock_creator_mchid":"161408","openid":"ogOC****dArDM"},"payload":{"stock_creator_mchid":"1614*****08"},"direction":null,"destination":{"code":"PARAM_ERROR","detail":{"location":"uri_template","value":""},"message":"输入源“/uri_template/stock_id”映射到字段“批次id”必填性规则校验失败,此字段为必填项"},"destination_origin":{}}}}
nginx/apache 日志