Skip to main content
GET
Page exact model-cost attempts and charges for a session scope

Authorizations

Authorization
string
header
required

A Recursion API key, created in the console under API keys.

Path Parameters

session_id
string<uuid>
required

Session id (UUID) the cost read is scoped to. Any id in the tree; scope decides how far the read reaches from it.

Query Parameters

scope
enum<string>
default:self

self selects only this session; subtree selects this session and descendants; tree selects the complete root tree.

Available options:
self,
subtree,
tree
limit
integer
default:50
Required range: 1 <= x <= 100
page_token
string

Signed, organization/session/scope/limit/snapshot-bound continuation token.

model_cost_snapshot_token
string

Signed token returned by a model-cost detail page. Pins this companion read to the exact same organization/session/scope snapshot.

Response

One page of model-cost attempts for a session scope, together with the rollups for the same pinned snapshot, so a page and its totals cannot disagree. Continuation pages and companion hierarchy reads stay on that snapshot rather than re-reading a moving ledger.

One page of model-cost attempts for a session scope, together with the rollups for the same pinned snapshot, so a page and its totals cannot disagree. Continuation pages and companion hierarchy reads stay on that snapshot rather than re-reading a moving ledger.

attempts
object[] | null
required

Attempts in scope, oldest first by reservation time, up to the requested limit.

model_cost_snapshot_token
string
required

Signed organization/session/scope-bound token that pins companion model-cost reads to this exact snapshot.

read_timestamp
string<date-time>
required

RFC 3339 timestamp of the database snapshot every figure on this page was read from.

scope
enum<string>
required

How far the read reached from that session: this session alone (self), this session and its descendants (subtree), or every session under the same root (tree).

Available options:
self,
subtree,
tree
session_id
string
required

Session the read was scoped to (UUID).

summaries
object
required

Self, subtree, and tree totals from the same pinned snapshot as this attempt page.

Example:
summary
object
required

Rollup for the requested scope, from the same pinned snapshot as this attempt page.

Example:
next_page_token
string

Continuation for the next page, passed back as page_token. Absent on the last page. It is bound to this organization, session, scope, limit, and snapshot, so it cannot be replayed against a different read.