I want to authenticate gmail login with backend server, So I came across this https://developers.google.com/identity/sign-in/android/backend-auth
Gmail signin option,
GoogleSignInOptions gso = new GoogleSignInOptions.Builder(GoogleSignInOptions.DEFAULT_SIGN_IN)
.requestIdToken(getString(R.string.server_client_id))
.requestEmail()
.build();
here I am requesting for requestIdToken
.
server_client_id
is Web application auth id generated from google developer console.
This works fine when I request only email in GoogleSignInOptions, But when I request for IdToken it is giving developer error
Tried below links, but still developer error only.