E2B
创建快照
保存沙箱状态,返回本平台的快照 ID 与原始别名。
先调用「创建沙箱」,用返回的 sandboxID 替换 sbx_123。
POST
/e2b/sandboxes/{sandboxID}/snapshots● 支持请求参数
sandboxIDstring必填path:
namestring可选可选别名。同一主体重复使用该别名会更新既有快照,保留本平台快照 ID。
返回
201
错误按 E2B 格式返回,参见 错误码
响应
HTTP 201
Snapshot created successfully
application/json
| 名称 | 类型 | 说明 |
|---|---|---|
| snapshotID | string | Identifier of the snapshot template including the tag. Uses namespace/alias when a name was provided (e.g. team-slug/my-snapshot:default), otherwise falls back to the raw template ID (e.g. abc123:default). |
| names | array<string> | Full names of the snapshot template including team namespace and tag (e.g. team-slug/my-snapshot:v2) |