I have a use case where we have enabled organizations feature and each organization has its separate URL, for example, we have org1.example.com and org2.example.com. Because our application is invitation only, after creating a user in let say org2 domain and sending him a change password email via Authentication API change password endpoint, after the user changes password he gets redirected to the default login page which is org1.example.com, which is not his organization URL. How can we configure a redirect from the change password email so it redirects to the proper organization domain?
Thanks for contacting Auth0 Community
This doc explains organization invitation flow and also explains the redirect URI handling process Invite Organization Members
Let us know if this helps.
Thank you for your response. When we add a user to the application, we first create a user, then add that user to the specific organization, and then send him a change password request. The problem is after changing the password user gets redirected to the default URL where we want to redirect him to the URL of that organization where he is added.
Apologies for the late reply.
Instead of creating a user manually, you can invite a user directly from an organization via Auth0 Dashboard. This way users can sign up by themselves saving you some time and effort. Send Organization Membership Invitations
Thanks for your time to help me with this issue. After sending an organization membership invitation, when the user goes to the organization signup page, he always gets an error because of the pre-user-registration hook. The hook is expecting the user to have user_metadata assigned to him but only invitation to that user has user_metadata. My question is can I in the pre-user-registration hook get access to that user_metadata from the invitation so I can assign it to that user?
Please open a new thread for this and cc me in it.