create a multi-tenant authentication flow in Java Spring Boot using Auth0

I’m looking to create a multi-tenant authentication flow in Java Spring Boot using Auth0(With Java SDK). Here’s a brief overview of what I’m aiming to achieve:

  • When users come for signup, they will be asked to register themselves.
  • During signup, we can assign roles to users.
  • Upon signing in, users will receive an ID token, access token, and refresh token.
  • These tokens will contain role-based information and some user data, which we can utilize in our application.

Do community have any experience or ideas on how to implement this?