Welcome to Zuora Product Documentation

Explore our rich library of product information

BAI2 Parser

Describes the BAI2 bank statement format, supported banks, core transaction parsing, Citibank-specific enhancements, and known limitations of the BAI2 parser.

BAI2 is an industry-standard bank statement format. All BAI2 parsers share the same core field set but differ in bank-specific quirks (decimal handling, currency maps, regex patterns). Use this topic to determine whether a bank statement file delivered by your bank is supported, what data is extracted, and what is ignored.

Supported banks:

  1. Citi Bank -> Exhaustive support

  2. Truist

  3. Wells Fargo

Background: How a BAI2 file is structured

BAI2 is a plain text, comma-delimited format. Every line is a record identified by the number at the start of the line. Records are read in sequence to build up the context for each transaction.

01, <file header>        ← ignored by all parsers

02, <bank header>        ← sets bank ID, as-of date, and currency (Citibank only)

03, <account header>     ← sets account number, currency, amount sign

16, <transaction>        ← one transaction; references bank+account header above

88, <continuation>       ← additional text for the preceding 16, record

88, <continuation>       ← further continuation lines possible

16, <next transaction>

...

How to identify a BAI2 file: The first line of the file must end with 2/ (e.g., 01,SENDER,RECEIVER,yyMMdd,hhmm,1,64,2/). Files that do not match this are rejected by all BAI2 parsers. BAI3 has no such version check.

Amount encoding: Amounts in the file are integers — no decimal point. The parser inserts the decimal based on the currency. For example, USD 12345 → 123.45.

Date format: yyMMdd (2-digit year, e.g., 260421 = April 21, 2026).

Core transaction processing supported

  1. Transaction amount parsing with multi-currency decimal handling

  2. Currency code extraction

  3. Value date and fund type date parsing

  4. Bank reference number extraction

  5. Customer account reference number extraction

  6. Bank account number extraction

Transaction classification and codes supported

  1. Detail Type codes (Example: 142, 165, etc)

  2. Multi-line continuation records (Code 88)

  3. Transaction description extraction from continuation records

Funds availability handling

Funds availability is not handled.

Bank-specific enhancements

Supports Citibank-specific parsing:

  1. Original amount extraction using regex

  2. FX rate extraction using regex

  3. Bank charge extraction using regex

What are not supported

  • Does not support opening and closing balance parsing

  • Does not support account summaries or totals

  • Does not support sender or remitter identification