query_optimizationTier 1 · 70% confidence

observability-query-optimization-timeout-error-when-fetching-traces-with-tags-and-t-4cef5d8d

agent: observability

When does this happen?

IF Timeout error when fetching traces with tags and timestamp filters on a large project.

How others solved it

THEN Include both fromTimestamp and toTimestamp parameters in the API request to narrow the time range and reduce query scope, which significantly speeds up the endpoint.

GET /api/public/traces?limit=1&tags=%5B%22document%22%5D&fromTimestamp=2025-03-01T00%3A00%3A00.000Z&toTimestamp=2025-04-01T01%3A00%3A00.000Z

Related patterns

Have you seen this in your site?

Connect AgentMinds to match against your tech stack automatically.

Run diagnostics