Skip to main content
Glama

BAI2 Bank Statement Parser API - US Treasury

bai2_parser
Read-onlyIdempotent

Parse US BAI2 cash management bank statement files (01/02/03/16/88/49/98/99 records) into structured JSON accounts, opening and closing balances, credit and debit totals, BAI type codes, continuation lines and optional CSV. Deterministic server-side parsing, zero AI, nothing stored, sub-second response for ERP and corporate treasury pipelines. Free: 5 calls/day per IP. Paid: Radar API key (from €15/mo at https://radarbg.com/pricing#starter via X-API-Key) or $0.005/call via x402 at https://radarbg.com/x402/bai2-parser.

Example tool call

This call uses example arguments supplied in the tool’s input schema.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "limit": 50,
      "content": "01,CHASUS33,ACMECORP,261115,0800,1,,,2/\r\n02,ACMECORP,CHASUS33,1,261114,2359,USD,2/\r\n03,000123456789,USD,010,2500000,,,015,2795000,,,/\r\n16,165,450000,0,BNKREF001,INV-2026-88,ACH CREDIT NORTHWIND TRADING LLC/\r\n88,PAYMENT FOR INVOICE 2026-88/\r\n16,475,125000,0,BNKREF002,CHK-4012,CHECK PAID OFFICE LEASE/\r\n16,698,30000,0,BNKREF003,FEE-NOV,MONTHLY TREASURY ACCOUNT FEE/\r\n49,5900000,5/\r\n98,5900000,1,7/\r\n99,5900000,1,9/\r\n"
    },
    "name": "bai2_parser"
  }
}

Input Schema

NameRequiredDescriptionDefault
limitNoMaximum number of transactions to return per account (1-2000).
contentNoRaw statement text content (UTF-8/ASCII). Provide either content or fileBase64.
fileBase64NoBase64-encoded statement file (alternative to content, max 15 MB).
includeCsvNoWhen true, also return transactions serialized as a ready-to-import CSV string.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.1/5.0
Behavior5/5

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

Annotations only declare readOnly/openWorld/idempotent; the description adds genuinely non-derivable behavior: deterministic server-side parsing with zero AI, no data retention, sub-second latency, a 5 calls/day per-IP free tier, and paid access via X-API-Key or x402. Auth mechanism and rate limits are exactly the operational details annotations cannot convey.

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?

Front-loaded with the capability and record types, then operational facts. The second sentence is a dense run-on mixing performance claims, rate limits, pricing URLs and auth, which is a lot of marketing surface, but every clause is at least actionable.

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

Completeness4/5

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

With no output schema, the description does describe the returned structure (accounts, opening/closing balances, totals, type codes, continuation lines, CSV), which is the key gap to fill. It omits error behavior on malformed or non-BAI2 input and how the limit parameter affects the response, so it is strong but not exhaustive.

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 coverage is 100% and every parameter (limit, content, fileBase64, includeCsv) is documented inline, so the schema carries the load. The description only echoes that CSV output is optional and that continuation lines are captured, adding little beyond the structured fields.

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?

States a specific verb+resource: parse BAI2 US cash management bank statement files, and enumerates the record types handled (01/02/03/16/88/49/98/99) plus the output shape (accounts, balances, credit/debit totals, BAI type codes, continuation lines, optional CSV). The BAI2/format+country naming clearly separates it from the other format parsers in the catalog.

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

Usage Guidelines3/5

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

Implies usage context ('ERP and corporate treasury pipelines') and gives the access tiers, but never states when to pick this over a sibling such as bank_statement_converter or another national-format parser, nor any exclusion criteria. The agent must infer the choice from the format name alone.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources