Crypto Server
Preparing search index...
lib/auth
authenticate
Function authenticate
authenticate
(
request
:
FastifyRequest
,
reply
:
FastifyReply
,
)
:
Promise
<
AuthPayload
|
null
>
Authenticate a request. Checks (in order):
Bearer JWT token in Authorization header
API key in x-api-key header
If neither configured, allow all (dev mode)
Returns the authenticated payload or sends 401.
Parameters
request
:
FastifyRequest
reply
:
FastifyReply
Returns
Promise
<
AuthPayload
|
null
>
Settings
Member Visibility
Protected
Inherited
Theme
OS
Light
Dark
Crypto Server
Loading...
Authenticate a request. Checks (in order):
Returns the authenticated payload or sends 401.