3

I need to put custom query params to firebase dynamic link leading to AppStore. Once a user has installed the app I need to get that URL with query params.

I tried to build both short and long dynamic links, but it doesn't work.

Firebase dynamic link configuration for https://myApp.page.link/ios: enter image description here

Things I've tried:

1) https://myApp.page.link/ios/?link=https://apps.apple.com/ru/app...&ifl=https://www.google.com&gclid=4324234

2) https://myApp.page.link/?link=https://apps.apple.com/ru/app...&gclid=4324234

3) https://myApp.page.link/?link=https://apps.apple.com/ru/app...?gclid=4324234

4) https://myApp.page.link/?link=https://apps.apple.com/ru/app...&ifl=https://www.google.com&gclid=4324234

Inside the app I try to get the initial link using flutter firebase_dynamic_links pub package and i always get only link, leading to AppStore with no query params.

What am I doing wrong? How should links look like to be able to put custom param into app?

1 Answer 1

1

You need to make sure that the parameters of your deep link are URL Encoded. For example, if your deep link look like this:

https://example.com/login?token=GDGEGDFGE345DF

Then your long dynamic link should look something like this:

https://example.page.link/?link=https://example.com/login?token%3DGDGEGDFGE345DF&apn=com.my.app.package&ibi=com.my.app.bundle

As you can see the token= parameter becomes token%3D, the = sign is encoded. Otherwise, firebase_dynamic_links cannot parse your deep link correctly and you may not get any query parameters back.

2
  • 1
    You probably also need to URL encode the entire value assigned to your link param: https%3A%2F%2Fexample.com%2Flogin%3Ftoken%3DGDGEGDFGE345DF
    – hvaughan3
    Commented May 11, 2021 at 16:11
  • Did this solution work for you @alectogeek ?
    – ΩlostA
    Commented Jul 7, 2022 at 16:50

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.