Skip to main content
Three routes read one trace. Right: read. A trace of 100,000 spans is hundreds of MB with its text: for such a trace, list its spans in pages without text, then get the text of one span.

Get every span of a trace

GET /v1/traces/:id returns {"spans": [span]}: every span with its text, by startedAt, then spanId. A trace with no spans: 404.
string
required
The trace id.
object[]

List the spans of a trace in pages

GET /v1/traces/:id/spans?limit=n&cursor=c returns {"count", "spans", "nextCursor"}: the spans of the trace without their text, oldest first. count is every span of the trace. A trace that is not there gives an empty list with count 0.
string
required
The trace id.
integer
default:"50"
At most 10,000. 0 returns only the count. Another query parameter than limit or cursor gets 400.
string
The nextCursor of the page before, as it is: it needs no escaping.
object[]
Each page reads the time of every span of the trace once, as every list by cursor does: for a whole trace, use a large limit. All fields come from columns except parentSpanId, which the server reads from the stored span of each row that has a parent.

Get one span

GET /v1/traces/:id/spans/:spanId returns one span with every field. No such span: 404.
string
required
The span id.
A client that does not use upsert (OTLP always does) can write a span twice with the same ids. This route then returns the copy that started last.

Read and export

A guide with real answers.

Scores of a trace

The evals and feedback on a trace.