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

# Download report



## OpenAPI

````yaml api-reference/openapi.yaml post /downloadReport
openapi: 3.0.0
info:
  title: Parcha API
  version: 1.0.0
  description: API for managing Parcha jobs and checks
servers:
  - url: https://api.parcha.ai/api/v1
    description: Agent Hub API server
  - url: https://demo.parcha.ai/api/v1
    description: Sandbox API server
  - url: https://us1.parcha.ai/api/v1
    description: Legacy API server
  - url: http://{your-company-domain}.parcha.ai/api/v1
    description: Custom Enterpris server (your company's API server)
security:
  - bearerAuth: []
paths:
  /downloadReport:
    post:
      summary: Download report
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ReportDownloadRequest'
      responses:
        '200':
          description: Report downloaded successfully
          content:
            application/pdf:
              schema:
                type: string
                format: binary
        '401':
          description: Unauthorized
        '404':
          description: Report not found
      security:
        - bearerAuth: []
components:
  schemas:
    ReportDownloadRequest:
      type: object
      required:
        - case_id
        - agent_key
      properties:
        case_id:
          type: string
          description: The unique identifier of the case
        agent_key:
          type: string
          description: The key of the agent to use for generating the report
        force_refresh_report:
          type: boolean
          default: false
          description: If true, forces regeneration of the report even if cached
        download_test_report:
          type: boolean
          default: false
          description: >-
            If true, returns a placeholder test report (useful for testing the
            endpoint)
        report_version:
          type: string
          enum:
            - v1
            - v2
          default: v1
          description: >-
            The report version to use. Use "v2" for the latest Parcha 2.0 report
            format with enhanced styling and layout.
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        API key obtained from your Parcha account settings. Include as Bearer
        token in the Authorization header.

````