---
title: "Create"
method: POST
path: "/api/workspaces"
tags: ["Workspaces"]
---

# Create

`POST /api/workspaces`

## Request

- Base URL: `https://api.kolens.ai` (the document declares no server; this is the origin it was published from)
- URL: `https://api.kolens.ai/api/workspaces`
- Auth: HTTP bearer

## Headers

- `x-kolens-user-id` string, nullable

## Request body

- CreateWorkspaceRequest
  - `name` string, required
  - `slug` string, nullable
  - `plan` string, nullable

## Response `201`

Successful Response

- WorkspaceOut
  - `id` string, required
  - `name` string, required
  - `slug` string, required
  - `owner_user_id` string, required
  - `plan` string, required
  - `role` 'admin' | 'billing' | 'member', nullable
  - `member_count` integer, nullable
  - `is_personal` boolean, nullable
  - `created_at` string, date-time, required
  - `updated_at` string, date-time, required

## Other responses

- `422`: Validation Error

---

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