> ## Documentation Index
> Fetch the complete documentation index at: https://docs.corepillar.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# List traces

> Traces in a project, newest first by `started_at`, with cursor pagination.

**Auth:** session. **Permission:** member of the project's organization.



## OpenAPI

````yaml /api-reference/openapi.json get /projects/{projectId}/traces
openapi: 3.1.0
info:
  title: CorePillar API
  version: 1.0.0
  description: >-
    REST API for AgentHub and ModelHub. Ingestion endpoints authenticate with a
    project tracing key; all other endpoints use the signed-in user's browser
    session.
servers:
  - url: https://pillarforge.corepillar.ai/api/v1
    description: AgentHub
security: []
tags:
  - name: Ingestion
    description: 'Send traces with a tracing key: JSON ingest and OpenTelemetry (OTLP).'
  - name: Traces
    description: Read traces and spans.
  - name: Evaluations
    description: Evaluate traces with evaluator collections.
  - name: Evaluators
    description: Built-in and custom evaluators.
  - name: Evaluator collections
    description: Ordered groups of evaluators.
  - name: Organizations
    description: Organizations you belong to.
  - name: Members
    description: Organization members, invites and roles.
  - name: Projects
    description: Projects inside an organization.
  - name: SSO
    description: Okta SSO configuration.
  - name: Tracing keys
    description: Create, list and revoke project tracing keys.
  - name: Cost calculator
    description: Estimate, generate and execute scenario runs.
  - name: Synthetic
    description: Synthetic agent and data setup from source material.
  - name: Chat
    description: ModelHub chat. Served at https://modelhub.corepillar.ai/api/v1.
  - name: Auth
    description: Sign-in helpers.
  - name: E2E
    description: Internal end-to-end encryption key directory.
paths:
  /projects/{projectId}/traces:
    get:
      tags:
        - Traces
      summary: List traces
      description: >-
        Traces in a project, newest first by `started_at`, with cursor
        pagination.


        **Auth:** session. **Permission:** member of the project's organization.
      operationId: listTraces
      parameters:
        - name: projectId
          in: path
          required: true
          description: Project id.
          schema:
            type: string
            format: uuid
        - name: q
          in: query
          required: false
          description: Case-insensitive substring match on `root_name` or `trace_id`.
          schema:
            type: string
        - name: status
          in: query
          required: false
          description: Filter by status. Any other value returns all.
          schema:
            type: string
            enum:
              - OK
              - ERROR
        - name: limit
          in: query
          required: false
          description: Page size.
          schema:
            type: integer
            default: 50
            maximum: 100
            minimum: 1
        - name: cursor
          in: query
          required: false
          description: '`meta.cursor` from the previous page.'
          schema:
            type: string
      responses:
        '200':
          description: A page of traces.
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/Trace'
                  meta:
                    $ref: '#/components/schemas/Meta'
        '401':
          description: Not signed in (`UNAUTHORIZED`).
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorEnvelope'
        '403':
          description: >-
            Not a member of the organization, or missing the required permission
            (`FORBIDDEN`).
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorEnvelope'
        '404':
          description: Project not found or not visible to you (`PROJECT_NOT_FOUND`).
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorEnvelope'
        '500':
          description: Unexpected server error (`INTERNAL_ERROR`).
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorEnvelope'
      security:
        - session: []
components:
  schemas:
    Trace:
      type: object
      properties:
        id:
          type: string
          format: uuid
        organization_id:
          type: string
          format: uuid
        project_id:
          type: string
          format: uuid
        trace_id:
          type: string
        root_name:
          type: string
        status:
          $ref: '#/components/schemas/Status'
        environment:
          type: string
        source:
          type: string
          enum:
            - live
            - simulation
        duration_ms:
          type: integer
          description: Wall-clock extent of all spans.
        llm_time_ms:
          type: integer
          description: Time covered by `llm` spans, overlaps counted once.
        http_time_ms:
          type: integer
          description: Time covered by `http` spans, overlaps counted once.
        span_count:
          type: integer
        llm_call_count:
          type: integer
        tool_call_count:
          type: integer
        tokens_in:
          type: integer
        tokens_out:
          type: integer
        cost_usd:
          type: number
        started_at:
          type: string
          format: date-time
        tags:
          type: array
          items:
            type: string
        created_at:
          type: string
          format: date-time
        updated_at:
          type: string
          format: date-time
    Meta:
      type: object
      description: Present only on endpoints that page or count results.
      properties:
        page:
          type: integer
        pageSize:
          type: integer
          description: Number of items in this response.
        total:
          type: integer
        cursor:
          type:
            - string
            - 'null'
          description: Opaque cursor for the next page; `null` on the last page.
    ErrorEnvelope:
      type: object
      required:
        - error
      properties:
        error:
          type: object
          required:
            - code
            - message
          properties:
            code:
              type: string
              description: Stable machine-readable code. Branch on this, not on `message`.
              examples:
                - VALIDATION_ERROR
            message:
              type: string
              description: Human-readable description. May change.
            details:
              type: object
              additionalProperties: true
              description: Extra context; often empty.
    Status:
      type: string
      enum:
        - OK
        - ERROR
  securitySchemes:
    session:
      type: apiKey
      in: cookie
      name: session
      description: >-
        The session cookie set when you sign in to AgentHub or ModelHub in a
        browser. The cookie name shown here is illustrative. There are no API
        tokens for these endpoints.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.