Advantages of JWT It is compact – Can be sent via URL/ Post request/HTTP Header which makes it fast for transmission and usable. Self Content – It contains the details of user (not session id in cookies like traditional request), so no need to query database to get user details.
Read moreWhen should I use JWT token?
To authenticate a user , a client application must send a JSON Web Token (JWT) in the authorization header of the HTTP request to your backend API. API Gateway validates the token on behalf of your API, so you don’t have to add any code in your API to process the authentication.
Read more