---
title: "Get results of a span analytics query."
method: GET
path: "/v1/tracing/spanquery/{queryId}/rows/{rowId}/spans"
tags: ["spanAnalytics"]
---

# Get results of a span analytics query.

`GET /v1/tracing/spanquery/{queryId}/rows/{rowId}/spans`

Get a list of spans matching a query with the specified id. The response is paginated with a default limit of 100 spans per page.

## Path parameters

- `queryId` string, required
- `rowId` string, required

## Query parameters

- `limit` integer
- `token` string

## Response `200`

Details about the given span query.

- SpanQueryResultSpansResponse
  - `spanPage` SpanQuerySpanData[], required — List of trace spans.
    - `spanId` string — Identifier of the span.
    - `traceId` string — Identifier of the trace.
    - `parentSpanId` string — Identifier of the parent span, if any. If the span has no parent it's considered a root span.
    - `operationName` string — The name of the operation given to the span.
    - `service` string — The name of the service this span is part of.
    - `remoteService` string — Name of the possible remote span's service.
    - `duration` integer, required — Number of nanoseconds the span lasted.
    - `startedAt` string, date-time, required — Date and time the span was started in [ISO 8601 / RFC3339](https://tools.ietf.org/html/rfc3339) format.
    - `status` TraceSpanStatus
      - `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`.
    - `tagsJSON` string — Tags attached to this span as JSON.
    - `metadata` object — Metadata attached to the span.
  - `next` string — Next continuation token.

## 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/versions/18a824df1e78/schema)
