-
-
Notifications
You must be signed in to change notification settings - Fork 874
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error "unknown status code: 12501" when using clientID #22
Comments
I have exactly the same issue with the same configuration. I downgraded |
the non-obvious thing from Google documentation is that clientId has to be of type from your google project console, on the the newly generated clientID is the one ;) |
@lesniakania have you tried clientid of type "Web application", as @devfd devfd said? This solution didn't help me :( |
well that's weird, the sample app is working fine even with a clientId check that:
|
@vladvasyuk it partially worked for me. I needed to change it to When I changed that and use In short - everything works for me fine for |
@vladvasyuk Please see my pull request: #26 Additionally, I needed to update my app to If you don't want to upgrade The flow of the sign in looks like this:
I'm happy to help you more on priv if you want - slimak.ania@gmail.com These resources helped me: |
I still have this issue and getting 12501 error code. @lesniakania I tried your code from pull request, it didn't help. I tried example from this project, set up all client id (android and web app) and it also didn't work. I have tried different versions of react native and this package. No result. I tried completely native example from google https://github.com/googlesamples/google-services/tree/master/android/signin and it works fine, I can get server Auth Code. I don't know how to fix it. maybe I need some special settings in gradle file ? Can anyone share his working example ? Many thanks |
when trying the sample app included in this project, simply: and you are good to go. the client id is already configured correctly. please confirm everything is working as expected. also you can set up a public github repo with your App so that we can help you better |
Yes, I did as you wrote. and got ERROR signin in Object {error: "unknown status code: 12501", code: 12501} |
alright strange. on what device you are testing ? |
Maybe try
And also quit from your React packager console (and make sure that you don't have any zombie processes - |
So I'm having the same issue now with 0.19. Do you end up having to create two sets of credentials and two clientIds? One for the android app (google_secrets.json) and another one for the oauth? |
Yes, because that is how oauth flow should actually works. You can read more (here)[https://developers.google.com/identity/protocols/OAuth2ForDevices] and (here)[https://developers.google.com/identity/sign-in/android/offline-access]. |
I'm testing on different devices: LG G4 Android 6.0, Samsung Galaxy s4 android 5.1 @lesniakania Thanks, I have tried your solutions, but it didn't help. I have set up public repo on github with my test app https://github.com/ddzyndra/googleSignIn |
@ddzyndra your google configuration seems to be off. you are missing API Keys. they are auto-created by the configuration wizzard. Also your Please start again from a fresh install, carefully follow the instructions and you should be fine ;) |
Thank you, @devfd very much for your help :) Yes, I have API Keys, I posted wrong screenshot. Did you get my example working? do you use debug or release key store? Does it depend on node version ? |
@ddzyndra sorry, I have crazy week, I will look at your code tomorrow evening. |
sorry guys, it looks like I have found my problem. I changed the owner of .gradle file and ran react-native run-android without sudo. And it works now. Thank you @devfd and @lesniakania for your help! |
I'm getting this issue now. @ddzyndra how did changing the owner fix it and how do i go about doing that? |
apologies, didnt restart my node server after doing all this... my issue is fixed |
I had the same problem and here is the answer: http://stackoverflow.com/a/41413713/1498586 and this is sample code in github: https://github.com/mahdit83/FireBaseAuthDemo |
Without providing client Id to GoogleSignin.configure plugin works well. But when i pass this parameter, i get the "unknown status code: 12501". I learned that this error may come from wrong configuration, but...
The client Id i get from google developers console (New credentials -> OAuth ClientID -> Android). SHA-1 signing-certificate fingerprints specified correctly (fingerprint from ~/.android/debug.keystore matches to that specified in android/app/google-services.json and this key definitely used to sign my debug apk). Also client_id in google-services.json matches to that i pass to GoogleSignin.configure.
Any thoughts?
Android 6.0.1, react-native@0.17.0, react-native-google-signin@0.3.0
The text was updated successfully, but these errors were encountered: