indian-bank-statement-parser¶
Offline-first CLI & Python library to convert Indian bank statement PDFs (HDFC, ICICI, SBI, Axis) into standardized CSV/JSON for GST reconciliation, accounting, and lending workflows.
Why this exists¶
- ๐ 100% local โ bank data never leaves your machine/server
- ๐ฆ 4 major banks, production-ready โ HDFC, ICICI, SBI, Axis (covering ~70% of retail statements)
- ๐ Standardized output โ same schema across all banks (
date,description,debit,credit,balance,ref_no,category) - โ๏ธ Plugin architecture โ add custom bank parsers in ~50 lines
- ๐ณ Docker + PyPI โ
pip installordocker pull, runs anywhere - ๐งพ GST-ready โ optional GSTR-2A reconciliation output
- ๐ค CI/CD friendly โ GitHub Action template included
Quick start¶
Install¶
# pip (standard)
pip install indian-bank-statement-parser
# Poetry
poetry add indian-bank-statement-parser
# UV (fast)
uv add indian-bank-statement-parser
# Docker (no Python needed)
docker pull ghcr.io/raptar231/indian-bank-statement-parser:latest
CLI¶
# Parse all PDFs in a directory
parse-bank-statements \
--input-dir ./statements \
--output-dir ./parsed \
--bank hdfc \
--format csv
# Parse single file
parse-bank-statements \
--input-file ./statement.pdf \
--output-file ./parsed.csv \
--bank icici
# With GST reconciliation (GSTR-2A format)
parse-bank-statements \
--input-dir ./statements \
--output-dir ./parsed \
--bank sbi \
--reconcile-gstr2a \
--gstin 29ABCDE1234F1Z5
# List supported banks
parse-bank-statements --list-banks
Python API¶
from bank_parser import parse_statements, parse_file, list_banks
import pandas as pd
# Parse all PDFs in directory
df = parse_statements(
input_dir="./statements",
bank="hdfc",
output_format="dataframe"
)
# Parse single file
df = parse_file("./statement.pdf", bank="icici")
# With GST reconciliation
df = parse_statements(
input_dir="./statements",
bank="sbi",
reconcile_gstr2a=True,
gstin="29ABCDE1234F1Z5"
)
# Save to CSV
df.to_csv("parsed.csv", index=False)
# List supported banks
print(list_banks())
# ['hdfc', 'icici', 'sbi', 'axis']
Documentation¶
- Quickstart โ Get running in 5 minutes
- Installation โ Detailed install options
- Why not Bank CSV? โ Comparison with bank CSVs
- CLI Reference โ All commands and flags
- Python API โ
parse_statements,parse_file, models - Supported Banks โ HDFC, ICICI, SBI, Axis details
- Output Schema โ Standardized columns
- GSTR-2A Reconciliation โ GST workflow
- Adding a Bank Parser โ Step-by-step guide
- Architecture โ Internal design
- Testing โ Test patterns
- Docker โ Build, run, CI/CD
- GitHub Actions โ CI/CD workflows
- PyPI Release โ Release process
Supported banks¶
| Bank | Status | Statement types |
|---|---|---|
| HDFC | โ Production | Savings, Current, Credit Card |
| ICICI | โ Production | Savings, Current, Credit Card |
| SBI | โ Production | Savings, Current (all regional variants) |
| Axis | โ Production | Savings, Current, Credit Card |
Missing your bank? Add a parser in ~50 lines or request it.
License¶
Apache-2.0 โ see LICENSE.
Built for CA firms, lenders, and fintechs processing Indian bank statements at scale.
Report a bank format issue โข Request a feature โข Request a bank