---
title: "Every expense, the supplier invoices behind them and the mortgages"
method: GET
path: "/api/v1/expenses"
tags: ["Money"]
---

# Every expense, the supplier invoices behind them and the mortgages

`GET /api/v1/expenses`

## Request

- Base URL: `http://localhost:5180`
- URL: `http://localhost:5180/api/v1/expenses`
- Auth: API key in cookie `better-auth.session_token`

One page of each of the three lists, in primary key order. `limit` and `offset` move the window on all three at once, and `totals` says how many of each exist, so a client reads whichever list it cares about a page at a time until that total is reached. Every amount is integer cents. A loan secured on one lot carries a `unitId`, so it is never counted twice at building level.

## Query parameters

- `limit` integer
- `offset` integer

## Response `200`

Expenses, supplier invoices and mortgages.

- object
  - `ok` unknown, required
  - `data` object, required
    - `expenses` object[], required: What was spent. `treatment` decides whether it is deductible in-year or depreciated, and `chargeability` whether any of it is recoverable from a tenant.
      - `id` string, required: Stable record id, e.g. `lse_012`.
      - `teamId` string, required: Stable record id, e.g. `lse_012`.
      - `buildingId` string: Stable record id, e.g. `lse_012`.
      - `unitId` string: Stable record id, e.g. `lse_012`.
      - `category` string, required
      - `treatment` 'opex' | 'capex', required: OPEX is deductible in-year; CAPEX is depreciated.
      - `description` string, required
      - `date` string, required: A calendar date, `YYYY-MM-DD`.
      - `netAmount` integer, required: Money, always in integer cents. €1,250.00 is 125000.
      - `vatAmount` integer, required: Money, always in integer cents. €1,250.00 is 125000.
      - `total` integer, required: Money, always in integer cents. €1,250.00 is 125000.
      - `vatRecoverable` boolean, required
      - `chargeability` 'owner_only' | 'tenant_recoverable' | 'split', required: Whether any of this is rechargeable to the tenant through service charges.
      - `paidOn` string: A calendar date, `YYYY-MM-DD`.
    - `supplierInvoices` object[], required: The paper behind the spend. `quoteVariance` is the gap against the accepted quote, which is what decides whether payment needs approving first.
      - `id` string, required: Stable record id, e.g. `lse_012`.
      - `contractorId` string: Stable record id, e.g. `lse_012`.
      - `supplierName` string, required
      - `workOrderId` string: Stable record id, e.g. `lse_012`.
      - `number` string, required
      - `issueDate` string, required: A calendar date, `YYYY-MM-DD`.
      - `dueDate` string, required: A calendar date, `YYYY-MM-DD`.
      - `netAmount` integer, required: Money, always in integer cents. €1,250.00 is 125000.
      - `vatAmount` integer, required: Money, always in integer cents. €1,250.00 is 125000.
      - `total` integer, required: Money, always in integer cents. €1,250.00 is 125000.
      - `status` 'received' | 'matched' | 'disputed' | 'approved' | 'paid', required
      - `quoteVariance` integer: The gap against the accepted quote. It decides whether this needs approval before payment.
      - `documentId` string: Stable record id, e.g. `lse_012`.
      - `expenseId` string: Stable record id, e.g. `lse_012`.
      - `provenance` object, required
        - `actor` object, required
          - `kind` 'owner' | 'ai' | 'tenant' | 'contractor' | 'system' | 'channel', required: `ai` is Dardaris acting on the owner’s behalf. Everything it touches is marked.
          - `id` string: Stable record id, e.g. `lse_012`.
          - `name` string, required
        - `at` string, required: ISO 8601 timestamp.
        - `workflowRunId` string: Set when an automated run produced this, linking the record back to the run.
        - `reasoning` string: The rationale the AI recorded at the moment it acted.
    - `mortgages` object[], required: The loans secured on the portfolio. Only the interest half of `currentSplit` is a cost, the principal half is repayment.
      - `id` string, required: Stable record id, e.g. `lse_012`.
      - `buildingId` string, required: Stable record id, e.g. `lse_012`.
      - `unitId` string: Set when the loan is secured on one lot, so a unit loan is never counted twice at building level.
      - `lender` string, required
      - `reference` string
      - `principal` integer, required: Money, always in integer cents. €1,250.00 is 125000.
      - `outstanding` integer, required: Money, always in integer cents. €1,250.00 is 125000.
      - `interestRate` number, required: A decimal ratio. 0.21 is 21%.
      - `rateType` 'fixed' | 'variable' | 'mixed', required
      - `startDate` string, required: A calendar date, `YYYY-MM-DD`.
      - `termMonths` number, required
      - `monthlyPayment` integer, required: Money, always in integer cents. €1,250.00 is 125000.
      - `deferralMonths` number: Months at the start with nothing repaid; their simple interest, before tax, is added to the principal.
      - `interestVat` number: Tax charged on the interest of every instalment, as a ratio (0.10 for Morocco). The instalment is worked at the rate times one plus this.
      - `kind` 'bank' | 'plan': `plan` is a payment plan of dates and amounts with no interest; absent is a bank credit.
      - `instalments` object[]: A payment plan’s instalments, each counted as paid once its date has come.
        - `id` string, required: Stable record id, e.g. `lse_012`.
        - `dueDate` string, required: A calendar date, `YYYY-MM-DD`.
        - `amount` integer, required: Money, always in integer cents. €1,250.00 is 125000.
      - `currentSplit` object: This month’s payment split, recomputed from the amortisation schedule. Only the interest half is deductible.
        - `interest` integer, required: Money, always in integer cents. €1,250.00 is 125000.
        - `principal` integer, required: Money, always in integer cents. €1,250.00 is 125000.
      - `nextReviewDate` string: A calendar date, `YYYY-MM-DD`.
    - `limit` number, required: The page size this response was actually read at, which is `limit` capped at 200.
    - `offset` number, required: The offset each of the three lists was read at.
    - `totals` object, required: How many rows exist of each, not how many came back. Every one of them is reachable through `offset`.
      - `expenses` number, required
      - `supplierInvoices` number, required
      - `mortgages` number, required
  - `meta` object, required
    - `requestId` string, required: Echoed in the x-request-id header. Quote it in a bug report.

## Other responses

- `400`: `limit` or `offset` is out of range.

---

[API](https://skmtc.dev/dardaris/apis/dardaris-api.md) · [All operations](https://skmtc.dev/dardaris/apis/dardaris-api/llms.txt) · [OpenAPI document](https://skmtc.dev/dardaris/apis/dardaris-api/revisions/4aff33835c73?raw)
