Read file or list directory
PreviewManage execution sessions and rooms, and their files, tasks, storage, databases and managed sandboxes.
/v1/workspaces/{workspace_id}/fs/{path}See authentication for credentials and permissions.
Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Workspace ID (wsp_<32-hex>)
File or directory path. Wildcard route: nested paths are literal /-separated segments, not a single URL-encoded value.
Query Parameters
Section titled “Query Parameters”List recursively
Responses
200File content or directory listing
File content or directory listing
Complete file with content
object
File content. Encoding is controlled by the encoding field: plain UTF-8 text for text, base64-encoded bytes for base64. None for directories and when this is a metadata-only listing.
Timestamp when this entry was created (RFC 3339).
Content encoding for the content field: text (UTF-8) or base64 (binary).
Internal database UUID for this file entry.
true when this entry represents a directory; false for a regular file.
Whether the entry was marked read-only at creation. Read-only entries cannot be edited or deleted by the session.
File or directory name (the last segment of path).
Absolute path within the session workspace (e.g. /notes.md).
UUID of the owning session.
File size in bytes. 0 for directories.
Timestamp when this entry was last updated (RFC 3339).
Response wrapper for list endpoints.
All list endpoints return responses wrapped in a data field.
object
Array of items returned by the list operation.
File metadata without content
object
Timestamp when this entry was created (RFC 3339).
Internal database UUID for this file entry.
true when this entry represents a directory; false for a regular file.
Whether the entry was marked read-only at creation. Read-only entries cannot be edited or deleted by the session.
File or directory name (the last segment of path).
Absolute path within the session workspace (e.g. /notes.md).
UUID of the owning session.
File size in bytes. 0 for directories.
Timestamp when this entry was last updated (RFC 3339).
Example
{ "data": [ { "created_at": "2026-05-25T10:14:00Z", "id": "550e8400-e29b-41d4-a716-446655440000", "is_directory": false, "is_readonly": false, "name": "notes.md", "path": "/notes.md", "session_id": "01933b5a-0000-7000-8000-000000000001", "size_bytes": 4096, "updated_at": "2026-05-25T10:15:30Z" } ]}404Not found
Not found
500Internal server error
Internal server error