middleware/jwt

Middleware function for role-based authentication and authorization.
Source:
Parameters:
Name Type Description
roles Array.<string> An array of roles allowed to access the route.
Returns:
Type:
function
- The middleware function.