尝试使用 Oauth 系统从雅虎访问用户配置文件,为此我正在寻求 Scribe-Java API 的帮助
它工作正常,除了一个问题,我确信与我正在使用的 API 无关
在我的雅虎个人资料中,我有以下设置
Yahoo! Email --->[email protected]
Email--->[email protected] Primary - Change
所以我得到的是 [email protected]
这意味着我无法获取登录用户的正确信息。一旦我能够获取 guid,我将请求发送到通过以下 URL,
http://social.yahooapis.com/v1/user/guid/profile?format=json
我可以获取与用户关联的 yahoo 邮件 ID,以代替其他邮件id 即使它被设置为主要或与任何其他电子邮件 ID 一起,我想要的只是获取他/她登录系统的用户的雅虎邮件 ID。
Trying to access user profile from Yahoo using Oauth system and for that i am taking help of Scribe-Java API
its working fine except one issue whcih i am sure not related to the API i am using
In my yahoo profile i have following settings
Yahoo! Email --->[email protected]
Email--->[email protected] Primary - Change
So what i am getting back is [email protected]
which means i am not able to get correct information of the logged in user.Once i am able to get guid i am sending the request to following URL
http://social.yahooapis.com/v1/user/guid/profile?format=json
any way i can get the yahoo mail id to which user is associated in place of other id even if that is set as primary or along with any other email id all i want is to get the yahoo mail id of the user by which he/she logged in to the system.
发布评论
评论(1)
您必须获取 yahoo 帐户的电子邮件有什么具体原因吗?
我之前也遇到和你一样的问题。
经过深思熟虑,主要电子邮件意味着成为用户可联系的电子邮件。
也许这就是雅虎这样做的原因。
当然,如果他们能再提供一封电子邮件,即帐户的电子邮件,那就更好了。
但如果你只是想有唯一的标识符,我们可以使用guid。
那么您可以再检查一下,您的要求是否必须有帐户的电子邮件?
或者您只需要用户设置主要电子邮件地址,因为他们更喜欢通过该电子邮件进行联系?
现在我将仅使用 Yahoo 返回的主要电子邮件作为我的 OAuth
Is there any specific reason you must get the yahoo account's email?
I also facing the same problem as you earlier.
After think over, primary email means to be the contactable email for the user.
So may be that's why yahoo make it that way.
Of course it will be good if they can provide one more email which is account's email.
But if you just want to have unique identifier, we can use the guid.
So may be you can check again, does your requirement must have the account's email?
or you just need an email where user set primary because they preferred to be contactable by that email?
Now I will just make use of the primary email return from Yahoo for my OAuth