reconcile_account
Compare an account with the balance your bank shows, then reconcile it.
Give the balance shown by the bank today (currency units). If YNAB’s cleared
balance differs, nothing is written: the result explains the gap with the
pending transactions, the one whose amount matches the difference
(explained_by) and likely duplicates. Fix those first (with the user), then
call again. Only if the user wants to accept the remaining gap, call with
adjust=true: a “Balance adjustment” transaction is added to Ready to Assign.
When balances match, every cleared transaction is marked reconciled after the
user confirms (as for apply_categories). undo_operation reverts it.
Verhalten
Abschnitt betitelt „Verhalten“| Art | schreibend — ohne AVENIR_MCP_WRITE=1 verborgen |
| Bestätigung | ja: Vorschau, dann Anwendung nach Zustimmung des Nutzers |
| Rückgängig | ja, mit undo_operation |
| Destruktiv | ja |
| Idempotent | nein |
| YNAB-Anfragen | 2 für das Beispiel unten, leerer Cache |
Parameter
Abschnitt betitelt „Parameter“| Name | Typ | Pflicht | Standard | Beschreibung |
|---|---|---|---|---|
plan_id |
string | ja | — | YNAB plan id or ‘last-used’. |
account_id |
string | ja | — | Account to reconcile (from list_accounts). |
bank_balance |
number | ja | — | In currency units, negative for money out; at most a billion either way. |
adjust |
boolean | nein | false |
Record the remaining difference as an adjustment. |
confirmation |
string | null | nein | null |
Code from a previous “confirmation_required” result. |
Rückgabe
Abschnitt betitelt „Rückgabe“| Feld | Typ | Beschreibung |
|---|---|---|
status |
“applied” | “confirmation_required” | “declined” | “nothing_to_do” | “difference_found” | Outcome: difference_found (nothing changed; see analysis), confirmation_required, applied, declined, or nothing_to_do (already reconciled). |
message |
string | What happened and what to do next, for the agent to relay. |
account |
string | Account name. |
analysis |
object | The comparison with the bank. |
analysis.account_id |
string | The account analysed. |
analysis.bank_balance |
number | Balance the bank shows, as given. |
analysis.cleared_balance |
number | Sum of the account’s cleared and reconciled transactions in YNAB. |
analysis.working_balance |
number | Sum of all the account’s transactions, cleared or not. |
analysis.difference |
number | Bank balance minus cleared balance; negative when YNAB counts more money than the bank. |
analysis.to_reconcile_count |
integer | Cleared transactions not yet reconciled. |
analysis.uncleared_count |
integer | Transactions the bank has not shown yet. |
analysis.uncleared |
array of object | Up to 50 of them. |
analysis.explained_by |
array of string | Uncleared transactions whose amount equals the difference. |
analysis.possible_duplicates |
array of array of string | Pairs with the same amount and merchant, at most 3 days apart, over the last 60 days. |
adjustment |
number | null | Amount of the balance adjustment created, if adjust was requested; else null. |
confirmation |
string | null | Single-use code confirming exactly this preview, valid 10 minutes; null unless status is confirmation_required. |
operation_id |
string | null | Journal id of the applied operation, for undo_operation; null unless status is applied. |
Beispiel
Abschnitt betitelt „Beispiel“Argumente:
{ "plan_id": "demo-budget", "account_id": "acc-checking", "bank_balance": 3440.8}Antwort auf dem Demo-Budget:
{ "status": "difference_found", "message": "YNAB's cleared balance differs from the bank by -71.86. Nothing was changed. Check explained_by, uncleared and possible_duplicates with the user; call again once fixed, or with adjust=true to record the gap as an adjustment.", "account": "Girokonto", "analysis": { "account_id": "acc-checking", "bank_balance": 3440.8, "cleared_balance": 3512.66, "working_balance": 3512.66, "difference": -71.86, "to_reconcile_count": 49, "uncleared_count": 0, "uncleared": [], "explained_by": [], "possible_duplicates": [ [ "tx-050", "tx-051" ] ] }, "adjustment": null, "confirmation": null, "operation_id": null}Account {account_id} is not in this plan: use an id from list_accounts.This client cannot ask the user to confirm, and AVENIR_MCP_REQUIRE_ELICITATION=1 forbids confirmation codes: nothing was changed. Use a client that supports MCP elicitation, or unset the variable.This confirmation code is unknown, expired, already used, or was issued for different changes. Call again without confirmation to get a new preview.Confirmation codes are disabled (AVENIR_MCP_REQUIRE_ELICITATION=1): call again without confirmation, and the user answers in the client.The plan changed between the preview and the answer. Call again without an answer to get a new preview.
Fehler von YNAB selbst kommen als Error calling tool '<tool>': YNAB <status>: <detail> zurück.
Siehe auch
Abschnitt betitelt „Siehe auch“Inoffizielles Projekt. „We are not affiliated, associated, or in any way officially connected with YNAB or any of its subsidiaries or affiliates. The official YNAB website can be found at https://www.ynab.com. The names YNAB and You Need A Budget, as well as related names, tradenames, marks, trademarks, emblems, and images are registered trademarks of YNAB.“ Wir sind mit YNAB oder einer seiner Tochtergesellschaften oder verbundenen Unternehmen weder verbunden noch assoziiert noch in irgendeiner Weise offiziell verknüpft. Die offizielle Website von YNAB finden Sie unter https://www.ynab.com. Die Namen YNAB und You Need A Budget sowie zugehörige Namen, Handelsnamen, Zeichen, Marken, Embleme und Bilder sind eingetragene Marken von YNAB. avenir-mcp wird ohne Gewähr bereitgestellt und ist keine Finanzberatung. Rechtliche Hinweise · Datenschutz