Deeplinks that require login

I am using deeplink urls in emails in an app that requires authentication. The url points to a specific form in the app. If a user is already logged in and clicks on the link, the link works fine and the user is presented with the proper form. If a user is not already logged in, they are presented with the login form, which is correct, but after logging in they are redirected to the 'Default home page', which in my case is a microflow which shows the Home Page. However, after login I would like them to be redirected to the form that was specified in the deeplink url and am not sure how to achieve this as it seems that after login I have lost the reference to the specific form desired.
3 answers

In your login microflow, do you call the deeplink microflow, and handle the result? For the default home page and any role based home page navigation settings, the first thing to do is call microflow DeepLinkHome and check the result, if it returns true, end the processing in your microflow.


Anonymous access is not allowed.

For the normal user (user already logged in), the NAVHome microflow calls AnonymousLoginCopyDeeplinkInfo microflow, then DeepLinkHome. If DeepLinkHome returns true (which it does in this case), microflow ends and user goes to link. This is working as expected.

For user not already logged in, GuestHome microflow runs which calls AnonymousLoginCopyDeeplinkInfo and then DeepLinkHome. If DeepLinkHome returns false (which it does in this case), I display a LoginPage. User logs in and then NAVHome (above) runs. In this case, DeepLinkHome in NAV_Home returns false so user goes to home page rather than link.

In AnonymousLogin_CopyDeeplinkInfo, PendingLinkList is 0 for user who is prompted to log in.

Ralph - yes the user has access rights. After doing the above steps, so now logged in, when I try the link again it works.

Please let me know if you can see what I'm doing wrong and/or let me know if I can provide any more information.

Thank you. Tracy


I have it working now. This is how I have it set up:

  • Allow Guest access checked on Deeplink Config
  • Use Home Page checked on Deeplink Config
  • Set role based home page for Guest to LoginPage - LoginPage is page I created in Deeplink Module with LoginForm widget. Guest has access to this page but nothing else in Deeplink Module.
  • Nav_Home microflow runs for all other roles and calls DeeplinkHome microflow first as first step. If true microflow ends, if false shows home page.
  • Anonymous user sign-in microflow set to AnonymousLogin_CopyDeeplinkInfo
  • Deeplink Config calls LaunchDeeplink. LaunchDeeplink gets link based on Param and runs another microflow to display the link.
  • Guest access in my custom module has access to LaunchDeeplink and the microflow which opens the link from LaunchDeeplink

Think that's it!