runs

Get a run's script

Changed on

Returns every cell the run executed, in order, as one Python file and one by one, failed and exploratory cells included. A code run's first cell is its revision's script. The script is kept with the run's data, so it outlives the transcript; when that record is missing, the cells are rebuilt from what remains of the transcript and partial is true. 404 when there is nothing to build it from.

get/runs/{run_id}/script

Request

Path parameters

run_idstring uuid required

The run's id.

Response

OK

$schemastring uri

A URL to the JSON Schema for this object.

partialboolean required

True when the cells may not be all the run executed: the run's script record was missing and the cells were rebuilt from what remains of its transcript and, for a code run, its revision, or the record was never finished because the run is still going or its edge stopped mid-run. Such a script can miss cells, the last one included.

scriptstring required

The cells as one Python file, each headed by its number and status.

Example response

{
  "$schema": "/api/v1/AgentRunScript.json"
}

Changes