Create sandbox (v2)
Changed onCreate a sandbox from the template. All system communication with the sandbox is secured.
Request
- Base URLhttps://api.e2b.app
- URLhttps://api.e2b.app/v2/sandboxes
- Auth
- API key in header X-API-Key
- or HTTP bearer and API key in header X-Team-ID
- or API key in header X-Admin-Token and API key in header X-Team-ID
- or HTTP bearer and API key in header X-Team-ID
Headers
Optional team-scoped key for retrying sandbox creation. Use 1 to 255 lowercase ASCII letters, digits, or hyphens (a-z, 0-9, -), such as a lowercase UUID. When idempotency is enabled, matching retries replay the original status and body, including errors, for the retention period. Different request parameters return 409 with error_code idempotency_request_mismatch. An in-progress request returns 409 with error_code idempotency_in_progress; an unknown outcome returns 422 with error_code idempotency_outcome_unknown. These retries do not execute the request again. Retries do not extend retention. After the key expires, it can start a new creation.
Request body
Response
The sandbox was created successfully
Changes
- info
the request property
/became nullable - info
the
request property default valuetruewas removed
- info
- info
added the new optional
headerrequest parameterIdempotency-Key - info
added the new optional request property
/ - info
added the non-success response with the status
- info
added the non-success response with the status
- info
added the non-success response with the status
- info
added the non-success response with the status
- info