Skip to content Skip to sidebar Skip to footer

Apiexception On Silent Signing Using Googlesigninclient On Android

I get following error frequently when I try to sign in silently on android. How can I debug this. What is the reason for this. (I have an active google account on my android phone.

Solution 1:

There is a list of error codes

According to it, your error code means following:

public staticfinalint SIGN_IN_REQUIRED
The client attempted toconnectto the service but the userisnot signed in. The client may choose to continue withoutusing the API. Alternately, if hasResolution() returnstrue the client may call startResolutionForResult(Activity, int) to prompt the userto sign in. After the sign in activity returnswith RESULT_OK further attempts should succeed.

Constant Value: 4

It means, that user needs to login manually before you can use silentSignIn. You can find an example on Google github

Solution 2:

That error happened to me because I haven't added the email I was testing with to the Testers tab in Google Play Games Console.

I believe it also occurs if your build hasn't been signed with the same SHA1 key that your google play games app id was generated with

Post a Comment for "Apiexception On Silent Signing Using Googlesigninclient On Android"