Skip to main content
Skip to main content

TokenService

Constructors

constructor

**new TokenService**(«destructured»)

Parameters

__namedParametersInjectedDependenciesRequired

Properties

configModule_ConfigModuleRequired
RESOLUTION_KEYstringRequired

Methods

signToken

**signToken**(data, options?): string

Parameters

datastring | object | BufferRequired
optionsSignOptions

Returns

string

stringstring

verifyToken

**verifyToken**(token, options?): string \| Jwt \| JwtPayload

Parameters

tokenstringRequired
optionsVerifyOptions

Returns

string | Jwt | JwtPayload

string \| Jwt \| JwtPayloadstring | Jwt | JwtPayload
Was this section helpful?