Guides
Provider options
One API for every provider, without losing any provider's own features.
How options merge
provider_options (providerOptions in TypeScript) maps a provider id to fields of that provider's own create request, named exactly as in its API docs. When SandboxPlease starts the sandbox on a provider, it merges that provider's entry into the request it sends: objects merge key by key, arrays and values replace. Entries for the other providers are ignored. An unknown provider id is a unknown_provider error listing the valid ids.
template stays generic, but template names differ per vendor: provider_options.e2b.template replaces it when the sandbox lands on E2B.
With fallbacks
One request can carry options for every provider in its fallback list. Below, E2B gets its template and metadata; if E2B fails and the sandbox falls back to Modal, Modal gets its ports and the generic template. Every entry is checked before anything starts, so a bad option fails the request at once, not halfway through the fallbacks.
Fields SandboxPlease owns
Size, lifetime, credentials and anything that changes what SandboxPlease bills or when it kills the sandbox stay SandboxPlease's. Setting one in provider_options is a provider_option_conflict error that names the field and the SandboxPlease parameter to use instead. A few fields change the vendor's price, like a GPU; they work only on your own provider key (BYOK), where the vendor bills you directly.
{
"error": {
"code": "provider_option_conflict",
"message": "provider_options.e2b.timeout is set by SandboxPlease and cannot be overridden",
"hint": "Drop provider_options.e2b.timeout and use timeout instead.",
"details": { "field": "provider_options.e2b.timeout", "use": "timeout" }
}
}Per provider
One example per provider, taken from the vendor's API docs. SandboxPlease keeps the option names, never their values: they can hold environment variables and secrets.
E2B provider_options.e2b
autoPause and autoResume keep a sandbox alive past what SandboxPlease bills, so they run on your own E2B key only.
{
"template": "my-python-template",
"metadata": {
"team": "ml"
},
"network": {
"allowOut": ["pypi.org", "*.github.com"],
"denyOut": ["0.0.0.0/0"]
}
}| Set by SandboxPlease | Use instead |
|---|---|
templateID | template |
timeout | timeout |
cpuCount | size |
memoryMB | size |
devices | devices |
autoPause | your own key (BYOK) |
autoResume | your own key (BYOK) |
lifecycle | your own key (BYOK) |
volumeMounts | your own key (BYOK) |
network.rules | your own key (BYOK) |
iam | your own key (BYOK) |
Daytona provider_options.daytona
{
"labels": {
"team": "ml"
},
"network_policy": {
"allow_domains": ["pypi.org", "*.github.com"]
},
"lifecycle_policy": {
"idle_expiry_seconds": 900,
"on_idle_timeout": "stop"
}
}| Set by SandboxPlease | Use instead |
|---|---|
cpu | size |
cores_max | size |
memory_mib | size |
memory_max_mib | size |
lifecycle_policy.timeout_seconds | timeout |
lifecycle_policy.on_timeout | timeout |
image | template |
disk_mib | your own key (BYOK) |
disk_max_mib | your own key (BYOK) |
spot | your own key (BYOK) |
gpu | your own key (BYOK) |
memory | your own key (BYOK) |
disk | your own key (BYOK) |
class | your own key (BYOK) |
snapshot | your own key (BYOK) |
volumes | your own key (BYOK) |
secrets | your own key (BYOK) |
Modal provider_options.modal
Fields are the JS SDK's sandbox params. volumes maps a mount path to the name of a Modal Volume and needs your own Modal key; template is the registry image.
{
"template": "node:22",
"encryptedPorts": [8080],
"volumes": {
"/data": "my-volume"
}
}| Set by SandboxPlease | Use instead |
|---|---|
cpu | size |
cpuLimit | size |
memoryMiB | size |
memoryLimitMiB | size |
timeoutMs | timeout |
image | template |
gpu | gpu |
regions | your own key (BYOK) |
cloud | your own key (BYOK) |
volumes | your own key (BYOK) |
secrets | your own key (BYOK) |
proxy | your own key (BYOK) |
cloudBucketMounts | your own key (BYOK) |
customDomain | your own key (BYOK) |
Vercel Sandbox provider_options.vercel
{
"source": {
"type": "git",
"url": "https://github.com/vercel/next.js",
"depth": 1
},
"ports": [3000],
"networkPolicy": {
"mode": "custom",
"allowedDomains": ["registry.npmjs.org"]
}
}| Set by SandboxPlease | Use instead |
|---|---|
projectId | your Vercel key (<token>:<teamId>:<projectId>) |
resources | size |
timeout | timeout |
persistent | timeout |
image | template |
source.snapshotId | your own key (BYOK) |
mounts | your own key (BYOK) |
networkId | your own key (BYOK) |
credentials | your own key (BYOK) |
Blaxel provider_options.blaxel
{
"metadata": {
"labels": {
"team": "ml"
}
},
"spec": {
"region": "eu-lon-1",
"runtime": {
"ports": [
{
"name": "web",
"target": 3000,
"protocol": "HTTP"
}
]
}
}
}| Set by SandboxPlease | Use instead |
|---|---|
metadata.name | the generated name in provider_metadata |
spec.runtime.memory | size |
spec.runtime.ttl | timeout |
spec.runtime.expires | timeout |
spec.lifecycle | timeout |
spec.runtime.image | template |
spec.runtime.envs | env |
spec.volumes | your own key (BYOK) |
spec.vpc | your own key (BYOK) |
spec.network.subnet | your own key (BYOK) |
spec.network.egress | your own key (BYOK) |
Fly.io Sprites provider_options.sprites
{
"url_settings": {
"auth": "public"
}
}| Set by SandboxPlease | Use instead |
|---|---|
name | the generated name in provider_metadata |
config.cpus | size |
config.ram_mb | size |
config.storage_gb | size |
Northflank provider_options.northflank
{
"ports": [
{
"name": "web",
"internalPort": 8080,
"public": true,
"protocol": "HTTP"
}
],
"deployment": {
"storage": {
"ephemeralStorage": {
"storageSize": 4096
}
}
}
}| Set by SandboxPlease | Use instead |
|---|---|
name | the generated id in provider_metadata |
billing | size |
deployment.instances | pause |
deployment.external.imagePath | template |
createOptions.expiryTime | timeout |
deployment.gpu | your own key (BYOK) |
deployment.external.credentials | your own key (BYOK) |
deployment.internal | your own key (BYOK) |
deployment.image | your own key (BYOK) |
deployment.containerSnapshot | your own key (BYOK) |
createOptions.volumesToAttach | your own key (BYOK) |
ports[].domains | your own key (BYOK) |
ports[].security.sso | your own key (BYOK) |
CodeSandbox provider_options.codesandbox
Top-level fields go to the fork request; start goes to the VM start request.
{
"description": "agent run 42",
"start": {
"ipcountry": "NL"
}
}| Set by SandboxPlease | Use instead |
|---|---|
start.tier | size |
start.hibernation_timeout_seconds | timeout |
start_options | provider_options.codesandbox.start |
start.automatic_wakeup_config | your own key (BYOK) |
CodeSandbox SDK: createSandboxForkRequest and VmStartRequest
miniSandbox provider_options.minisandbox
miniSandbox speaks the E2B API, so it takes E2B's create fields.
{
"metadata": {
"team": "ml"
}
}| Set by SandboxPlease | Use instead |
|---|---|
templateID | template |
timeout | timeout |
cpuCount | size |
memoryMB | size |
devices | devices |
autoPause | your own key (BYOK) |
autoResume | your own key (BYOK) |
lifecycle | your own key (BYOK) |
volumeMounts | your own key (BYOK) |
network.rules | your own key (BYOK) |
iam | your own key (BYOK) |
Boat provider_options.boat
{
"name": "agent-run-42",
"labels": {
"team": "ml"
},
"hostedPorts": [
{
"port": 3000,
"public": true
}
]
}| Set by SandboxPlease | Use instead |
|---|---|
type | size |
ttlSeconds | timeout |
from | template |
count | one call per sandbox |
environment | your own key (BYOK) |
noEnv | your own key (BYOK) |
org | your own key (BYOK) |
teamId | your own key (BYOK) |
Novita provider_options.novita
Novita runs the E2B stack, so it takes E2B's create fields; internet access is allow_internet_access.
{
"metadata": {
"team": "ml"
},
"allow_internet_access": false
}| Set by SandboxPlease | Use instead |
|---|---|
templateID | template |
timeout | timeout |
cpuCount | size |
memoryMB | size |
devices | devices |
autoPause | your own key (BYOK) |
autoResume | your own key (BYOK) |
lifecycle | your own key (BYOK) |
volumeMounts | your own key (BYOK) |
network.rules | your own key (BYOK) |
iam | your own key (BYOK) |
InstaBox provider_options.instabox
template is a template id, or a snapshot id (sn_…) such as an imported Docker or OCI image.
{
"template": "sn_01jd8z4n6q8s0u2w4y6a8c0e2g",
"autoSuspendAfterSeconds": 600,
"metadata": {
"team": "ml"
}
}| Set by SandboxPlease | Use instead |
|---|---|
vcpus | size |
memMiB | size |
deleteAfterSeconds | timeout |
templateId | template |
snapshotId | template |
imageId | template |
gpu | your own key (BYOK) |
model | your own key (BYOK) |
acceptMinimumLease | your own key (BYOK) |
vault | your own key (BYOK) |
secrets | your own key (BYOK) |
envSecrets | your own key (BYOK) |
directSecrets | your own key (BYOK) |
orgId | your own key (BYOK) |
Tensorlake provider_options.tensorlake
template is a registered Sandbox Image name. secret_names injects secrets stored in your Tensorlake project.
{
"template": "my-sandbox-image",
"network": {
"allow_out": ["pypi.org", "github.com"]
},
"secret_names": ["HF_TOKEN"]
}| Set by SandboxPlease | Use instead |
|---|---|
name | the generated name in provider_metadata |
resources.cpus | size |
resources.memory_mb | size |
timeout_secs | timeout |
image | template |
wait | nothing: SandboxPlease waits for the sandbox to run |
resources.disk_mb | your own key (BYOK) |
resources.gpus | your own key (BYOK) |
secret_names | your own key (BYOK) |
file_systems | your own key (BYOK) |
snapshot_id | your own key (BYOK) |
template_id | your own key (BYOK) |
Upstash Box provider_options.upstash
Upstash publishes no REST reference: field names follow its open-source SDK. SandboxPlease creates ephemeral boxes so the TTL bounds their lifetime.
{
"runtime": "python",
"labels": ["agent-run-42"],
"network_policy": {
"mode": "custom",
"allowed_domains": ["pypi.org", "*.github.com"]
}
}| Set by SandboxPlease | Use instead |
|---|---|
ephemeral | timeout |
ttl | timeout |
keep_alive | timeout |
size | size |
snapshot_id | template |
agent | your own key (BYOK) |
Freestyle provider_options.freestyle
The VM boots at its snapshot's size: a template snapshot keeps its own vCPU and memory. firewall defaults to open outbound internet; pass your own rules to restrict it.
{
"idleTimeoutSeconds": 900,
"metadata": {
"team": "ml"
},
"automaticRestart": false
}| Set by SandboxPlease | Use instead |
|---|---|
snapshotId | size, or template for your own snapshot |
ttlSeconds | timeout |
networks | your own key (BYOK) |
vpcs | your own key (BYOK) |
tls | your own key (BYOK) |
firewall | your own key (BYOK) |
reassignSlug | your own key (BYOK) |
slug | your own key (BYOK) |
customerId | your own key (BYOK) |
customer | your own key (BYOK) |
Namespace provider_options.namespace
SandboxPlease runs one container named main from template (default ubuntu:24.04) and execs into it. Append @eu to the token for the EU region; the default is us.
{
"labels": [
{
"name": "team",
"value": "ml"
}
],
"experimental": {
"authorizedSshKeys": ["ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAI… you@laptop"]
}
}| Set by SandboxPlease | Use instead |
|---|---|
shape | size |
deadline | timeout |
containers | template for the image, env for its environment |
workloadPermissions | your own key (BYOK) |
volumes | your own key (BYOK) |
containerCache | your own key (BYOK) |
additionalRegistries | your own key (BYOK) |
applications | your own key (BYOK) |
ingressBaseDomain | your own key (BYOK) |
experimental.volumes | your own key (BYOK) |
experimental.containerCache | your own key (BYOK) |
experimental.prometheusMetricsSink | your own key (BYOK) |
experimental.withConfiguration | your own key (BYOK) |
experimental.disks | your own key (BYOK) |
Namespace Compute API (CreateInstance)Namespace machine shapes
Koyeb provider_options.koyeb
SandboxPlease creates one app and one SANDBOX service per sandbox, in the region of your key (`token@region`, Frankfurt by default). Koyeb deletes it after the timeout, 24 hours at most. Only one port is published at a time: a new port_url moves the public route to that port.
{
"definition": {
"docker": {
"privileged": true
},
"config_files": [
{
"path": "/etc/app/config.yaml",
"content": "debug: true",
"permissions": "0644"
}
]
}
}| Set by SandboxPlease | Use instead |
|---|---|
name | the generated name in provider_metadata |
app_id | the app SandboxPlease creates per sandbox |
life_cycle.delete_after_create | timeout |
definition.type | nothing: SandboxPlease only creates sandboxes |
definition.docker.image | template |
definition.env | env |
definition.instance_types | size |
definition.regions | the region in KOYEB_API_TOKEN (`token@region`) |
definition.scalings | nothing: a sandbox runs one always-on instance |
definition.ports | port_url |
definition.routes | port_url |
definition.database | your own key (BYOK) |
instance_snapshot_id | your own key (BYOK) |
service_account_id | your own key (BYOK) |
definition.docker.image_registry_secret | your own key (BYOK) |
definition.volumes | your own key (BYOK) |
definition.git | your own key (BYOK) |
definition.archive | your own key (BYOK) |
definition.mesh | your own key (BYOK) |
definition.network_policy | your own key (BYOK) |
Hopx provider_options.hopx
A sandbox gets its vCPU and memory from its template, never from the request: SandboxPlease boots code-interpreter (2 vCPU / 4 GiB) unless you pass your own template. region is us-east or eu-west.
{
"region": "eu-west",
"internet_access": false
}| Set by SandboxPlease | Use instead |
|---|---|
template_id | template |
template_name | template |
timeout_seconds | timeout |
env_vars | env |
Celesto provider_options.celesto
Celesto publishes no REST reference: field names follow its official SDKs. network_policy defaults to open outbound internet. Commands are limited to 10,000 characters, so run long scripts from a file.
{
"template": "coding-agent",
"network_policy": {
"mode": "off"
}
}| Set by SandboxPlease | Use instead |
|---|---|
size_id | size |
vcpus | size |
ram_mb | size |
disk_size_mb | size |
template_id | template |
Superserve provider_options.superserve
Curated templates run at 2 vCPU / 4 GiB whatever the request asks: SandboxPlease boots superserve/base unless you pass your own template. timeout_seconds pauses the sandbox, it does not delete it.
{
"idle_timeout_seconds": 600,
"preview_access": "private"
}| Set by SandboxPlease | Use instead |
|---|---|
name | the sandbox id |
from_template | template |
from_snapshot | fromSnapshot |
timeout_seconds | timeout |
env_vars | env |
vcpu | size |
memory_mib | size |
secrets | your own key (BYOK) |
Render provider_options.render
Sandboxes start in your workspace's default sandbox group (Oregon). A template is an image you imported into that group (its name or sbb- id). idleTimeoutSeconds (default 900, 0 turns it off) suspends an idle sandbox, which resumes on its next command. A network allow-list takes domains only and blocks every protocol but HTTPS.
{
"template": "python-latest",
"idleTimeoutSeconds": 1800
}| Set by SandboxPlease | Use instead |
|---|---|
ownerId | your Render key (<api key>:<workspace id>) |
plan | size |
timeoutSeconds | timeout |
snapshotId | from_snapshot |
snapshotName | from_snapshot |
buildId | template |
buildName | template |
sandboxGroupId | your own key (BYOK) |
sharedFilesystems | your own key (BYOK) |
Prime Intellect provider_options.prime-intellect
Runs only on your own Prime Intellect key. Network lockdowns go through the network parameter (network_allowlist takes domains and IPv4 ranges); idle_timeout_minutes must not exceed the sandbox's timeout.
{
"arch": "arm64",
"idle_timeout_minutes": 15,
"secrets": {
"OPENAI_API_KEY": "sk-..."
}
}| Set by SandboxPlease | Use instead |
|---|---|
name | the generated name in provider_metadata |
docker_image | template |
cpu_cores | size |
memory_gb | size |
timeout_minutes | timeout |
environment_vars | env |
labels | nothing: SandboxPlease tags the sandbox with its environment |
vm | nothing: a VM is the only runtime |
gpu_count | your own key (BYOK) |
gpu_type | your own key (BYOK) |
disk_size_gb | your own key (BYOK) |
guaranteed | your own key (BYOK) |
team_id | your own key (BYOK) |
checkpoint_id | your own key (BYOK) |
volumes | your own key (BYOK) |
network_rules | your own key (BYOK) |
Prime Intellect: sandbox REST APIOpenAPI specPrime Intellect: create and manage
Runtime provider_options.runtime
SandboxPlease sends secrets: [] so a sandbox gets none of your account's secrets unless you name them, and deletes it after the timeout (deleteAfterSeconds). A sandbox has at least 2 vCPU and pauses after 300 s idle; any call resumes it. Starting one needs a card on your Runtime account.
{
"idlePauseSeconds": 0,
"labels": {
"team": "ml"
},
"maxCost": "5.00"
}| Set by SandboxPlease | Use instead |
|---|---|
vcpu | size |
memoryGB | size |
image | template |
from | template, or a snapshot id as template |
snapshot | template, or a snapshot id as template |
deleteAfterSeconds | timeout |
env | env |
diskGB | your own key (BYOK) |
volumes | your own key (BYOK) |
secrets | your own key (BYOK) |
Morph Cloud provider_options.morph
A new sandbox boots template (a Morph image, morphvm-minimal by default) with a 16 GB disk; a snapshot resumes with its memory and processes, at the size it was taken at. Morph bills whole MCUs: one per vCPU, per 4 GB of RAM or per 16 GB of disk, whichever is more.
{
"metadata": {
"team": "ml"
}
}| Set by SandboxPlease | Use instead |
|---|---|
vcpus | size |
memory | size |
disk_size | size |
snapshot_id | template for your own snapshot |
ttl_seconds | timeout |
ttl_action | timeout |
Exec options
exec_options does the same for commands, where a provider has extra command flags: Vercel Sandbox (sudo), InstaBox (noHistory), Tensorlake (user). Any other provider answers unsupported.
Drop down to the vendor SDK
Every sandbox carries provider_sandbox_id and provider_metadata: the non-secret fields of the provider's create response, such as its native id, URLs, region and image. Pass the native id to the vendor's SDK when you need a feature SandboxPlease does not route yet.
{
"sandboxID": "i9xk3l2q8m1n0p7r6s5t",
"templateID": "rki5dems9wqfm4r03t7g",
"domain": "e2b.app",
"envdVersion": "0.6.4"
}