Watch Directory
Filesystem API
Watch Directory
Watch a directory for filesystem changes via Server-Sent Events.
POST
Watch Directory
Registers a filesystem watcher on the specified directory and streams change events
to the client using Server-Sent Events (SSE). Events are emitted when files are
created, modified, or deleted under the watched path.
Currently returns
Full SSE streaming for file watch events is in progress. The current release
returns an empty
{} body. The endpoint signature and request format are stable
and will be updated to return a live event stream in an upcoming release.Path Parameters
The sandbox identifier. Format:
sbx-<8 chars>.Request Body
Absolute path of the directory to watch inside the sandbox.Example:
"/home/user/output"Response
When streaming is fully implemented, the response will haveContent-Type: text/event-stream and emit events with this format:
{}.
Example
Error Responses
| Status | Cause |
|---|---|
401 | Missing or invalid API key |
404 | Sandbox not found |
503 | Sandbox has no VM |