Reputation: 910
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:
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?
Upvotes: 3
Views: 820
Reputation: 140
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.
Upvotes: 1