Enable okta login for Dash

I was successful in integrating Dash with Okta by using dash-okta-auth . It does require flask dance but, while they say that they are not supporting the okta blueprint, it still seems to download as part of their package. Two quick tips:

  1. The auth = ‘auth’ statement can be commented out since it will throw an error

app = Dash(
    __name__,
    server=server,
    url_base_pathname='/',
    #  auth='auth',
)
  1. I had a good bit of difficulty with a ‘404 BAD REQUEST’ error from Okta. I was able to overcome this by copying the text behind the redirect_uri parameter in the url that appears with the error screen and then (after re-inserting the colon and slash etc.) placing that text into the ‘Login redirect URIs’ field on your Okta application. So for example, http%3A%2F%2Flocalhost%3A8050%2Flogin%2Fokta%2Fauthorized becomes http://localhost/8050/login/okta/authorized .

This is kind of hard to explain but if you run into trouble let me know and I will try to help.