Tokens

Validate Token

Validate a token. Throws an error if the token is invalid.

Request

  • token
    string

Response

  • token
    object
    • token.id
      string
    • token.type
      string
    • token.meta
      any value
    • token.createdAt
      string
    • token.expireAt
      nullable string
    • token.revokedAt
      nullable string

Usage

1. Install the module

2. Use this script

const data = await ctx.modules.tokens.validate({
  // Request body
});