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

# Short-TTL branded download link (scope: crew:documents:download)

> Mint a short-TTL, CrewPass-hosted link to download a document's file.

Consent-intersected on ``crew:documents:download``. 404 if the document is
not the crew member's current version or the crew is off-fleet. The returned
``download_url`` is a branded proxy link (never a raw storage URL).



## OpenAPI

````yaml /api-reference/openapi.json get /api/v2/employers/me/crew/{crew_unique_id}/documents/{document_id}/download
openapi: 3.1.0
info:
  title: crewpass-api-v2
  description: >-
    CrewPass V2 Partner API — a scope-gated, consent-intersected, multi-tenant
    front door onto existing CrewPass crew/vessel/compliance data.
  version: 0.1.0
servers: []
security: []
paths:
  /api/v2/employers/me/crew/{crew_unique_id}/documents/{document_id}/download:
    get:
      tags:
        - employers
      summary: 'Short-TTL branded download link (scope: crew:documents:download)'
      description: >-
        Mint a short-TTL, CrewPass-hosted link to download a document's file.


        Consent-intersected on ``crew:documents:download``. 404 if the document
        is

        not the crew member's current version or the crew is off-fleet. The
        returned

        ``download_url`` is a branded proxy link (never a raw storage URL).
      operationId: >-
        crew_document_download_api_v2_employers_me_crew__crew_unique_id__documents__document_id__download_get
      parameters:
        - name: crew_unique_id
          in: path
          required: true
          schema:
            type: string
            title: Crew Unique Id
        - name: document_id
          in: path
          required: true
          schema:
            type: string
            title: Document Id
        - name: authorization
          in: header
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Authorization
        - name: X-Partner-API-Key
          in: header
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: X-Partner-Api-Key
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DocumentDownloadResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - PartnerApiKey: []
components:
  schemas:
    DocumentDownloadResponse:
      properties:
        document_id:
          type: string
          title: Document Id
        download_url:
          type: string
          title: Download Url
        expires_at:
          type: string
          format: date-time
          title: Expires At
        content_type:
          anyOf:
            - type: string
            - type: 'null'
          title: Content Type
        file_name:
          anyOf:
            - type: string
            - type: 'null'
          title: File Name
      type: object
      required:
        - document_id
        - download_url
        - expires_at
      title: DocumentDownloadResponse
      description: >-
        `GET …/documents/{document_id}/download` — a short-TTL branded link.


        ``download_url`` is a CrewPass-hosted proxy link (never a raw storage
        URL);

        the bytes are streamed from storage server-side when the link is
        followed.
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
  securitySchemes:
    PartnerApiKey:
      type: http
      scheme: bearer
      description: Partner API key (`cpk_live_*` / `cpk_test_*`) as a Bearer token.

````