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

# Get custom report download URL

> Returns a URL to download a PDF report for one or more case screenings (in other words, case data).



## OpenAPI

````yaml /background-check-api/api-reference/openapi.json post /case/id/{caseId}/report/pdf/download/url
openapi: 3.1.0
info:
  title: KarmaCheck API
  description: >-
    All requests to the KarmaCheck API require a JSON Web Token (JWT) in the
    Authorization header. For an overview of the API and its authentication
    method, refer to the following topics:


    - [API basics](docs/overview/apis/api-overview.md)

    - [Authentication](docs/overview/apis/authentication.md)

    - [Environments](docs/overview/apis/environments.md)

    - [Status codes and errors](docs/overview/apis/errors.md)
  version: '1.0'
  contact:
    name: KarmaCheck
    email: customersuccess@karmacheck.com
servers:
  - description: Stage
    url: https://api-stage.karmacheck.io
  - description: Prod
    url: https://api.karmacheck.io
security:
  - JWT: []
tags:
  - name: Authentication
  - name: Cases
  - name: Candidate onboarding
  - name: Secure documents
  - name: Packages
  - name: Services
  - name: Users
  - name: Companies
  - name: Partner integrations
paths:
  /case/id/{caseId}/report/pdf/download/url:
    parameters:
      - schema:
          type: string
        name: caseId
        in: path
        required: true
        description: The ID of the case to get a report for.
    post:
      tags:
        - Cases
      summary: Get custom report download URL
      description: >-
        Returns a URL to download a PDF report for one or more case screenings
        (in other words, case data).
      operationId: post-caseid-caseId-report-pdf-download-url
      requestBody:
        content:
          application/json:
            schema:
              x-examples:
                Example 1:
                  caseDataIds:
                    - 7fcb0b74-147b-48e2-84c9-7aefa3d0e0fa
                  excludeCaseDataAttachments: false
              type: object
              required:
                - caseDataIds
              properties:
                caseDataIds:
                  type: array
                  description: >-
                    The list of case screenings to include in the report. Each
                    element of this array is the `caseDataId` associated with an
                    ordered service. It is *not* the `serviceId` itself. This
                    granularity allows you to generate a report with only some
                    instances of an ordered service. For example, you can
                    generate a report with just the most recent attempt at a
                    Drug 10 Panel instead of a previous one that was lost in
                    transit.
                  items:
                    type: string
                excludeCaseDataAttachments:
                  type: boolean
                  default: false
                  description: >-
                    Some services might have attachments that are permitted to
                    appear in the PDF report, like search results or supporting
                    documents. By default, these will appear in the report. You
                    can explicitly specify whether to include these attachments,
                    if there are any associated with the `caseDataId`s you've
                    chosen, by providing this flag. If there are no applicable
                    attachments, this flag is ignored. Note that some
                    attachments visible in the dashboard, like eScreen
                    ePassports, have feature flags that control whether or not
                    they will show in the reports, even if you set this flag to
                    `false`. Contact Customer Success if you do not see
                    attachments that you are expecting to see.
            examples:
              Example 1:
                value:
                  caseDataIds:
                    - 7fcb0b74-147b-48e2-84c9-7aefa3d0e0fa
                  excludeCaseDataAttachments: false
        description: ''
      responses:
        '200':
          description: >-
            The URL returned in this response is a self-signed S3 URL with a
            time to live (TTL) of 60 seconds. You have 60 seconds to begin the
            download, but once the download begins, it can take as long as
            needed. As many download attempts as needed can be made during the
            60-second period.
          content:
            text/html:
              schema:
                type: string
                format: uri
                example: >-
                  https://s3.amazonaws.com/stage.private.storage-bin.karmacheck.io/98704f90-2770-4999-ba01-453ef6d0deea-report.pdf?AWSAccessKeyId=ASIATUZWO5YBK7C3DIUH&Expires=1699391676&Signature=sL5Am9sMbvWSd8%2B%2F5CoejqsmeO4%3D&X-Amzn-Trace-Id=Root%3D1-654aa880-4e319ca04da8fe7c3faa6d1e%3BParent%3D3b8e51107e55b256%3BSampled%3D0%3BLineage%3D1dda0c46%3A0&x-amz-security-token=FwoGZXIvYXdzEIb%2F%2F%2F%2F%2F%2F%2F%2F%2F%2FwEaDML%2B7WMBiIwah8j4aiK7AVB2sHfQ5tkVkU4Okov%2BRz%2BB%2FMSg6XpdmcOmEb5hJAdg%2BEAxL%2Bt33yt3We5CJUf4auHXMr9huYmkLK%2FQtg3QJQS8CAcZKXPSCaAQ7Wn66D8%2Bpl3x5ppxmgzAONgfejqSfKrYgxl0Srr%2BuAHOz53R5ujbAUA9wwgvfXFoWlJZ4YHah%2BgjFFLzbva%2F4a63g5Mw0Nyngb3EoccWRRn4tEWlzavuGjXYffFcZo2jHT7GXr9eeLoK1sZ96c2jn9oo6cqqqgYyLT8yXkspVciOKVnnBS32UCjIS5rlwu7bL2bMJAW2ocIW0ymnVbak0qb1fMnp6w%3D%3D
        '403':
          description: >-
            Your token does not have access to the `caseId` requested, or you do
            not have access to individual screening reports.
        '404':
          description: The report could not be found in the S3 bucket.
        '422':
          description: >-
            A data issue exists, or the report is not ready.


            In particular, custom reports require that all `caseDataId`s
            requested for the report have their services in a completed state.
            If one or more services are pending, a 422 will be returned.
        '500':
          description: Internal Server Error
components:
  securitySchemes:
    JWT:
      type: http
      scheme: bearer

````