Skip to main content

Backend HTTP Surface

Use this page for controller-level contract summaries after they have been verified against the backend implementation.

Truth Sources

When this page and the implementation disagree, use this order:

  1. backend controllers under core/backend/src/**/interfaces/http/
  2. backend application and supporting services
  3. backend workspace manifests and scripts
  4. this page

Runtime Surface

SurfaceNotes
GET /healthAggregate finance backend health response
GET /health/liveLiveness probe
GET /health/readyReadiness probe
GET /ops/metricsPrometheus-compatible metrics payload, including process defaults plus HTTP request count and duration
POST /auth/registerCreate a local email/password user and return a bearer session
POST /auth/loginAuthenticate a local user and return a bearer session
GET /auth/meReturn the current bearer-session user
GET /auth/google/startRedirect to Google OAuth using configured client credentials
GET /auth/google/callbackComplete Google OAuth, create/link the user, and redirect to the frontend callback route
GET /finance/overviewDashboard read model with net worth, cashflow, accounts, transactions, budgets, goals, bills, chart data, selected range, and review count for the active finance month
GET /finance/overview?period=YYYY-MMDashboard read model for an explicit selected month; response includes periodKey, rangeStart, rangeEnd, and availablePeriods
GET /finance/overview?startDate=YYYY-MM-DD&endDate=YYYY-MM-DD&account=<account>Dashboard read model filtered to a custom date range and finance account
GET /finance/accountsAccount overview records
POST /finance/accountsCreate an account record
GET /finance/categoriesReturn user-scoped categories, including delete-protected defaults, custom categories, and usage counts from transactions, recurring entries, and budgets
POST /finance/categoriesCreate a custom category for the authenticated user
PATCH /finance/categories/:idRename any authenticated-user category and update same-user transactions, recurring entries, and budgets using it
DELETE /finance/categories/:idDelete an unused custom category; default categories and categories with transactions, recurring entries, or budgets are rejected
GET /finance/transactionsRecent ledger transactions
POST /finance/transactionsCreate a transaction and apply its balance impact
PATCH /finance/transactions/reviewMark selected authenticated-user transactions reviewed, optionally applying one category in bulk
PATCH /finance/transactions/bulkUpdate selected authenticated-user transactions in one database transaction, currently category and/or source account
DELETE /finance/transactions/bulkDelete selected authenticated-user transactions in one database transaction and reverse their balance impact
POST /finance/voice/interpretUpload a short audio command, transcribe it with Speech-to-Text, interpret it with Gemini Flash-Lite or local rules, normalize the result against transcript facts, and return a preview-only action, including safe open_route tab navigation for known routes
POST /finance/voice/confirmConfirm a previewed voice create_transaction action and save it as a review-tagged authenticated-user transaction
POST /finance/imports/invoice/previewParse a CSV/TXT invoice upload into a reviewable expense preview
POST /finance/imports/invoice/jobsEnqueue one to five invoice/statement files for async Gemini classification, or return a completed cached job when the same scoped file content was already classified; digital PDFs send bounded extracted text so the model can ignore document noise and return real transaction rows with persisted progress, summary totals, and classificationSource
GET /finance/imports/jobs/notificationsReturn unread completed/failed import-job notifications for the authenticated user
GET /finance/imports/jobs/:idReturn one authenticated user's import classification job, including progressPercent, progressMessage, income/spend/transfer summary totals, errors/fallbacks, and completed preview when ready
PATCH /finance/imports/jobs/:id/readMark an import-job notification read
POST /finance/imports/invoice/confirmImport selected invoice preview rows as ledger withdrawals, deposits, or transfers after server-side direction normalization
POST /finance/imports/statement/previewParse a CSV/TXT/basic OFX bank statement into a reviewable ledger preview
POST /finance/imports/statement/confirmImport selected statement rows as scoped ledger withdrawals, deposits, or transfers
PATCH /finance/transactions/:idUpdate a transaction and reapply its balance impact
DELETE /finance/transactions/:idDelete a transaction and reverse its balance impact
GET /finance/budgetsUser-scoped category budgets with active flag and computed spend
POST /finance/budgetsCreate a category budget with period, monthly amount, currency, and active flag
PATCH /finance/budgets/:idUpdate one authenticated user's category budget
DELETE /finance/budgets/:idDelete one authenticated user's category budget
GET /finance/automationBills, recurring transactions with category, and rules
POST /finance/automation/recurring-transactionsCreate a user-scoped recurring expense entry using an existing category
PATCH /finance/automation/recurring-transactions/:idUpdate one authenticated user's recurring expense entry
DELETE /finance/automation/recurring-transactions/:idDelete one authenticated user's recurring expense entry
GET /finance/reportsCashflow, category-spend, and budget-performance report data
GET /finance/feature-mapClean rewrite parity map

Finance endpoints require a bearer session and must return only records owned by the authenticated user.

Backend responses include x-request-id. Error responses are normalized with requestId, statusCode, message, path, and timestamp so UI/support can correlate failures with logs and metrics.