Success Redirect after User MFA enrollment using ticket

Hi,

I am doing https://auth0.com/docs/multifactor-authentication/developer/custom-enrollment-ticket and following the post body from the sample here https://auth0.com/docs/api/management/v2#!/Guardian/post_ticket

I got it working till the part that I get email > click on link > mfa widget > enroll mfa

But once that is done, it wont redirect anywhere or close the window.
guardian_auth

and then it time out after sometime to
orchard_guardian_auth

Question: Is there a parameter or way I can ask it to show success after last step or provide a redirect url with the “enrollment ticket”? It works when it gets called with the login flow and redirects to the callback url from login. So I am assuming there is a param that is missing in my case.

Hi @npatel
For the MFA enrollment ticket there’s no callback URL (there should probably be an option for it).

As part of the enrollment you are supposed to confirm the enrollment (by entering the OTP o confirming the push). After that, the MFA widget is supposed to tell you that you are done:

Is your MFA hosted page customized with anything that might be affecting this flow?

True. it does give me success message same as screenshot. But If you leave the window open for a litte bit (~3-4 mins) then it gives you an error saying “Login Timeout”. that is why I was trying to see if I can close that window on success or redirect somewhere.

As to changing guardian-mfa page, Yes we have made some small changes. The only thing that I can think of was we added sentry logs when any MFA failure occurs.
See the sample here https://gist.github.com/aonamrata/36eb19345d64ebdc049c8274acefa08c

Though I was able to hack it a little to by resetting the post action URL like this

  let url = "{{ postActionURL }}";
  if (!url || url == '')
    url = "https://mysite/login/auth0redirect?error=unauthorized&error_description=mfa-reset";
  const widget = new Auth0MFAWidget({
    container: "container",
    postActionURL: url,

It would be nice if we can provide this when we create the ticket or something.