bearerAuthenticateStatic
function bearerAuthenticateStatic(options): AuthenticateFn;Defined in: src/http/bearer.ts:48
Create a bearer-token authenticate callback from a static token map.
Convenience wrapper around bearerAuthenticate that looks up the
token in a pre-built mapping using constant-time comparison.
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
options |
{ tokens: | ReadonlyMap<string, AuthContext> | Record<string, AuthContext>; } |
options.tokens |
| ReadonlyMap<string, AuthContext> | Record<string, AuthContext> |
