pydo.harness.create_session_workspace_upload()

Generated on 6 Nov 2026 from pydo version v0.45.0

Usage

client.harness.create_session_workspace_upload(
    session_id="a1b2c3d4-e5f6-7890-abcd-ef1234567890",
    path="example",
    is_archive=None,
    x_content_sha256=None,
    body={...},
)
Returns JSON Raises HttpResponseError

Description

Streams the raw request body to a path inside the sandbox workspace. Concurrent transfers (upload + download) are capped server-side; over the cap the request blocks and may return 503. The optional X-Content-Sha256 request header carries a hex digest the guest verifies after the full payload is written.

Parameters

session_id string required

Example: a1b2c3d4-e5f6-7890-abcd-ef1234567890

The session UUID.

path string required

Example: example

Destination path inside the sandbox workspace. Relative paths resolve under the workspace root; paths that escape the workspace are rejected. Required.

is_archive boolean optional

Example: True

If true, the body is a tar stream that the guest extracts under path. Defaults to false (single file).

x_content_sha256 string optional

Example: example

Optional hex SHA-256 of the full payload. The guest verifies it after writing; a mismatch returns 400.

body JSON or IO[bytes] required

Raw file bytes (or tar stream when is_archive=true). Capped at 500 MiB.

Response Example

Show Response Example
{
  "path": "example",
  "bytes_written": 1
}

More Information

See /v2/agents/sessions/{session_id}/workspace/upload in the API reference for additional detail on responses, headers, parameters, and more.

We can't find any results for your search.

Try using different keywords or simplifying your search terms.