# Page through the steps of one turn of a session's trace, optionally only the failed ones.

Source: <https://everruns.com/docs/api/operations/list_session_trace_steps/>

GET

/v1/sessions/{session\_id}/trace/turns/{turn}/steps

Select code samplecURL (shell:curl)

```js
const url = 'https://app.everruns.com/api/v1/sessions/example/trace/turns/example/steps';
const options = {method: 'GET'};


try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```sh
curl --request GET \
  --url https://app.everruns.com/api/v1/sessions/example/trace/turns/example/steps
```

* Production APIapp.everruns.com/api/v1/sessions/{session\_id}/trace/turns/{turn}/steps

## Parameters

### Path Parameters

**session\_id**

required

string

Prefixed public identifier

**turn**

required

string

Prefixed public identifier

### Query Parameters

**from\_step**

integer format: int32

First step of the range, inclusive. Defaults to 1.

**to\_step**

integer format: int32

Last step of the range, inclusive. Defaults to the turn’s last step.

**errors\_only**

boolean

Only failed steps.

**limit**

integer format: int32

Steps per page, 1 to 500. Defaults to 100.

## Responses

### 200

Success

Media typeapplication/json

A page of plain steps of one turn.

object

**next\_step**

Step number to continue from, when more remain in the range.

integer | null format: int32

**steps**

required

Steps in step order.

Array\<object>

A model call, tool call, approval, sub-agent or message. Empty fields are left out: a page carries hundreds of these.

object

**child\_session\_id**

Session a `spawn_agent` call started.

string | null

**duration\_ms**

Wall time of the step; absent while running.

integer | null format: int64

**end\_sequence**

Last event sequence of the step.

integer | null format: int32

**input\_tokens**

Prompt tokens of a model call.

integer | null format: int32

**kind**

required

`model`, `answer`, `tool`, `approval`, `agent` or `send`.

string

**model**

Model that served the call, for model steps.

string | null

**name**

Tool name, or model for model calls.

string | null

**narration**

What the model said alongside this call (model calls and answers).

string | null

**offset\_ms**

required

Start relative to the turn’s start.

integer format: int64

**output\_tokens**

Completion tokens of a model call.

integer | null format: int32

**requested\_tool\_call\_ids**

Tool calls this model call asked for.

Array\<string>

**result**

Short result or error.

string | null

**start\_sequence**

required

First event sequence of the step.

integer format: int32

**started\_at**

required

When the step started.

string format: date-time

**status**

required

`running`, `success`, `error` or `cancelled`.

string

**step**

required

Per-turn step number, 1-based.

integer format: int32

**target**

What the call acted on, from the tool’s narration.

string | null

**tool\_call\_id**

Tool call identifier, for tool steps.

string | null

**turn**

required

Turn the step belongs to.

integer format: int32

##### Example

```json
{
  "next_step": 101,
  "steps": [
    {
      "duration_ms": 269,
      "end_sequence": 21,
      "kind": "tool",
      "model": "gpt-6.1-sol",
      "name": "bash",
      "offset_ms": 3010,
      "start_sequence": 14,
      "status": "success",
      "step": 2,
      "tool_call_id": "call_PzDcvnFaUll8os3tPhWj",
      "turn": 1240
    }
  ]
}
```