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

# List documents

> List documents across all types (BILL, INVOICE, RECEIPT, PAYROLL_REPORT, etc.). Filter by `type` (one kind) or `types` (several, repeated or comma-separated), plus `lifecycle`, counterparty, integration details, or date range. Add `stage` — inbox, outstanding, or done, read per kind — to page one stage of them; omit it for every stage. Naming several kinds returns them grouped by kind in the order named, at one stage or at all of them. `counts` tallies all three stages whichever one is read; `countsByKind` counts the rows this list holds per kind — within `stage` when one is given, over every stage when none is. POSTED bills and invoices include `derivedSettlementStatus` and `derivedOutstandingAmount`; use those fields to find documents still awaiting payment.



## OpenAPI

````yaml /openapi.json get /api/documents
openapi: 3.1.0
info:
  title: Equated API
  version: 1.0.0
  description: >-
    Agent-facing accounting API. Authenticate with a bearer token issued from
    Settings → API Tokens, or via the in-app session cookie when called from the
    web client.
servers:
  - url: https://app.equated.co
    description: API server
security: []
paths:
  /api/documents:
    get:
      tags:
        - Documents
      summary: List documents
      description: >-
        List documents across all types (BILL, INVOICE, RECEIPT, PAYROLL_REPORT,
        etc.). Filter by `type` (one kind) or `types` (several, repeated or
        comma-separated), plus `lifecycle`, counterparty, integration details,
        or date range. Add `stage` — inbox, outstanding, or done, read per kind
        — to page one stage of them; omit it for every stage. Naming several
        kinds returns them grouped by kind in the order named, at one stage or
        at all of them. `counts` tallies all three stages whichever one is read;
        `countsByKind` counts the rows this list holds per kind — within `stage`
        when one is given, over every stage when none is. POSTED bills and
        invoices include `derivedSettlementStatus` and
        `derivedOutstandingAmount`; use those fields to find documents still
        awaiting payment.
      parameters:
        - schema:
            type: string
            enum:
              - UNKNOWN
              - RECEIPT
              - REIMBURSEMENT
              - BILL
              - INVOICE
              - PAYROLL_REPORT
              - SETTLEMENT_REPORT
              - SHOPIFY_TRANSACTION
              - SHOPIFY_ORDER
              - SQUARE_PAYMENT
            description: One kind. Shorthand for a `types` naming it alone.
          required: false
          description: One kind. Shorthand for a `types` naming it alone.
          name: type
          in: query
        - schema:
            anyOf:
              - type: string
              - type: array
                items:
                  type: string
            description: >-
              Document kinds to list together, repeated or comma-separated.
              Replaces `type`.
          required: false
          description: >-
            Document kinds to list together, repeated or comma-separated.
            Replaces `type`.
          name: types
          in: query
        - schema:
            type: string
            enum:
              - inbox
              - outstanding
              - done
            description: >-
              inbox (awaiting work), outstanding (confirmed, still owed or
              owing), or done, read per kind. Omit for every stage.
          required: false
          description: >-
            inbox (awaiting work), outstanding (confirmed, still owed or owing),
            or done, read per kind. Omit for every stage.
          name: stage
          in: query
        - schema:
            type: string
          required: false
          name: lifecycle
          in: query
        - schema:
            type: string
            enum:
              - 'true'
              - 'false'
          required: false
          name: is_matched
          in: query
        - schema:
            type: string
            enum:
              - unresolved
              - matched
            description: >-
              Receipts: unresolved (inbox — not linked to a transaction) or
              matched (linked to one).
          required: false
          description: >-
            Receipts: unresolved (inbox — not linked to a transaction) or
            matched (linked to one).
          name: resolution
          in: query
        - schema:
            type: string
          required: false
          name: integration_kind
          in: query
        - schema:
            type: number
            nullable: true
          required: false
          name: integration_id
          in: query
        - schema:
            type: integer
            minimum: 0
            exclusiveMinimum: true
          required: false
          name: org_merchant_id
          in: query
        - schema:
            type: string
          required: false
          name: date_from
          in: query
        - schema:
            type: string
          required: false
          name: date_to
          in: query
        - schema:
            anyOf:
              - type: string
              - type: array
                items:
                  type: string
          required: false
          name: ai_typenames
          in: query
        - schema:
            type: number
            minimum: 1
            maximum: 200
            default: 50
          required: false
          name: limit
          in: query
        - schema:
            type: number
            nullable: true
            minimum: 0
            default: 0
          required: false
          name: offset
          in: query
      responses:
        '200':
          description: Documents matching the filter
          content:
            application/json:
              schema:
                type: object
                properties:
                  documents:
                    type: array
                    items:
                      $ref: '#/components/schemas/Document'
                  total:
                    type: integer
                    minimum: 0
                  counts:
                    type: object
                    properties:
                      inbox:
                        type: integer
                        minimum: 0
                      outstanding:
                        type: integer
                        minimum: 0
                      done:
                        type: integer
                        minimum: 0
                      all:
                        type: integer
                        minimum: 0
                    required:
                      - inbox
                      - outstanding
                      - done
                      - all
                  countsByKind:
                    type: object
                    additionalProperties:
                      type: integer
                      minimum: 0
                required:
                  - documents
                  - total
                  - counts
                  - countsByKind
      security:
        - bearerAuth: []
components:
  schemas:
    Document:
      type: object
      properties:
        id:
          type: integer
          minimum: 0
          exclusiveMinimum: true
        documentType:
          type: string
        lifecycle:
          type: string
        amount:
          type: string
          nullable: true
        currency:
          type: string
          nullable: true
        displayTitle:
          type: string
          nullable: true
        documentNumber:
          type: string
          nullable: true
        dueDate:
          type: string
          nullable: true
        createdAt:
          type: string
        orgMerchantId:
          type: integer
          nullable: true
          minimum: 0
          exclusiveMinimum: true
        orgMerchant:
          type: object
          nullable: true
          properties:
            id:
              type: integer
              minimum: 0
              exclusiveMinimum: true
            name:
              type: string
            website:
              type: string
              nullable: true
            imageUrl:
              type: string
              nullable: true
            logo:
              type: string
              nullable: true
          required:
            - id
            - name
            - website
            - imageUrl
            - logo
          additionalProperties:
            nullable: true
        amountBase:
          type: string
          nullable: true
        baseCurrency:
          type: string
          nullable: true
        derivedSettlementStatus:
          $ref: '#/components/schemas/SettlementStatus'
        derivedOutstandingAmount:
          type: string
          nullable: true
          description: Unapplied balance in the document currency.
        payerAccountId:
          type: integer
          nullable: true
          minimum: 0
          exclusiveMinimum: true
          description: >-
            Reimbursement liability/equity payer account; retained on unconfirm
            and null until selected.
        resolution:
          type: string
          nullable: true
          enum:
            - unresolved
            - matched
            - null
          description: >-
            Receipts only: unresolved (not linked to a transaction) or matched
            (linked to one); null for other document types.
      required:
        - id
        - documentType
        - lifecycle
        - amount
        - currency
        - displayTitle
      additionalProperties:
        nullable: true
    SettlementStatus:
      type: string
      enum:
        - open
        - partially_closed
        - closed
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: API token issued from the Equated app under Settings → API Tokens.

````