authorization
authorization: (
options?) =>Function
Defined in: http/authorization.js:50
Creates an authorization middleware that parses the Authorization header and dispatches to the matching strategy handler.
Parameters
Section titled “Parameters”options?
Section titled “options?”Authorization configuration
strategies?
Section titled “strategies?”object[] = []
Authentication strategy definitions
Returns
Section titled “Returns”Function
- Async middleware
(req) => infoon success; on failure{response: {statusCode: 401|403, headers?}}with optionalWWW-Authenticateheader tuples fromauthenticate