第三方平台代开发小程序 - 微信登录
1.获取code
https://open.weixin.qq.com/connect/oauth2/authorize?
appid=xxxxx
&redirect_uri=xxxxx
&response_type=code
&scope=snsapi_userinfo
&state=xxxxx&connect_redirect=1
2.微信登录
https://api.weixin.qq.com/sns/component/jscode2session?
js_code=0330cQIY0G86sY16FsGY0KHVIY00cQIa
&grantnt_type=authorization_code
&appid=小程序ID
&comxponeet_appid=xxx
&component_access_token=xxxx
得到
errcode: 48001
errmsg: "api unauthorized, hints: [ req_id: sELBZ8yFe-xxxx ]"
能否告知出现该错误的原因?以及【第三方代开发小程序-微信登录】的示例?
你好,请提供相关appid、完整请求、具体返回信息、具体操作时间
js_code: 023wYoI11rg8ES1dd3G11IxEI11wYoIr
grant_type: authorization_code
appid: wx8c4012c8476bdb86
component_appid: wx5c42a32e4f127af5
component_access_token: 32_-ZCjcuayl7lfLUvAAPyue3LJMlQWjG7l5Ql7Qq-WIf3eWJlk44u5Yr9ySB8Kn87023ByJu3jHKBoKwv_rnEEJ6_Jh2yYqgPCTvHuLaEDfwXWSjk6ICCLWF-pwJv8u8f_KcUrP2pmPuUtz4wVBXObAFDSOF
完整请求如下:
https://api.weixin.qq.com/sns/component/jscode2session?js_code=023wYoI11rg8ES1dd3G11IxEI11wYoIr&grant_type=authorization_code&appid=wx8c4012c8476bdb86&component_appid=wx5c42a32e4f127af5&component_access_token=32_-ZCjcuayl7lfLUvAAPyue3LJMlQWjG7l5Ql7Qq-WIf3eWJlk44u5Yr9ySB8Kn87023ByJu3jHKBoKwv_rnEEJ6_Jh2yYqgPCTvHuLaEDfwXWSjk6ICCLWF-pwJv8u8f_KcUrP2pmPuUtz4wVBXObAFDSOF
完整响应如下:
{errcode: 48001, errmsg: "api unauthorized, hints: [ req_id: tfLBQ0yFe-R ]"}
errcode: 48001
errmsg: "api unauthorized, hints: [ req_id: tfLBQ0yFe-R ]"
2020-04-24 11:42
小程序服务商-第三方平台 AppId: wx168641976a2baf16
小程序服务商-第三方平台-绑定的小程序 AppId:wx5c42a32e4f127af5
商户授权绑定的小程序AppId: wx8c4012c8476bdb86
appid=wx8c4012c8476bdb86&component_appid=wx5c42a32e4f127af5