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

# Get person documents

> Retrieve a paginated list of documents (resumes, cover letters, transcripts, work samples, assessments, etc.) for a person. Each document includes a short-lived signed download URL that expires in minutes — re-fetch if the link expires. Pass include_text=true to also receive extracted plain-text content for reading or summarizing document contents. Optionally filter to specific document types via document_types (comma-separated type keys).



## OpenAPI

````yaml /api-reference/openapi-v1.json get /v1/persons/{id}/documents
openapi: 3.1.0
info:
  title: Stardex API (v1)
  version: 1.0.0
  description: >-
    Stardex ATS API — manage candidates, jobs, companies, and recruiting
    workflows.
servers:
  - url: https://api.stardex.ai
    description: Production API server
security:
  - bearerAuth: []
tags:
  - name: Persons
    description: Manage person records — contacts, work history, and custom fields.
  - name: Jobs
    description: Manage job postings — pipeline stages, team members, and custom fields.
  - name: Candidates
    description: Manage candidate records and pipeline stage transitions.
  - name: Companies
    description: Browse and retrieve company records.
  - name: Lists
    description: Create, search, and retrieve saved person and company lists.
  - name: Person Activities
    description: Create and manage activity records (notes, emails, meetings) for persons.
  - name: Team Members
    description: List team members for use in search filters and assignments.
  - name: Custom Fields
    description: Retrieve custom field definitions and tag options for search filters.
paths:
  /v1/persons/{id}/documents:
    get:
      tags:
        - Persons
      summary: Get person documents
      description: >-
        Retrieve a paginated list of documents (resumes, cover letters,
        transcripts, work samples, assessments, etc.) for a person. Each
        document includes a short-lived signed download URL that expires in
        minutes — re-fetch if the link expires. Pass include_text=true to also
        receive extracted plain-text content for reading or summarizing document
        contents. Optionally filter to specific document types via
        document_types (comma-separated type keys).
      operationId: getPersonDocuments
      parameters:
        - in: path
          name: id
          required: true
          schema:
            type: string
            description: Person ID
        - schema:
            type:
              - integer
              - 'null'
            minimum: 0
            default: 0
            description: Records to skip for pagination. Defaults to 0.
          required: false
          name: offset
          in: query
        - schema:
            type: integer
            minimum: 1
            maximum: 100
            default: 100
            description: Max records per page (1–100). Defaults to 100.
          required: false
          name: limit
          in: query
        - schema:
            type:
              - boolean
              - 'null'
            default: false
            description: >-
              When true, each document includes its extracted plain-text content
              (text_content, char_count, truncated). Useful for reading resumes,
              cover letters, transcripts, etc. Omit or pass false to receive
              only metadata and signed download links.
          required: false
          name: include_text
          in: query
        - schema:
            type: string
            description: >-
              Comma-separated list of document type keys to filter by. Seeded
              values: resume_doc, resume_link, cover_letter, reference,
              additional_links, transcript, work_sample, offer_letter,
              assessment, other. Omit to return all types.
          required: false
          name: document_types
          in: query
      responses:
        '200':
          description: Documents fetched
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PersonDocumentsResponse'
              example:
                success: true
                data:
                  - created_at: '2024-02-01T10:00:00Z'
                    updated_at: '2024-02-02T12:00:00Z'
                    type: resume_doc
                    title: John_Doe_Resume.pdf
                    link: https://signed-url.example.com/...
                    text_content: |-
                      John Doe
                      Software Engineer

                      Experience
                      Senior Engineer at Acme Corp (2020–Present)
                      - Led platform migration...
                    char_count: 112
                    truncated: false
                  - created_at: '2024-01-15T09:30:00Z'
                    updated_at: '2024-01-15T09:30:00Z'
                    type: cover_letter
                    title: Cover_Letter.pdf
                    link: https://signed-url.example.com/...
                    text_content: >-
                      Dear Hiring Manager, I am excited to apply for the Senior
                      Engineer role...
                    char_count: 76
                    truncated: false
                meta:
                  total: 2
                  offset: 0
                  limit: 20
        '400':
          description: Validation error
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    enum:
                      - false
                    description: Always false for error responses.
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        description: >-
                          Machine-readable error code (e.g. "VALIDATION_ERROR",
                          "NOT_FOUND").
                      message:
                        type: string
                        description: Human-readable error description.
                    required:
                      - code
                      - message
                required:
                  - success
                  - error
        '404':
          description: Resource not found
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    enum:
                      - false
                    description: Always false for error responses.
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        description: >-
                          Machine-readable error code (e.g. "VALIDATION_ERROR",
                          "NOT_FOUND").
                      message:
                        type: string
                        description: Human-readable error description.
                    required:
                      - code
                      - message
                required:
                  - success
                  - error
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    enum:
                      - false
                    description: Always false for error responses.
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        description: >-
                          Machine-readable error code (e.g. "VALIDATION_ERROR",
                          "NOT_FOUND").
                      message:
                        type: string
                        description: Human-readable error description.
                    required:
                      - code
                      - message
                required:
                  - success
                  - error
components:
  schemas:
    PersonDocumentsResponse:
      type: object
      properties:
        success:
          type: boolean
          enum:
            - true
        data:
          type: array
          items:
            $ref: '#/components/schemas/PersonDocument'
        meta:
          type: object
          properties:
            total:
              type: number
              description: Total matching records across all pages.
            offset:
              type: number
              description: Current pagination offset.
            limit:
              type: number
              description: Page size used for this request.
          required:
            - total
            - offset
            - limit
      required:
        - success
        - data
        - meta
    PersonDocument:
      type: object
      properties:
        created_at:
          type: string
          description: ISO 8601 upload timestamp.
        updated_at:
          type: string
          description: ISO 8601 last-modified timestamp.
        type:
          type: string
          description: Document type (e.g. "resume", "cover_letter", "other").
        title:
          type:
            - string
            - 'null'
          description: File name or document title.
        link:
          type: string
          description: >-
            Short-lived signed download URL. Expires in minutes; re-fetch if
            needed.
        text_content:
          type:
            - string
            - 'null'
          description: >-
            Extracted plain-text content of the document. Only present when
            include_text=true was passed. May be truncated if the document
            exceeds the per-entry character cap.
        char_count:
          type: number
          description: >-
            Number of characters in the returned text_content. Only present when
            include_text=true.
        truncated:
          type: boolean
          description: >-
            True if text_content was trimmed due to character limits. Only
            present when include_text=true.
      required:
        - created_at
        - updated_at
        - type
        - title
        - link
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: >-
        Authenticate with a Bearer token: API key, OAuth token, or session
        token.

````