1

I am using Firebase Dynamic Links to handle deep linking into my ios app (from external links) and this works fine.

My issue is when I try to handle a dynamic link that has been launched from inside the app. In particular, I am using Firebase in-app messaging with a dynamic link as the action on the card button.

I have added the capabilities and URL scheme to Xcode. The documentation states that I use the Firebase app bundle as the URL scheme value. The only thing that isn't clear is whether this means the Firebase project id or the dynamic link domain which is the one set in the capabilities tab as the applinks: value.

When I tap on the button to launch the dynamic link it does recognise it as a dynamic link (because it doesn't just open my hosting domain in the browser), but it redirects to the browser first and asks me if I want to open the app (that I just came from).

enter image description here

Does anybody know how to configure this behaviour so the links don't ask you first? Would this then immediately handle the link in the app?

UPDATE

I was able to get the app to handle the dynamic link immediately in the app by skipping the preview page. You do this by manually constructing the link and setting the efr=1 parameter. This article explains it all: https://firebase.google.com/docs/dynamic-links/create-manually

BUT - although my app was handling the deep-link, it STILL redirected to the browser where it attempted to load the web.app domain from hosting.

I feel this could be something to do with the URL types setting in Xcode which if set properly should prevent it from trying to handle links in the browser.

UPDATE UPDATE For some reason, this just stopped redirecting to the browser and I have no idea why. I watched a Firebase video and the guy did mention something about iOS being weird, and that Safari can break dynamic links and he recommended always testing them from the notes app. Weird. I wonder if something got pwned somewhere. I will write up an answer.

Lee Probert
  • 10,308
  • 8
  • 43
  • 70

1 Answers1

0

Not entirely sure why, but this just started to behave. The dynamic link I am using in the in-app messaging campaign is the long-form URL with the efr=1 parameter to skip the preview page in the browser.

Lee Probert
  • 10,308
  • 8
  • 43
  • 70