Clancey / simple_auth

The Simplest way to Authenticate in Flutter
MIT License
352 stars 108 forks source link

Can't understand how to auth and redirect to my app after logging in google #128

Open tmp05 opened 4 years ago

tmp05 commented 4 years ago

my code:

SimpleAuthFlutter.init(context);

final simpleAuth.GoogleApi googleApi = new simpleAuth.GoogleApi("google",
        "my_client_id.apps.googleusercontent.com",
        "my_redirect_url",
    );

in Android.manifest:

        <activity android:name="clancey.simpleauth.simpleauthflutter.SimpleAuthCallbackActivity" >
            <intent-filter android:label="simple_auth">
                <action android:name="android.intent.action.VIEW" />
                <category android:name="android.intent.category.DEFAULT" />
                <category android:name="android.intent.category.BROWSABLE" />
                <data android:scheme="com.googleusercontent.apps.my_client_ID" />
            </intent-filter>
        </activity>

So, await googleApi.getUserProfile() opens empty google page

cahyowhy commented 4 years ago

up