【问题标题】:Socialauth android get profile picture from googleSocialauth android从谷歌获取个人资料图片
【发布时间】:2013-05-20 22:28:28
【问题描述】:

我正在使用这个库https://code.google.com/p/socialauth-android/ 使用谷歌帐户登录我的应用程序。到目前为止,一切都很好。我可以获取用户名、电子邮件,但可以获取用户个人资料图片。我认为,该库使用 OpenId + Oauth 登录和调用后:

profile.getProfileImageURL()

我得到空值。

我可以通过调用获取令牌和秘密(OpenId?):

socialAuthAdapter.getCurrentProvider().getAccessGrant()
For example:
token key : 1/J0_R-D03mykbqHnnNrVV1lk9FH2j996G05O2WVcHTrQ
token secret : vnh25rzUBVJKjHNpT_USeyjK

但我无法使用此链接通过以下链接检索用户个人资料网址:https://www.googleapis.com/oauth2/v1/userinfo

您能给我一些提示吗,如何使用我从这个库中获得的内容来获取图片网址?

我的 oauth_consumer.properties:

www.google.com.consumer_key = xxxxx.com
www.google.com.consumer_secret = xxxxxxxxxx
www.google.com.custom_permissions = https://www.googleapis.com/auth/userinfo.profile

【问题讨论】:

    标签: android oauth openid socialauth


    【解决方案1】:

    对延迟回复表示歉意。我们会定期监控有关 Google 项目的 socialauth 问题。

    问题是 Google OpenId + OAuth api 没有给出图片 URL。我们正在使用 Google+ 改造 Google 提供商,因此这将在下一个小版本中提供 - 为我们的 Google 项目 socialauth 加注星标以获取更新。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2013-11-20
      • 2020-01-05
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2014-10-16
      • 1970-01-01
      • 2014-09-15
      相关资源
      最近更新 更多