Options
All
  • Public
  • Public/Protected
  • All
Menu

Class responsible for JWT generation.

Hierarchy

  • JwtGenerator

Index

Constructors

constructor

Properties

accessTokenSigner

accessTokenSigner: IAccessTokenSigner

apiKey

apiKey: IPrivateKey

apiKeyId

apiKeyId: string

appId

appId: string

millisecondsToLive

millisecondsToLive: number

Methods

generateToken

  • Generates a token with the given identity as the subject and optional additional data.

    Parameters

    • identity: string

      Identity to be associated with JWT (i.e. the Subject).

    • Optional ada: IExtraData

      Additional data to be encoded in the JWT.

    Returns Jwt