收藏
回答

服务号里调用客户会话接口openCustomerServiceChat怎么没法使用呢?

调用以下接口出现:Uncaught TypeError: wx.openCustomerServiceChat is not a function

	wx.openCustomerServiceChat({
			corpid: '', // 企业微信客服需填企业ID,普通公众号客服留空
			url: '', // 可选:客服会话的欢迎语页面链接(需在公众号域名下)
			success: function(res) {
				console.log('唤起客服会话成功', res);
			},
			fail: function(res) {
				console.error('唤起客服会话失败', res);
				// 兼容处理:失败时引导用户手动进入客服
				alert('唤起客服失败,请点击公众号菜单【联系客服】');
			}
		});

回答关注问题邀请回答
收藏

1 个回答

登录 后发表内容