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

# Get a document

> One document with what was read from it: its facts (with page and box), the balances it proposed, and the accounts it made or fed.



## OpenAPI

````yaml /openapi/advisor.json get /clients/{client}/documents/{document}
openapi: 3.1.0
info:
  title: Redbark Advisor API
  version: 2.0.0
  description: >-
    Read and write access to one advice firm in Redbark Advisor: clients,
    checklists, documents, money, messages, reports, team and webhooks. Send an
    API key or a connected app’s access token as a bearer token. A credential
    carries scopes, one read and one write per area, and each call says the
    scope it needs. A write scope brings its read scope. Each key may make 120
    requests a minute.
servers:
  - url: https://advisor.redbark.com/api/v1
security:
  - bearerAuth: []
tags:
  - name: Firm
    description: The firm, its name and its branding.
  - name: Team
    description: Team members and their roles.
  - name: Clients
    description: Clients, their people and portal invites.
  - name: Checklists
    description: Checklist templates, the checklists sent to clients and their answers.
  - name: Documents
    description: Documents clients upload and the details read from them.
  - name: Money
    description: Bank connections, accounts, balances and transactions.
  - name: Document types
    description: Document types, their fields and the client facts they fill.
  - name: Messages
    description: Messages between the firm and clients.
  - name: Reports
    description: Reports exported for clients.
  - name: Webhooks
    description: Webhook endpoints and their deliveries.
  - name: Webhook events
    description: Events sent to your webhook endpoints.
paths:
  /clients/{client}/documents/{document}:
    get:
      tags:
        - Documents
      summary: Get a document
      description: >-
        One document with what was read from it: its facts (with page and box),
        the balances it proposed, and the accounts it made or fed.
      operationId: get_document
      parameters:
        - name: client
          in: path
          required: true
          schema:
            type: string
            minLength: 1
            maxLength: 60
            description: The client id, from list_clients.
        - name: document
          in: path
          required: true
          schema:
            type: string
            minLength: 1
            maxLength: 60
            description: The document id, from list_documents.
      responses:
        '200':
          description: Success.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DocumentDetail'
        '400':
          description: The request is not valid.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '401':
          description: The API key or access token is missing, wrong, expired or revoked.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '402':
          description: >-
            subscription_required: the firm has no active subscription, so it
            cannot add or invite clients or send checklists.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '403':
          description: >-
            The credential lacks the scope this call needs, the call is for
            admins only, or the member it acts as has left the firm.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: No such resource in this firm.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '409':
          description: >-
            The resource is in a state that does not allow this, such as an
            archived client, or client_limit_reached: the plan’s 20 active
            clients are in use.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '413':
          description: The request body is too large.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '429':
          description: Too many requests. See the Retry-After header.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '500':
          description: Something went wrong on our side. Try again.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
      security:
        - bearerAuth:
            - documents:read
components:
  schemas:
    DocumentDetail:
      type: object
      properties:
        object:
          type: string
          enum:
            - document
        id:
          type: string
        file_name:
          type: string
        mime_type:
          type: string
        size_bytes:
          type: number
        status:
          type: string
          enum:
            - uploaded
            - reading
            - read
            - unreadable
            - replaced
          description: >-
            uploaded (waiting to be read), reading, read, unreadable, or
            replaced by a newer upload.
        doc_type:
          anyOf:
            - type: string
            - type: 'null'
          description: >-
            The kind of document, such as super_statement or payslip. Null until
            read.
        doc_type_label:
          anyOf:
            - type: string
            - type: 'null'
        statement_date:
          anyOf:
            - type: string
            - type: 'null'
          description: The date the document carries, YYYY-MM-DD.
        page_count:
          anyOf:
            - type: number
            - type: 'null'
        failure:
          anyOf:
            - type: string
            - type: 'null'
          description: Why it could not be read, in words for the client.
        uploaded_by:
          anyOf:
            - type: object
              properties:
                kind:
                  type: string
                  enum:
                    - person
                    - member
                id:
                  type: string
                name:
                  anyOf:
                    - type: string
                    - type: 'null'
              required:
                - kind
                - id
                - name
              additionalProperties: true
            - type: 'null'
        checklist_item_id:
          anyOf:
            - type: string
            - type: 'null'
        replaced_by_id:
          anyOf:
            - type: string
            - type: 'null'
        facts_proposed:
          type: number
        facts_accepted:
          type: number
        review_status:
          type: string
          enum:
            - reading
            - to_review
            - choose_type
            - couldnt_read
            - approved
            - filed
            - sent_back
          description: >-
            Where the firm’s review stands: reading, to_review (values wait for
            approval), choose_type (we could not tell what it is), couldnt_read,
            approved, filed (kept as a file only) or sent_back.
        values_read:
          type: number
          description: How many values were read from it.
        values_to_review:
          type: number
          description: Values waiting for approval.
        values_to_check:
          type: number
          description: >-
            Values waiting that were read with low confidence and are checked
            first.
        created_at:
          type: string
          description: An ISO 8601 time in UTC.
        read_at:
          anyOf:
            - type: string
              description: An ISO 8601 time in UTC.
            - type: 'null'
        reviewed_at:
          anyOf:
            - type: string
              description: An ISO 8601 time in UTC.
            - type: 'null'
        facts:
          type: array
          items:
            $ref: '#/components/schemas/Fact'
        balances:
          type: array
          items:
            $ref: '#/components/schemas/Balance'
        account_ids:
          type: array
          items:
            type: string
          description: The accounts this document made or fed, for get_account.
      required:
        - object
        - id
        - file_name
        - mime_type
        - size_bytes
        - status
        - doc_type
        - doc_type_label
        - statement_date
        - page_count
        - failure
        - uploaded_by
        - checklist_item_id
        - replaced_by_id
        - facts_proposed
        - facts_accepted
        - review_status
        - values_read
        - values_to_review
        - values_to_check
        - created_at
        - read_at
        - reviewed_at
        - facts
        - balances
        - account_ids
      additionalProperties: true
    Error:
      type: object
      properties:
        error:
          type: object
          properties:
            type:
              type: string
              enum:
                - invalid_request_error
                - authentication_error
                - permission_error
                - rate_limit_error
                - api_error
            code:
              type: string
            message:
              type: string
            param:
              anyOf:
                - type: string
                - type: 'null'
            request_id:
              type: string
          required:
            - type
            - code
            - message
            - param
            - request_id
          additionalProperties: true
      required:
        - error
      additionalProperties: true
    Fact:
      type: object
      properties:
        object:
          type: string
          enum:
            - fact
        id:
          type: string
        key:
          type: string
          description: Such as person.address or person.salary.
        label:
          type: string
        value:
          type: string
          description: Dates are YYYY-MM-DD and amounts are dollars with two decimals.
        read_value:
          anyOf:
            - type: string
            - type: 'null'
          description: The value as read, when a member changed it.
        status:
          type: string
          enum:
            - proposed
            - accepted
            - rejected
        superseded:
          type: boolean
        document_id:
          anyOf:
            - type: string
            - type: 'null'
        page:
          anyOf:
            - type: number
            - type: 'null'
        box:
          anyOf:
            - type: object
              properties:
                left:
                  type: number
                top:
                  type: number
                width:
                  type: number
                height:
                  type: number
              required:
                - left
                - top
                - width
                - height
              additionalProperties: true
              description: Where on the page, as fractions of its width and height.
            - type: 'null'
        created_at:
          type: string
          description: An ISO 8601 time in UTC.
        decided_at:
          anyOf:
            - type: string
              description: An ISO 8601 time in UTC.
            - type: 'null'
      required:
        - object
        - id
        - key
        - label
        - value
        - read_value
        - status
        - superseded
        - document_id
        - page
        - box
        - created_at
        - decided_at
      additionalProperties: true
    Balance:
      type: object
      properties:
        object:
          type: string
          enum:
            - balance
        id:
          type: string
        account_id:
          type: string
        amount_cents:
          type: number
          description: Negative for what is owed.
        as_at:
          type: string
          description: An ISO 8601 time in UTC.
        status:
          type: string
          enum:
            - proposed
            - accepted
        document_id:
          anyOf:
            - type: string
            - type: 'null'
      required:
        - object
        - id
        - account_id
        - amount_cents
        - as_at
        - status
        - document_id
      additionalProperties: true
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        A firm API key, shown once when it is made, or a connected app’s OAuth
        access token. Each operation lists the scope it needs, such as
        clients:write.

````

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