Firebase Dynamic Links Always Returned CANCELED

I use dynamic links for my application.

I took a step-by-step step through the training course, and I can open the application by clicking on the link posted on facebook.

But when I call getInvitation, I always have CANCEL as the status of AppInviteInvitationResult.

AppInvite.AppInviteApi.getInvitation(mGoogleApiClient, this, false).setResultCallback( new ResultCallback<AppInviteInvitationResult>() { @Override public void onResult(@NonNull AppInviteInvitationResult result) { if (result.getStatus().isSuccess()) { // Extract deep link from Intent Intent intent = result.getInvitationIntent(); String deepLink = AppInviteReferral.getDeepLink(intent); // [END_EXCLUDE] } else { Log.d("StartActivity", "getInvitation: no deep link found."); } } }); 

In debugging, I see that result.getStatus () returns CANCELED, but clicking on ligue opens the application correctly.

Where am I mistaken?

EDIT: the link I'm using: https://wft4z.app.goo.gl/?link=https://aqld.it/testlink/112972&al=aqld://test/about?params%3D17363&apn=com.project .mydeeplink

Filter in manifest:

+6
source share
3 answers

The status is canceled when no intention has been received. I was interested in the same thing, and it turned out that my links created on the firebase web page were incorrect. I wrote some ideas on how to debug url problem as an answer to another question. If you have the same problems as me, they should be helpful:

fooobar.com/questions/195583 / ...

0
source

It does not directly answer your question, but you can eliminate incorrectly formed URLs as the main reason, using this page to create dynamic firebase links for ios and Android: http://fdl-links.appspot.com/

0
source

Just double check if you added SHA-1 in the firebase console, and the added SHA-1 matches the SHA1 of the generated APK. I saw the same problem - result.getStatus () returned CANCELED before that, but after adding SHA-1 to the firebase console, it started working fine. :)

0
source

All Articles