---
title: "Mint an API key"
method: POST
path: "/workspaces/{id}/api-keys"
---

# Mint an API key

`POST /workspaces/{id}/api-keys`

## Request

- Base URL: `https://creadal.com/api/v1`
- URL: `https://creadal.com/api/v1/workspaces/{id}/api-keys`
- Auth: HTTP bearer

SESSION-ONLY (admin). The response's `key` is the raw secret, shown exactly once.

## Path parameters

- `id` string, required

## Request body

- object
  - `label` string, required
  - `scopes` string[], required

## Response `201`

{ key, view }

---

[API](https://skmtc.dev/creadal/apis/creadal-generation-api.md) · [All operations](https://skmtc.dev/creadal/apis/creadal-generation-api/llms.txt) · [OpenAPI document](https://skmtc.dev/creadal/apis/creadal-generation-api/revisions/703dfc723415?raw)
