Skip to content
Docs
GitHub

Get one session task with its recent message thread

Preview

Manage execution sessions and rooms, and their files, tasks, storage, databases and managed sandboxes.

Public APIEverruns Cloud and self-hosted Platform

GET/v1/sessions/{session_id}/tasks/{task_id}

See authentication for credentials and permissions.

session_id
required
string

Session ID

task_id
required
string

Task ID

after_id
string

Return only messages after this message ID (exclusive cursor)

limit
integer format: int32

Max messages to return (default 50, max 500)

Responses

200Session task detail

Session task detail

Media typeapplication/json

Task snapshot plus the recent message thread.

object
messages
required
Array<object>

A message exchanged between a session and one of its tasks.

object
content
required
Array
One of:
object
text
required
string
type
required
string
Allowed values: text
created_at
required
string format: date-time
direction
required

Direction of a task message. Inbound = session → task.

string
Allowed values: inbound outbound
id
required

tmsg_* public ID.

string
in_reply_to

Set when this message answers a TaskInputRequest.

string | null
task_id
required
string
task
required

A unit of background work owned by a session.

object
artifacts
Array<object>

Typed link to something the task produced.

object
name
required
string
path

Session VFS path, when the artifact lives in the session filesystem.

string | null
type
required

Artifact type: “file”, “url”, “session”, “pr”, etc.

string
url

External URL, when the artifact lives elsewhere.

string | null
attempt

Execution attempt, starting at 1. Incremented on re-attach.

integer format: int32
cancel_requested_at

Cooperative cancel intent. A flag, not a state.

string | null format: date-time
created_at
required
string format: date-time
display_name
required

Human-readable label.

string
error
One of:

Terminal error detail. Timeout/rejection/orphaned are kinds, not states.

object
kind
required
string
message
required
string
finished_at
string | null format: date-time
heartbeat_at
string | null format: date-time
id
required

task_* public ID.

string
input_request
One of:

Pending ask while awaiting_input; cleared when answered.

object
expected

Optional machine-readable description of the expected answer.

object
id
required

Stable ID referenced by the answering message’s in_reply_to.

string
prompt
required

Human/agent-readable prompt.

string
kind
required

Task kind: “subagent”, “external_agent”, “background_tool”, “monitor”, …

string
links

Cross-references owned by a task.

object
child_session_id

Child session, for subagent-shaped tasks. Full transcript lives there.

string | null
remote_task_id

Remote task ID, for tasks wrapping an external protocol task (A2A).

string | null
resource_ids

Session resources (sandboxes, browser sessions) this task holds.

Array<string>
progress
One of:

Structured progress reported by background tools.

object
current
integer | null format: int64
label
string | null
steps

Ordered checklist, for work that plans its steps up front (a thread’s assignment). Empty for plain counters.

Array<object>

One checklist line in [BackgroundProgress::steps].

object
status
required

State of one checklist line.

string
Allowed values: pending in_progress done skipped
title
required
string
total
integer | null format: int64
unit
string | null
result_path

Machine result in the session VFS: /.tasks/{task_id}/result.json.

string | null
root_session_id

Root of the owning session’s delegation tree (EVE-680). Populated on API reads from the denormalized storage column so cross-session tooling (e.g. the Work view) can group a whole tree’s tasks by one id. None for a top-level session that is its own root, or when unavailable. Storage-derived, never client-settable on create.

string | null
session_id
required

Owning session.

string
spec

Kind-specific input (instructions, tool args, external agent id).

object
started_at
string | null format: date-time
state
required

Lifecycle state of a session task.

Three classes: active (queued, running), interrupted (awaiting_input, resumable), terminal (succeeded, failed, canceled). Timeout and rejection are error.kind values on failed, not states.

string
Allowed values: queued running awaiting_input succeeded failed canceled
state_detail

Short live status line (“polling remote task”, “iteration 4/10”).

string | null
summary

Human-readable outcome.

string | null
updated_at
required
string format: date-time
wake_policy

When outbound task activity wakes the owning session’s agent.

string
Allowed values: silent on_terminal on_activity
worker_id
string | null

Example

{
"messages": [
{
"content": [
{
"type": "text"
}
],
"direction": "inbound"
}
],
"task": {
"progress": {
"steps": [
{
"status": "pending"
}
]
},
"state": "queued",
"wake_policy": "silent"
}
}
404Session or task not found

Session or task not found