---
title: "Check whether a project has spans"
method: GET
path: "/v1/private/spans/exists"
tags: ["Spans"]
---

# Check whether a project has spans

`GET /v1/private/spans/exists`

Returns whether the project has at least one span matching the given scope. Cheap existence probe (LIMIT 1) used to drive empty-state decisions without scanning or aggregating the whole project.

## Query parameters

- `project_id` string, uuid
- `project_name` string
- `source` string — Restrict the probe to a single ingestion source (e.g. 'sdk' for the Logs empty state), matching the rendered list's logs-source scope. Omit to probe any source.

## Response `200`

Span existence

- ExistenceResponse
  - `exists` boolean — Whether the project has at least one matching entity for the given scope

---

[API](https://skmtc.net/comet-ml/apis/opik-rest-api.md) · [All operations](https://skmtc.net/comet-ml/apis/opik-rest-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/comet-ml/opik-rest-api/versions/4ed2fbc97cc3/schema)
