Tokens

Create Token

Request

  • type
    string
  • meta
    combination of empty object and record of strings
  • expireAt
    optional string

Response

  • token
    object
    • token.token
      string
    • 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.create({
  // Request body
});