Spring Boot: Integrating User Login with JWT Authentication?

Hi all this is my first post, hope someone can help me.

I have followed the Spring Example in order to add JWT auth to my spring boot api and it worked great!

I am now confused how to also add a User login/logout using Auth0 that will integrate with my JWT protected API. Can someone point me in the right direction?

I am assuming the flow is as below?

  1. User enters user name and password
  2. Check is made against DB in Auth0 or elsewhere
  3. if log in is successful then make call to Auth0 to generate JWT

Are there any existing Auth0 tutorials for this? thanks!