应用程序在 Play 商店中上线后,Android 应用程序链接不起作用 [英] Android app link not working after the application is made live in play store
问题描述
我已根据以下链接实现了 Android 应用链接.
<块引用>adb shell dumpsys 包 domain-preferred-apps
当我运行上面的命令时
我遇到了同样的问题,因为它在未上传到 Playstore 的签名 apk 上运行良好.
后来我发现我需要从 PlayConsole 添加 SHA256 密钥前往 Play 管理中心的应用程序仪表板然后发布管理--> 应用签名在那里你会发现 SHA-256 证书指纹在 https://ourdomain/.well-known/assetlinks.json 的 assetlinks.json 中使用此 SHA-256 然后从 Playstore 重新安装应用它开始对我很好
I have implemented Android app links based on the below links.
https://developer.android.com/studio/write/app-link-indexing.html
https://developer.android.com/training/app-links
I have hosted assetlinks
file into our domain https://ourdomain/.well-known/assetlinks.json
And also I have verified this using https://developers.google.com/digital-asset-links/tools/generator
and from android studio's App Links Assitant also. and got verified status from both the ways.
Now when I generate a signed build and tested it via google drive links. Android app link works as expected(on click of the link the application gets open without opening disambiguation dialog for android version 6.0 and above).
After uploading the same version to the play store it's not working.
Below is the code used in the manifest file.
<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" />
<data
android:scheme="https"
android:host="<ourdomain>" />
</intent-filter>
EDIT: Android app link did work as expected for one day after uploading it to the play store. and started opening disambiguation dialog again on the second day. Any idea what could be the issue?
The same version from the play store gave me two different Statuses as Ask and Always on a different day.
adb shell dumpsys package domain-preferred-apps
When I run the above command
I got into the same issue as it was working perfectly on the signed apk which was not uploaded to the playstore.
Later I found out that I need to add the SHA256 key from PlayConsole By going to Application Dashboard in Play Console then Release Management --> App Signing and there you will find SHA-256 certificate fingerprint Use this SHA-256 in assetlinks.json at https://ourdomain/.well-known/assetlinks.json and then reinstall the app from playstore It started working fine for me
这篇关于应用程序在 Play 商店中上线后,Android 应用程序链接不起作用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!