Task Runs represent the outcome of a single Task within a Run. Each task run is executed in its own Playground and contains Eval Runs with individual assertion results.
Endpoints not yet in OpenAPI spec.
Endpoints
| Method | Endpoint | Description |
|---|
GET | /task-runs?run_id={runId} | List task runs for a run |
GET | /task-runs/{id} | Get task run details |
POST | /task-runs/{id}/complete | Mark a task run as complete |
POST | /task-runs/{id}/cancel | Cancel a task run |
Task Run Object
| Field | Type | Description |
|---|
id | string | Unique identifier |
run_id | string | Parent Run |
task_id | string | Source Task |
playground_id | string | Playground used for execution |
status | Status | Current status (pending, running, completed, cancelled, failed) |
verdict | Verdict | null | Pass/fail verdict, set on completion |
score | number | null | Task score (0-1), set on completion |
snapshot | object | null | Frozen copy of the task definition at execution time |
started_at | datetime | When execution started |
completed_at | datetime | null | When execution finished |
SDK Example
// List task runs for a run
const taskRuns = await verial.taskRuns.list({ runId: 'run_abc123' })
// Get task run details
const details = await verial.taskRuns.get({ id: taskRuns.data[0].id })
// Mark as complete
await verial.taskRuns.complete({ id: details.id })
// Cancel a running task
await verial.taskRuns.cancel({ id: details.id })