---
title: "Save Sandbox Partial Results"
method: POST
path: "/auto-agent/run/{run_id}/partial-results"
tags: ["auto-agent"]
---

# Save Sandbox Partial Results

`POST /auto-agent/run/{run_id}/partial-results`

Save partial deliverables when the sandbox is interrupted (timeout/SIGTERM).

If all three result files (``deliverables_json``, ``final_report``,
``curation_report``) are present, the run is marked ``complete``.
Otherwise the run flips to ``failed`` (only when still ``running`` —
a concurrent ``stop_run`` keeps its ``stopped`` status) with whatever
partial data was provided.

Args:
    run_id: Run UUID from the path.
    body: Partial results payload + ``error_message``.
    callback_token: One-time token issued at run creation.

Raises:
    HTTPException 401: Token invalid or run already finalized.
    HTTPException 404: Run not found.

## Path parameters

- `run_id` string, required

## Headers

- `X-Callback-Token` string, required

## Request body

- SandboxPartialResultsRequest — Best-effort save of in-flight files when the container is interrupted.
  - `deliverables_json` object, nullable
  - `final_report` string, nullable
  - `curation_report` string, nullable
  - `error_message` string, required

## Response `204`

Successful Response

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.net/pioneer/apis/brain-api.md) · [All operations](https://skmtc.net/pioneer/apis/brain-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/pioneer/brain-api/revisions/31dfe831e079/schema)
