Closed Abdurahman-hassan closed 1 year ago
It is unlikely that the tab can be automatically closed. In practice, it may not be desirable anyway, because a user usually already has a browser window with multiple tabs, your automatic closing the sign-in tab would probably end up with the user looking at an irrelevant preexisting tab.
You may, however, use an undocumented behavior of MSAL Python to supply a success_template="<html><body>Hooray, you have signed in! Now you may want to read <a href="http://example.com">our documentation page</a></body></html>"
. One of MSAL Python's downstream application, the Azure CLI, has a creative usage which can automatically redirect end user to the documentation page after 10 seconds.
Thank you,
I have added this and it works for me success_template="""
"""
Hello,
After I set http://localhost in the active directory and use the acquire_token_interactive function to fetch the token
The content of redirection after successful authentication: Authentication completed. You can close this window now.
how I can close the localhost tab automatically http://localhost:5001/?code=0.ATAXXXXXX&session_state=8beXXXXXX
Is there a way to automate this process
I'm using msal for python