Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Universal/deep link in safari/chrome should auto trigger app #17550

Closed
yqrashawn opened this issue Oct 5, 2023 · 27 comments
Closed

Universal/deep link in safari/chrome should auto trigger app #17550

yqrashawn opened this issue Oct 5, 2023 · 27 comments
Assignees
Labels
deep-link https://www.notion.so/Chainmakers-b78f651f5aa04539ad4ac2a93218d1a7 feature feature requests universal-link

Comments

@yqrashawn
Copy link
Contributor

yqrashawn commented Oct 5, 2023

Feature Issue

As a user, I'd like to open a https://status.app/ URL shared from another user in Safari and have it automatically opened in the status mobile app if the app is already installed.

Note:


ios: https://status.app/.well-known/apple-app-site-association
android: https://status.app/.well-known/assetlinks.json

@yqrashawn yqrashawn added feature feature requests deep-link https://www.notion.so/Chainmakers-b78f651f5aa04539ad4ac2a93218d1a7 labels Oct 5, 2023
@yqrashawn yqrashawn self-assigned this Oct 9, 2023
@yqrashawn
Copy link
Contributor Author

got this in safari now
we need im.status.ethereum.pr in https://status.app/.well-known/apple-app-site-association

IMG_5504a

@yqrashawn
Copy link
Contributor Author

issue created https://github.com/status-im/status-website/issues/421

@yqrashawn
Copy link
Contributor Author

same after im.status.ethereum.pr added
IMG_0330

@felicio
Copy link

felicio commented Oct 11, 2023

For the CDN to successfully cache the file, it must be hosted on a domain that is available to all IP addreses and ranges, does not redirect, and is not blocked by access policies. – https://developer.apple.com/documentation/technotes/tn3155-debugging-universal-links#Understand-Apples-CDN

PR pending https://github.com/status-im/status-website/pull/444.

Cc @yqrashawn

@felicio
Copy link

felicio commented Oct 11, 2023

fyi @yqrashawn, merged the above.

curl -v https://status.app/.well-known/apple-app-site-association

@yqrashawn
Copy link
Contributor Author

yqrashawn commented Oct 12, 2023

It's working now but the user still needs to click on the button.

Maybe we need to define the paths in web or ios if we want auto-trigger, will check the doc

            "appID": "8W66MEA7DD.com.spotify.client",
            "paths": [
                  "/pair",
                  "/onlyyou",
                  "/onlyyou/",
                  "/*/onlyyou",
                  "/*/onlyyou/",
                  "/wrapped",
                  "/wrapped/",
                  "/*/wrapped",
                  "/*/wrapped/"
            ]
RPReplay_Final1697109906.MP4

@yqrashawn
Copy link
Contributor Author

@yqrashawn
Copy link
Contributor Author

Hi @felicio
Could you please add this to status.app/.well-known/assetlinks.json, Thank you!
https://join.status.im/.well-known/assetlinks.json

@felicio
Copy link

felicio commented Oct 17, 2023

Hi @felicio
Could you please add this to status.app/.well-known/assetlinks.json, Thank you!
https://join.status.im/.well-known/assetlinks.json

PR pending https://github.com/status-im/status-website/pull/491

Cc @yqrashawn

@yqrashawn yqrashawn changed the title Universal/deep link in safari should trigger app when open in safari Universal/deep link in safari/chrome should auto trigger app Oct 18, 2023
@yqrashawn
Copy link
Contributor Author

yqrashawn commented Oct 18, 2023

hi @felicio could you please add another fingerprints to the sha256_cert_fingerprints array
it's FA:C6:17:45:DC:09:03:78:6F:B9:ED:E6:2A:96:2B:39:9F:73:48:F0:BB:6F:89:9B:83:32:66:75:91:03:3B:9C
and it's from the debug.keystore https://github.com/status-im/status-mobile/blob/61792d5ec711c3fe9a7a0e7224943df7c664d552/android/app/debug.keystore

Also need to add another target for im.status.ethereum.pr
can't find the keystore file, asking for help, will add it later

@yqrashawn
Copy link
Contributor Author

hi @felicio, seems we use the same keystore for pr and release build, this should do

[
  {
    "relation": [
      "delegate_permission/common.handle_all_urls"
    ],
    "target": {
      "namespace": "android_app",
      "package_name": "im.status.ethereum",
      "sha256_cert_fingerprints": [
        "29:58:6A:6B:A0:CA:FA:A5:38:AA:CE:EA:DF:60:55:1C:EC:22:E9:65:68:40:35:D4:75:B7:9A:0A:8B:13:E2:9F",
        "FA:C6:17:45:DC:09:03:78:6F:B9:ED:E6:2A:96:2B:39:9F:73:48:F0:BB:6F:89:9B:83:32:66:75:91:03:3B:9C"
      ]
    }
  },
  {
    "relation": [
      "delegate_permission/common.handle_all_urls"
    ],
    "target": {
      "namespace": "android_app",
      "package_name": "im.status.ethereum.pr",
      "sha256_cert_fingerprints": [
        "29:58:6A:6B:A0:CA:FA:A5:38:AA:CE:EA:DF:60:55:1C:EC:22:E9:65:68:40:35:D4:75:B7:9A:0A:8B:13:E2:9F"
      ]
    }
  }
]

@felicio
Copy link

felicio commented Oct 19, 2023

fyi @yqrashawn, merged the above.

curl -v https://status.app/.well-known/assetlinks.json

@yqrashawn
Copy link
Contributor Author

Thanks @felicio

@yqrashawn
Copy link
Contributor Author

yqrashawn commented Oct 23, 2023

iOS PR build works on real device
build is the #15 from #17465 (comment)

RPReplay_Final1698041828.webm

@yqrashawn
Copy link
Contributor Author

PR build works on android real device
one plus 5, android 9

build is the #15 from #17465 (comment)

23-10-23-16-01-50.-.01.webm

@yqrashawn
Copy link
Contributor Author

yqrashawn commented Oct 23, 2023

iOS nightly build works on real device, no Status PR installed
StatusIm-Mobile-231023-020800-04a7f7-nightly.ipa

RPReplay_Final1698049550.webm

@yqrashawn
Copy link
Contributor Author

android nightly build works on real device, no Status PR
one plus 5, android 9

android build at
CleanShot 2023-10-23 at 17 11 30@2x

23-10-23-17-00-29.-.01.webm

@yqrashawn
Copy link
Contributor Author

android local build works
tested on simulator

CleanShot.2023-10-23.at.19.35.43.mp4

@yqrashawn
Copy link
Contributor Author

ok, iOS local app has im.status.ethereum.debug as bundle identifier

  • iOS
    • release im.status.ethereum
    • pr im.status.ethereum.pr
    • local im.status.ethereum.debug
  • Android
    • release im.status.ethereum
    • pr im.status.ethereum.pr
    • local im.status.ethereum

@yqrashawn
Copy link
Contributor Author

Hi @felicio, sorry to bother you again.
Could you please add another app id to https://status.app/.well-known/apple-app-site-association, it's app id for iOS local build. Thanks.

{
  "appID": "8B5X2M6H2Y.im.status.ethereum.debug",
  "paths": [
    "*"
  ],
  "appIDs": [
    "8B5X2M6H2Y.im.status.ethereum.debug"
  ]
}

@yqrashawn
Copy link
Contributor Author

yqrashawn commented Nov 13, 2023

Test again for https://status.app

  • android (debug and pr won't work on simulator but works on real device)
    • debug ✅
    • pr ✅ on real device (chrome works, builtin-browser doesn't work)
    • nightly ✅
  • ios
    • debug ❌
    • pr ✅
    • nightly ✅

@yqrashawn
Copy link
Contributor Author

ios debug still won't work, will try on real device

@yqrashawn
Copy link
Contributor Author

upgraded macos to 14
upgraded xcode 15
building debug build for real device

@yqrashawn
Copy link
Contributor Author

yqrashawn commented Nov 30, 2023

No luck, ios debug build still won't trigger jumping to app

@yqrashawn
Copy link
Contributor Author

Close in favor of #18490

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
deep-link https://www.notion.so/Chainmakers-b78f651f5aa04539ad4ac2a93218d1a7 feature feature requests universal-link
Projects
None yet
Development

No branches or pull requests

2 participants