Skip to main content

Workspaces

Create, manage, and control development workspaces. Workspaces are interactive computing environments (e.g., Jupyter, VS Code, RStudio) provisioned within a project.

All endpoints require authentication via X-API-Key header and the appropriate scope.


Workspace Object​

{
"_id": "ws_ghi789",
"name": "Training Environment",
"description": "GPU-enabled workspace for model training",
"projectId": "proj_abc123",
"branch": "main",
"status": "running",
"environment": {
"type": "jupyter",
"label": "Jupyter Lab",
"port": 8888
},
"resources": {
"cpu": "4",
"memory": "16GB",
"disk": "20GB",
"gpu": "1",
"gpuType": "nvidia-a10g",
"useSpot": true,
"spotFallback": true
},
"workspaceVolumeSize": "50GB",
"environmentVariables": { "EPOCHS": "10" },
"addons": [],
"dataSources": [],
"aiGateways": [],
"workflows": [],
"codingAssistants": ["claude-code"],
"codeSessionEnabled": false,
"cluster": {
"engine": "ray",
"coordinator": { "cpu": "2", "memory": "4GB" },
"worker": { "cpu": "2", "memory": "4GB" },
"workers": 2,
"status": "ready",
"connectAddress": "ray://<host>:10001",
"dashboardUrl": "https://.../dashboard"
},
"volumes": [
{
"volumeId": "vol_def001",
"name": "training-data",
"scope": "local",
"code": { "remote": "git@github.com:my-org/training.git", "branch": "main" },
"data": { "version": "latest" }
}
],
"organizationId": "org_xyz",
"owner": "user_456",
"url": "/api/workspace-proxy/ws_ghi789/lab",
"createdAt": "2025-01-16T11:00:00Z",
"updatedAt": "2025-02-01T08:00:00Z"
}
  • resources.disk is the container's ephemeral scratch; workspaceVolumeSize is the persistent /workspace volume.
  • environment.type is the IDE (jupyter, vscode, rstudio, custom) and environment.port the port it serves on (for a Custom IDE, the customPort you set); a Custom IDE also carries any declared proxyHeaders.
  • status is one of stopped, deploying, starting, running, stopping, error.
  • waiting is set while it waits for a machine: reason (WaitingForCapacity: the cloud has no machine of the size it asked for free right now) and detail in plain words. It starts as soon as a machine is free; waiting is absent or null otherwise.
  • owner is the id of the user who created the workspace. url is the path the workspace opens at on your instance.
  • platformUpdatePending is true while the running workspace was deployed by an earlier platform version; POST /workspaces/:id/restart applies the update (it ends open notebooks, terminals and processes). Absent otherwise. See Platform Updates.
  • volumes lists the code/data volumes the workspace mounts, as they mount.
  • cluster is present only when a compute cluster is attached; once ready it exposes the connectAddress and dashboardUrl. See Compute Clusters.

GET /api/v1/workspaces​

List all workspaces accessible to the authenticated user. Each workspace is a summary: _id, name, description, status, owner, projectId, environmentId, environment, resources, url, branch, workspaceVolumeSize, lastAction, lastActionAt, lastAccessedAt, createdAt, updatedAt, and waiting while it waits for a machine. GET /api/v1/workspaces/:id returns the full workspace (deployment record, volumes, platform containers, connected services).

Scope: workspaces:read

Query Parameters

ParameterTypeRequiredDescription
qstringNoSearch by name or description
statusstringNoFilter by status: stopped, deploying, starting, running, stopping, error
projectIdstringNoFilter by project ID
limitintegerNoNumber of results to return (default: 50, max: 200)
cursorstringNometa.nextCursor of the previous page; omit for the first page
sortstringNoSort field, prefixed with - for descending (default: -createdAt)

Response 200 OK

{
"data": [
{
"_id": "ws_ghi789",
"name": "Training Environment",
"description": "GPU-enabled workspace for model training",
"projectId": "proj_abc123",
"status": "running",
"environment": { "type": "jupyter", "label": "Jupyter Lab", "port": 8888 },
"resources": { "cpu": "4", "memory": "16GB", "disk": "20GB" },
"organizationId": "org_xyz",
"owner": "user_456",
"url": "/api/workspace-proxy/ws_ghi789/lab",
"createdAt": "2025-01-16T11:00:00Z",
"updatedAt": "2025-02-01T08:00:00Z"
}
],
"meta": {
"total": 8,
"limit": 50,
"nextCursor": null,
"requestId": "req_abc123"
}
}

GET /api/v1/workspaces/stats​

Count the workspaces GET /api/v1/workspaces lists, with the same filters: every one the list holds for you with these filters, not a page, counted by the database. Each by<Field> is a list of rows, one per value with how many have it ({ "<field>": value, "total": n }), most first; a value the records leave out is null.

Scope: workspaces:read

Query Parameters (the list's own filters)

ParameterTypeRequiredDescription
qstringNoSearch by name or description
statusstringNoOnly workspaces with this status
projectIdstringNoOnly this project's workspaces

Response 200 OK

{
"data": { "total": 8, "byStatus": [ { "status": "stopped", "total": 5 }, { "status": "running", "total": 3 } ], "byEnvironment": [ { "environment": "VS Code", "total": 6 }, { "environment": "Jupyter Lab", "total": 2 } ] },
"meta": { "requestId": "..." }
}
FieldDescription
totalHow many the list holds with these filters.
byStatusEach status with how many workspaces have it.
byEnvironmentEach IDE the workspaces open (the environment's label) with how many open it.

POST /api/v1/workspaces​

Create a new workspace.

Scope: workspaces:write

Request Body

The request body has full parity with the Create Workspace UI: choose the IDE, size it (with custom resources or a saved environment), set a persistent volume size, attach services, environment variables, coding assistants, and optionally a distributed compute cluster.

{
"name": "Training Environment",
"description": "GPU-enabled workspace for model training",
"environmentType": "jupyter",
"projectId": "proj_abc123",
"customResources": {
"cpu": "4",
"memory": "16GB",
"disk": "20GB",
"gpu": "1",
"gpuType": "nvidia-a10g"
},
"workspaceVolumeSize": "50GB",
"useSpot": false,
"environmentVariables": { "EPOCHS": "10" },
"dataSources": [],
"addons": [],
"aiGateways": [],
"workflows": [],
"codingAssistants": ["claude-code"],
"cluster": {
"engine": "ray",
"coordinator": { "cpu": "2", "memory": "4GB" },
"worker": { "cpu": "2", "memory": "4GB" },
"workers": 2,
"engineOptions": { "metricsDashboards": true }
}
}
FieldTypeRequiredDescription
namestringYesWorkspace name
descriptionstringYesWorkspace description
environmentTypestringYesThe IDE the workspace opens: jupyter, vscode, rstudio, or custom. Independent of the hardware sizing.
projectIdstringNoProject the workspace belongs to. The project's volume is mounted at /volumes/local/<name>. If omitted, a project is created automatically.
sharedVolumeIdsstring[]NoThe shared volumes to mount at /volumes/shared/<name> (code/ read-only). None unless listed. A volume you may not mount is refused with 400, by name, and one whose share is later taken away is dropped from the list.
environmentIdstringNoId of a saved environment (from list_environments) supplying the container image and the size. Use this for a specific software stack (for example an RStudio image with your R packages). Set either environmentId or customResources.
environmentVersionnumberNoPin a specific version of the selected environment. Omit for the latest.
customResourcesobjectWhen no environmentIdThe size when not using environmentId: { cpu, memory, disk, gpu?, gpu_type? }. The workspace runs at exactly this size; no size is assumed, and a create with neither customResources nor environmentId is refused. At least 0.5 CPU and 1 GB of memory (the platform services' share plus room for the IDE); a smaller workspace is refused at Start with the size that would do. disk is the container's ephemeral scratch disk (not the persistent volume). A size with gpu is checked against the GPU machine sizes allowed on the Compute page and refused with a message naming the machine it needs when none is allowed (an A100 or H100 needs the largest sizes).
workspaceVolumeSizestringNoSize of the persistent /workspace scratch volume (virtual environments, caches, scratch files), which survives stop/start and is deleted with the workspace; until you sync, the working copy of the code and the data files you changed are kept on it too (for example "50GB"). Code and data you keep belong in the project's volume. Distinct from customResources.disk. Default "20GB".
useSpotbooleanNoRun the workspace on spot capacity (cheaper; it can be reclaimed, and the workspace restarts on a new node with its volumes kept). Default false.
spotFallbackbooleanNoWith useSpot, fall back to on-demand capacity when no spot is available (default true); false waits for spot.
customPortnumberNoCustom IDE only: the port the environment image serves its IDE on. Default 8888.
proxyHeadersarrayNoCustom IDE only: extra request headers forwarded to your IDE, as { name, value }. Values may use ${BASE_PATH} / ${ORIGIN} / ${PATH} / ${REQUEST_URI} placeholders.
environmentVariablesobjectNoKey/value environment variables injected into the workspace container. The workspace's own only: a name the platform sets in a workspace (WORKSPACE_ID, STRONGLY_WORKSPACE_ID, STRONGLY_SERVICES, STRONGLY_API_URL and the rest the Configuration tab lists) or STRONGLY_API_KEY is refused with 400.
dataSourcesarrayNoIds of data sources to wire into the workspace (delivered in STRONGLY_SERVICES).
addonsarrayNoIds of add-ons to attach (injected via STRONGLY_SERVICES).
aiGatewaysarrayNoIds of AI models / gateways to make available (injected via STRONGLY_SERVICES).
workflowsarrayNoIds of workflows to make available (injected via STRONGLY_SERVICES).
codingAssistantsarrayNoThe coding assistant to install at startup: at most one of claude-code, codex, opencode (CLIs, Jupyter and VS Code) or cline (a VS Code extension, VS Code only; refused with 400 for another IDE). More than one is refused with 400.
assistantModelIdstringWith clineThe id of the AI Gateway chat model Cline calls (one you may use). Required with cline, refused with 400 otherwise. Cline calls it through the AI Gateway as you; no key is stored.
skillIdsarrayNoIds of your Skill Library skills to install at each start, with the Strongly skill, for every coding assistant (chosen or not). Jupyter Lab and VS Code only; a skill you cannot read is refused with 400.
codeSessionEnabledbooleanNoLet an agent drive a terminal in the workspace (a code session).
clusterobjectNoAttach a distributed compute cluster. engine is one of ray, dask, spark; plus coordinator: { cpu, memory }, worker: { cpu, memory, gpu?, gpuType? }, workers, optional autoscale: { enabled, maxWorkers }, and engineOptions: { metricsDashboards }. The cluster is provisioned on deploy, removed on stop, recreated on start, and deleted with the workspace. See Compute Clusters.

Response 201 Created

The new Workspace object, created stopped; start it to run it.

Error 400 Bad Request when neither environmentId nor customResources is set, or the size is too small:

{
"type": "urn:strongly:problem:validation-error",
"title": "Validation failed",
"status": 400,
"detail": "Set the workspace CPU, memory and disk (or choose an environment)",
"code": "validation-error",
"requestId": "req_abc123"
}

GET /api/v1/workspaces/:id​

Get a single workspace by ID.

Scope: workspaces:read

Path Parameters

ParameterTypeRequiredDescription
idstringYesWorkspace ID

Response 200 OK

Returns the full Workspace object.


PATCH /api/v1/workspaces/:id​

Rename a workspace, change its description, change the services it selects or its coding assistants and their skills (applied at its next start or restart), or set its environment variables. Send only the fields you are changing; any other field is refused with 400. The size, image, IDE and environment are fixed when the workspace is created; to change them, create a new workspace.

Scope: workspaces:write

Path Parameters

ParameterTypeRequiredDescription
idstringYesWorkspace ID

Request Body

{
"name": "Updated Training Environment",
"description": "Updated description",
"environmentVariables": { "EPOCHS": "10" }
}
FieldTypeRequiredDescription
namestringNoWorkspace name
descriptionstringNoWorkspace description
addons, dataSources, aiGateways, mlModels, workflows, featureStores, agentsarrayNoThe services the workspace selects, each list replacing the current one (its STRONGLY_SERVICES is built from them)
codingAssistantsarrayNoThe coding assistant installed at each start, at most one of claude-code, codex, opencode or cline (VS Code only) ([] for none), replacing the current one. More than one is refused with 400. Jupyter and VS Code only. Changing away from cline drops its model.
assistantModelIdstringNoCline only: the AI Gateway chat model Cline calls, applied at the next start or restart.
skillIdsarrayNoSkill Library skills installed at each start for every coding assistant (chosen or not), replacing the current list. Jupyter Lab and VS Code only; a skill the workspace's owner cannot read is refused with 400. A selected skill that was deleted or is no longer shared stops the start, so remove it here.
sharedVolumeIdsstring[]NoThe shared volumes it mounts at /volumes/shared/<name> from its next start or restart, replacing the current list ([] for none). The project's volume always mounts. A volume the owner may not mount is refused with 400, by name.
environmentVariablesobjectNoEnvironment variables (string values), replacing the current set. They are applied when the workspace is deployed: its first start, or a start from error. A name the platform sets in a workspace, or STRONGLY_API_KEY, is refused.

Response 200 OK

{
"data": {
"success": true
},
"meta": {
"requestId": "req_abc123"
}
}

Errors

StatusCodeDescription
400validation-errorThe body has a field other than the three above (for example cpu or image), an environment variable value is not a string, or a variable takes a name the platform sets
409invalid-stateenvironmentVariables on a workspace that is already deployed

DELETE /api/v1/workspaces/:id​

Delete a workspace, running or stopped: a running one is stopped first. Its /workspace volume and anything not synced to its volumes are deleted with it. This action is irreversible.

Scope: workspaces:write

Path Parameters

ParameterTypeRequiredDescription
idstringYesWorkspace ID

Response 204 No Content


POST /api/v1/workspaces/:id/start​

Start a stopped workspace. The call returns as soon as the start is accepted, with the workspace in starting; it does not wait for the IDE to come up. Poll GET /api/v1/workspaces/:id until status is running (the workspace url is then set) or error. The first start of a new workspace deploys it. Starting a workspace that is already running or starting changes nothing and returns 200. A workspace (or its compute cluster's coordinator or worker) whose CPU, memory, GPU count or disk is above the largest machine its pool may start (see GET /api/v1/compute/pools, allowedSizes) is refused with 400 validation-error naming the resource and both figures (for example "A workspace cannot start: 100 GiB disk asked; the largest machine allowed gives one workload 88 GiB."), and nothing starts. A workspace with a compute cluster answers at once too: the cluster comes up after the start (cluster.status provisioning), and the workspace is running once its cluster is ready. A cluster that cannot start (for example a coordinator or worker no machine fits) fails the start: the workspace ends in error with the reason in error, and cluster.status is error with the same reason in cluster.error.

Scope: workspaces:write

Path Parameters

ParameterTypeRequiredDescription
idstringYesWorkspace ID

Response 200 OK: the workspace, as GET /api/v1/workspaces/:id returns it, with its status now.

{
"data": {
"id": "ws_abc123",
"name": "ray-notebook",
"status": "deploying",
"cluster": {
"engine": "ray",
"status": "provisioning"
}
},
"meta": {
"requestId": "req_abc123"
}
}

POST /api/v1/workspaces/:id/stop​

Stop a running workspace. Releases compute resources while preserving workspace state.

Scope: workspaces:write

Path Parameters

ParameterTypeRequiredDescription
idstringYesWorkspace ID

Response 200 OK

{
"data": {
"success": true,
"message": "Workspace stopped successfully. Data in volumes has been preserved."
},
"meta": {
"requestId": "req_abc123"
}
}

POST /api/v1/workspaces/:id/restart​

Restart a running workspace. Equivalent to stop followed by start.

Scope: workspaces:write

Path Parameters

ParameterTypeRequiredDescription
idstringYesWorkspace ID

Response 200 OK

{
"data": {
"success": true
},
"meta": {
"requestId": "req_abc123"
}
}

GET /api/v1/workspaces/:id/platform-environment​

The variables the platform sets in the workspace (WORKSPACE_ID, STRONGLY_SERVICES, ...), each with the value its running IDE container was started with. While it is not running, running is false and every name is listed with a null value. Its owner's only: STRONGLY_SERVICES carries the owner's connections' credentials.

Scope: workspaces:write

Response 200 OK​

{
"data": {
"running": true,
"variables": [
{ "name": "WORKSPACE_ID", "value": "ws-abc123" },
{ "name": "WORKSPACE_TYPE", "value": "jupyter" }
]
}
}

GET /api/v1/workspaces/:id/status​

Read the workspace's current status now. The platform records what it finds, so the workspace list and details page show the same status.

Scope: workspaces:read

Path Parameters

ParameterTypeRequiredDescription
idstringYesWorkspace ID

Response 200 OK

{
"data": {
"status": "running",
"url": "/api/workspace-proxy/45TwJjGz6v9FWnAt3",
"error": null
},
"meta": {
"requestId": "req_abc123"
}
}
FieldDescription
statusdeploying, starting, running, stopping, stopped or error.
urlWhere the workspace IDE opens once it is running.
errorWhy the workspace is in error, for example a container that keeps crashing, an image that cannot be pulled, or a setup step that failed; null otherwise.

A workspace is in error only when it has actually failed. A slow start stays starting for as long as it takes; there is no time limit that turns it into an error.

Errors

StatusCodeWhen
404not-foundNo workspace with this ID that you can see.
502backend-unavailableThe status could not be read right now. The workspace's status is left unchanged; try again.

GET /api/v1/workspaces/:id/pod​

What runs the workspace right now, read live: its phase, every container and why it is not running yet.

Scope: workspaces:read

Response 200 OK

{
"data": {
"name": "workspace-abc-7d9f-x2",
"phase": "Running",
"node": "node-1",
"createdAt": "2026-10-27T10:00:00+00:00",
"startedAt": "2026-10-27T10:00:02+00:00",
"ready": true,
"restartCount": 1,
"containers": [
{ "name": "vol-data", "kind": "sidecar", "ready": true, "restartCount": 1,
"state": { "status": "running", "startedAt": "2026-10-27T10:05:00+00:00" },
"lastTerminated": { "reason": "OOMKilled", "exitCode": 137, "startedAt": "2026-10-27T10:00:03+00:00", "finishedAt": "2026-10-27T10:04:59+00:00" } },
{ "name": "workspace", "kind": "main", "ready": true, "restartCount": 0,
"state": { "status": "running", "startedAt": "2026-10-27T10:00:04+00:00" }, "lastTerminated": null }
],
"pendingReasons": []
},
"meta": { "requestId": "..." }
}
  • phase is Pending, Running, Succeeded, Failed or Unknown; restartCount is the total of its containers'.
  • Each container has a kind: main (the IDE), sidecar (a platform service beside it: its data volume, its auth proxy) or init (a setup step). state is its state now (status waiting, running or terminated, with reason, message, exitCode); lastTerminated is how its previous run ended (reason such as OOMKilled or Error, exitCode, startedAt, finishedAt), null before any restart.
  • pendingReasons says why it is not running yet: the scheduler's answer (source scheduler, e.g. no machine has room), a container waiting on its image or a mount (container), and its Warning events (event: reason such as FailedScheduling, FailedMount or BackOff, message, count, at).

Returns 404 not-found when the workspace has no worker (it is stopped).


GET /api/v1/workspaces/:id/metrics​

Measure a running workspace now. Each call takes a fresh measurement (about 6 seconds, including a 5 second network sample). Nothing is cached, and a value that cannot be measured is reported as an error rather than a zero.

Scope: workspaces:read

Path Parameters

ParameterTypeRequiredDescription
idstringYesWorkspace ID

Response 200 OK

{
"data": {
"cpu": { "usageMillicores": 250.4, "limitMillicores": 1000, "percent": 25.0 },
"memory": { "usageBytes": 1073741824, "limitBytes": 2147483648, "percent": 50.0 },
"disk": { "usedBytes": 2092804096, "capacityBytes": 10464022528, "percent": 20.0, "path": "/workspace" },
"network": { "receiveBytesPerSecond": 5125.4, "transmitBytesPerSecond": 1500.2, "totalBytesPerSecond": 6625.6, "windowSeconds": 5.02 },
"gpu": null,
"responseTime": { "avgMs": 3.1, "minMs": 2.4, "maxMs": 4.9, "samples": 5, "urlPath": "/" },
"containers": [
{ "name": "workspace", "role": "workspace", "cpuMillicores": 250.4, "cpuLimitMillicores": 1000, "cpuPercent": 25.0,
"memoryBytes": 1073741824, "memoryLimitBytes": 2147483648, "memoryPercent": 50.0 },
{ "name": "vol-data", "role": "platform", "cpuMillicores": 1.2, "cpuLimitMillicores": 100, "cpuPercent": 1.2,
"memoryBytes": 20971520, "memoryLimitBytes": 268435456, "memoryPercent": 7.8 }
],
"platformContainersTotal": { "cpuMillicores": 1.2, "memoryBytes": 20971520, "count": 1 },
"measuredAt": "2026-09-23T04:03:40.331446+00:00"
},
"meta": {
"requestId": "req_abc123"
}
}
FieldDescription
cpu, memoryUsage of your workspace container against the size you set.
diskSpace used on the workspace volume mounted at /workspace.
networkBytes per second received and sent over the sampling window, so even light traffic shows a reading.
gpu{ "percent": ... } GPU utilization for workspaces with GPUs; null otherwise.
responseTimeRound trip time of the workspace IDE answering an HTTP request.
containersEvery container in the workspace, with its usage and size. role is workspace for yours and platform for the containers the platform runs beside it, such as one per mounted data volume.
platformContainersTotalCombined usage of the platform containers.

Errors

StatusCodeWhen
409invalid-stateThe workspace is not running.
500internal-errorA measurement could not be taken; the message gives the reason.

GET /api/v1/workspaces/:id/time-series​

A workspace's CPU and memory over time, from the hourly records kept of what its workers used and requested (the platform's own containers beside it are taken out). Usage is settled hourly, so the latest hour or two arrive after they end. For its use right now, measure it with GET /api/v1/workspaces/:id/metrics.

Every series has the same shape: the window, its granularity, start (the start of the first point) and end (now), and points, one for every hour or UTC day of the window, from the one its start falls in to the current one (so far). A quiet point counts zero and averages nothing (null).

Scope: workspaces:read

Path Parameters​

ParameterTypeRequiredDescription
idstringYesThe workspace ID

Query Parameters​

ParameterTypeRequiredDescription
windowstringNo24h (hourly points), 7d or 30d (daily UTC points). 30d when left out.
granularitystringNohourly for 24h, daily for 7d and 30d; the window's when left out. Another is refused (400).

Response 200 OK​

{
"data": {
"window": "7d",
"granularity": "daily",
"start": "2026-10-14T00:00:00Z",
"end": "2026-10-21T13:40:00Z",
"points": [
{ "timestamp": "2026-10-20T00:00:00Z", "cpuCores": 0.0052, "cpuCoresPeak": 0.0091, "cpuRequestCores": 2,
"memoryBytes": 309463177, "memoryBytesPeak": 311427072, "memoryRequestBytes": 8589934592, "runningMinutes": 1440 },
{ "timestamp": "2026-10-21T00:00:00Z", "cpuCores": null, "cpuCoresPeak": null, "cpuRequestCores": null,
"memoryBytes": null, "memoryBytesPeak": null, "memoryRequestBytes": null, "runningMinutes": 0 }
]
},
"meta": { "requestId": "..." }
}
FieldDescription
cpuCores, memoryBytesThe mean CPU cores and memory bytes used, weighted by the minutes it ran in the point.
cpuCoresPeak, memoryBytesPeakIts busiest hour in the point.
cpuRequestCores, memoryRequestBytesIts size (what it requested).
runningMinutesHow long it ran in the point; 0, with every figure null, when it did not run.

Whoever may see the workspace may read it: its owner, its project's owner and platform admins.

Errors​

StatusCodeWhen
400validation-errorA window or granularity it does not offer.
404not-foundNo such workspace, or one you may not see.

GET /api/v1/workspaces/:id/logs​

Retrieve logs for a workspace. Supports different log types for build, deploy, and runtime phases.

Scope: workspaces:read

Path Parameters

ParameterTypeRequiredDescription
idstringYesWorkspace ID

Query Parameters

ParameterTypeRequiredDescription
typestringNoWhich log: pod (the running IDE's own log, the Runtime log on the Logs tab; the default) or deploy (its Kubernetes rollout)

Response 200 OK

{
"data": [
{
"timestamp": "2025-02-01T08:01:30Z",
"level": "info",
"message": "Starting Jupyter server..."
},
{
"timestamp": "2025-02-01T08:01:32Z",
"level": "info",
"message": "Jupyter server is running at https://0.0.0.0:8888"
}
],
"meta": {
"requestId": "req_abc123"
}
}

POST /api/v1/workspaces/:id/sync​

Start a sync of the running workspace to its durable volumes. For the project's volume, the sync commits and pushes the code half to its configured branch; for every mounted volume you may write, it records the data files you changed, each as a new version of that file. A shared volume's code is read-only, so its code result is { "skipped": "read-only" }. Unsynced work survives stop, start and restart; only deleting the workspace loses it. Until you sync, it is not on the volume, not visible to others, not versioned, and not what an app deploy or a job reads. Sync before you delete the workspace, hand work off, run a job on the data, or deploy from the volume.

A sync runs in the background in the workspace, however many files it saves: the request answers at once with the sync, status running. Follow it with GET .../syncs/:id until its status is completed, cancelled or failed; start a job that reads the saved data once it is completed. The data is committed in batches (500 files or 64 MB at a time), so the files a sync committed stay committed when it is cancelled or cut off, and the next sync carries on from there. A file a program is still writing while the sync reads it is left for the next sync and listed in the volume's data.skipped. One sync of a workspace runs at a time.

Scope: workspaces:write

Path Parameters

ParameterTypeRequiredDescription
idstringYesWorkspace ID

Response 202 Accepted

{
"data": {
"_id": "sync-3f9c1a7d2b4e6081",
"workspaceId": "ws_ghi789",
"ownerId": "usr_123",
"status": "running",
"message": "Sync from workspace",
"cancelRequested": false,
"startedAt": "2026-10-27T03:00:00+00:00",
"endedAt": null,
"volumes": [
{ "volumeId": "vol_def001", "name": "training-data", "status": "waiting", "phase": null, "progress": null, "result": null },
{ "volumeId": "vol_sh002", "name": "datasets", "status": "waiting", "phase": null, "progress": null, "result": null }
]
},
"meta": {
"requestId": "req_abc123"
}
}
StatusCodeWhen
409invalid-stateThe workspace is not running, or mounts no code/data volume
409conflictA sync of the workspace is already running
409workspace-not-readyThe workspace's storage is still starting
502backend-unavailableThe sync could not be started in the workspace (the reason is in detail)

When the code changed on the volume since the workspace's last sync, on the same lines, the volume's code result is { "conflict": true, "pushed": false, "files": ["app.py"] }: nothing is overwritten, and the merge waits for you to decide each file (below). Sync again once no files are left: that finishes the merge and pushes it.


GET /api/v1/workspaces/:workspaceId/syncs/:id​

A sync: its status (running, then completed when every volume is saved, cancelled or failed) and, per volume in mount order, its status (waiting, saving, then saved, cancelled or failed), its phase while it saves (code, then data), its progress while its data saves, and its result once done. A sync whose workspace stopped, or whose storage restarted, before it finished is failed, with the reason in each unfinished volume's result.error (for example The workspace's storage restarted (OOMKilled, exit code 137) before the save finished).

Scope: workspaces:read

Path Parameters

ParameterTypeRequiredDescription
workspaceIdstringYesWorkspace ID
idstringYesThe sync's _id, as POST .../sync answered it

Response 200 OK

{
"data": {
"_id": "sync-3f9c1a7d2b4e6081",
"workspaceId": "ws_ghi789",
"status": "completed",
"cancelRequested": false,
"startedAt": "2026-10-27T03:00:00+00:00",
"endedAt": "2026-10-27T03:01:12+00:00",
"volumes": [
{
"volumeId": "vol_def001",
"name": "training-data",
"status": "saved",
"phase": "data",
"progress": { "filesTotal": 6500, "bytesTotal": 459000000, "filesSaved": 6500, "bytesSaved": 459000000,
"bytesRead": 459000000, "filesSkipped": 0, "filesChanged": 6500, "deletesTotal": 0 },
"result": {
"volumeId": "vol_def001",
"base": "/volumes/local/training-data",
"code": { "committed": true, "pushed": true, "conflict": false, "rebased": false },
"data": { "committed": true, "changed": 6500, "saved": 6500, "deleted": 0, "skipped": [], "cancelled": false, "refreshed": true }
}
},
{
"volumeId": "vol_sh002",
"name": "datasets",
"status": "saved",
"phase": "code",
"progress": null,
"result": {
"volumeId": "vol_sh002",
"base": "/volumes/shared/datasets",
"code": { "skipped": "read-only" },
"data": { "committed": false, "reason": "no data changes", "refreshed": true }
}
}
]
},
"meta": {
"requestId": "req_abc123"
}
}

progress counts the files and bytes in the workspace's writable layer and those committed so far. In result.data, saved counts the files committed, changed those saved as new versions (a file saved unchanged keeps its version), deleted the stored files deleted through the workspace, and skipped lists { path, reason } of files a program was writing while the sync read them, which the next sync saves. refreshed means the workspace's data/ now shows every file's latest version; when that could not be done, refreshError says why (restart the workspace to see them).


POST /api/v1/workspaces/:workspaceId/syncs/:id/cancel​

Cancel a running sync: it stops before its next batch. What it committed stays committed; the rest stays in the workspace for the next sync. Answers the sync with cancelRequested: true; it ends cancelled. A sync that is not running is refused with 409 invalid-state.

Scope: workspaces:write


GET /api/v1/workspaces/:id/sync/conflicts​

The files still to decide after a Sync conflict, per mounted volume. A file you merged by hand in the IDE counts as decided once its conflict markers are gone.

Scope: workspaces:read

Response

{
"data": {
"workspaceId": "ws_abc123",
"volumes": [
{ "volumeId": "vol_def001", "name": "training-data", "merging": true, "files": ["app.py"] }
]
}
}

POST /api/v1/workspaces/:id/sync/resolve​

Decide one conflicted file: keep your version or take the volume's.

Scope: workspaces:write

Request Body

FieldTypeRequiredDescription
volumeIdstringYesThe mounted volume the file is in
pathstringYesThe file, relative to the volume's code/ folder
takestringYesmine (this workspace's version) or theirs (the volume's)

Returns the volume's remaining files, as GET .../sync/conflicts does.


POST /api/v1/workspaces/:id/sync/abort​

Cancel a volume's waiting merge: the workspace's code goes back to how it was before the Sync (your own changes kept, not yet synced).

Scope: workspaces:write

Request Body

FieldTypeRequiredDescription
volumeIdstringYesThe mounted volume

POST /api/v1/workspaces/:id/execute​

Run a shell command inside the running workspace container. The command runs in the workspace until it exits, with no time limit, whatever happens to this request: a dropped connection never stops it and never loses its result. The answer waits a short while (up to 20 seconds) for it:

  • 200 OK when it ended in that time: the execution with its exitCode and its output from the start;
  • 202 Accepted while it still runs: the execution, status running. Follow it with GET .../executions/:id until it ends.

The Idempotency-Key header is optional (see Idempotency). Without it, every request runs the command. Send one (1 to 255 characters; you generate it, such as a random UUID, before the first attempt) to make a retry safe: sending the same command again with the same key answers the same execution (its id, status and output, with Idempotent-Replayed: true) and never runs the command a second time. Retry with the same key whenever the connection drops before the answer. A key belongs to you and this workspace's execute route, and is kept for 24 hours from its first request. The same key for another command (or cwd) is refused with 422 idempotency-key-reused; the same key while its first request is still being answered gets 409 idempotency-key-in-use with Retry-After: send it again after that wait, with the same key. A 202 answer carries Location, the path of the execution's status (/api/v1/workspaces/:workspaceId/executions/:id).

The workspace must be running: while it is starting or restarting (its IDE container not ready yet) the command is refused with 409 workspace-not-ready, whose detail names the worker's phase and each container's state; run it again once the workspace is running.

Scope: none (the workspace's owner only; an agent runs commands in its own workspace as its owner)

Path Parameters

ParameterTypeRequiredDescription
idstringYesWorkspace ID

Headers

HeaderRequiredDescription
Idempotency-KeyNoOptional. A key you generate (such as a UUID): a retry with the same key is the same execution. Without it, every request runs the command

Request Body

{
"command": "python train.py --epochs 10",
"cwd": "/volumes/local/my-project/code"
}
FieldTypeRequiredDescription
commandstringYesThe shell command to run
cwdstringNoWorking directory to run the command in

Response 200 OK (it ended) or 202 Accepted (it still runs)

{
"data": {
"_id": "exec-3f9c2a7d1e4b5a6c8d9e0f1a2b3c4d5e",
"workspaceId": "ws_abc123",
"command": "python train.py --epochs 10",
"cwd": "/volumes/local/my-project/code",
"status": "completed",
"exitCode": 0,
"error": null,
"startedAt": "2026-10-27T10:00:00+00:00",
"endedAt": "2026-10-27T10:00:12+00:00",
"stdout": "Epoch 10 complete\n",
"stderr": ""
},
"meta": {
"requestId": "req_abc123",
"nextCursor": null
}
}
FieldDescription
statusrunning, then completed (it exited; exitCode says how) or failed (error says why: the workspace stopped or restarted while it ran)
exitCodeThe command's exit code; null while it runs. On failure stderr carries the error output and exitCode is non-zero
stdout, stderrThis page of each stream (up to 1 MiB of each)
meta.nextCursorReads the next page with GET .../executions/:id?cursor=; null once it ended and its output is read whole

GET /api/v1/workspaces/:workspaceId/executions/:id​

An execution of a command (POST .../execute answered its _id): its status, exitCode and a page of its stdout and stderr from cursor. Read it until meta.nextCursor is null, passing each answer's meta.nextCursor as cursor and appending each page's stdout and stderr; while it runs, wait a couple of seconds between reads. No output is ever cut off: the pages hold all of it. A running execution whose workspace stopped or restarted is answered failed. An execution and its output are kept for 24 hours after it ends; once its output is gone, stdout and stderr are null and outputError says so.

Scope: none (the workspace's owner only)

Path Parameters

ParameterTypeRequiredDescription
workspaceIdstringYesWorkspace ID
idstringYesExecution ID

Query Parameters

ParameterTypeRequiredDescription
cursorstringNometa.nextCursor of the previous answer; omitted, its output from the start

Example

KEY=$(uuidgen)
EXEC=$(curl -s -X POST "$BASE/workspaces/$WS/execute" -H "X-API-Key: $KEY_API" \
-H "Idempotency-Key: $KEY" -H 'Content-Type: application/json' \
-d '{"command": "npm run build"}')
ID=$(jq -r '.data._id' <<<"$EXEC"); CURSOR=$(jq -r '.meta.nextCursor // empty' <<<"$EXEC")
jq -j '.data.stdout' <<<"$EXEC"
while [ -n "$CURSOR" ]; do
[ "$(jq -r '.data.status' <<<"$EXEC")" = running ] && sleep 2
EXEC=$(curl -s "$BASE/workspaces/$WS/executions/$ID?cursor=$CURSOR" -H "X-API-Key: $KEY_API")
jq -j '.data.stdout' <<<"$EXEC"; CURSOR=$(jq -r '.meta.nextCursor // empty' <<<"$EXEC")
done
jq -r '.data.exitCode' <<<"$EXEC"

GET /api/v1/workspaces/minimum-size​

The smallest workspace that runs: cpu and memoryGb (the platform's services beside the IDE, in platform, plus room for it), the smallest compute-cluster coordinator per engine (clusterCoordinator), and the smallest job run (job). A smaller size is refused at create and at start.

Scope: workspaces:read


GET /api/v1/workspaces/planned-volumes​

The volumes a new workspace in a project would mount: { volumes: [{ volumeId, name, scope }] }, the project's volume (scope local) and the shared volumes listed in the sharedVolumeIds query parameter, comma-separated (scope shared; none if omitted). A listed volume you may not mount is refused with 400, by name.

Scope: workspaces:read

Query parameterTypeDescription
projectIdstringThe project the workspace would be in

GET /api/v1/workspaces/:id/deletion-impact​

Before deleting: whether it can be deleted and, if not, what uses it, as the delete dialog says.

Response 200 OK

{
"data": {
"canDelete": false,
"reason": "in-use",
"message": "... is in use by ... Stop or delete those first.",
"dependents": [{ "kind": "app", "items": [{ "id": "app-abc", "name": "forecast-dashboard" }] }]
}
}

When it can be deleted, canDelete is true and dependents is empty.

Scope: workspaces:read


GET /api/v1/workspaces/:id/volumes​

The volumes the workspace mounts, as its Volumes tab lists them, each with its mount path, code source, owner and access. Paged.

Scope: workspaces:read

Query parameterTypeDescription
groupstringproject (default): its project's volume. shared: the shared volumes chosen for it
qstringName contains
sortstringname (default), createdAt or updatedAt
sortDirstringasc (default) or desc
pagenumberPage, from 1
pageSizenumber1 to 100 (default 10)

POST /api/v1/workspaces/:id/ports​

Save a labeled quick link to a port (the Ports tab). Any port from 1024 to 65535 opens at <workspace URL>/port/<port>/ with or without a saved link; the link is a bookmark. Only the workspace's owner can open its ports.

Scope: workspaces:write

FieldTypeRequiredDescription
portnumberYesPort the app listens on (1024 to 65535)
labelstringNoLabel for the link

Response 201 Created: the link, { port, label, url }.


DELETE /api/v1/workspaces/:workspaceId/ports/:id​

Remove a saved port link. The app on that port keeps running and still opens by its port URL.

Scope: workspaces:write