upbank-mcp
upbank-mcp
Ein Model Context Protocol-Server, der die Up Banking API für LLM-Clients bereitstellt, gebaut mit FastMCP und für Docker verpackt.
Er bietet 19 Tools und 2 Ressourcen, die die gesamte öffentliche Oberfläche der Up API abdecken — Konten, Transaktionen, Kategorien, Tags, Anhänge und Webhooks — mit für Tokeneffizienz umgeformten Antworten, durchgängig erhaltener Cursor-Paginierung und automatischen Wiederholungsversuchen bei Rate Limits.
Inhalt
Related MCP server: Up Bank MCP Server
Voraussetzungen
Up-Konto | Ein persönlicher Zugriffs-Token von https://api.up.com.au/getting_started. Tokens sehen wie |
Docker | Docker Engine 20.10+ mit Compose v2 ( |
Python | 3.11+ — nur wenn außerhalb von Docker ausgeführt. |
Die Up API ist für Up-Kunden in Australien verfügbar. Ein Token gewährt ausschließlich Zugriff auf die eigenen Daten des ausstellenden Kunden.
Schnellstart
git clone git@github.com:uiux-me/upbank-mcp.git
cd upbank-mcp
cp .env.example .env # paste your token into UP_API_TOKEN
docker compose up --buildDer Server lauscht auf http://127.0.0.1:8000/mcp. So überprüfen Sie ihn:
docker compose exec upbank-mcp python -c "
import asyncio, upbank_mcp
from fastmcp import Client
async def main():
async with Client(upbank_mcp.mcp) as c:
print((await c.call_tool('ping')).data)
asyncio.run(main())"Eine fehlerfreie Antwort enthält Ihre Kunden-id und ein Status-Emoji:
{'ok': True, 'id': 'eb59f467-…', 'status_emoji': '⚡️'}Konfiguration
Die gesamte Konfiguration erfolgt über Umgebungsvariablen. Compose liest .env automatisch aus dem Projektverzeichnis.
Variable | Standard | Beschreibung |
| (erforderlich) | Persönlicher Zugriffs-Token. Die einzige Variable, die der Server für Anmeldedaten liest. Compose weigert sich, ohne sie zu starten; bei direktem Start startet der Server und schlägt beim ersten Tool-Aufruf fehl. |
|
| API-Basis-URL. Nur für Tests gegen einen Mock überschreiben. |
|
|
|
|
| Bind-Adresse für den HTTP-Transport innerhalb des Containers. |
|
| Port, auf dem der HTTP-Transport innerhalb des Containers lauscht. |
|
| Nur Compose. Host-Port, der auf |
Server ausführen
HTTP, via Compose
Am besten für einen langlebigen Server, der von mehreren Clients auf Ihrem Rechner gemeinsam genutzt wird.
docker compose up --build # foreground
docker compose up -d --build # detached
docker compose logs -f # follow logs
docker compose down # stop and removeDer Port wird nur auf 127.0.0.1 veröffentlicht. Siehe Sicherheit.
stdio, via Docker
Am besten für MCP-Clients, die den Server als Unterprozess starten. Bauen Sie das Image einmal:
docker build -t upbank-mcp:latest .Das Image verwendet standardmäßig MCP_TRANSPORT=stdio, daher ist keine Transport-Überschreibung erforderlich.
Ohne Docker
pip install -e .
export UP_API_TOKEN=up:yeah:...
upbank-mcpSetzen Sie MCP_TRANSPORT=http, um über HTTP statt stdio zu dienen.
MCP-Client verbinden
Claude Code
claude mcp add upbank \
-e UP_API_TOKEN=up:yeah:... \
-- docker run -i --rm -e UP_API_TOKEN upbank-mcp:latestClaude Desktop oder jeder Client, der die mcpServers-Konfiguration verwendet
{
"mcpServers": {
"upbank": {
"command": "docker",
"args": ["run", "-i", "--rm", "-e", "UP_API_TOKEN", "upbank-mcp:latest"],
"env": { "UP_API_TOKEN": "up:yeah:..." }
}
}
}-i ist erforderlich — der Server kommuniziert über stdin/stdout. --rm entfernt den Container, wenn der Client die Verbindung trennt.
Über HTTP
Richten Sie den Client auf http://127.0.0.1:8000/mcp, während der Compose-Stack läuft.
Tool-Referenz
Erforderliche Parameter sind fett. Jedes Listen-Tool akzeptiert cursor; siehe Paginierung.
Dienstprogramm
Tool | Parameter | Rückgabe |
| — |
|
Konten
Tool | Parameter | Rückgabe |
|
| Seite von Konten mit Kontoständen. |
|
| Ein Konto. |
Transaktionen
Tool | Parameter | Rückgabe |
|
| Seite von Transaktionen, neueste zuerst. Lassen Sie |
|
| Eine Transaktion, einschließlich Hold-, Round-up- und Cashback-Details. |
since und until begrenzen createdAt inklusiv. category akzeptiert eine Eltern-ID, die alle zugehörigen Unterkategorien abdeckt.
Kategorien
Tool | Parameter | Rückgabe |
|
| Der Kategoriebaum oder die Unterkategorien einer einzelnen Eltern-Kategorie. Nicht paginiert. |
|
| Eine Kategorie mit ihren Eltern- und Kinder-IDs. |
|
| Setzt die Kategorie oder entfernt sie, wenn |
Kategorien sind von Up festgelegt und können nicht erstellt werden. IDs sind Slugs wie restaurants-and-cafes. Nur Transaktionen mit is_categorizable: true können geändert werden, und nur Blatt-Kategorien werden akzeptiert — die Übergabe einer Eltern-Kategorie wie good-life liefert HTTP 403.
Tags
Tool | Parameter | Rückgabe |
|
| Seite von Tags. Die ID eines Tags ist seine Bezeichnung. |
|
| Fügt Tags hinzu und erstellt nicht vorhandene. |
|
| Entfernt Tags von der Transaktion. |
Eine Transaktion enthält höchstens 6 Tags. Tags, die keiner Transaktion mehr zugeordnet sind, verschwinden aus list_tags.
Anhänge
Tool | Parameter | Rückgabe |
|
| Seite von Anhängen. |
|
| Ein Anhang. |
file_url ist eine signierte URL, die mit file_url_expires_at abläuft. Rufen Sie sie zeitnah ab oder fordern Sie den Anhang erneut an.
Webhooks
Tool | Parameter | Rückgabe |
|
| Seite von Webhooks. |
|
| Ein Webhook. |
|
| Der neue Webhook, einschließlich |
|
|
|
|
| Sendet ein Test- |
|
| Letzte Zustellversuche mit Antwortcodes und -texten. |
secret_key wird nur bei der Erstellung zurückgegeben und nie wieder. Bewahren Sie ihn auf, um den X-Up-Authenticity-Signature-Header (SHA-256-HMAC) bei eingehenden Zustellungen zu verifizieren.
Ressourcen
URI | Inhalt |
| Jedes Konto und sein aktueller Kontostand als einzelner JSON-Snapshot. |
| Der vollständige Kategoriebaum zum Auflösen gültiger Werte für den |
Beide werden bei Bedarf gelesen und spiegeln den Zustand zum Lesezeitpunkt wider.
Antwort-Konventionen
Aufbau
Up gibt JSON:API zurück, das jedes Feld unter attributes/relationships verschachtelt und auf jeder Ressource Self-Links wiederholt. Dieser Server flacht jede Ressource zu einem kompakten Dict ab und lässt optionale Felder weg, wenn sie fehlen, was die Token-Kosten erheblich reduziert, ohne Informationen zu verlieren, die ein Aufrufer benötigt.
{
"id": "45b83097-c97d-40da-9790-254056f03d40",
"status": "SETTLED",
"description": "Google One",
"amount": { "value": "-2.49", "currency": "AUD", "base_units": -249 },
"created_at": "2026-08-20T06:53:17+10:00",
"settled_at": "2026-08-20T06:53:17+10:00",
"account_id": "90c0fffc-bed6-4214-9450-6a76cd39957b",
"category_id": "games-and-software",
"parent_category_id": "good-life",
"tags": [],
"is_categorizable": true
}Felder wie foreign_amount, hold_info, round_up, cashback, card_purchase_method, note und message erscheinen nur, wenn die Transaktion sie enthält.
Geldbeträge
Jeder Betrag ist ein Objekt:
{ "value": "-2.49", "currency": "AUD", "base_units": -249 }value ist eine Dezimalzeichenfolge, base_units ist die ganzzahlige Untereinheit (Cent für AUD). Abbuchungen sind negativ. Bevorzugen Sie base_units für Berechnungen, um Gleitkommafehler zu vermeiden.
Paginierung
Listen-Tools geben zurück:
{ "items": [ ... ], "next_cursor": "https://api.up.com.au/...", "prev_cursor": null }Zum Blättern übergeben Sie einen zurückgegebenen Cursor als cursor-Argument an dasselbe Tool. Cursor sind Ups eigene opake URLs und kodieren bereits die Filter und die Seitengröße, daher werden alle anderen Argumente ignoriert, wenn cursor gesetzt ist. Ein Null-Cursor bedeutet, dass es keine weitere Seite in dieser Richtung gibt.
Cursors werden vor dem Folgen gegen den konfigurierten API-Host validiert, sodass ein Cursor den Client nicht auf einen anderen Server umleiten kann.
Daten
since und until akzeptieren entweder YYYY-MM-DD oder einen vollständigen RFC-3339-Zeitstempel. Reine Datumsangaben und naive Datums-/Zeitangaben werden an Australia/Sydney gebunden, passend zur Darstellung von Zeiten in der Up-App; für das jeweilige Datum wird der korrekte Offset angewendet, sodass auch die Sommerzeit berücksichtigt wird. Nicht pareisierbare Eingaben werden abgelehnt, bevor die Anfrage gesendet wird, und erscheinen nicht erst als undurchsichtiger HTTP-400-Fehler.
Fehlerbehandlung und Ratenbegrenzung
API-Fehler werden als
ToolErrorausgelöst, mit dem HTTP-Status und dem eigenen Fehlertitel und den eigenen Details von Up, zum Beispiel:HTTP 403 — Forbidden: Top-level categories cannot be set directly on transactions.429- und 5xx-Antworten werden bis zu 3 Mal mit exponentiellem Backoff wiederholt; der
Retry-After-Header wird berücksichtigt, wenn er vorhanden ist.Netzwerkfehler werden nach demselben Zeitplan erneut versucht, bevor sie gemeldet werden.
Andere 4xx-Antworten als 429 werden nicht erneut versucht — sie weisen auf eine ungültige Anfrage hin.
Projektstruktur
src/upbank_mcp/
├── client.py Async HTTP client: auth, retry/backoff, date normalisation,
│ cursor host validation
├── shapes.py JSON:API → flat dict transforms, one per resource type
├── server.py FastMCP instance, tool and resource definitions, entrypoint
├── __init__.py Exports `mcp` and `main`
└── __main__.py Enables `python -m upbank_mcp`Die Trennung ist beabsichtigt: client.py kennt nur HTTP und nichts über MCP, shapes.py ist eine reine Datentransformation und server.py enthält die Tool-Verträge. Jede Komponente ist unabhängig testbar.
Entwicklung
pip install -e .
export UP_API_TOKEN=up:yeah:...
upbank-mcp # stdio
MCP_TRANSPORT=http upbank-mcp # http on :8000Betreiben Sie den Server prozessintern mit dem FastMCP-Client:
import asyncio
from fastmcp import Client
import upbank_mcp
async def main():
async with Client(upbank_mcp.mcp) as client:
print(await client.list_tools())
result = await client.call_tool("list_accounts", {"account_type": "TRANSACTIONAL"})
print(result.data)
asyncio.run(main())Erstellen Sie das Image nach Änderungen neu:
docker compose up -d --buildSicherheit
Das Token ist mächtig. Persönliche Zugriffstokens von Up können kein Geld bewegen — die API bietet keinen Zahlungs- oder Überweisungsendpoint —, aber sie können Ihren vollständigen Transaktionsverlauf lesen und Kategorien, Tags und Webhooks ändern. Behandeln Sie ein Token so vertraulich wie ein Passwort.
Der HTTP-Transport hat keine eigene Authentifizierung. Alles, was den Port erreichen kann, kann Ihre Bankdaten lesen. Compose veröffentlicht den Dienst daher nur auf
127.0.0.1. Binden Sie ihn nicht an0.0.0.0und setzen Sie ihn nicht über einen Tunnel oder Reverse-Proxy ein, ohne eine Authentifizierung davorzuschalten.Das Token wird niemals in ein Image eingebacken.
.envist in.dockerignoreaufgeführt und wird zur Laufzeit bereitgestellt. Es erscheint in keiner Image-Schicht, sodass das Image bedenkenlos in eine Registry gepusht werden kann..envist gitignoriert, und.env.exampleenthält nur einen Platzhalter.Der Container läuft als Nicht-Root-Benutzer (uid 10001).
Sofort rotieren, unter https://api.up.com.au/getting_started, falls ein Token jemals offengelegt wurde. Tokens laufen nicht von selbst ab.
Troubleshooting
Symptom | Ursache und Behebung |
|
|
Compose exits with | Auf gleiche Ursache, bereits beim Containerstart erkannt statt beim ersten Aufruf. |
| Ein anderer Prozess belegt Port 8000. Setzen Sie |
| Token ist ungültig oder widerrufen. Stellen Sie es neu aus. |
|
|
| IDs sind kunde-spezifisch. Prüfen Sie, ob die ID aus den Daten dieses Tokens stammt. |
Wiederholtes | Anhaltende Ratenbegrenzung. Reduzieren Sie |
Client zeigt keine Tools | Der Client muss den Container mit |
Referenz
Liste:
Available Tools
19 toolsadd_tags_to_transactionAdd Tags To TransactionC
Add one or more tags to a transaction.
Inputs: tags (required), transaction_id (required). Returns: object
categorize_transactionCategorize TransactionA
Set or clear a transaction's category.
Only transactions with is_categorizable: true can be changed.
Inputs: transaction_id (required), category_id. Returns: object
create_webhookCreate WebhookA
Register a webhook for transaction events.
The response contains secret_key, which is returned only once — store it now
to verify the X-Up-Authenticity-Signature header on incoming deliveries.
Inputs: url (required), description. Returns: object
delete_webhookDelete WebhookB
Permanently delete a webhook. This cannot be undone.
Inputs: webhook_id (required). Returns: object
get_accountGet AccountC
Retrieve a single account by id.
Inputs: account_id (required). Returns: object
get_attachmentGet AttachmentB
Retrieve a single attachment by id.
Inputs: attachment_id (required). Returns: object
get_categoryGet CategoryB
Retrieve a single category by id.
Inputs: category_id (required). Returns: object
get_transactionGet TransactionB
Retrieve a single transaction by id, including hold, round-up and cashback detail.
Inputs: transaction_id (required). Returns: object
get_webhookGet WebhookC
Retrieve a single webhook by id.
Inputs: webhook_id (required). Returns: object
list_accountsList AccountsB
List the customer's Up accounts with their current balances.
Inputs: cursor, page_size, account_type, ownership_type. Returns: object
list_attachmentsList AttachmentsB
List transaction attachments. File URLs are signed and expire shortly.
Inputs: cursor, page_size. Returns: object
list_categoriesList CategoriesA
List the category tree. Categories are fixed by Up, not user-defined.
Inputs: parent. Returns: object
list_tagsList TagsB
List all tags the customer has created. A tag's id is its label.
Inputs: cursor, page_size. Returns: object
list_transactionsList TransactionsA
List transactions, newest first, optionally filtered by account, status, date range, category or tag.
Inputs: tag, since, until, cursor, +4 more. Returns: object
list_webhook_logsList Webhook LogsA
List recent delivery attempts for a webhook, to debug failing deliveries.
Inputs: webhook_id (required), cursor, page_size. Returns: object
list_webhooksList WebhooksC
List configured webhooks.
Inputs: cursor, page_size. Returns: object
pingPingA
Check that the configured Up API token is valid and the API is reachable.
Inputs: no named parameters. Returns: object
ping_webhookPing WebhookA
Send a test PING event to a webhook to verify it is reachable.
Inputs: webhook_id (required). Returns: object
remove_tags_from_transactionRemove Tags From TransactionC
Remove one or more tags from a transaction.
Inputs: tags (required), transaction_id (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 19 tools
Each tool targets a distinct resource and action (accounts, transactions, categories, tags, attachments, webhooks), with clear separation between list/get/create/delete/add/remove/ping operations. Overlap is minimal and descriptions explicitly differentiate ambiguous pairs like ping vs ping_webhook.
Nearly all tools follow a consistent snake_case verb_noun pattern (list_accounts, get_transaction, create_webhook, add_tags_to_transaction). The sole minor deviation is 'ping', which lacks a noun but remains unambiguous and predictable.
19 tools across six resource groups is slightly above the typical 3–15 sweet spot, but each tool maps to a distinct, necessary operation for a banking API. No tool appears redundant or trivially thin.
Coverage is broad: full webhook lifecycle plus ping/logs, transaction list/get/categorize, tag add/remove/list, and read operations for accounts, categories, and attachments. Minor gaps exist, notably no attachment upload/delete, but core workflows are otherwise well-covered.
Maintenance
Related MCP Connectors
The Mercado Pago MCP Server implements the Model Context Protocol to provide AI agents and LLMs with access to Mercado Pago's APIs and tools within compatible development environments. It acts as an intermediary that translates Mercado Pago resources into executable functions (tools) that AI applications can invoke to perform actions and automate flows. The server simplifies integration, enables using documentation to implement or improve code, and optimizes operations through natural language interactions without manual implementations.
Model Context Protocol server for the Apideck Unified API. Connect any MCP-compatible agent framework to 100+ accounting systems, HRIS platforms, file storage providers, and more through one integration. More information https://www.apideck.com/mcp-server
A comprehensive Model Context Protocol (MCP) server that enables AI assistants to interact with yo…
An MCP server that provides read access to your cloud storage providers, bank accounts and more.
Related MCP Servers
- AlicenseDqualityCmaintenanceA Model Context Protocol server that allows AI assistants to connect to and manage Israeli bank accounts, fetch transactions, and handle authentication for all major Israeli banks and credit card companies.238ISC
- AlicenseNot gradedqualityDmaintenanceAn MCP wrapper for Up Bank's API that allows Claude and other MCP-enabled clients to manage accounts, transactions, categories, tags, and webhooks from Up Bank.3MIT
- AlicenseNot gradedqualityDmaintenanceA Model Context Protocol server that enables interaction with You Need A Budget (YNAB) via their API, allowing users to manage budgets, accounts, categories, and transactions through natural language.2MIT
- AlicenseNot gradedqualityDmaintenanceA Model Context Protocol server that allows AI assistants to interact with Lunch Money accounts, enabling management of transactions, categories, budgets, and other financial data through natural language commands.MIT