How to login using google play?

Hi i need to authenticate my users using google play?
is it possible with sdkbox? if not can you give me some alternatives? thanks guys :smile:

Hey @eydamson

I believe that comes with GooglePlayGameServices but unfortunately SDKBOX has no support for it as of now. It’s still in our pipeline to add GooglePlayGameServices and GameCenter to SDKBOX.

If you want to have it, you could integrate GooglePlayGameService outside of SDKBOX as of now.
We will update you once we have these services ready within SDKBOX.

Best,
Pabitra

I also need to use google play and apple game center as login method, please notify me too once you support it, thanks! :slight_smile:

1 Like

we’re working on it, and will release it soon, @pabitrapadhy will let you know :wink:

hi @pabitrapadhy, did sdkbox 2.2.1 supported this feature? I noticed in the description says:
ā€œSDKBOX Play is your one stop solution for cross-platform Loginā€, but went over the document again and it’s not mentioned anywhere…

sorry for bump this up, just to make sure if I am missing something…

@mobic
looks like team forget to add method for us like std::string getUserId(); that return unique user id from Apple/Google store

1 Like

agree, we need some kind of id to know who is who, just like the sdkbox for facebook, with userId and token information.

There’s plenty of information that could be retrieved, from id, screen name, to the photo url.
Having a getUserId method sounds mandatory. But any other field that you guys would like have added ? probably via a more generic method like:
map<string, string> getUserFields( vector<string> ) ?

Also, if there’s any other missing/expected functionality for sdkbox play, please let us know.

Thanks.

getUserFields would be great!
id and name is enough for our game, id for bind to our own system, name to save users time to type again.

by the way, could I know the schedule for this? we need this to publish our game :slight_smile:

It is already released in 2.2.2, now you get name of player and Google Play User ID.
Thanks @ibon for the rapid work!

wow, thanks a lot! that’s really fast!

is there any chance I can get game center id? or is there any ID? I saw people could using game center as login account.
currently I could only get unique id from google play. as the document says:

player_id Android only

my game will be publish both on google play and AppStore, I am going to allow user to login via google play id, also game center id. for now it seems I can not get the game center ID

You do get both iOS game center and Android play ID, as well as name.
Check out our documentation :
ā€œThese fields are common to ios and android: player_id name * display_name
making a call to sdkbox::SdkboxPlay::getPlayerAccountField( const std::string& field ) will return a string with the field contents. If the requested field does not exist, empty string will returned in exchange. player_id will be returned by calling sdkbox::SdkboxPlay::getPlayerId() too.
ā€

You can also get extra info other than ID and name in Android:

"For Android platform, there are some other available fields:
title
icon_image_uri
hires_image_uri
last_play_timestamp
retrieved_timestamp
use the same getPlayerAccountField to get these values as strings.
"

Thanks, Ryan

oh yep, my bad, didn’t read it through, thanks!

nice work, helped us a lot!