I’m trying to figure out how should I assign a role to a user in
app_metadata when the user registers.
My use case is as follows: I have 2 roles, A and B. I want to figure out a way to let the user choose when signing up if he/she wants to have role A or role B.
After signing up, the user should be assigned to either role A or role B.
I want to expose different functionality of my app (Angular6 with Django backend API) depending on the role of the user.
At the moment I’m using the universal login page for signing up/logging in users. Should I provide an extra parameter to the universal login page and then set up a custom rule, such that I assign the role based on this extra
Or should I use custom fields for Lock when signing up? I understand this requires database signups, but I want Auth0 to host the login info.
I only want to modify the user’s
app_metadata at signup , as I don’t want the user to be able to change roles later.
Thank you very much for your help.