JSAPI 调起支付的时候提示缺少参数appId?

微信支付 文章 2021-03-04 06:41 1667 0 全屏看文

AI助手支持GPT4.0

JSAPI 调起支付的时候提示缺少参数appId?JSAPI prompts that the parameter appId is missing when calling up payment?

JSAPI 调起支付的时候提示缺少参数appId?

开发过程中用wx.chooseWXPay调起微信支付的时候,一直提示:调用支付JSAPI缺少参数:appId。

该传入的参数都已经传入了,然后发现一个问题就是:

在网页登录状态的时候wx.chooseWXPay就可以成功调起支,。同一个地方为什么会出现这样的问题呢

当我在网页退出登录状态的时候wx.chooseWXPay就怎么都无法调起支付,一直就提示缺少appId,在微信开发工具上打印的参数也都是正确的,求解答

在线等,急急急!

Use in the development process wx.chooseWXPay When wechat payment is called, it is always prompted that calling the payment jsapi lacks the parameter appid. All the parameters passed in have been passed in, and then a problem is found: when the web page is in login status wx.chooseWXPay We can successfully adjust the expenditure,. Why do I have such a problem in the same place when I log out of the website wx.chooseWXPay How can't start payment, has been prompted the lack of appid, the parameters printed on wechat development tools are also correct, seek answers online, etc., urgent!

回答:

微信支付技术社区运营-Tasting:

该问题可能是以下两个原因:

1,统一下单接口中上传的appid与调起微信客户端进行支付的appid不一致

2,调起微信客户端进行支付的必要参数prepayid有误或者prepayid已经过期(有效期2小时)


赵鉥丰:appid如果与调起的微信客户端的appid不一致的话 ,他应该会提示appid不一致的都嘛。是在同一个地方,所有的参数都是一样的,我的h5网页在登录的状态下,可以成功调起支付。但是h5网页退出登录状态才会提示缺少appid。
赵鉥丰:

wx.chooseWXPay 文档里面也没有说到要传appid呢,而且我传入了 还是没用



微喵网络:

传的参数发出来看看

赵鉥丰:wx.chooseWXPay调的时候 我打印了参数,wx.chooseWXPay调支付的时候不用传appid就可以调起来,我看他提示缺少appid,我现在传入的是死的值,还是不行

-EOF-

AI助手支持GPT4.0