v1

latestOpenAPI 3.0.02026-07-141,4077,1665.2 MB
APM Trace

Get a pruned trace by ID

Retrieve a pruned, hierarchical view of an APM trace by its trace ID. The trace is summarized as a tree of spans rooted at the trace root and reduced in size to keep rendering large traces in the UI practical. This endpoint is rate limited to 60 requests per minute per organization.

get/api/v2/pruned_trace/{trace_id}

Path parameters

trace_idstring required

The trace ID. Accepts either a 32-character hexadecimal string (128-bit trace ID) or a decimal string of up to 39 digits.

Query parameters

expand_span_idinteger

Span ID to expand and preserve in the pruned tree even when its branch would normally be summarized.

time_hintinteger

Optional Unix time hint, in seconds, used to optimize the lookup of the trace in long-term storage.

force_sourcestring

Force the trace to be loaded from a specific source. When unset, the API picks the source automatically.

include_pathstring[]

Restrict the pruned tree to spans matching the given key:value pairs. Values may be passed as repeated query parameters.

tag_includestring[]

Regex patterns of tag keys whose values must be included in the pruned spans. Values may be passed as repeated query parameters.

tag_excludestring[]

Regex patterns of tag keys whose values must be excluded from the pruned spans. Values may be passed as repeated query parameters.

only_service_entry_spansboolean

When set to true, only service entry spans are included in the pruned tree.

Response

OK

Example response

{
  "data": {
    "attributes": {
      "size_bytes": 12345,
      "summarized_trace": {
        "root": {
          "children": [],
          "durationSeconds": 0.5,
          "endTime": "2026-05-27T12:00:00.5Z",
          "meta": {
            "env": "production"
          },
          "metrics": {
            "http.status_code": 200
          },
          "name": "web.request",
          "resource": "GET /products",
          "service": "web-store",
          "spanID": 9876543210987655000,
          "span_kind": "SERVER",
          "startTime": "2026-05-27T12:00:00Z"
        },
        "traceId": "0000000000000000abc1230000000000"
      }
    },
    "id": "0000000000000000abc1230000000000",
    "type": "pruned_trace"
  }
}