Is it possible to get phone number via Google oAuth2?

▼魔方 西西 提交于 2019-12-23 07:59:14

问题


According to OpenID specification it should be possible http://openid.net/specs/openid-attribute-properties-list-1_0-01.html however there is no mention of it in Google OAuth2 Documentation. Anyone have experience with that?


回答1:


We don't currently offer the phone number as part of our people/get Google+ API.

https://developers.google.com/+/api/latest/people

Visibility of attributes in this api are controlled by the user in G+ profile settings.

The userinfo api is specific to OpenId and probably won't get this field.

https://developers.google.com/accounts/docs/OAuth2Login#userinfocall

It may happen in the future and we're open to requests.

davep



来源:https://stackoverflow.com/questions/13276919/is-it-possible-to-get-phone-number-via-google-oauth2

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!