config和agentConfig的区别
- 所有的接口都需要config的注入权限,部分接口需要config和agentConfig的注入权限
agentConfig - 出现的问题
1 errMsg:“agentConfig:invalid corpId more info athttps://open.work.weixin.qq.com/devtool/query?e=40013”
- 解决:第三方公司配置的公司corpId和提供的企业微信corpId保持一致
2 errMsg:“agentConfig:invalid signature more info at https://open.work.weixin.qq.com/devtool/query?e=40093”
3 errMsg:“agentConfig:not match any reliable domain. more info at https://open.work.weixin.qq.com/devtool/query?e=80001”
- 解决:需要第三方配置或后台返回时设置可信域名,并下载对应的.txt文件,然后让后台把.txt文件放到当前页面对应的域名下做根域名校验
4 agentConfig 成功 但是分享的标题,内容,图片还是不生效
config - 出现的问题
1 {errCode:2,err_info:“invalid signature more info at https://open.work.weixin.qq.com/devtool/query?e=40093”,errMsg}
- 解决:第三方配置或后台返回时,应注意config的签名,随机字符串,时间戳和agentConfig的都不一样。config应使用自己的
<script src="https://res.wx.qq.com/open/js/jweixin-1.2.0.js"></script>
<script>
function shareWxa () {
wx.config({
beta: true,