---
title: "Create a workspace"
method: POST
path: "/v1/account/workspaces"
tags: ["WorkspaceAdminService", "Workspace Admin"]
---

# Create a workspace

`POST /v1/account/workspaces`

Creates a new workspace in the account. Admin only.

## Request body

- CreateWorkspaceRequest
  - `metadata` CreateAccountResourceMetadata, required — CreateAccountResourceMetadata contains the user-provided fields for creating an account-scoped resource. Read-only fields (id, account_id, profile_id) are excluded since they are set by the server.
    - `name` string, required — Human-readable name for the resource (e.g., "Production API Key", "Staging Workspace")
    - `externalId` string — External ID for the resource (e.g., a workflow ID from an external system)
    - `labels` object — Key-value pairs for categorization and filtering. Values are 0-63 alphanumeric characters with "-", "_", or "." allowed between; keys follow the same shape and additionally accept an optional DNS-subdomain prefix (e.g. "cadenya.com/") of at most 253 characters. Examples: {"environment": "production", "team": "platform", "version": "v2"}
  - `spec` WorkspaceSpec, required
    - `description` string

## Response `200`

OK

- Workspace
  - `metadata` AccountResourceMetadata, required — AccountResourceMetadata is used to represent a resource that is associated to an account but not to a workspace.
    - `id` string, required — Unique identifier for the resource (prefixed ULID, e.g., "apikey_01HXK...")
    - `accountId` string, required — Account this resource belongs to for multi-tenant isolation (prefixed ULID)
    - `name` string, required — Human-readable name for the resource (e.g., "Customer Support Agent", "Email Tool") Required for resources that users interact with directly
    - `externalId` string — External ID for the resource (e.g., a workflow ID from an external system)
    - `labels` object — Key-value pairs for categorization and filtering. Values are 0-63 alphanumeric characters with "-", "_", or "." allowed between; keys follow the same shape and additionally accept an optional DNS-subdomain prefix (e.g. "cadenya.com/") of at most 253 characters. Examples: {"environment": "production", "team": "platform", "version": "v2"}
    - `profileId` string, required
    - `createdAt` string, date-time
  - `spec` WorkspaceSpec, required
    - `description` string
  - `status` 'STATUS_ENABLED' | 'STATUS_DISABLED' | 'STATUS_ARCHIVED', enum — Lifecycle status of the workspace. Archived workspaces reject all requests scoped to them. Server-populated.
  - `info` WorkspaceInfo — WorkspaceInfo returns counts
    - `totalAvailableTools` integer
    - `totalMemoryEntries` integer
    - `totalAgents` integer
    - `totalAgentVariations` integer

## Other responses

- `default` — Default error response

---

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