Skip to content
Get started

Get a trace and all its spans

GET/api/traces/{trace_id}/

Looked up by trace_id (the OTel 32-char hex), not by row id. Returns the root span plus every span sharing that trace_id.

Path ParametersExpand Collapse
trace_id: string
ReturnsExpand Collapse
root: object { agent, attributes, duration_ns, 22 more }

Full span — used both for /api/traces/{trace_id}/ (one span row in the per-trace list) and as the per-row representation for any span query.

agent: string
formatuuid
attributes: unknown
duration_ns: number
end_time_ns: number
events: unknown
is_root: boolean
iteration: string
formatuuid
job: string
formatuuid
kind: number
name: string
operation: string
parent_span_id: string
project: string
formatuuid
received_at: string
formatdate-time
resource_attrs: unknown
scope_name: string
scope_version: string
service_name: string
span_id: string
span_type: "llm_call" or "tool_call"
  • llm_call - Llm Call
  • tool_call - Tool Call
Accepts one of the following:
"llm_call"
"tool_call"
start_time_ns: number
status_code: number
status_message: string
trace_id: string
span_count: number
spans: array of object { agent, attributes, duration_ns, 22 more }
agent: string
formatuuid
attributes: unknown
duration_ns: number
end_time_ns: number
events: unknown
is_root: boolean
iteration: string
formatuuid
job: string
formatuuid
kind: number
name: string
operation: string
parent_span_id: string
project: string
formatuuid
received_at: string
formatdate-time
resource_attrs: unknown
scope_name: string
scope_version: string
service_name: string
span_id: string
span_type: "llm_call" or "tool_call"
  • llm_call - Llm Call
  • tool_call - Tool Call
Accepts one of the following:
"llm_call"
"tool_call"
start_time_ns: number
status_code: number
status_message: string
trace_id: string
trace_id: string
Get a trace and all its spans
curl https://api.overmindlab.ai/api/traces/$TRACE_ID/
{
  "root": {
    "agent": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
    "attributes": {},
    "duration_ns": 0,
    "end_time_ns": 0,
    "events": {},
    "is_root": true,
    "iteration": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
    "job": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
    "kind": 0,
    "links": {},
    "name": "name",
    "operation": "operation",
    "parent_span_id": "parent_span_id",
    "project": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
    "received_at": "2019-12-27T18:11:19.117Z",
    "resource_attrs": {},
    "scope_name": "scope_name",
    "scope_version": "scope_version",
    "service_name": "service_name",
    "span_id": "span_id",
    "span_type": "llm_call",
    "start_time_ns": 0,
    "status_code": 0,
    "status_message": "status_message",
    "trace_id": "trace_id"
  },
  "span_count": 0,
  "spans": [
    {
      "agent": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
      "attributes": {},
      "duration_ns": 0,
      "end_time_ns": 0,
      "events": {},
      "is_root": true,
      "iteration": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
      "job": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
      "kind": 0,
      "links": {},
      "name": "name",
      "operation": "operation",
      "parent_span_id": "parent_span_id",
      "project": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
      "received_at": "2019-12-27T18:11:19.117Z",
      "resource_attrs": {},
      "scope_name": "scope_name",
      "scope_version": "scope_version",
      "service_name": "service_name",
      "span_id": "span_id",
      "span_type": "llm_call",
      "start_time_ns": 0,
      "status_code": 0,
      "status_message": "status_message",
      "trace_id": "trace_id"
    }
  ],
  "trace_id": "trace_id"
}
Returns Examples
{
  "root": {
    "agent": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
    "attributes": {},
    "duration_ns": 0,
    "end_time_ns": 0,
    "events": {},
    "is_root": true,
    "iteration": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
    "job": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
    "kind": 0,
    "links": {},
    "name": "name",
    "operation": "operation",
    "parent_span_id": "parent_span_id",
    "project": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
    "received_at": "2019-12-27T18:11:19.117Z",
    "resource_attrs": {},
    "scope_name": "scope_name",
    "scope_version": "scope_version",
    "service_name": "service_name",
    "span_id": "span_id",
    "span_type": "llm_call",
    "start_time_ns": 0,
    "status_code": 0,
    "status_message": "status_message",
    "trace_id": "trace_id"
  },
  "span_count": 0,
  "spans": [
    {
      "agent": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
      "attributes": {},
      "duration_ns": 0,
      "end_time_ns": 0,
      "events": {},
      "is_root": true,
      "iteration": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
      "job": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
      "kind": 0,
      "links": {},
      "name": "name",
      "operation": "operation",
      "parent_span_id": "parent_span_id",
      "project": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
      "received_at": "2019-12-27T18:11:19.117Z",
      "resource_attrs": {},
      "scope_name": "scope_name",
      "scope_version": "scope_version",
      "service_name": "service_name",
      "span_id": "span_id",
      "span_type": "llm_call",
      "start_time_ns": 0,
      "status_code": 0,
      "status_message": "status_message",
      "trace_id": "trace_id"
    }
  ],
  "trace_id": "trace_id"
}