How to handle Auth0 RBAC (Roles Based Access Control) using remix-auth-auth0? #93
-
I have Auth0 Application with 2 roles and various users assigned to these roles When I login as a user I expect to have access to their roles so I can control certain rendering. For example, administrators should see extra content and features that other users can't see. This information is supposedly encoded into the access token scopes, but the library doesn't give us access to the token. If I use the Auth0 managementClient I can query a users roles; however, given the power of feature I thought it is likely supported and I just do not know how to use it. Can someone give me example or suggestion? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
Hey @mattmazzola we indeed give you the accessToken on the callback when a user login/register in your app You can save that accessToken anywhere you want to be able to read it 👀 |
Beta Was this translation helpful? Give feedback.
You can pass a custom scope when creating an instance of the strategy.