Reputation: 13
I released multi player game two years ago, and I have integrated google+ sign in two weeks ago. Google+ sign in works perfectly on both platforms Web and Android, but there is issue when profile pictures are shown in list of online players on both platforms. Some profile pictures are shown, some are not.
To get profile picture I have used:
https://www.googleapis.com/plus/v1/people/{user_id}?fields=image&key={browser_key or android_key}
In case when request is failed, status is 404.
{
"error": {
"errors": [
{
"domain": "global",
"reason": "notFound",
"message": "Not Found"
}
],
"code": 404,
"message": "Not Found"
}
}
Here you can find Google+ API report
Any comment/suggestion or hint are welcome. Thank you.
Upvotes: 1
Views: 185
Reputation: 117321
Users are no longer required to create accounts on Google+. Profile data is linked to google+ So if you have a user logged in who has not made an account on google+ your not going to find any data.
GET https://www.googleapis.com/plus/v1/people/111102772937280436258
result
{
"error": {
"errors": [
{
"domain": "global",
"reason": "notFound",
"message": "Not Found"
}
],
"code": 404,
"message": "Not Found"
}
}
Google+ page link doesnt work. This one user does have a google+ account thats why it works.
Suggestion ask the user to create a google+ account or give them the ability to upload their own picture to your system. I dont think there is a way for you to programmaticly update the users profile picture on Google.
Upvotes: 1