Skip to content

Write a file

POST
/v1/sandbox/{sandboxID}/filesystem/write-file

Write a single file to the sandbox. The raw file bytes are sent as the request body.

sandboxID
required
string

Unique sandbox identifier.

path
required
string

Absolute file path inside the sandbox.

permissions
string

Optional octal file mode (e.g. “0755”).

string format: binary

File written.

Bad request – validation error.

object
message
required

Summary message, e.g. “Invalid request”.

string
errors
required
Array<object>
object
field
required

JSON field name that failed validation (e.g. “path”, “command”).

string
error
required

Human-readable description of the validation failure.

string

Unauthorized – invalid or missing API key.

object
message
required

Human-readable error message.

string