Skip to content

Suspend & resume

Suspend freezes a running sandbox to disk: its running guest process is snapshotted, its RAM is reclaimed, and its network is released — but the sandbox is fully resumable by id. Resume restores it back to running in place.

This is how you hold a session open cheaply: an agent waiting on a human, a rollout parked between phases, a long-lived workspace between bursts of activity.

Terminal window
curl -X POST https://api.collimate.ai/v1/sandboxes/sbx_9f2a1c7b3e40/suspend \
-H "Authorization: Bearer $COLLIMATE_API_KEY"
{ "id": "sbx_9f2a1c7b3e40", "state": "suspended", "mem_bytes": 41943040 }

mem_bytes is the size of the on-disk memory image — the resident cost while held. Suspending stops the meter: while a sandbox is suspended you are billed only for snapshot storage (per GB-month), not for CPU or RAM. See Pricing.

Terminal window
curl -X POST https://api.collimate.ai/v1/sandboxes/sbx_9f2a1c7b3e40/resume \
-H "Authorization: Bearer $COLLIMATE_API_KEY"
{ "id": "sbx_9f2a1c7b3e40", "state": "running" }

The restored sandbox has the exact process memory and filesystem it had at suspend — running processes, open files, in-memory state — and takes a fresh network identity. The meter restarts.

A suspended sandbox does not count against your tier's concurrent-sandbox limit (it isn't live), so suspending is also how you hold more sessions than your concurrency cap while keeping them instantly resumable. Delete it with DELETE /v1/sandboxes/{id} when you're truly done — that reclaims the snapshot storage too.