sandboxes

Read one sandbox.

Add waitFor=running (or paused, stopped) and timeoutSeconds to hold the answer until it gets there.

get/v1/sandboxes/{id}

Request

  • Base URL: https://api.withruntime.com
  • URL: https://api.withruntime.com/v1/sandboxes/{id}
  • Auth: HTTP bearer

Path parameters

idstring required

Resource identifier (UUID).

Query parameters

waitFor'running' | 'paused' | 'stopped'
timeoutSecondsinteger

Response

Success

idstring required

Resource identifier (UUID).

kind'sandbox' required
namestring nullable
labelsobject

Your own key/value tags, at most 32. Filter lists with label=key:value.

status'pending' | 'active' | 'paused' | 'stopping' | 'stopped' required

Deprecated: read state. An older, coarser name for it, kept for older clients.

state'starting' | 'running' | 'pausing' | 'paused' | 'resuming' | 'stopping' | 'stopped' required
regionstring required
funding'trial' | 'paid' required
vcpuinteger
memoryMiBinteger
diskMiBinteger
cpu'shared' | 'reserved'
cpuFloorMillisinteger
pausableboolean
timeoutSecondsinteger

Its time limit in seconds, up to 86400 (24 hours); 0 is none: it runs while it works and pauses when idle.

onTimeout'pause' | 'stop' | 'delete'

What happens when its time limit, credit or a spending limit ends it. The same value as onLeaseEnd, its older name.

idlePauseSecondsinteger

Pauses after this many idle seconds; 0 is never.

idlePauseUnusedOnlyboolean

True only for a sandbox created before 27 September 2026 with the old default idle pause, which paused it only while nothing had used it. False when the idle time counts from the last activity.

autoWakeboolean

A request wakes it when paused: an exec, a file or terminal call, or a visit to a shared port.

persistentboolean

It has no time limit and is not paused for being idle unless idlePauseSeconds says so.

diskKeptboolean

Stopped with its disk kept: :restart starts it again from the disk. A stop keeps the disk; only a delete removes it.

lastActiveAtstring date-time nullable

The last exec, file, terminal, desktop or preview request, or open preview connection, to within five seconds (a minute for a sandbox whose idle time counts only while unused).

createdAtstring date-time required
readyAtstring date-time nullable

When its current run became ready to run commands. Null before that, while it is paused, and once a stop that kept its disk has ended the run; endedAt says when it ended.

expiresAtstring date-time required

Paid up to, at most an hour ahead, or when a stopped sandbox ended: kept for older clients. Read endsAt for when it stops or pauses by itself.

endsAtstring date-time nullable

When it stops or pauses by itself: the end of its time limit, which :extend moves, or where its funding ends when credit or a spending limit stops its renewal. null when it never will: no time limit, or not running.

endedAtstring date-time nullable
stopReasonstring nullable

Why it stopped or paused. Yours: requested, time_limit (its timeoutSeconds ran out and it was made to stop rather than pause; lease_expired before 4 October 2026), idle, paused_expired (kept paused past its retention), insufficient_funds (credit ran out), pilot_hours_used (its pilot's sandbox hours are used; credit does not run it, and the account's owner may write to support to extend the pilot or ask for more hours), pilot_ended (its pilot and the pilot's grace are over; credit does not run it, and the account's owner may write to support to extend the pilot), lifetime_cap (this sandbox's own maxTotalCostMicros), spending_limit (an owner-set spending limit, usually this agent's daily limit; see what is left with GET /v1/limits or runtime limits) or authority_revoked (the key that made it lost the right). A fault on our side, not in your code: host_lost (its machine failed; create a new sandbox) and pause_failed (its memory could not be kept; it is paused with its files, and the next wake starts it from its disk, memoryRestored false). operator_stopped: our operator stopped it. startup_failed: it stopped before it was ready to run commands; from your own image, check its start and ready commands. account_busy_here: it can start only on the servers that hold its snapshot or image, and your own sandboxes there were short of CPU, so it did not start and nothing ran; start it again in a minute. service_unready: a service on our side that it needs was unavailable, so it could not keep running; create a new one. host_stopped: its machine ended without a stop being asked for; while it was starting or waking that is our fault, and once it was running it can also be a shutdown or crash inside the sandbox.

pausedAtstring nullable
pausedExpiresAtstring nullable

When a paused or stopped sandbox is deleted. Null while it is kept as long as your account has credit.

memoryRestoredboolean
placementstring nullable

Opaque tag of the server it is on: the same for your sandboxes and snapshots on one server, different on another, never the server's name. Compare tags to see whether two share a server; keep them apart with spreadFrom on create. Null before it is placed.

chargedMicrosinteger

Settled, in microdollars (1,000,000 = $1).

heldMicrosinteger

Deprecated, kept for older clients: read chargedMicros and GET /v1/usage.

ratesobject
envNamesstring[]

The names of its own environment variables (env), sorted, on a create, an update and a read of one sandbox. Values are never shown.

secretsstring[] nullable

The egress secrets it may use, fixed when it was created: only those of your secrets that would otherwise reach it. null: every secret that reaches it. On a create, an update and a read of one sandbox.

secretsEnforcedboolean

On an update with labels by a key that may read secrets, when one of your egress secrets is scoped: true when every server running your sandboxes holds the change, so the next request from this sandbox is rewritten (or no longer is) by the new labels. False when a server has not confirmed yet; it takes the change within 15 seconds. Absent for any other key: its change reaches the servers within 15 seconds.

simulatedboolean
replayedboolean

Present and true when an Idempotency-Key replay answered.

Changes

No recorded changes to this operation across all 1 revision of this API.