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

# List AI execution history

> Lists still-present execution metadata, including every lifecycle status by default, in a fixed 30/90-day window anchored on the first page. Ordered by started_at DESC, id DESC, preserving timestamp precision. Read each execution with getVisibilityResponse for retained public answer evidence. No raw provider blobs or analytical counts. This live operational population is not a visibility denominator and does not use rollup logical dates. Enterprise platforms are included only for entitled accounts. Keep cohort filters and window unchanged when continuing; signed cursors expire after 90 days and on server secret rotation. Page size may change. The metadata query requests at most 101 rows, below the configured PostgREST cap.



## OpenAPI

````yaml /openapi.json get /projects/{projectId}/visibility/response-history
openapi: 3.1.0
info:
  title: DevTune API
  version: 2.0.0
  description: >-
    API for programmatic access to your AI visibility data, webhook
    subscriptions, and automation workflows. Use this API to integrate DevTune
    data into CI/CD pipelines, BI tools, AI agents, and operational systems.
servers:
  - url: https://devtune.ai/api/v2
    description: Production
security:
  - bearerAuth: []
paths:
  /projects/{projectId}/visibility/response-history:
    get:
      summary: List AI execution history
      description: >-
        Lists still-present execution metadata, including every lifecycle status
        by default, in a fixed 30/90-day window anchored on the first page.
        Ordered by started_at DESC, id DESC, preserving timestamp precision.
        Read each execution with getVisibilityResponse for retained public
        answer evidence. No raw provider blobs or analytical counts. This live
        operational population is not a visibility denominator and does not use
        rollup logical dates. Enterprise platforms are included only for
        entitled accounts. Keep cohort filters and window unchanged when
        continuing; signed cursors expire after 90 days and on server secret
        rotation. Page size may change. The metadata query requests at most 101
        rows, below the configured PostgREST cap.
      operationId: listVisibilityResponseHistory
      parameters:
        - name: projectId
          in: path
          required: true
          schema:
            type: string
            format: uuid
        - name: windowDays
          in: query
          schema:
            type: integer
            enum:
              - 30
              - 90
            default: 30
        - name: pageSize
          in: query
          schema:
            type: integer
            minimum: 1
            maximum: 100
            default: 50
        - name: cursor
          in: query
          schema:
            type: string
            minLength: 1
            maxLength: 4096
        - name: promptId
          in: query
          schema:
            type: string
            format: uuid
        - name: platform
          in: query
          schema:
            type: string
            minLength: 1
            maxLength: 100
        - name: status
          in: query
          schema:
            type: string
            enum:
              - pending
              - running
              - success
              - failed
              - rate_limited
      responses:
        '200':
          description: One execution history page
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    $ref: '#/components/schemas/VisibilityResponseHistory'
                  meta:
                    $ref: '#/components/schemas/Meta'
                required:
                  - data
                  - meta
        '400':
          $ref: '#/components/responses/BadRequestError'
        '401':
          $ref: '#/components/responses/UnauthorizedError'
        '403':
          $ref: '#/components/responses/ForbiddenError'
        '404':
          $ref: '#/components/responses/NotFoundError'
        '429':
          $ref: '#/components/responses/RateLimitExceededError'
components:
  schemas:
    VisibilityResponseHistory:
      type: object
      additionalProperties: false
      required:
        - items
        - window
        - population
        - pageSize
        - pageCursor
        - nextCursor
        - hasMore
      properties:
        items:
          type: array
          maxItems: 100
          items:
            type: object
            additionalProperties: false
            required:
              - executionId
              - promptId
              - platform
              - status
              - startedAt
              - completedAt
            properties:
              executionId:
                type: string
                format: uuid
              promptId:
                type: string
                format: uuid
              platform:
                type: string
              status:
                type: string
                enum:
                  - pending
                  - running
                  - success
                  - failed
                  - rate_limited
              startedAt:
                type: string
                format: date-time
              completedAt:
                type:
                  - string
                  - 'null'
                format: date-time
        window:
          type: object
          additionalProperties: false
          required:
            - days
            - from
            - before
            - timeBasis
          properties:
            days:
              type: integer
              enum:
                - 30
                - 90
            from:
              type: string
              format: date-time
              description: Inclusive lower bound.
            before:
              type: string
              format: date-time
              description: Exclusive anchor set on the first page.
            timeBasis:
              type: string
              enum:
                - started_at
        population:
          type: object
          additionalProperties: false
          required:
            - kind
            - consistency
            - answerEvidence
            - promptId
            - platform
            - status
            - enterprisePlatformsIncluded
          properties:
            kind:
              type: string
              enum:
                - still_present_executions
            consistency:
              type: string
              enum:
                - live
              description: >-
                No database snapshot. Retention, deletion and lifecycle status
                can change during traversal.
            answerEvidence:
              type: string
              enum:
                - read_each_response
            promptId:
              type:
                - string
                - 'null'
              format: uuid
            platform:
              type:
                - string
                - 'null'
            status:
              type:
                - string
                - 'null'
              enum:
                - pending
                - running
                - success
                - failed
                - rate_limited
                - null
            enterprisePlatformsIncluded:
              type: boolean
        pageSize:
          type: integer
          minimum: 1
          maximum: 100
        pageCursor:
          type: string
          description: >-
            Replay this page with its original window anchor. Deduplicate
            previously exported execution IDs after a mid-page interruption.
        nextCursor:
          type:
            - string
            - 'null'
        hasMore:
          type: boolean
    Meta:
      type: object
      properties:
        timestamp:
          type: string
          format: date-time
        projectId:
          type: string
          format: uuid
    Error:
      type: object
      properties:
        error:
          type: string
        message:
          type: string
        reason:
          type: string
          description: >-
            Why the request was refused, for an error with more than one cause,
            such as a refused content-draft start.
        status:
          type: integer
      required:
        - error
        - message
        - status
  responses:
    BadRequestError:
      description: Bad request
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    UnauthorizedError:
      description: Unauthorized
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    ForbiddenError:
      description: Forbidden
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    NotFoundError:
      description: Not found
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    RateLimitExceededError:
      description: Rate limit exceeded
      headers:
        X-RateLimit-Limit:
          $ref: '#/components/headers/X-RateLimit-Limit'
        X-RateLimit-Remaining:
          $ref: '#/components/headers/X-RateLimit-Remaining'
        X-RateLimit-Reset:
          $ref: '#/components/headers/X-RateLimit-Reset'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
  headers:
    X-RateLimit-Limit:
      description: Maximum requests per window
      schema:
        type: integer
    X-RateLimit-Remaining:
      description: Requests remaining in current window
      schema:
        type: integer
    X-RateLimit-Reset:
      description: Unix timestamp when the window resets
      schema:
        type: integer
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        API key with dtk_live_ prefix. Obtain it from API Keys in the account
        sidebar. New keys start with all supported scopes selected for the
        chosen project, and you can narrow them to specific read/write scopes as
        needed.

````

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