Skip to main content
Glama
bankstatementparser-mcp

bankstatementparser-mcp

Parse statement transactions and summary

parse_statement
Read-onlyIdempotent

Parses inline bank statement content into transaction rows and a summary, supporting CAMT, CSV, OFX/QFX, MT940, and pain.001 formats for reconciliation and analysis.

Instructions

Parse an inline statement payload into transaction rows and a summary.

Returns the resolved ``format``, the ``columns``, the full
``transaction_count``, the ``transactions`` as row dicts (at most
``limit``) and the statement ``summary``. For balances only,
``summarize_statement`` returns just the summary; to confirm a
payload parses without any rows, ``validate_statement``.

Raises:
    ToolError: If the format is unsupported, cannot be detected, or
        the payload does not parse.

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": {
      "content": "<content>"
    },
    "name": "parse_statement"
  }
}

Input Schema

NameRequiredDescriptionDefault
limitNoMaximum transaction rows to return; omitted returns all. 'transaction_count' is always the full count.
formatNoExplicit format identifier that overrides detection from the filename. Must be exactly one of: 'camt', 'pain001', 'csv', 'ofx', 'qfx', 'mt940' (see list_supported_formats). When omitted, the format is inferred from the filename extension.
contentYesThe raw statement text to parse, inline (not a file path). Accepts ISO 20022 CAMT.053 and pain.001 XML, SWIFT MT940, CSV exports, and OFX/QFX payloads.
filenameNoOriginal filename; its extension (.xml, .csv, .ofx, .qfx, .mt940, .sta) selects the format when 'format' is omitted.statement.xml

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv0.0.37
    • changedInput schema / properties / filename / description
      Previous value: -"Original filename of the payload; its extension (.xml, .csv, .ofx, .qfx, .mt940, .sta) selects the format when 'format' is omitted. Defaults to 'statement.xml'."New value: +"Original filename; its extension (.xml, .csv, .ofx, .qfx, .mt940, .sta) selects the format when 'format' is omitted."
    • changedInput schema / properties / limit / description
      Previous value: -"Optional maximum number of transaction rows to return. The full 'transaction_count' is always reported even when the returned rows are truncated. When omitted, all rows are returned."New value: +"Maximum transaction rows to return; omitted returns all. 'transaction_count' is always the full count."
  2. Changed2 schema fields changedv0.0.19
    • changedInput schema / properties / format / description
      Previous value: -"Explicit format identifier that overrides detection from the filename. Must be exactly one of: 'camt', 'csv', 'mt940', 'ofx', 'pain001', 'qfx' (see list_supported_formats). When omitted, the format is inferred from the filename extension."New value: +"Explicit format identifier that overrides detection from the filename. Must be exactly one of: 'camt', 'pain001', 'csv', 'ofx', 'qfx', 'mt940' (see list_supported_formats). When omitted, the format is inferred from the filename extension."
    • changedInput schema / properties / format / enum
      Previous value: -[
      -  "camt",
      -  "csv",
      -  "mt940",
      -  "ofx",
      -  "pain001",
      -  "qfx"
      -]New value: +[
      +  "camt",
      +  "pain001",
      +  "csv",
      +  "ofx",
      +  "qfx",
      +  "mt940"
      +]
  3. Changed2 schema fields changed
    • changedInput schema / properties / format / description
      Previous value: -"Explicit format identifier that overrides detection from the filename. One of: 'camt' (CAMT.053), 'pain001', 'csv', 'ofx', 'qfx', 'mt940'. When omitted, the format is inferred from the filename extension."New value: +"Explicit format identifier that overrides detection from the filename. Must be exactly one of: 'camt', 'csv', 'mt940', 'ofx', 'pain001', 'qfx' (see list_supported_formats). When omitted, the format is inferred from the filename extension."
    • addedInput schema / properties / format / enum
      Added value: +[
      +  "camt",
      +  "csv",
      +  "mt940",
      +  "ofx",
      +  "pain001",
      +  "qfx"
      +]
  4. Changed4 schema fields changedv0.0.16
    • addedInput schema / properties / content / description
      Added value: +"The raw statement text to parse, inline (not a file path). Accepts ISO 20022 CAMT.053 and pain.001 XML, SWIFT MT940, CSV exports, and OFX/QFX payloads."
    • addedInput schema / properties / filename / description
      Added value: +"Original filename of the payload; its extension (.xml, .csv, .ofx, .qfx, .mt940, .sta) selects the format when 'format' is omitted. Defaults to 'statement.xml'."
    • addedInput schema / properties / format / description
      Added value: +"Explicit format identifier that overrides detection from the filename. One of: 'camt' (CAMT.053), 'pain001', 'csv', 'ofx', 'qfx', 'mt940'. When omitted, the format is inferred from the filename extension."
    • addedInput schema / properties / limit / description
      Added value: +"Optional maximum number of transaction rows to return. The full 'transaction_count' is always reported even when the returned rows are truncated. When omitted, all rows are returned."
  5. First observedv0.0.14

TDQS

A4.4/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already cover the safety profile (readOnlyHint, idempotentHint, destructiveHint false, openWorldHint false), and the description adds genuinely new behavior: the 'limit' truncates rows while transaction_count stays the full count, and a ToolError is raised for unsupported, undetectable, or unparseable formats. That error contract is the kind of failure-mode detail annotations cannot express. It stops short of 5 only because the return-shape sentence largely duplicates the output schema.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The core action and return shape are front-loaded, followed by sibling routing and then a Raises block, which is a sensible ordering. It is slightly verbose with reST-style double backticks and a multi-line return enumeration, but no sentence is outright wasted.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a read-only parser with 4 well-documented parameters and an output schema, the description covers what the tool does, what comes back, how to truncate results, when to use the two alternatives, and what errors to expect. Nothing an agent needs in order to call it correctly is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, including the enum values and the filename-extension detection rule, so the schema already carries parameter meaning. The description reinforces the limit-versus-transaction_count relationship and the format-override resolution order, but adds no syntax or edge-case detail beyond what is already written in the properties. Baseline 3 applies when the schema does the heavy lifting.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with a specific verb and resource: 'Parse an inline statement payload into transaction rows and a summary.' It also names the two nearest siblings (summarize_statement, validate_statement) and what they return instead, so an agent can distinguish this tool from them without opening any schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It gives explicit routing: for balances only, use summarize_statement; to confirm a payload parses without any rows, use validate_statement. Both alternatives come with the condition that selects them, leaving nothing to inference.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.