Requiring a Signed-In User
A requireUser middleware checks the token in a request's Authorization header before the route runs, puts the signed-in user in req.user, and answers 401 when the token is missing, made up or expired.
Updated

- Category
- Node.js
- Level
- Journeyman
- Tags
- 401 Unauthorized, Authentication, Authorization, Bearer Token, Middleware in Express, nodejs, rest-api