---
title: "Create workspace API key"
method: POST
path: "/v1/console/api-keys"
tags: ["Console - API Keys"]
---

# Create workspace API key

`POST /v1/console/api-keys`

Create a new API key for accessing workspace management APIs. The secret is only shown once.

## Request body

- CreateApiKeyDto
  - `name` string, required

## Response `201`

API key created successfully

- ApiKeyResponseDto
  - `id` string, required
  - `name` string, required
  - `secret` string, required — Full API key secret (only returned once at creation time — persist it immediately as it cannot be retrieved later).
  - `last_used_at` number — Unix timestamp
  - `revoked_at` number — Unix timestamp
  - `created_at` number, required — Unix timestamp

## Other responses

- `401` — Unauthorized

---

[API](https://skmtc.net/hopae/apis/hconnect-api.md) · [All operations](https://skmtc.net/hopae/apis/hconnect-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/hopae/hconnect-api/revisions/ed6e97ac6f2f/schema)
