publish_file.
This page is the canonical sandbox file API. The
fs/* routes below (fs/write, fs/read, fs/list, fs/mkdir, fs/remove) are the single source of truth for reading and writing a computer’s disk. Sandbox scratch files are distinct from persistent, org-scoped Files — the latter are what an agent publishes to keep beyond a run.File operations on a sleeping computer wake it automatically. On a parked computer they are rejected — resume it first. See lifecycle.
Binary files
There is no dedicated upload or download operation. To move binary data in or out of the sandbox, usewrite / read with encoding: "base64".
Working directory
The filesystem operations take absolute paths — they do not carry a working directory. The current directory is a per-exec concern: passcwd to the bash tool to control where a command runs. Nothing about cwd persists between calls.
Limits at a glance
Operations
- write
- read
- list
- mkdir
- remove
Next: shell
Run commands with the
bash tool and read the buffered output.