JWT is very popular authentication mechanism in microservice applications. With this way, the services will be able to retrieve the user information in the token and with this way those services does not have to be coupled with user service. In this tutorial we are going to build two separate express applications. One of them will be auth service, which will be checking the credentials and creating token based on that. And the other service, article, will be retrieving user information from token than it will associate incoming article request with that logged in user.
The repo for this tutorial can be found here https://github.com/basarbk/express-jwt
#jwt #express #node