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

# Outstanding payables

> Everything the organisation owes (bills in Approved or Scheduled), aged into buckets and grouped by supplier, with per-currency totals, an in-review pipeline figure, and a recommendation.



## OpenAPI

````yaml /api-reference/openapi.json get /payables/outstanding
openapi: 3.1.1
info:
  title: Dolfin API
  description: >-
    Dolfin API for AR & AP. Authenticate using the `x-dolfin-api-key` header
    with the API key distributed to your organisation.
  version: v1
servers:
  - url: https://api.dolfinai.co
    description: Production
security:
  - {}
tags:
  - name: Webhooks
  - name: Users
  - name: TaxRates
  - name: Suppliers
  - name: Supplier Credit Notes
  - name: Bills
  - name: SpendCategories
  - name: Payables
  - name: RecurringInvoices
  - name: Receivables
  - name: Purchase Orders
  - name: Products
  - name: Payments
  - name: Invoices
  - name: Organisations
  - name: Members
  - name: MCP
  - name: Matching
  - name: Invoice Reminders
  - name: Industries
  - name: Gmail
  - name: Delivery Notes
  - name: Customers
  - name: Currencies
  - name: Credit Notes
  - name: Clients
  - name: ClientInvites
  - name: BankPayments
  - name: Bank details
  - name: Auth
  - name: ApprovalPolicies
  - name: ApiKeys
  - name: Agent
paths:
  /payables/outstanding:
    get:
      tags:
        - Payables
      summary: Outstanding payables
      description: >-
        Everything the organisation owes (bills in Approved or Scheduled), aged
        into buckets and grouped by supplier, with per-currency totals, an
        in-review pipeline figure, and a recommendation.
      parameters:
        - name: asOf
          in: query
          schema:
            type: string
            format: date
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OutstandingPayablesResponse'
components:
  schemas:
    OutstandingPayablesResponse:
      required:
        - totals
        - recommendation
      type: object
      properties:
        asOf:
          type: string
          format: date
        totals:
          $ref: '#/components/schemas/OutstandingPayablesTotals'
        aging:
          type: array
          items:
            $ref: '#/components/schemas/CurrencyAging'
        suppliers:
          type: array
          items:
            $ref: '#/components/schemas/OutstandingSupplierRow'
          description: >-
            One row per supplier per currency — a supplier billing in multiple
            currencies appears once per currency. Amounts are never summed
            across currencies. Org default currency rows first, largest to-pay
            first within each currency.
        recommendation:
          $ref: '#/components/schemas/Recommendation'
    OutstandingPayablesTotals:
      type: object
      properties:
        supplierCount:
          pattern: ^-?(?:0|[1-9]\d*)$
          type:
            - integer
            - string
          description: >-
            Distinct suppliers with bills to pay. May be lower than the number
            of Suppliers rows, which are per (supplier, currency).
          format: int32
        billCount:
          pattern: ^-?(?:0|[1-9]\d*)$
          type:
            - integer
            - string
          format: int32
        toPayByCurrency:
          type: array
          items:
            $ref: '#/components/schemas/CurrencyTotal'
          description: >-
            Committed liability: bills in Approved or Scheduled. Bills still in
            review are NOT included — see InReviewByCurrency.
        notYetDueByCurrency:
          type: array
          items:
            $ref: '#/components/schemas/CurrencyTotal'
        overdueByCurrency:
          type: array
          items:
            $ref: '#/components/schemas/CurrencyTotal'
        dueWithin7DaysByCurrency:
          type: array
          items:
            $ref: '#/components/schemas/CurrencyTotal'
          description: >-
            Subset of NotYetDue falling due within the next 7 days — the cash
            about to go out.
        inReviewByCurrency:
          type: array
          items:
            $ref: '#/components/schemas/CurrencyTotal'
          description: >-
            Bills in PendingReview or NeedsApproval — pipeline, not yet a
            committed liability. Never part of ToPay.
    CurrencyAging:
      required:
        - currency
        - buckets
      type: object
      properties:
        currency:
          type: string
        buckets:
          $ref: '#/components/schemas/AgingBuckets'
    OutstandingSupplierRow:
      required:
        - supplierName
        - currency
      type: object
      properties:
        supplierId:
          type:
            - 'null'
            - string
          description: >-
            Null when OCR extracted a supplier name but no Supplier record was
            ever matched — suggest fixing the match rather than ignoring the
            bill.
          format: uuid
        supplierName:
          type: string
        currency:
          type: string
        totalToPay:
          pattern: ^-?(?:0|[1-9]\d*)(?:\.\d+)?$
          type:
            - number
            - string
          format: double
        overdueAmount:
          pattern: ^-?(?:0|[1-9]\d*)(?:\.\d+)?$
          type:
            - number
            - string
          format: double
        notYetDueAmount:
          pattern: ^-?(?:0|[1-9]\d*)(?:\.\d+)?$
          type:
            - number
            - string
          format: double
        billCount:
          pattern: ^-?(?:0|[1-9]\d*)$
          type:
            - integer
            - string
          format: int32
        maxDaysOverdue:
          pattern: ^-?(?:0|[1-9]\d*)$
          type:
            - integer
            - string
          format: int32
        oldestBill:
          oneOf:
            - type: 'null'
            - $ref: '#/components/schemas/BillSummary'
        billIds:
          type: array
          items:
            type: string
            format: uuid
    Recommendation:
      required:
        - headline
        - action
      type: object
      properties:
        headline:
          type: string
        action:
          type: string
          description: review_overdue | none
        nextTool:
          type:
            - 'null'
            - string
    CurrencyTotal:
      required:
        - currency
        - amount
        - count
      type: object
      properties:
        currency:
          type: string
        amount:
          pattern: ^-?(?:0|[1-9]\d*)(?:\.\d+)?$
          type:
            - number
            - string
          format: double
        count:
          pattern: ^-?(?:0|[1-9]\d*)$
          type:
            - integer
            - string
          description: Invoices for receivables, bills for payables.
          format: int32
    AgingBuckets:
      type: object
      properties:
        current:
          $ref: '#/components/schemas/AgingBucket'
          description: Issued but not yet due.
        d1To30:
          $ref: '#/components/schemas/AgingBucket'
        d31To60:
          $ref: '#/components/schemas/AgingBucket'
        d61To90:
          $ref: '#/components/schemas/AgingBucket'
        d90Plus:
          $ref: '#/components/schemas/AgingBucket'
    BillSummary:
      required:
        - state
      type: object
      properties:
        billId:
          type: string
          format: uuid
        invoiceNumber:
          type:
            - 'null'
            - string
        totalAmount:
          pattern: ^-?(?:0|[1-9]\d*)(?:\.\d+)?$
          type:
            - number
            - string
          format: double
        dueDate:
          type:
            - 'null'
            - string
          format: date
        daysOverdue:
          pattern: ^-?(?:0|[1-9]\d*)$
          type:
            - integer
            - string
          format: int32
        state:
          type: string
    AgingBucket:
      type: object
      properties:
        amount:
          pattern: ^-?(?:0|[1-9]\d*)(?:\.\d+)?$
          type:
            - number
            - string
          format: double
        count:
          pattern: ^-?(?:0|[1-9]\d*)$
          type:
            - integer
            - string
          description: Invoices for receivables, bills for payables.
          format: int32

````