Create a JWT validation middleware for every request to the server. For the validation checker use the universal salt used by every team in order to have the ability to use the same valid token on every server. Discuss with the developers on the other teams about the used salt. The salt will be stored in a .env file that MUST NOT BE PUSHED TO THE REPO. This file will be passed to the developers in a safe way.
If the token is valid proceed with the response based on the id serialized in the token.
If the token in invalid respond with a message and unauthorized http status code. (check HTTP status codes)
Create a JWT validation middleware for every request to the server. For the validation checker use the universal salt used by every team in order to have the ability to use the same valid token on every server. Discuss with the developers on the other teams about the used salt. The salt will be stored in a .env file that MUST NOT BE PUSHED TO THE REPO. This file will be passed to the developers in a safe way.