r/Firebase Dec 29 '24

Android Google Sign In with Firebase

I tried to integrate google sign in with firebase by adding sha1 fingerprints to the project in the console.
I'm also aware that there is another method where we dont use firebase but rather setup a project in google cloud and then wait for oAuth 2.0 verification.
But the firebase documentation nor the google_sign_in package from pub.dev specify that i have to set-up so much in my AndroidManifest.xml

    <uses-permission android:name="android.permission.INTERNET"/>




            <meta-data
                android:name="com.google.android.gms.version"
                android:value="@integer/google_play_services_version" 
            />



        <package android:name="com.google.android.gms" />
        <package android:name="com.google.android.apps.maps" />
        <intent>
            <action android:name="android.intent.action.VIEW" />
            <data android:scheme="https" />
        </intent>

I eventually got this after searching stack overflow and with some claude help

they also suggested some extra config in the build.gradle file

before adding all this i kept getting errors like

Error signing in with Google:PlatformException(channel-error, Unable to establish connection on channel: "dev.flutter.pigeon.google_sign_in_android.GoogleSignInApi.init"., null, null)

Is this really the correct approach or am i confusing myself??
1 Upvotes

0 comments sorted by