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

# Get Date Range

> Returns the date range with available data for one streaming schedule's prompts. Omitting schedule_id selects Default, including all pre-cutover history.



## OpenAPI

````yaml /api-reference/openapi.json get /api/v1/date-range
openapi: 3.1.0
info:
  title: AthenaHQ API
  description: >-
    AthenaHQ API provides programmatic access to manage your websites and
    prompts for AI-powered content optimization.
  version: 1.0.0
  contact:
    email: support@athenahq.ai
servers:
  - url: https://api.athenahq.ai
    description: Production server
security:
  - apiKey: []
tags:
  - name: Basics
    description: Core API operations for managing websites and prompts
  - name: Metrics
    description: Metrics and analytics endpoints for tracking AI visibility
  - name: Billing
    description: Billing and credits endpoints for managing usage
  - name: Team Management
    description: Endpoints for managing team members and invitations
  - name: Groups
    description: Endpoints for managing groups of websites
  - name: Content
    description: >-
      Endpoints for accessing Content Hub data — tabs, tracked URLs, and per-URL
      prompt breakdowns.
  - name: Pitch Workspace
    description: >-
      Endpoints for accessing pitch workspace reports — org-scoped pitch runs
      with competitors, prompts, attributes, and aggregate metrics.
  - name: Knowledge Base
    description: >-
      Endpoints for reading the brand Knowledge Base — approved brand facts and
      the pillars that organize them.
paths:
  /api/v1/date-range:
    get:
      tags:
        - Basics
      summary: Get Date Range
      description: >-
        Returns the date range with available data for one streaming schedule's
        prompts. Omitting schedule_id selects Default, including all pre-cutover
        history.
      operationId: getDateRange
      parameters:
        - name: website_id
          in: query
          description: The ID of the website to retrieve the date range for
          required: true
          schema:
            type: string
            format: uuid
        - name: schedule_id
          in: query
          required: false
          schema:
            $ref: '#/components/schemas/PromptScheduleSelection'
        - name: prompt_status
          in: query
          description: >-
            Filter by prompt status. If omitted, includes all prompts (active
            and paused).
          required: false
          schema:
            type: string
            enum:
              - active
              - paused
      responses:
        '200':
          description: Successful response with date range
          content:
            application/json:
              schema:
                type: object
                properties:
                  min_date:
                    type: string
                    format: date-time
                    nullable: true
                    description: The earliest timestamp with available data (UTC)
                    example: '2024-01-15T08:20:17.844Z'
                  max_date:
                    type: string
                    format: date-time
                    nullable: true
                    description: The latest timestamp with available data (UTC)
                    example: '2024-12-01T14:30:45.123Z'
                required:
                  - min_date
                  - max_date
        '400':
          description: Bad request - Invalid parameters
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              examples:
                missing_website_id:
                  value:
                    error: website_id is required
                invalid_status:
                  value:
                    error: prompt_status must be 'active' or 'paused'
        '401':
          description: Unauthorized - Invalid or missing API key
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '403':
          description: Forbidden - You don't have access to this website
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              example:
                error: Unauthorized access to this website
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
      security:
        - apiKey: []
components:
  schemas:
    PromptScheduleSelection:
      description: >-
        Select one streaming schedule. Use the selection returned by GET
        /api/v1/prompt-schedules. Default includes all pre-cutover history and
        ad hoc runs; archived schedules retain results. The retired manual token
        is accepted as an alias of default. No All schedules selection.
      default: default
      oneOf:
        - type: string
          enum:
            - default
            - manual
        - type: string
          format: uuid
    Error:
      type: object
      description: Error response object
      required:
        - error
      properties:
        error:
          type: string
          description: Error message describing what went wrong
          example: Unauthorized
  securitySchemes:
    apiKey:
      type: apiKey
      in: header
      name: x-api-key
      description: >-
        API key for authentication. You can create one
        [here](https://app.athenahq.ai/organization?tab=api).

````