---
title: "Add Key"
method: POST
path: "/keys"
tags: ["Keys"]
---

# Add Key

`POST /keys`

## Request body

- KeyGenerationRequest
  - `name` string, required

## Response `201`

Successful Response

- KeyResponse
  - `id` string
  - `name` string
  - `organization_id` string, required
  - `created_at` string, date-time
  - `key_preview` string
  - `api_key` string

## Other responses

- `404` — Not found
- `422` — Validation Error

---

[API](https://skmtc.dev/dataherald/apis/fastapi.md) · [All operations](https://skmtc.dev/dataherald/apis/fastapi/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/dataherald/fastapi/revisions/e168e98625a8/schema)
