---
title: "Issue a workspace master key"
method: POST
path: "/v1/workspaces/{id}/keys"
tags: ["Workspaces"]
---

# Issue a workspace master key

`POST /v1/workspaces/{id}/keys`

## Request

- Base URL: `https://anjal.app`
- URL: `https://anjal.app/v1/workspaces/{id}/keys`
- Auth: API key in header `X-API-Key`

Returns a `wk_...` key scoped to this workspace. The key is only shown in the response body — store it securely.

## Request body

- object
  - `name` string

## Response `201`

Created

- WorkspaceKey
  - `id` string, uuid
  - `key` string: Plain-text key — only returned on creation. Store it somewhere safe.
  - `prefix` string
  - `name` string
  - `workspaceId` string, uuid
  - `createdAt` string, date-time

---

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