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

# Create API key

> Creates an API key for the workspace associated with the Management API key. Maximum number of API keys in defined by your plan limits. If you need additional API keys, contact our support team.



## OpenAPI

````yaml reference/management-api_2025-11-20.json POST /api-keys
openapi: 3.0.0
info:
  title: Management API
  description: >-
    Managment API allows you to manage your Fingerprint account and applications
    programmatically from a server environment.
  version: '2025-11-20'
  contact: {}
servers:
  - url: https://management-api.fpjs.io
security:
  - Management-API-key: []
tags: []
paths:
  /api-keys:
    post:
      tags:
        - api-keys
      summary: Create API key
      description: >-
        Creates an API key for the workspace associated with the Management API
        key. Maximum number of API keys in defined by your plan limits. If you
        need additional API keys, contact our support team.
      operationId: ApiKeysController_create
      parameters:
        - name: X-API-Version
          in: header
          description: Management API version.
          example: '2025-11-20'
          required: true
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateApiKeyDtoV1'
      responses:
        '201':
          description: Created API key object.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/b43bcdb2376818c770704'
        '400':
          description: 'Error: API key can''t be created due to validation errors.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ValidationApiExceptionDto'
        '401':
          description: 'Error: Invalid API key.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiExceptionDto'
        '429':
          description: 'Error: API key has exceeded its rate limit.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiExceptionDto'
components:
  schemas:
    CreateApiKeyDtoV1:
      type: object
      properties:
        type:
          type: string
          enum:
            - public
            - secret
            - proxy
          description: Type of an API key.
        name:
          type: string
          description: Name of an API key.
          maxLength: 255
          minLength: 3
        description:
          type: string
          description: Description for an API key.
          maxLength: 255
          minLength: 3
        environment:
          type: string
          description: >-
            Environment in which to create an API key. If omitted for proxy or
            secret API keys, the key will be scoped to the workspace. If omitted
            for other types of keys, the API key will be created in the default
            environment.
      required:
        - type
        - name
    b43bcdb2376818c770704:
      type: object
      properties:
        data:
          $ref: '#/components/schemas/ApiKeyResponseDtoV2'
      required:
        - data
    ValidationApiExceptionDto:
      type: object
      properties:
        error:
          $ref: '#/components/schemas/BaseValidationApiExceptionDto'
      required:
        - error
    ApiExceptionDto:
      type: object
      properties:
        error:
          $ref: '#/components/schemas/BaseApiExceptionDto'
      required:
        - error
    ApiKeyResponseDtoV2:
      type: object
      properties:
        id:
          type: string
          description: Auto-generated ID for an API key
          example: tok_No3jUysGLCDuqB3RnCVf1weo
        name:
          type: string
          description: API key name
          example: My Public Key
        description:
          type: string
          description: API key description
          example: Description for my public key
        status:
          type: string
          enum:
            - enabled
            - disabled
          description: API key status, indicates if an API keys is enabled or disabled.
          example: enabled
        environment:
          type: object
          description: ID of an environment the API key belongs to.
          example: ae_rrETjdWcfqI6AFsk
          nullable: true
        type:
          type: string
          enum:
            - public
            - secret
            - proxy
          description: Type of an API key.
          example: public
        token:
          type: string
          description: >-
            Value of an API key. This field is immutable, and for secret keys
            it's only visible upon creation.
          example: eWDrrpGGLjDQW0LBA0Wj
        rate_limit:
          type: number
          description: Current limit in requests-per-second for the API key.
          example: 5
        created_at:
          format: date-time
          type: string
          description: Date when API key was created.
          example: '2024-05-31T01:24:39.506Z'
        disabled_at:
          format: date-time
          type: string
          description: Date when API key was disabled.
          example: null
      required:
        - id
        - name
        - status
        - environment
        - type
        - rate_limit
        - created_at
    BaseValidationApiExceptionDto:
      type: object
      properties:
        message:
          type: string
          description: Verbal description of the error.
        code:
          type: string
          description: Error code.
        violations:
          description: List of validation violations.
          type: array
          items:
            $ref: '#/components/schemas/BaseValidationApiExceptionViolationDto'
      required:
        - message
        - code
    BaseApiExceptionDto:
      type: object
      properties:
        message:
          type: string
          description: Verbal description of the error.
        code:
          type: string
          description: Error code.
      required:
        - message
        - code
    BaseValidationApiExceptionViolationDto:
      type: object
      properties:
        property:
          type: string
          description: Property that has failed validation.
        message:
          type: string
          description: Description of the violation.
      required:
        - property
        - message
  securitySchemes:
    Management-API-key:
      scheme: bearer
      bearerFormat: JWT
      type: http

````