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

# Create an API key

`POST /api-keys/create`

## Request

- Base URL: `https://api.foudroyer.com` (the document declares no server; this is the origin it was published from)
- URL: `https://api.foudroyer.com/api-keys/create`
- Auth: HTTP bearer

Creates an API key for the authenticated user. The plaintext key is returned only once.

## Request body

- ApiKeysCreateDto
  - `name` string, required: Label to identify this key
  - `scopes` string[]: Permissions granted to this key

## Response `200`

Created API key. The `key` field is shown only in this response.

---

[API](https://skmtc.dev/foudroyer/apis/foudroyer-api.md) - [All operations](https://skmtc.dev/foudroyer/apis/foudroyer-api/llms.txt) - [OpenAPI document](https://skmtc.dev/foudroyer/apis/foudroyer-api/revisions/5b917c67e013?raw)
