---
title: "Get span details."
method: GET
path: "/v1/tracing/traces/{traceId}/spans/{spanId}"
tags: ["traces"]
---

# Get span details.

`GET /v1/tracing/traces/{traceId}/spans/{spanId}`

Get details of a span with the given identifier.

## Path parameters

- `traceId` string, required
- `spanId` string, required

## Response `200`

Details of the span with the given identifier.

- TraceSpanDetail
  - `id` string, required — Identifier of the span.
  - `parentId` string — Identifier of the parent span, if any. If the span has no parent it's considered a root span.
  - `operationName` string, required — The name of the operation given to the span.
  - `resource` string — The name of the resource attached to the span.
  - `service` string — The name of the service this span is part of.
  - `serviceColor` string — Color hex code assigned to the service.
  - `serviceType` string — Defines type of service.
  - `duration` integer, required — Number of nanoseconds the span lasted.
  - `startedAt` string, date-time, required — Date and time the span was started in the [ISO 8601 / RFC3339](https://tools.ietf.org/html/rfc3339) format.
  - `status` TraceSpanStatus, required
    - `code` string, required — Status code of the span. Possible values: `OK`, `ERROR`, `UNKNOWN`.
    - `message` string — Optional descriptive message about the status, could be an http status code or the kind of an error, e.g. OSError.
  - `kind` string — Span kind describes the relationship between the Span, its parents, and its children in a Trace. Possible values: `CLIENT`, `SERVER`, `PRODUCER`, `CONSUMER`, `INTERNAL`.
  - `remoteService` string — Name of the possible remote span's service.
  - `remoteServiceColor` string — Color hex code assigned to the remote service.
  - `remoteServiceType` string — Defines type of service.
  - `info` TraceSpanInfo
    - `type` string, required — Type of this span. Possible values: `TraceHttpSpanInfo`, `TraceDbSpanInfo`, `TraceMessageBusSpanInfo`.
  - `numberOfLinks` integer — Number of span links in this span.
  - `errorMessage` string — Produced error message (could be a stack trace, database error code, ..)
  - `fields` object — Fields attached to this span.
  - `criticalPathContribution` TraceSpanCriticalPathContribution
    - `duration` integer, required — Overall processing time in nanoseconds consumed by this span in the critical path of its trace (a sum of the duration times of this span's critical path segments).
    - `fraction` number, double, required — The total fraction (value between 0.0 and 1.0) of the trace duration time consumed by this span in the critical path of its trace.
  - `logs` string[] — Logs attached to this span.
  - `events` SpanEvent[] — Events attached to this span.
    - `timestamp` string, date-time, required — Time when an event happened in the [ISO 8601 / RFC3339](https://tools.ietf.org/html/rfc3339) format.
    - `name` string, required — Name of the event.
    - `attributes` SpanEventAttribute[] — Span event attributes.
      - `attributeName` string — Name of the attribute.
      - `attributeValue` EventAttributeValue
        - `type` string, required — Type of the event attribute value.
  - `links` SpanLink[] — List of casually related spans.
    - `traceId` string, required — Trace identifier of the linked span.
    - `spanId` string, required — Span identifier of the linked span.

## Other responses

- `default` — Operation failed with an error.

---

[API](https://skmtc.net/sumologic/apis/sumo-logic-api.md) · [All operations](https://skmtc.net/sumologic/apis/sumo-logic-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/sumologic/sumo-logic-api/revisions/18a824df1e78/schema)
