Book Norma 43 bank statement as journal
bank_to_journalConvert bank statements, Norma 43 files, or CSV movement lists into journal entries, matching each movement to accounts and flagging unmatched items for review.
Instructions
Turn a bank statement (Norma 43, the bank's Excel/CSV export, or a movements list) into journal entries.
One entry per movement: abono -> Debe bank / Haber counterpart; cargo -> Debe counterpart / Haber bank.
The counterpart comes from the first matching rule; with no match it goes to suspense_account
(default 555 'partidas pendientes de aplicación', padded to the bank account length) and the movement is
listed in unmatched, so nothing is guessed.
Args: bank_account: The 572 subaccount of the bank, e.g. "57200001" (for QuickBooks/Xero: that program's bank account name or code, and suspense_account is then required). target_format: csv (default) | a3 | contaplus_csv | contaplus_ascii | contasol | quickbooks_iif | quickbooks_csv | xero_csv. content / content_base64: The .n43 file (base64 for CP850/Latin-1 bytes), or the bank's CSV export (Excel saved as CSV: a header row with fecha + importe, or cargo + abono, and concepto). movements: Instead of a file, [{"date": "2026-03-05", "amount": "-121.00", "text": "IBERDROLA"}] for statements read from Excel or PDF (+ money in, - money out). open_items: Pending invoices to settle FIRST, before rules: [{"account": "43000012", "amount": "1210.00", "reference": "F-2026-031", "name": "Talleres Ruiz", "date": "2026-02-28"}]. Signed as the bank sees it (+ cobro de cliente, - pago a proveedor). A movement is booked against the customer/supplier subaccount only on the same amount AND a unique reference or name in the bank text (or a unique amount within window_days). Ties are listed in open_items.ambiguous and never guessed. invoices_to_journal returns these items ready to pass here. rules: Ordered list, first match wins. Each: {"account": "62800000", "contains": ["IBERDROLA"] or "regex": "...", "common_concept": "03" (AEB concept, e.g. 03 recibos, 04 transferencias, 12 comisiones), "direction": "cargo"|"abono", "concept": optional fixed text}. Text matching is case-insensitive over the movement description (own concept + record-23 texts). bank_accounts: For files with several bank accounts: {IBAN or last digits: "57200002"}. use_value_date: Date entries by value date instead of operation date. account_digits / account_split: Resize every subaccount (see convert_journal). start_entry_number: First entry number (default 1).
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"bank_account": "<bank_account>"
},
"name": "bank_to_journal"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| rules | No | ||
| content | No | ||
| a3_format | No | ||
| movements | No | ||
| date_style | No | ||
| open_items | No | ||
| window_days | No | ||
| bank_account | Yes | ||
| company_code | No | 00001 | |
| account_split | No | ||
| bank_accounts | No | ||
| decimal_comma | No | ||
| target_format | No | csv | |
| xero_tax_rate | No | No VAT | |
| account_digits | No | ||
| content_base64 | No | ||
| use_value_date | No | ||
| suspense_account | No | ||
| start_entry_number | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||