0
With Disqus,我正在寫一個OAuth
我要求用戶的電子郵件,但電子郵件地址不是由用戶的詳細信息返回。5 Disqus用戶電子郵件不退還
OAuth
響應
stdClass Object
(
[username] => Meeeeee
[user_id] => xxxx638
[access_token] => xxxxxxxxxx2db3cb0b7c10134e83
[expires_in] => 2592000
[token_type] => Bearer
[state] =>
[scope] => read,write,email
[refresh_token] => exxxxxxxx799826a93409f6f98
)
用戶詳細請求
stdClass Object
(
[username] => Meeeeee
[numFollowers] => 0
[about] =>
[name] => meeeee
[url] =>
[joinedAt] => 2014-01-08T15:38:32
[rep] => 1.231755
[numFollowing] => 0
[connections] => stdClass Object
(
)
[numPosts] => 0
[reputation] => 1.231755
[location] =>
[profileUrl] => http://disqus.com/Meeee/
[isPrivate] =>
[numLikesReceived] => 0
[isPrimary] => 1
[isAnonymous] =>
[id] => xxxxxx638
[avatar] => stdClass Object
(
[small] => stdClass Object
(
[permalink] => https://disqus.com/api/users/avatars/meeee.jpg
[cache] => //a.disquscdn.com/uploads/users/8970/638/avatar32.jpg?1389195513
)
[isCustom] =>
[permalink] => https://disqus.com/api/users/avatars/meeee.jpg
[cache] => //a.disquscdn.com/uploads/users/8970/638/avatar92.jpg?1389195513
[large] => stdClass Object
(
[permalink] => https://disqus.com/api/users/avatars/meeee.jpg
[cache] => //a.disquscdn.com/uploads/users/8970/638/avatar92.jpg?1389195513
)
)
)
如圖在上述範圍確實有用戶的電子郵件。但是對用戶詳細信息的API請求不包含電子郵件地址,這與api不一致。我的例子是在PHP中生成的,但在使用他們的web api時也有相同的響應。
當您指定了「電子郵件」範圍時是否獲得原始授權?你有沒有嘗試過與新用戶,或者在撤銷你的應用程序後再次檢查? –
我不確定,它經歷了很多迭代,但我猜測沒有。我將如何完全撤銷應用程序泄露,然後重新開始? –
轉到http://disqus.com/account/ - 然後單擊「應用程序」選項卡並撤銷您的應用程序。然後重新啓動授權過程。您應該在新授權授權窗口中看到電子郵件許可警告。 –