Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

开放平台服务,取消授权会有哪些参数过来? #909

Closed
liuyami opened this issue Sep 5, 2017 · 5 comments
Closed

开放平台服务,取消授权会有哪些参数过来? #909

liuyami opened this issue Sep 5, 2017 · 5 comments

Comments

@liuyami
Copy link

liuyami commented Sep 5, 2017

开放平台服务,授权通知、授权权限更新,都能通过获取到信息

$base_info = $openPlatform->getAuthorizationInfo($event->AuthorizationCode);

但是这代码在取消授权通知里面,就报错,easywechat 日志:

[2017-09-05 11:04:36] easywechat.DEBUG: Current config: {"open_platform":{"app_id":"***19a2a","secret":"***6bace","token":"oL6iJRIotAGNd7dtsBFiu2YX6DO38n4H","aes_key":"1CvsXvRhLMzGHctC8u1WWOnTyXrKldvNPBv8ISauG8d"},"d$
[2017-09-05 11:04:36] easywechat.DEBUG: OpenPlatform Request received: {"Method":"POST","URI":"/platform/serve?signature=9ea9c6c2dbd4eacf6faf5cebb0ed10237fee6797&timestamp=1504580676&nonce=1809933422&encrypt_type=aes$
[2017-09-05 11:04:36] easywechat.DEBUG: OpenPlatform Event Message detail: {"AppId":"wx147b33c5cff19a2a","CreateTime":"1504580675","InfoType":"unauthorized","AuthorizerAppid":"wxa10ac71a8741474e"} []
[2017-09-05 11:04:36] easywechat.DEBUG: Client Request: {"url":"https://api.weixin.qq.com/cgi-bin/component/api_query_auth","method":"POST","options":{"timeout":5,"query":[],"body":"{\"component_appid\":\"wx147b33c5c$
[2017-09-05 11:04:36] easywechat.DEBUG: Request: POST https://api.weixin.qq.com/cgi-bin/component/api_query_auth {"timeout":5,"handler":{},"synchronous":true,"allow_redirects":{"max":5,"protocols":["http","https"],"s$
[2017-09-05 11:04:36] easywechat.DEBUG: Request headers:{"Content-Length":["66"],"User-Agent":["GuzzleHttp/6.2.1 curl/7.35.0 PHP/7.0.9-1+deb.sury.org~trusty+1"],"Host":["api.weixin.qq.com"],"content-type":["applic$
[2017-09-05 11:04:36] easywechat.DEBUG: Client Request: {"url":"https://api.weixin.qq.com/cgi-bin/component/api_component_token","method":"POST","options":{"timeout":5,"query":[],"body":"{"component_appid":"wx147b$
[2017-09-05 11:04:36] easywechat.DEBUG: API response: {"Status":200,"Reason":"OK","Headers":{"Connection":["keep-alive"],"Content-Type":["application/json; encoding=utf-8"],"Date":["Tue, 05 Sep 2017 03:04:36 GMT"],"C$
[2017-09-05 11:04:36] easywechat.DEBUG: API response decoded: {"contents":{"component_access_token":"rd_k73A5EZGFQtynROam0QS1J369iV4K9sbjEXJ4IVZLmerDfOUt0fAp3jYOTmETsF-NOujvvfFE2ANu5NL7uCbqT-iZTMKyR2PEB9khpZ0ijLcu-GS$
[2017-09-05 11:04:36] easywechat.DEBUG: API response: {"Status":200,"Reason":"OK","Headers":{"Connection":["keep-alive"],"Content-Type":["application/json; encoding=utf-8"],"Date":["Tue, 05 Sep 2017 03:04:36 GMT"],"C$
[2017-09-05 11:04:36] easywechat.DEBUG: API response decoded: {"contents":{"errcode":40097,"errmsg":"invalid args hint: [dZzpIA0676nfo1]"}} []

不知取消授权处理和新增授权、更新权限通知有什么区别。

@mingyoung
Copy link
Collaborator

报什么错?

@mingyoung
Copy link
Collaborator

取消授权没有 AuthorizationCode 的

@liuyami
Copy link
Author

liuyami commented Sep 5, 2017

@mingyoung 你好,那请问我怎么知道取消授权是取消哪一个的呢?

@mingyoung
Copy link
Collaborator

这是取消授权微信推送的内容:

<xml>
<AppId>第三方平台appid</AppId>
<CreateTime>1413192760</CreateTime>
<InfoType>unauthorized</InfoType>
<AuthorizerAppid>公众号appid</AuthorizerAppid>
</xml>

@liuyami
Copy link
Author

liuyami commented Sep 5, 2017

@mingyoung 感谢,搞定了

@liuyami liuyami closed this as completed Sep 5, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants