Skip to content

API Reference

The Flask API serves data to the dashboard and can be used directly for custom reporting. All endpoints return JSON.

Transactions

MethodEndpointDescription
GET/api/transactionsList transactions with filters
PATCH/api/transactions/<id>Update category, notes or reviewed flag
PATCH/api/transactions/<id>/splitOverride business split percentage

GET /api/transactions

Query parameters:

ParamDescription
fromStart date (YYYY-MM-DD)
toEnd date (YYYY-MM-DD)
categoryFilter by category name
accountFilter by account name
searchSearch description (LIKE match)
exclude_loansExclude loan accounts (default: true)
exclude_transfersExclude transfer transactions (default: true)
limitMax results

Each Uncategorized row (up to the first 300) carries suggestions: up to three categories from the most similar filed merchants, each with a score (its share of their similarity-weighted vote). Other rows have an empty list.

Example:

Terminal window
curl "http://localhost:5050/api/transactions?from=2025-01-01&category=Groceries&limit=50"

PATCH /api/transactions/<id>

Update a transaction’s category, notes, or reviewed flag. Setting a category confirms the row (confidence 1.0) and, by default, labels its merchant so later transactions from it are filed the same way. Pass "learn": false for a one-off that leaves the merchant alone.

Terminal window
curl -X PATCH http://localhost:5050/api/transactions/42 \
-H "Content-Type: application/json" \
-d '{"category_name": "Eating Out", "notes": "Dinner with friends"}'

The response lists the other unconfirmed rows from the same merchant (and direction) that are filed under a different category, so a client can offer to move them:

{"ok": true, "same_merchant": [57, 91]}

PATCH /api/transactions/<id>/split

Override the business split percentage for a transaction.

Terminal window
curl -X PATCH http://localhost:5050/api/transactions/42/split \
-H "Content-Type: application/json" \
-d '{"business_pct": 50, "business_name": "My Business"}'

Set business_pct to 0 to remove the split.

Merchants

MethodEndpointDescription
GET/api/merchants/reviewMerchants flagged for a person’s decision
POST/api/merchants/<id>/decideFile a flagged merchant and refile its rows

GET /api/merchants/review

Each entry has id, merchant (the normalised key), direction (in or out), category (the current label), alternative (the other candidate, if any), note, origin, rows, total, first, last, and up to three examples of the description as printed. Sorted by the size of total, largest first.

POST /api/merchants/<id>/decide

Terminal window
curl -X POST http://localhost:5050/api/merchants/7/decide \
-H "Content-Type: application/json" \
-d '{"category_name": "Groceries"}'

Labels the merchant human, clears the flag, and refiles every unconfirmed row from it at confidence 1.0. Returns {"ok": true, "refiled": <count>}.

Summaries

MethodEndpointDescription
GET/api/summary/monthlyMonthly income vs expenses
GET/api/summary/categorySpending totals by category
GET/api/summary/trendsMonthly spending by category over time
GET/api/summary/taxFY tax summary by category
GET/api/summary/year-reviewComprehensive year-in-review stats
GET/api/summary/top-merchantsTop merchants by spend
GET/api/budget-vs-actualBudget vs actual for budgeted categories

Common query parameters: year, from, to, account, fy (financial year, e.g. 2025).

GET /api/budget-vs-actual

Terminal window
curl "http://localhost:5050/api/budget-vs-actual?month=2025-03"

Returns each budgeted category with budget, actual, and remaining amounts.

Spreadsheet (Financial Year)

MethodEndpointDescription
GET/api/spreadsheet/outgoing?fy=2025All FY expenses with business splits
GET/api/spreadsheet/incoming?fy=2025All FY income by category
GET/api/spreadsheet/rental?fy=2025Rental property schedule
GET/api/spreadsheet/work-trips?fy=2025Work trips and WFH deductions

ATO Return

MethodEndpointDescription
GET/api/ato/return?fy=2025Structured ATO return data

Returns a JSON object with sections: income (salary, interest, tax withheld), rental (per-property schedule), business (per-business P&L), deductions (WFH, work trips), manual_entries, and spouse info.

Reference Data

MethodEndpointDescription
GET/api/categoriesAll categories with budgets
GET/api/accountsAll accounts
GET/api/accounts/summaryAccount balances and net worth
GET/api/tagsAll tags with counts and totals

Holdings

MethodEndpointDescription
GET/api/holdingsAll holdings (shares, property, super)
POST/api/holdingsCreate or update a holding
GET/api/holdings/<id>/eventsAsset events for a holding
POST/api/holdings/<id>/eventsAdd an asset event (buy, sell, dividend, valuation)

Work Trips

MethodEndpointDescription
GET/api/work-trips?fy=2025List work trips
POST/api/work-tripsCreate a work trip with expenses
DELETE/api/work-trips/<id>Delete a work trip

Tax Overrides

MethodEndpointDescription
GET/api/tax-overrides?fy=2025List tax overrides
POST/api/tax-overridesCreate/update a tax override
DELETE/api/tax-overrides/<id>Delete a tax override

Shared Expenses

MethodEndpointDescription
GET/api/shared-expensesHousehold expenses split with a partner, with totals shared and settled
POST/api/shared-expensesMark a transaction as shared
PATCH/api/shared-expenses/<id>Change a share
DELETE/api/shared-expenses/<id>Remove a share

Recurring Schedules

MethodEndpointDescription
GET/api/schedulesRecurring schedules from config/schedules.yaml, expected against paid to date

Depreciation and Lodged Returns

MethodEndpointDescription
GET/api/depreciationAsset register and decline in value by FY
GET/api/ato/lodgedReturns already lodged, from config/ato_returns.yaml

Economics

MethodEndpointDescription
GET/api/cpiCPI series used to deflate historical figures
POST/api/cpi/syncRefresh the CPI series from the ABS
GET/api/summary/economicsSpending against inflation

Maintenance

MethodEndpointDescription
POST/api/dedupRun cross-account duplicate resolution