I am trying to integrate Firebase dynamic link into Android app but the problem is that even if the app is installed the dynamic link is taking me to play store page to download the App from play store. I sent email with dynamic link. Then at Android smartphone, I opened the email and clicked the dynamic link, it goes to play store always.. Did anybody face the same problem and have solution for the same.
When I tested at https://firebase.google.com/docs/app-indexing/android/test the dynamic link goes to the app well. Because the app was installed.
I added SHA-1, SHA-256 key to my app.
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="io.chillingchat.android">
<uses-permission android:name="android.permission.INTERNET" />
<application
android:allowBackup="true"
android:icon="@drawable/adv"
android:label="@string/app_name"
android:roundIcon="@mipmap/ic_launcher_round"
android:supportsRtl="true"
android:theme="@style/AppTheme"
>
<activity
android:name="io.chillingchat.android.view.MainActivity"
android:label="@string/app_name">
</activity>
<activity
android:name="io.chillingchat.android.view.AuthActivity">
<intent-filter android:autoVerify="true">
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT"/>
<category android:name="android.intent.category.BROWSABLE"/>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
<data
android:host="chillingchat.io"
android:scheme="https"/>
<data
android:host="chillingchat.io"
android:scheme="http"/>
</intent-filter>
</activity>
</application>
actionCodeSettings = ActionCodeSettings.newBuilder()
// URL you want to redirect back to. The domain (www.example.com)
// URL must be whitelisted in the Firebase Console.
.setUrl("https://chillingchat.page.link/in")
// This must be true
.setHandleCodeInApp(true)
.setAndroidPackageName(
"io.chillingchat.android",
true, /* installIfNotAvailable */
"16" /* minimumVersion */)
.build();