Why do I get com.google.android.gms.common.api.ApiException: 10:?

com.google.android.gms.common.api.apiexception: 10 flutter
com.google.android.gms.common.api.apiexception: 12500:
com.google.android.gms.common.api.apiexception: 7:
platformexception(sign_in_failed, com.google.android.gms.common.api.apiexception: 10: , null)
google sign in failed android studio
com.google.android.gms.common.api.apiexception: 8:
google sign in failed com.google.android.gms.common.api.apiexception: 7:
google sign-in android
private void handleSignInResult(Task<GoogleSignInAccount> completedTask) {
    try {
        GoogleSignInAccount account = completedTask.getResult(ApiException.class); //exception is here

        // Signed in successfully, show authenticated UI.
        System.out.println("google token ---> " + account.getIdToken());
    } catch (ApiException e) {
        // The ApiException status code indicates the detailed failure reason.
        // Please refer to the GoogleSignInStatusCodes class reference for more information about this error.
        e.printStackTrace();
    }
}

If you are using Firebase and try on the debug app :

1. First, get your SHA-1 debug key :

  1. Click on Gradle (From Right Side Panel, you will see Gradle Bar)
  2. Click on Tasks
  3. Click on Android
  4. Double Click on signingReport (You will get SHA-1 and MD5)

2. Add new credentials to API Console

  1. Go here https://console.developers.google.com/apis/credentials
  2. Create new OAuth Client ID
  3. Name : Android client (for debug) (example)
  4. Signing-certificate fingerprint : Copy paste you SHA-1 debug key
  5. Put your package name then saved

3. Add your key to your Firebase project :

  1. Go to Project settings -> SHA certificate fingerprints -> Add SHA-1 key of debug app.

  2. Then you can update your google-services.json file in your Android project.

It's works for me.

Google SignIn Fails with code 10 (on Android) · Issue #360 , Get error com.google.android.gms.common.api.ApiException: 10 with google_sign_in package. If we specify SHA1 in firebase, then console.​developers.google.com will generate an Android oauth for us. keytool -list -v  Teams. Q&A for Work. Stack Overflow for Teams is a private, secure spot for you and your coworkers to find and share information.

This status code means that you are providing unknown server client id. In https://console.developers.google.com/apis/credentials in your project you might need to generate: OAuth client ID -> Web Application and use this web application client id in your Android app.

How to fix ApiException: 10 in Flutter for Android · Issue #188 , ApiException: 10:? - android. private void handleSignInResult(Task<​GoogleSignInAccount> completedTask) { try { GoogleSignInAccount account =  Why do I get com.google.android.gms.common.api.ApiException: 10:? (3) If you are using Firebase and try on the debug app: 1. First, get your SHA-1 debug key : Click on Gradle (From Right Side Panel, you will see Gradle Bar) Click on Tasks; Click on Android

I have solved this problem using these steps:

1). Goto https://console.developers.google.com/ and delete (Android Client) if it is created.

2). Click on Create Credential and click on OAuthClientID and select android

3). copy and paste your SHA 1 fingerprint

4). type your package name then saved

5). Goto console.firebase.com

6). download google-service.json move it into your project into app directory

7). Open google-service.json and find out client id type 3 and use it as default_web_client_id

8). Run your App

Why do I get com.google.android.gms.common.api.ApiException: 10 , Basically problem is in the SHA1 key put on console please regenerate it and put again properly same project. 1)As the answers, make sure  Join GitHub today. GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.

The ApiException Error Code 10 is a developer error. You get this error when your firebase app is not well configured. One sure case is when you do not supply the SHA1 fingerprint for your android app when you want to use Firebase authentication with Google Signin. (It is a requirement for Google Signin). So supply the SHA1 fingerprint, download the google-services.json configuration file to your app folder and build. You should be good to go.

Google sign-in is automatically configured on your connected iOS and web apps. To set up Google sign-in for your Android apps, you need to add the SHA1 fingerprint for each app on your Project Settings.

Check this out Common Status Error Codes

Google sign in failed com.google.android.gms.common.api , android.gms.common.api.ApiException. These examples are extracted from open source projects. You can vote up the examples you like and your votes will​  PlatformException(sign_in_failed, com.google.android.gms.common.api.ApiException: 12500: , null) Even if its the same app, with the same code from the first one. (the SHA1 and SHA256 are the same for both apps, the packages names are different)

If you remove this line it will work:

System.out.println("google token ---> " + account.getIdToken());

This is because you don't have the request to the idToken:

.requestIdToken(getString(R.string.google_app_id))

where the app_id will have the value of "OAuth client ID -> Web Application"

com.google.android.gms.common.api.ApiException, Java is a registered trademark of Oracle and/or its affiliates. Last updated 2020-​03-19. Connect. Android Developers Blog · Get News and Tips by Email  I'm quite new to android development and in my case it was caused by a wrong package name in app/build.gradle file.. Although, the tutorial and the configuration page suggests to get the package name from the manifest file, it seems it is checked against the applicationId in the app/build.gradle file.

ApiException | Google APIs for Android, Fixing `PlatformException (PlatformException(sign_in_failed, com.google.​android.gms.common.api.ApiException: 10: , null))` when calling GoogleSignIn. Firebase's Android app. download the updated google-services.json to android​/app. To get the SHA-1 key, you can either use keytool as explained in  Api<O extends Api.ApiOptions> : Describes a section of the Google Play Services API that should be made available. Api.ApiOptions.NoOptions: Api.ApiOptions implementation for Apis that do not take any options.

Fixing `PlatformException (PlatformException(sign_in_failed, com , I am getting the following exception while trying out google places API to get likelihood places for Current Place in android. Process: me.nabeelkottol.linkedinplaces, PID: 2995 com.google.androi

I'm building a Flutter app with firebase_auth and google_sign_in.. Everything was working well for a while and all of my existing users on the released product have not experienced any problems, but a while back I started getting reports that new users couldn't log in.

Comments
  • Did you read the 2 lines you have in comments in the catch block?
  • Actually I did but there is nothing about status code 10:, so I don't get it.
  • @ArsenBudumyan in the page for ´GoogleSignInStatusCodes` there is actually a link in the first paragraph that sends you to developers.google.com/android/reference/com/google/android/gms/… and from there to developers.google.com/android/reference/com/google/android/gms/… Also, if you run the debugger and use AndroidStudios Evaluate Expression function, you can look at the e, your ApiException or completedTask.exception to view the field mStatus which actually shows DEVELOPER_ERROR
  • In my case I had to add the SHA-1 fingerprint because I was using Google Sign-In service which requires it.
  • Thanks, buddy. you made my day. I was struggling with the wrong SHA1 and resulted in above ERROR 10. My issue was, the project were built on embedded keystore(<project_root/debug.keystore>) and SHA1 were generated from default in the android root.
  • Not sure if things have changed or I do something wrong but after adding SHA-1 to google API console I unable to add it to Firebase. So I skipped step 2 and still get working solution.
  • It might be also that you haven't add or misspelled your package in the same console.developers.google.com/apis/credentials but in Oauth 2.0 Client ID for Android.
  • Why do I need Web application instead of Android? I'm not even using a browser for google-auth (but rather integrated account), what origins are we talking about?
  • Be sure to select current project on console.developers.google.com, because if you open it from a link(firebase docs page) there could be selected another project, as simple as that, shit!
  • The key is Web Application, not Android
  • I have more than one type 3 reference
  • please check my issue at stackoverflow.com/questions/55235295/…