Create workspace
/v1/api/workspacesStarts a cloud workspace on a fresh branch and, if you pass a prompt, sends it to the agent. The machine starts right away; poll Get workspace or subscribe to webhooks to follow progress.
Authorization
apiKey An API key that starts with zk_. Create one in the Zuse app.
In: header
Header Parameters
Retrying with the same key returns the original result instead of repeating the action. Up to 200 characters.
length <= 200Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Options for a new cloud workspace. Every field is optional when your account has one ready project and an earlier workspace to copy the agent and model from.
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/v1/api/workspaces" \ -H "Content-Type: application/json" \ -d '{}'{ "workspace": { "workspaceId": "workspace_Q2x8mN4pR7sT1vWz", "providerId": "box", "projectId": "proj_8f2c1a", "branch": "fix-order-validation", "baseRef": "main", "state": "queued", "statusCode": "agent-running", "startupPhase": "allocating", "runtimeState": "offline", "agentStatus": "working", "latestSeq": 4, "lastTurn": { "turnId": "turn_7a2c9e", "outcome": "completed", "completedAt": 1760697600000 }, "createdAt": 1760697600000, "updatedAt": 1760697600000 }}{ "error": "invalid_api_key", "detail": "string"}{ "error": "invalid_api_key", "detail": "string"}{ "error": "invalid_api_key", "detail": "string"}{ "error": "invalid_api_key", "detail": "string"}{ "error": "invalid_api_key", "detail": "string"}{ "error": "invalid_api_key", "detail": "string"}