Create a sandbox
POST/sandboxes
Boots a Firecracker microVM. All fields are optional; an empty body uses the daemon defaults. `image` boots from a converted OCI image (pulled on demand — see the images endpoints); a daemon without an image store answers 501.
Request bodyapplication/json
CreateSandboxRequest
boot_argsstringdisk_bytesintegerint64imageImageRef
ocistringpathstringmemory_mibintegernetworkNetworkRequest
allowlistarray
items
string
enabledbooleanprofilestringpublisharray
items
PortMapping
guest_portintegerhost_ipstringhost_portintegerprotocolstringpullstringserviceWireServiceSpec
cmdarray | null
items
string
cwdstringenvobject
additional properties
string
env_exactbooleanlog_buffer_bytesintegerrestartWireRestartPolicy
max_retriesintegerpolicystringstop_grace_sintegerstop_signalstringuserstringtimeout_sintegervcpusintegerResponses
201 CreatedCreated
SandboxResponse
created_atstringdate-timeidstringmemory_mibintegernetworkNetworkResponse
allowlistarray
items
string
enabledbooleangatewaystringguest_ipstringprofilestringpublishedarray
items
PortMapping
guest_portintegerhost_ipstringhost_portintegerprotocolstringsource_snapshot_idstringvcpusintegerworkdirstring400 Bad requestBad Request
ErrorResponse
errorstring403 ForbiddenForbidden
ErrorResponse
errorstring500 Server errorInternal Server Error
ErrorResponse
errorstring501 Not Implemented
ErrorResponse
errorstring502 Bad gatewayBad Gateway
ErrorResponse
errorstringAuthentication
bearerAuthHTTP bearer. Daemon API key. Omit on a keyless loopback daemon.Request
▍POST/sandboxes
curl '/sandboxes' \
-X POST \
-H 'Content-Type: application/json' \
-d '{}'const response = await fetch("/sandboxes", {
method: "POST",
headers: {
"Content-Type": "application/json",
},
body: "{}",
});
const data = await response.json();import requests
response = requests.post(
"/sandboxes",
headers={
"Content-Type": "application/json",
},
data="{}",
)
data = response.json()Response
201 Created
{
"created_at": "2026-01-02T15:04:05Z",
"id": "string",
"memory_mib": 0,
"network": {
"allowlist": [
"string"
],
"enabled": false,
"gateway": "string",
"guest_ip": "string"
},
"profile": "string",
"published": [
{
"guest_port": 0,
"host_ip": "string",
"host_port": 0,
"protocol": "string"
}
],
"source_snapshot_id": "string",
"vcpus": 0,
"workdir": "string"
}