API reference · Schema
ServerlessWorker
objectstringrequiredAlways `serverless_worker`: the type of this object
One of
serverless_workeridstringrequiredUnique ID (`swk_…`)
ID with prefix swk_
endpoint_idstringrequiredID of the endpoint
release_idstringrequiredID of the release
workload_idstringrequiredID of the workload
node_idstring | nullrequiredThe node the worker runs on, once placed
skustringrequiredHardware type code
statestringrequired`paused`: frozen in place (fast resume), not charged; `resuming`: unfrozen, taking work again once it proves itself
One of
provisioningidlebusydrainingpausedresumingterminatedrunning_jobsintegerrequiredQueue endpoints: jobs this worker is running (0 for HTTP endpoints)
in_flightintegerrequiredHTTP endpoints: requests in flight at this worker (0 for queue endpoints)
healthstring | nullrequiredHTTP endpoints: the health check (null when unknown)
One of
startinghealthyunhealthydrain_reasonstring | nullrequiredWhile `draining`: why, for example `idle`, `over_max` (above `max_workers`), `outdated` (an older release), `pause` (about to be paused) or `endpoint_deleted`; null otherwise
cold_start_msinteger | nullrequiredMilliseconds from the worker being created until it was ready; null until then
paused_atstring (date-time) | nullrequiredTime paused (ISO 8601, UTC)
resumed_atstring (date-time) | nullrequiredTime resumed (ISO 8601, UTC)
resume_countintegerrequiredTimes the worker was resumed from pause
created_atstring (date-time)requiredWhen it was created (ISO 8601, UTC)
ready_atstring (date-time) | nullrequiredTime ready (ISO 8601, UTC)
last_seen_atstring (date-time) | nullrequiredTime last seen (ISO 8601, UTC)
idle_sincestring (date-time) | nullrequiredSince when the worker has had no work; null while it is working or not ready
terminated_atstring (date-time) | nullrequiredTime terminated (ISO 8601, UTC)
termination_reasonstring | nullrequiredWhy the worker was removed, for example `idle`, `drained`, `outdated`, `startup_timeout`, `placement_timeout`, `unhealthy`, `silent` (stopped reporting), `paused_expired` or `endpoint_deleted`; null while it is live
scheduling_statusstring | nullrequiredPlacement on a host: `pending` (waiting for capacity), `placed`, `refused` or `unschedulable` (no host can take it; see `scheduling_message`); null when unknown
scheduling_messagestring | nullrequiredWhy placement is waiting or failed; null when there is nothing to say
How the worker started, in order: pulling its image, making each model present (from the host’s model cache or by downloading it), starting the container. Loading inside the container ends at ready_at.
ShowHide 8 fields of
startstepstringrequiredWhich step: pulling the image, making one model present, or starting the container
One of
imagemodelcontainerstatestringrequiredimage: pulling | pulled | present (already on the host) | failed; model: cached (found in the host cache, nothing downloaded) | downloading | downloaded | failed; container: started
atstring (date-time) | nullrequiredWhen the step reached its state; null for an image already on the host
repositorystringModel steps: the repository
bytes_totalintegerModel steps: the size of the model in bytes
bytes_doneintegerModel steps: bytes present and verified so far
bytes_downloadedintegerModel steps: bytes downloaded for this start (0 when the host already had the model)
secondsinteger | nullDownloaded model steps: how long the download took, in seconds
{
"object": "serverless_worker",
"id": "swk_01jc5zq4m8k3v6x9t2w7r0b1e4",
"endpoint_id": "string",
"release_id": "string",
"workload_id": "string",
"node_id": "string",
"sku": "string",
"state": "provisioning",
"running_jobs": 1,
"in_flight": 1,
"health": "starting",
"drain_reason": "string",
"cold_start_ms": 1,
"paused_at": "2026-01-01T00:00:00.000Z",
"resumed_at": "2026-01-01T00:00:00.000Z",
"resume_count": 1,
"created_at": "2026-01-01T00:00:00.000Z",
"ready_at": "2026-01-01T00:00:00.000Z",
"last_seen_at": "2026-01-01T00:00:00.000Z",
"idle_since": "2026-01-01T00:00:00.000Z",
"terminated_at": "2026-01-01T00:00:00.000Z",
"termination_reason": "string",
"scheduling_status": "string",
"scheduling_message": "string",
"start": [
{
"step": "image",
"state": "string",
"at": "2026-01-01T00:00:00.000Z",
"repository": "string",
"bytes_total": 1,
"bytes_done": 1,
"bytes_downloaded": 1,
"seconds": 1
}
]
}Used by
- Workers of the endpoint with their state (live ones and those removed in the last hour)
GET /v1/serverless/endpoints/{endpoint_id}/workers