1 回复
wx.request({
//获取openid接口
url: ‘https://api.weixin.qq.com/sns/jscode2session’,
data: {
appid: APP_ID,
secret: APP_SECRET,
js_code: res.code,
grant_type: ‘authorization_code’
},
header: {
“Content-Type”: “application/text”
},
method: ‘GET’,
success: function (res) {
}
}