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

# Generate PDF report

> Generate a branded PDF report for a completed search or verification.

Pass **either** `searchId` or `verificationId` (not both).

**Search PDFs** include all data collected during the original search:
- Business registry results (provincial and federal)
- Regulatory registrations (charities, MSB, cannabis licences, health service providers)
- Key people (directors, beneficial owners)
- Sanctions screening results (if enabled during search)
- Website analysis and extracted data (if enabled during search)
- Industry classification (NAICS)

**Verification PDFs** include:
- Field-level match results (legal name, registration number, address)
- People verification results (if enabled)
- Registry data used for comparison
- AI-generated analyst summary

**Note:** Only resources belonging to your organization can be retrieved.

**Typical response time:** 10-30 seconds (headless browser renders the report)




## OpenAPI

````yaml /openapi.yaml post /generate-pdf
openapi: 3.1.0
info:
  title: Current Business Verification API
  version: 1.0.0
  description: >
    The Current API provides programmatic access to Canadian business
    verification services.


    ## Authentication

    All API requests require authentication via API key. Include your key using
    one of these methods:

    - `Authorization: Bearer cur_live_xxxxx` (recommended)

    - `X-API-Key: cur_live_xxxxx`


    ## Rate Limits

    All endpoints are rate limited to **60 requests per minute** per API key.


    Rate limit headers are included in all responses:

    - `X-RateLimit-Limit`: Maximum requests allowed in current window

    - `X-RateLimit-Remaining`: Remaining requests in current window

    - `X-RateLimit-Reset`: Unix timestamp when the rate limit resets


    ## Request IDs

    All responses include an `X-Request-Id` header for traceability.

    You can provide your own via the `X-Request-Id` request header; otherwise
    one is generated automatically.

    Include this ID when contacting support about a specific request.
  contact:
    name: Current Support
    url: https://getcurrent.ca
  license:
    name: Proprietary
servers:
  - url: https://api.getcurrent.ca/v1
    description: Production
security:
  - bearerAuth: []
  - apiKeyHeader: []
tags:
  - name: Search
    description: Business verification search operations
  - name: Pre-fill
    description: Fast typeahead lookup of canonical business candidates
  - name: Generate PDF
    description: PDF report generation
  - name: Business Reports
    description: Business report operations
  - name: Sanctions
    description: Standalone sanctions screening operations
  - name: Verification
    description: Business verification operations
  - name: Businesses
    description: >-
      Business record sync (list/read as a change feed, upsert to keep records
      current)
paths:
  /generate-pdf:
    post:
      tags:
        - Generate PDF
      summary: Generate PDF report
      description: >
        Generate a branded PDF report for a completed search or verification.


        Pass **either** `searchId` or `verificationId` (not both).


        **Search PDFs** include all data collected during the original search:

        - Business registry results (provincial and federal)

        - Regulatory registrations (charities, MSB, cannabis licences, health
        service providers)

        - Key people (directors, beneficial owners)

        - Sanctions screening results (if enabled during search)

        - Website analysis and extracted data (if enabled during search)

        - Industry classification (NAICS)


        **Verification PDFs** include:

        - Field-level match results (legal name, registration number, address)

        - People verification results (if enabled)

        - Registry data used for comparison

        - AI-generated analyst summary


        **Note:** Only resources belonging to your organization can be
        retrieved.


        **Typical response time:** 10-30 seconds (headless browser renders the
        report)
      operationId: generatePDFReport
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/GeneratePDFRequest'
            examples:
              searchPdf:
                summary: Generate PDF for a search
                value:
                  searchId: f47ac10b-58cc-4372-a567-0e02b2c3d479
              verificationPdf:
                summary: Generate PDF for a verification
                value:
                  verificationId: a1b2c3d4-e5f6-7890-abcd-ef1234567890
      responses:
        '200':
          description: PDF generated and uploaded successfully
          headers:
            X-Request-Id:
              $ref: '#/components/headers/X-Request-Id'
            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/GeneratePDFResponse'
              examples:
                searchPdf:
                  summary: Successful search PDF generation
                  value:
                    meta:
                      searchId: f47ac10b-58cc-4372-a567-0e02b2c3d479
                      verificationId: null
                      generatedAt: '2026-02-21T12:00:00.000Z'
                      generatedBy: user@example.com
                      name: Shopify Inc
                      status: completed
                      duration: 14200
                    report:
                      url: >-
                        https://abc.supabase.co/storage/v1/object/sign/business-documents/tenant/search-id/search-report/Shopify-Inc-Current-Business-Report.pdf?token=...
                      filename: Shopify-Inc-Current-Business-Report.pdf
                      expiresAt: '2031-02-21T00:00:00.000Z'
                verificationPdf:
                  summary: Successful verification PDF generation
                  value:
                    meta:
                      searchId: null
                      verificationId: a1b2c3d4-e5f6-7890-abcd-ef1234567890
                      generatedAt: '2026-02-21T12:00:00.000Z'
                      generatedBy: user@example.com
                      name: Shopify Inc.
                      status: completed
                      duration: 12500
                    report:
                      url: >-
                        https://abc.supabase.co/storage/v1/object/sign/business-documents/tenant/verification-id/verification-report/Shopify-Inc-Verification-Report.pdf?token=...
                      filename: Shopify-Inc-Verification-Report.pdf
                      expiresAt: '2031-02-21T00:00:00.000Z'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          $ref: '#/components/responses/NotFound'
        '429':
          $ref: '#/components/responses/RateLimited'
        '500':
          $ref: '#/components/responses/InternalError'
      security:
        - bearerAuth: []
        - apiKeyHeader: []
components:
  schemas:
    GeneratePDFRequest:
      type: object
      properties:
        searchId:
          type: string
          format: uuid
          description: >
            The ID of the search to generate a PDF for.

            This is returned as `meta.searchId` in the response from `POST
            /search`.

            Mutually exclusive with `verificationId`.
          example: f47ac10b-58cc-4372-a567-0e02b2c3d479
        verificationId:
          type: string
          format: uuid
          description: >
            The ID of the verification to generate a PDF for.

            This is returned as `meta.verificationId` in the response from `POST
            /verify`.

            Mutually exclusive with `searchId`.
          example: a1b2c3d4-e5f6-7890-abcd-ef1234567890
      oneOf:
        - required:
            - searchId
        - required:
            - verificationId
    GeneratePDFResponse:
      type: object
      required:
        - meta
        - report
      properties:
        meta:
          type: object
          required:
            - generatedAt
            - generatedBy
            - name
            - status
            - duration
          properties:
            searchId:
              type:
                - string
                - 'null'
              format: uuid
              description: >-
                ID of the search the PDF was generated from (null for
                verification PDFs)
            verificationId:
              type:
                - string
                - 'null'
              format: uuid
              description: >-
                ID of the verification the PDF was generated from (null for
                search PDFs)
            generatedAt:
              type: string
              format: date-time
              description: When the PDF was generated
            generatedBy:
              type:
                - string
                - 'null'
              format: email
              description: Email of the API key owner who requested the PDF
            name:
              type: string
              description: Business name from the original search or verification
            status:
              type: string
              enum:
                - completed
            duration:
              type: integer
              description: PDF generation and upload time in milliseconds
        report:
          type: object
          required:
            - url
            - filename
            - expiresAt
          properties:
            url:
              type: string
              format: uri
              description: >-
                Signed URL to view or download the PDF. Valid for approximately
                5 years.
              example: >-
                https://abc.supabase.co/storage/v1/object/sign/business-documents/...
            filename:
              type: string
              description: Suggested filename for the PDF.
              example: Shopify-Inc-Current-Business-Report.pdf
            expiresAt:
              type: string
              format: date-time
              description: ISO 8601 timestamp when the signed URL expires.
              example: '2031-02-21T00:00:00.000Z'
    ErrorResponse:
      type: object
      required:
        - error
        - code
      properties:
        error:
          type: string
          description: Human-readable error message
        code:
          type: string
          description: >
            Machine-readable error code. Present on every error response.
            Distinct from the per-source `APIError.code` values that appear
            inside a successful response's `meta.errors` object.
          enum:
            - MISSING_API_KEY
            - INVALID_API_KEY
            - REVOKED_API_KEY
            - EXPIRED_API_KEY
            - RATE_LIMITED
            - VALIDATION_ERROR
            - INVALID_JSON
            - NOT_FOUND
            - STALE_WRITE
            - CONFLICT
            - METHOD_NOT_ALLOWED
            - UNAUTHORIZED
            - SERVER_ERROR
            - INTERNAL_ERROR
          example: VALIDATION_ERROR
  headers:
    X-Request-Id:
      description: >-
        Unique request identifier for traceability. Echoes client-provided value
        or auto-generated UUID.
      schema:
        type: string
        format: uuid
        example: a1b2c3d4-e5f6-7890-abcd-ef1234567890
    X-RateLimit-Limit:
      description: Maximum requests per minute
      schema:
        type: integer
        example: 60
    X-RateLimit-Remaining:
      description: Remaining requests in current window
      schema:
        type: integer
        example: 58
    X-RateLimit-Reset:
      description: Unix timestamp when rate limit resets
      schema:
        type: integer
        example: 1702915200
  responses:
    BadRequest:
      description: Invalid request parameters
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          example:
            error: name is required and must be a non-empty string
            code: VALIDATION_ERROR
    Unauthorized:
      description: Missing or invalid API key
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          examples:
            missing:
              value:
                error: >-
                  Missing API key. Provide via Authorization: Bearer <key> or
                  X-API-Key header.
                code: MISSING_API_KEY
            invalid:
              value:
                error: Invalid API key
                code: INVALID_API_KEY
            revoked:
              value:
                error: API key has been revoked
                code: REVOKED_API_KEY
            expired:
              value:
                error: API key has expired
                code: EXPIRED_API_KEY
    NotFound:
      description: Resource not found
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          example:
            error: Search not found
            code: NOT_FOUND
    RateLimited:
      description: Rate limit exceeded
      headers:
        X-RateLimit-Limit:
          $ref: '#/components/headers/X-RateLimit-Limit'
        X-RateLimit-Remaining:
          schema:
            type: integer
            example: 0
        X-RateLimit-Reset:
          $ref: '#/components/headers/X-RateLimit-Reset'
        Retry-After:
          description: Seconds until rate limit resets
          schema:
            type: integer
            example: 60
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          example:
            error: Rate limit exceeded. Try again in 60 seconds.
            code: RATE_LIMITED
    InternalError:
      description: Internal server error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          example:
            error: Internal server error
            code: SERVER_ERROR
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: 'API key as Bearer token: `Authorization: Bearer cur_live_xxxxx`'
    apiKeyHeader:
      type: apiKey
      in: header
      name: X-API-Key
      description: 'API key in header: `X-API-Key: cur_live_xxxxx`'

````