---
title: "POST /api-keys"
method: POST
path: "/api-keys"
---

# POST /api-keys

`POST /api-keys`

## Request

- Base URL: `https://api.farpy.com/v1`
- URL: `https://api.farpy.com/v1/api-keys`
- Auth: API key in cookie `farpy_session`

## Request body

- ApiKeyCreateRequest
  - `name` string, required

## Response `201`

API key created

- ApiKeyCreated
  - `ok` true, required
  - `key` string, required
  - `key_id` string, required
  - `name` string, required
  - `created_at` string, date-time, required

## Other responses

- `400`: Invalid key name
- `401`: Not authenticated
- `409`: Active key limit reached

---

[API](https://skmtc.dev/farpy/apis/farpy-public-api.md) · [All operations](https://skmtc.dev/farpy/apis/farpy-public-api/llms.txt) · [OpenAPI document](https://skmtc.dev/farpy/apis/farpy-public-api/revisions/fe4065160cb2?raw)
