---
title: "Create API key"
method: POST
path: "/api-keys"
tags: ["api-keys"]
---

# Create API key

`POST /api-keys`

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.

## Headers

- `X-API-Version` string, required

## Request body

- CreateApiKeyDtoV1
  - `type` 'public' | 'secret' | 'proxy', required — Type of an API key.
  - `name` string, required — Name of an API key.
  - `description` string — Description for an API key.
  - `environment` string — 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.

## Response `201`

Created API key object.

- B43bcdb2376818c770704
  - `data` ApiKeyResponseDtoV2, required
    - `id` string, required — Auto-generated ID for an API key
    - `name` string, required — API key name
    - `description` string — API key description
    - `status` 'enabled' | 'disabled', required — API key status, indicates if an API keys is enabled or disabled.
    - `environment` object, nullable, required — ID of an environment the API key belongs to.
    - `type` 'public' | 'secret' | 'proxy', required — Type of an API key.
    - `token` string — Value of an API key. This field is immutable, and for secret keys it's only visible upon creation.
    - `rate_limit` number, required — Current limit in requests-per-second for the API key.
    - `created_at` string, date-time, required — Date when API key was created.
    - `disabled_at` string, date-time — Date when API key was disabled.

## Other responses

- `400` — Error: API key can't be created due to validation errors.
- `401` — Error: Invalid API key.
- `429` — Error: API key has exceeded its rate limit.

---

[API](https://skmtc.net/fingerprint/apis/management-api.md) · [All operations](https://skmtc.net/fingerprint/apis/management-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/fingerprint/management-api/versions/b17eccec9d47/schema)
