Skip to main content
POST
Search traces
For the query syntax and how search fits with the other trace endpoints, see Querying traces.

Authorizations

Authorization
string
header
required

Authorization: Bearer <token>

Body

application/json

Request body for the unified search endpoint.

site_ids
string[]
required

Sites to search, as BSON ObjectIds: at least one, all in one account.

query
string | null

Bare words match an action name, exception name or tag value exactly, as one phrase. action:, error: and tag: match one field exactly, message: a case-insensitive whole-word phrase; quote values with spaces.

namespace
string | null

Optional namespace filter (e.g. "web", "background").

kind
enum<string>
default:all

Sample kind filter.

Available options:
all,
exception,
performance
from
string<date-time> | null

Start of the time range (inclusive). Defaults to, and is clamped to, the start of the account's retention.

to
string<date-time> | null

End of the time range (inclusive). Defaults to now.

limit
integer
default:50

Maximum number of results to return. Clamped to at most 2000.

Required range: x >= 0

Response

Up to limit results, newest first: one per incident digest of each matching span, so trace_id can repeat.

result_type
enum<string>
required

Whether this is an exception or performance result.

Available options:
exception,
performance
source
enum<string>
required

Where this result came from; always trace.

Available options:
trace
trace_id
string
required

Identifier to open the trace with.

site_id
string
required

Site identifier this result belongs to.

time
string<date-time>
required

Timestamp when the result was recorded.

duration
number<double>
required

Duration in milliseconds of the matched span.

tags
object
required

User-defined tags.

namespace
string | null

Namespace the result belongs to (e.g. "web", "background").

revision
string | null

Git revision or deployment identifier active when the result was recorded.

action_name
string | null

Action name of the result (e.g. "POST /api/users").

exception_name
string | null

Exception name; present for exception results only.

exception_message
string | null

Exception message; present for exception results only.

incident_digest
string | null

Incident digest used to link to the incident page.

incident_number
integer<int64> | null

Incident number, when the incident digest matches a known incident.