通过Google API获取用户信息 [英] Get user info via Google API
问题描述
是否可以通过Google API从用户个人资料中获取信息?如果可能,我应该使用哪个API?
我对这些信息很感兴趣:
以获取用户个人资料中的其他信息。
将其添加到范围 - https://www.googleapis.com/auth/userinfo.profile
授权完成后,从 - https://www.googleapis.com/oauth2/v1/userinfo?alt= json
它包含大量内容 - 包括名称,公开个人资料网址,性别,照片等。
Is it possible to get information from user's profile via Google API? If it is possible, which API should I use?
I'm interesting in such information:
- Url to the user profile (e.g. https://profiles.google.com/115063121183536852887);
- Gender (sex);
- Profile photo.
Also it would be cool to get other information from user's profile.
Add this to the scope - https://www.googleapis.com/auth/userinfo.profile
And after authorization is done, get the information from - https://www.googleapis.com/oauth2/v1/userinfo?alt=json
It has loads of stuff - including name, public profile url, gender, photo etc.
这篇关于通过Google API获取用户信息的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!