SPA Route user to authentication connection that matches the user domain

I have a react SPA that uses 2 or more enterprise connections to authenticate users, currently, after the user clicks on a login button using redirectWithLogin(), they are redirected to the auth0 domain where they see a list of connections, from there they are taken to their connection login page where they can log in with their credentials.

If we know in advance the user, is it possible to route them to their connection so they skip the connection selection?

e.g. if we know a user belongs to the Acme Connection, after the user clicks on the login button, the user is redirected directly to Acme connection login page instead of seeing the list of connections.

Hi Alex,
Yes this is doable & btw what login experience are you using? Classic or New Universal login(UL)?

New UL supports login_hint param OOB where you can pass the users email as a hint when redirecting to the auth0 /authorize endpoint & if identifier first flow is enabled then the user should be redirected to the external IDP if their email domain is mapped at the enterprise connection level.

For either, New/Classic you should be able to send an extra param “connection” whose value should be the connection name(for ex- acme), doing this when redirecting to /authorize endpoint will redirect the user to the external IDP’s login page.

“Connection” param is not a standard parameter defined in the specs so login_hint might work better when you are integrating 3rd party apps like Workday, Salesforce etc.

Below is the link to Authentication API docs where you can read about the connection param

Hope that helps!