personal-finance-mcp
personal-finance-mcp
Inoffiziell. Dieses Projekt ist nicht mit Plaid Inc. verbunden, wird von dieser nicht unterstützt oder gesponsert. "Plaid" ist eine Marke von Plaid Inc. Dies ist ein selbstgehosteter Client, der mit der API von Plaid unter Verwendung Ihrer bereitgestellten Anmeldedaten kommuniziert.
Ein selbstgehosteter, schreibgeschützter MCP-Server, der Ihre Banken, Kreditkarten, Kredite und Brokerage-Konten (über Plaid) mit einem MCP-Client wie Claude Code verbindet. Stellen Sie Fragen zu Ihren eigenen Finanzen in einfachem Englisch — ohne Drittanbieter-Aggregator (Monarch, Mint, etc.).
Was Sie fragen können
"Wie hoch ist mein Gesamtsaldo über alle Konten hinweg?"
"Zeige mir Transaktionen über 100 $ in den letzten 30 Tagen."
"Für welche Abonnements zahle ich noch?"
"Wie viel habe ich letzten Monat für Lebensmittel ausgegeben?"
"Muss irgendeine Bank neu authentifiziert werden?"
Beispielsitzung (illustrativ):
you : What did I spend on groceries last month?
claude : [calls get_transactions]
$487.23 across 14 transactions. Top merchants:
Whole Foods ($198), Trader Joe's ($156), Safeway ($89).
you : Any subscriptions I'm still paying for?
claude : [calls get_recurring_transactions]
7 active recurring outflows totaling $142/mo:
Netflix ($15.99), Spotify ($11.99), NYT ($4), ...Related MCP server: FinLynq
Tools
Alle 9 Tools sind schreibgeschützt. Jedes gibt {<data>: [...], "warnings": [...]} zurück, sodass eine defekte Bankverbindung nicht die gesamte Abfrage unterbricht.
Tool | Funktion |
| Jedes Konto bei jeder verknüpften Bank, mit Salden |
| Aktuelle + verfügbare Salden (optional nach Konto gefiltert) |
| Transaktionen in einem Datumsbereich (bis zu 2 Jahre zurück) |
| Stichwortsuche nach Händler / Name / Gegenpartei |
| Erkannte wiederkehrende Einnahmen- + Ausgabenströme |
| Kreditkarten, Studienkredite, Hypotheken mit effektivem Jahreszins und Zahlungsdetails |
| Aktuelle Bestände mit Symbol + Wertpapier-Metadaten |
| Kauf- / Verkaufs- / Dividendenhistorie in einem Datumsbereich |
| Status jeder verknüpften Bank (zeigt an, ob eine Neu-Authentifizierung nötig ist) |
Schnellstart
Erfordert Python 3.11+, ein Plaid-Konto (kostenloser Testplan) und einen MCP-Client.
1. Plaid-Einrichtung
Registrieren Sie sich unter https://dashboard.plaid.com/signup → wählen Sie den Trial-Plan (kostenlos, 10 Elemente).
Team Settings → Products: aktivieren Sie Transactions, Liabilities, Investments.
Team Settings → API: kopieren Sie Ihre
client_idund das Produktions-secret.
2. Installation
git clone https://github.com/JosueM1109/personal-finance-mcp.git
cd personal-finance-mcp
python3.11 -m venv .venv && source .venv/bin/activate
pip install -r requirements.txt
cp .env.example .env # then fill in PLAID_CLIENT_ID and PLAID_SECRET
pytest -v # sanity check3. Jede Bank verknüpfen
Führen Sie dies einmal pro Bank aus, die Sie verbinden möchten:
uvicorn link_helper:app --port 8765Öffnen Sie http://localhost:8765, klicken Sie auf Link a bank und schließen Sie Plaid Link ab. Das Terminal gibt eine Zeile wie PLAID_TOKEN_CHASE=access-prod-xxx... aus — fügen Sie diese in .env ein und wiederholen Sie den Vorgang für jede Bank.
4. Ausführen
python server.py # serves on http://localhost:8000/mcp5. Zu Claude Code hinzufügen
claude mcp add --transport http personal-finance http://localhost:8000/mcpVersuchen Sie "list my accounts", um es zu bestätigen.
Bereitstellung
Für eine Bereitstellung, die Sie von überall nutzen können:
Docker (enthalten):
docker build -t personal-finance-mcp . && docker run --rm -p 8000:8000 --env-file .env personal-finance-mcpJeder Python-Host (Fly.io, Railway, Raspberry Pi + Tailscale, ein VPS): setzen Sie die Umgebungsvariablen aus
.env.example, machen Sie/mcpüber HTTPS verfügbar und sichern Sie es mit einer Authentifizierung.Prefect Horizon (was der Autor verwendet — 0 $ laufende Kosten): siehe docs/DEPLOYMENT.md für die vollständige Anleitung.
Sichern Sie den Endpunkt. Ein exponierter MCP-Endpunkt mit Ihren Tokens legt jedes verknüpfte Konto offen. Verwenden Sie OAuth 2.1, Cloudflare Access oder binden Sie ihn nur an ein privates Netzwerk.
Sicherheit
Single-Tenant. Eine Bereitstellung pro Person. Nicht teilen.
Schreibgeschützt. Kein Tool ändert den Status bei irgendeinem Institut. Fügen Sie keine Tools hinzu, die dies tun.
Tokens leben in Umgebungsvariablen, niemals auf der Festplatte.
.envist in gitignore enthalten.Sie sind für die Plaid-Compliance verantwortlich. Sie sind der Plaid-Kunde unter Ihrem eigenen Konto.
Vor jeder Bereitstellung:
[ ]
.envniemals committen:git log --all -- .envgibt nichts zurück[ ] Keine echten Tokens in der Historie:
git log -S'access-prod-' --allgibt nur Platzhalter zurück[ ] Authentifizierungsschutz vor dem MCP-Endpunkt (oder nur localhost)
[ ]
HORIZON=1(oder ähnlich) in der Bereitstellungsumgebung gesetzt, blockiertlink_helper.pydort[ ] Überprüfen Sie
get_institutions_status()alle paar Wochen auf notwendige Neu-Authentifizierungen
Fehlerbehebung
Tool gibt trotz echter Daten nichts zurück. Plaid-Produkte waren nicht aktiviert, als Sie die Bank verknüpft haben. Verknüpfen Sie sie erneut mit aktivierten Transactions + Liabilities + Investments. Das Tool zeigt PRODUCTS_NOT_SUPPORTED in warnings an, wenn dies die Ursache ist.
get_institutions_status() zeigt re_auth_required. Die Plaid-Sitzung der Bank ist abgelaufen. Führen Sie link_helper.py im Update-Modus aus — Ihr bestehendes Zugriffstoken bleibt gleich. Siehe docs/DEPLOYMENT.md.
Plaid Link zeigt eine Bank als "nicht unterstützt" an (häufig bei Amex). Normalerweise ein INSTITUTION_REGISTRATION_REQUIRED-Problem — OAuth-Banken benötigen zuerst eine Registrierung pro Institut im Plaid-Dashboard. Siehe docs/TROUBLESHOOTING.md.
Weitere Probleme: docs/TROUBLESHOOTING.md.
Architektur
server.py — FastMCP-Server, 9 schreibgeschützte Tools.
plaid_client.py — Plaid SDK-Wrapper:
SecretStr-Token-Schwärzung, 5-Minuten-Gesundheits-Cache pro Element, Antwortformatierung, strukturierte Fehlerzuordnung.link_helper.py — Nur lokal verfügbare FastAPI-App für Plaid Link. Verweigert den Betrieb, wenn
HORIZON=1gesetzt ist.
Tieferer Einblick (einschließlich warum /transactions/get statt /transactions/sync): docs/ARCHITECTURE.md.
Mitwirken
Siehe CONTRIBUTING.md. Der Umfang ist bewusst eng gefasst: schreibgeschützt, Single-Tenant, Plaid-basiert.
Available Tools
9 toolsget_balancesGet BalancesARead-only
Get live current + available balances for accounts.
Inputs: account_ids. Returns: object
get_institutions_statusGet Institutions StatusARead-only
Return health status for every linked Item/institution.
No additional network calls beyond what all_items already makes (it
uses the 5-minute health cache). Enumerates linked Items and reports their
current health status.
Returns: {"items": [{"env_key", "institution", "institution_id", "status", "reason"}, ...]}
Inputs: no named parameters. Returns: object
get_investment_holdingsGet Investment HoldingsARead-only
Return investment holdings with security metadata across all linked Items.
Joins holdings with the securities list returned in the same response to provide symbol, name, and security type. Adds institution to each holding.
Returns: {"holdings": [...], "warnings": [...]}
Inputs: no named parameters. Returns: object
get_investment_transactionsGet Investment TransactionsARead-only
Fetch investment transactions in [start_date, end_date] across all healthy Items.
Dates are ISO YYYY-MM-DD. Uses offset pagination (count=500 per page). If start_date is older than ~2 years before end_date, the window is clipped and a warning is emitted. Each transaction is joined with security metadata (ticker symbol, name) from the same response.
Returns: {"investment_transactions": [...], "warnings": [...]}
Inputs: start_date (required), end_date (required). Returns: object
get_liabilitiesGet LiabilitiesARead-only
Return credit, student-loan, and mortgage liability details across all linked Items.
For Items where the liabilities product is not enabled, a per-Item warning with code PRODUCTS_NOT_SUPPORTED is emitted instead of failing the call.
Returns: {"credit": [...], "student": [...], "mortgage": [...], "warnings": [...]}
Inputs: no named parameters. Returns: object
get_recurring_transactionsGet Recurring TransactionsARead-only
Return recurring inflow and outflow streams across all linked Items.
Calls /accounts/get first per Item to collect account IDs (required by /transactions/recurring/get), then fetches recurring streams and shapes them into unified inflows/outflows lists.
Returns: {"inflows": [...], "outflows": [...], "warnings": [...]}
Inputs: no named parameters. Returns: object
get_transactionsGet TransactionsARead-only
Fetch transactions in [start_date, end_date] across all healthy Items.
Dates are ISO YYYY-MM-DD. Uses Plaid /transactions/get with offset pagination (count=500 per page). If start_date is older than ~2 years before end_date, the window is clipped and a warning is emitted.
Inputs: start_date (required), end_date (required), account_ids. Returns: object
list_accountsList AccountsARead-only
List every account across all linked Items, with balances.
Returns: {"accounts": [...], "warnings": [...]}. Warnings describe Items that are unhealthy (re-auth required, etc.) or hit API errors on this call.
Inputs: no named parameters. Returns: object
search_transactionsSearch TransactionsARead-only
Search transactions by keyword across merchant, name, and counterparty names.
Fetches transactions in [start_date, end_date] and filters them with a case-insensitive substring match against:
merchant_namenamecounterparties[].name
The match is performed on the raw Plaid payload before shaping so that
counterparty names (which are dropped by shape_transaction) are
searchable. Dates are ISO YYYY-MM-DD. The window is clipped to ~2 years
and a WINDOW_CLIPPED warning is emitted when applicable.
Returns: {"transactions": [...], "warnings": [...]}
Inputs: query (required), start_date (required), end_date (required). Returns: object
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 9 tools
Each tool targets a distinct aspect of personal finance data (balances, transactions, investments, liabilities, etc.), with clear boundaries. There is no overlap in functionality; even transaction-related tools distinguish between regular, investment, recurring, and search operations.
All tools follow a consistent verb_noun pattern in snake_case, primarily using 'get_' for retrieval and 'list_' for accounts, which is predictable and unambiguous.
With 9 tools, the server is well-scoped for a personal finance data aggregator. Each tool serves a clear purpose without redundancy, covering core financial data retrieval needs.
The tool surface covers most essential read operations for personal finance: accounts, balances, transactions (multiple types), liabilities, and holdings. Minor gaps such as lack of categorization or income/expense summaries are acceptable for a focused data provider.
Maintenance
Related MCP Connectors
Read-only finance MCP server. Connects your banks, cards, payment apps, books and payroll into one ledger for your AI. Can't move money. Open source (AGPL-3.0), free during beta.
Query your real net worth, spending, transactions, budgets and portfolio from any MCP client.
An MCP server that provides read access to your cloud storage providers, bank accounts and more.
Read-only bank & investment accounts via Plaid: balances, holdings, transactions, SQL analytics.
Related MCP Servers
- AlicenseAqualityDmaintenanceA read-only MCP server that enables users to analyze their real bank, credit card, loan, and brokerage data through Plaid. It provides financial analysis tools for transactions, balances, investments, liabilities, and debt while keeping all access tokens and data locally stored.24MIT
- AlicenseCqualityAmaintenanceopen-source personal finance app with a first-party MCP server. 91 HTTP tools (OAuth 2.1 + DCR) and 87 stdio tools cover transactions, budgets, accounts, portfolio analytics, FX conversion, loans, subscriptions, goals, importers, and rules. Users self-host with Docker + PostgreSQL or use the managed cloud8939AGPL 3.0
- FlicenseNot gradedqualityDmaintenanceEnables self-hosted personal finance management for MCP clients by connecting read-only bank accounts via SimpleFIN, syncing transactions into a local SQLite database, and exposing tools to query balances, spending, budgets, cash flow, and net worth.-
- AlicenseBqualityDmaintenanceA read-only MCP server that lets AI clients query real financial data (bank, credit card, loan, brokerage) via Plaid or Teller, offering tools for balances, transactions, investments, liabilities, identity, income, and debt analysis.24MIT