tenki_create_sandbox
Create a persistent microVM sandbox in seconds, optionally from a snapshot or template image, and get a session ID for executing code, managing files, and running git commands.
Instructions
Create a persistent sandbox microVM, optionally from a snapshot or template image. Returns the session (id, state) and its data-plane endpoint. Boots in ~2s. Use tenki_exec / tenki_read_file / tenki_write_file against the returned session_id.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| env | No | Environment variables as a key→value object. | |
| name | No | Human-readable name. | |
| tags | No | Tags for later filtering. | |
| image | No | Boot from a template image, passed as a reference STRING: the imageDigestRef of a READY build from tenki_build_template / tenki_get_template_build (e.g. 'ws/name@sha256:...'), or 'workspace/name' for its latest version. | |
| cpu_cores | No | vCPUs (default 2). | |
| memory_mb | No | Memory in MB (default 4096). | |
| wait_ready | No | Poll until the sandbox is RUNNING before returning (default true). | |
| snapshot_id | No | Boot from a snapshot. | |
| disk_size_gb | No | Disk in GB (default 5). | |
| workspace_id | No | Workspace to create in (defaults to the key's first workspace). | |
| allow_inbound | No | Allow inbound networking (off by default). | |
| allow_outbound | No | Allow outbound networking (off by default). | |
| clone_repo_url | No | Git URL to clone into the sandbox on boot. | |
| idle_timeout_minutes | No | Reap after N idle minutes. | |
| max_duration_seconds | No | Hard lifetime cap in seconds. |