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

# GET /document/public/get

> Public or credential-gated document access; see route handler. Query parameters inferred from handler; see source for edge cases.



## OpenAPI

````yaml /api-reference/trust-accounting/openapi.json get /document/public/get
openapi: 3.0.3
info:
  title: Stax API (stack, tpa, document)
  description: >-
    Routes under /stack, /tpa, and /document. Parameters and JSON bodies are
    inferred from Express handlers; multipart and streaming responses are called
    out explicitly. Session auth uses cookies userId + authToken or headers
    x-user-id + x-auth-token; API keys use Authorization.
  version: 1.0.0
servers:
  - url: /
    description: Relative to API host
security: []
tags:
  - name: stack
    description: Stack (workspace) operations
  - name: tpa
    description: Trust plan accounting (TPA)
  - name: document
    description: Document operations
paths:
  /document/public/get:
    get:
      tags:
        - document
      summary: GET /document/public/get
      description: >-
        Public or credential-gated document access; see route handler. Query
        parameters inferred from handler; see source for edge cases.
      operationId: get_document_public_get
      parameters:
        - name: fill
          in: query
          schema:
            type: string
          required: false
        - name: minimal
          in: query
          schema:
            oneOf:
              - type: boolean
              - type: string
            description: Boolean or string literal such as "true"
          required: false
        - name: presigned
          in: query
          schema:
            oneOf:
              - type: boolean
              - type: string
            description: Boolean or string literal such as "true"
          required: false
      responses:
        '200':
          description: JSON response
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                  doc:
                    $ref: '#/components/schemas/Document'
                additionalProperties: true
        '401':
          description: Not authorized
      security: []
components:
  schemas:
    Document:
      type: object
      description: Document record (subset; many optional fields exist in storage)
      properties:
        _id:
          $ref: '#/components/schemas/ObjectId'
        team:
          $ref: '#/components/schemas/ObjectId'
        stack:
          $ref: '#/components/schemas/ObjectId'
        name:
          type: string
        originalName:
          type: string
        format:
          type: string
        download:
          type: string
          nullable: true
        thumbnail:
          type: string
        source:
          type: string
        sourceUrl:
          type: string
        pages:
          type: array
          items:
            type: string
        job:
          type: object
          additionalProperties: true
        urgent:
          type: boolean
        deadline:
          $ref: '#/components/schemas/ISODateString'
        flagged:
          type: boolean
        pinned:
          type: boolean
        flags:
          type: array
          items:
            type: object
            additionalProperties: true
        reviewed:
          type: boolean
        archived:
          type: boolean
        assignee:
          $ref: '#/components/schemas/ObjectId'
        sharing:
          type: object
          additionalProperties: true
        checksum:
          type: string
        metadata:
          type: array
          items:
            type: object
            additionalProperties: true
        fillable:
          type: object
          additionalProperties: true
        keywords:
          type: array
          items:
            type: string
        bounds:
          type: array
          items:
            type: object
            additionalProperties: true
        tables:
          type: array
          items:
            type: object
            additionalProperties: true
        split:
          type: array
          items:
            type: object
            additionalProperties: true
        notes:
          type: array
          items:
            type: object
            additionalProperties: true
        canvas:
          type: object
          additionalProperties: true
        bulk:
          type: boolean
        original:
          $ref: '#/components/schemas/ObjectId'
        splitFrom:
          $ref: '#/components/schemas/ObjectId'
        attachments:
          type: array
          items:
            type: object
            additionalProperties: true
        time:
          type: array
          items:
            type: object
            additionalProperties: true
        viewed:
          type: object
          additionalProperties: true
        sync:
          type: array
          items:
            type: object
            additionalProperties: true
        receivedOn:
          $ref: '#/components/schemas/ISODateString'
        lastModified:
          $ref: '#/components/schemas/ISODateString'
        nextStack:
          $ref: '#/components/schemas/ObjectId'
        sender:
          type: string
        words:
          type: array
          items:
            type: object
            additionalProperties: true
        downloadUrl:
          type: string
        wordsUrl:
          type: string
      additionalProperties: true
    ObjectId:
      type: string
      pattern: ^[a-fA-F0-9]{24}$
      description: 24-character hexadecimal MongoDB ObjectId
    ISODateString:
      type: string
      format: date-time
      description: ISO-8601 timestamp

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.