> ## Documentation Index
> Fetch the complete documentation index at: https://docs.extractor.live/llms.txt
> Use this file to discover all available pages before exploring further.

# generate api key



## OpenAPI

````yaml /openapi.json post /api/v1/apikey
openapi: 3.0.3
info:
  title: Extractor Project (dev)
  version: 0.0.649
servers: []
security: []
paths:
  /api/v1/apikey:
    post:
      tags:
        - Api Key Route
      summary: generate api key
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateApiKeyDto'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiKeyDto'
      security:
        - SecurityScheme: []
components:
  schemas:
    CreateApiKeyDto:
      required:
        - label
      type: object
      properties:
        status:
          description: 'Status of the entity. Default: ''ACTIVE'''
          type: string
          allOf:
            - $ref: '#/components/schemas/Status'
        tenantId:
          format: int64
          description: >-
            The id of a tenant that owns the key. Only accepted if request from
            admin role or if matches auth tenant id.
          type: integer
        label:
          description: The label that's assigned to the key.
          pattern: \S
          type: string
        lifetime:
          format: int64
          description: The duration in seconds, after which the key expires.
          type: integer
    ApiKeyDto:
      type: object
      properties:
        id:
          format: int64
          description: Unique identifier of the entity
          type: integer
          example: 1
        createdAt:
          format: int64
          description: Time when entity was created
          type: integer
        updatedAt:
          format: int64
          description: Time when entity was updated
          type: integer
        status:
          description: 'Status of the entity. Default: ''ACTIVE'''
          type: string
          allOf:
            - $ref: '#/components/schemas/Status'
        tenantId:
          format: int64
          description: >-
            The id of a tenant that owns the key. Only accepted if request from
            admin role or if matches auth tenant id.
          type: integer
        apiKey:
          description: The api key (JWT token).
          type: string
        label:
          description: The label that's assigned to the key.
          type: string
        lifetime:
          format: int64
          description: The duration in seconds, after which the key expires.
          type: integer
        expiresAt:
          format: int64
          description: The time when api key was / will be expired.
          type: integer
        jti:
          description: The unique identifier of an api key (JWT token).
          type: string
    Status:
      enum:
        - ACTIVE
        - DISABLED
        - DELETED
      type: string
  securitySchemes:
    SecurityScheme:
      type: http
      description: Authentication
      scheme: bearer
      bearerFormat: JWT

````