> ## Documentation Index
> Fetch the complete documentation index at: https://docs.dalyenergy.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Create Workspace

> Create a new workspace with an auto-generated API key

# POST /workspaces

Create a new workspace. The calling user becomes the `owner` of the new workspace, and default workspace settings are initialized automatically.

## Notes

* Requires **admin** role in the current workspace.
* Request body requires an `identifier` string (a human-readable name for the workspace).
* The response includes a plaintext `api_key` for the new workspace. This is the only time it is visible -- store it securely.
* The workspace API key is stored as an HMAC-SHA256+PBKDF2 hash and cannot be retrieved later.
* The calling user is assigned the `owner` role in the newly created workspace.
* Default workspace settings are created automatically. Use `GET /workspaces/{workspace_id}/settings` to inspect or `PATCH /workspaces/{workspace_id}/settings` to customize them.

<Warning>Copy the returned `api_key` immediately. It cannot be recovered after this response.</Warning>
