pain001 — core library, CLI & REST
Ten pain.001 versions plus pain.008.001.02, five scheme rulebooks, exact decimal.Decimal arithmetic, recomputed control totals, streaming for large batches, and a FastAPI microservice.
Open source · ISO 20022 · CBPR+ ready
Pain001 turns the data you already have — CSV, Excel, SQLite, JSON, Parquet, legacy SWIFT MT101 — into schema-validated pain.001 and pain.008 XML, and proves it clean before submission. AI-agent tools and editor diagnostics included.
# Install the suite
pip install pain001 pain001-loader-xlsx pain001-loader-mt101
# Excel in, validated pain.001.001.09 out
pain001 -t pain.001.001.09 -d payments.xlsx -o out/
# Prove it clean before the bank sees it (exit 0 = valid)
pain001 -t pain.001.001.09 -d payments.csv --scheme sepa-sct --dry-runRuns entirely on your machine — no upload, no SaaS, no telemetry. Read the privacy position.
message definitions — pain.001 v03–v12 and pain.008
MCP tools for AI agents, every one read-only
line and branch coverage, enforced as a CI gate
bytes of payment data leave your machine
Start where you work
Files that pass the bank gate first time, and the vocabulary to brief your board — deadlines included.
Payment lifecycle guide ›--dry-run gates with exit codes, scheme rulebooks explained rule by rule, and pain.002 answers parsed for you.
A typed Python API, REST microservice, plugins, and 100% branch-covered code you can actually read.
Technical reference ›The only MCP server in the category — seventeen read-only tools your agents can call locally.
MCP server ›The suite
Every surface — CLI, library, REST, AI agent, editor — runs the same gate: JSON Schema per record, scheme rulebook, then the official XSD. Results never diverge, because there is one pipeline.
Ten pain.001 versions plus pain.008.001.02, five scheme rulebooks, exact decimal.Decimal arithmetic, recomputed control totals, streaming for large batches, and a FastAPI microservice.
The MCP server for ISO 20022 payment initiation. Agents validate identifiers, migrate versions, convert MT101, and generate validated XML — locally, over stdio, read-only by contract.
Meet the MCP server ›Live schema validation, IBAN checksum and BIC diagnostics, completion, hover documentation, quick fixes, and formatting for payment JSON in VS Code, Neovim, Helix, and Emacs.
Editor integration ›Parse legacy SWIFT MT101 into records that pass pain.001.001.09 validation — the version mandated when the interbank relay retires on 14 November 2026. Field mapping published in full.
Direct .xlsx/.xlsm ingestion with an IBAN safety guard: numeric cells in account columns stop the load before Excel's silent coercion corrupts a single account number.
Zero-trust XML via defusedxml, path-traversal guards, a plugin kill switch, non-root containers, a CycloneDX SBOM — and where an open implementation sits in a patented market.
The ISO 20022 cutover is done: MT–MX coexistence on SWIFT ended on 22 November 2025, and roughly 97% of cross-border payment instructions now travel as ISO 20022. What remains is data quality, and the clock runs to 14 November 2026 — the day fully unstructured postal addresses stop being accepted in CBPR+ payments, and the interbank MT101 relay is replaced by pain.001 version 9.
Pain001 ships both requirements today: structured and hybrid address elements in generated XML, and one-command MT101 conversion. The 2026 migration briefing maps every deadline with primary sources — no vendor fog, just dates and citations.
Start with the Installation Guide, browse the Technical Reference, or see how Pain001 compares — including where commercial platforms genuinely win.
The field
The full, sourced analysis — including what commercial platforms genuinely do better — is on the comparison page.
| Capability | Pain001 suite | Commercial translators | Open-source generators |
|---|---|---|---|
| Licence & auditability | ✓ Apache-2.0 / MIT, full source | ✗ Closed; SWIFT SDK lists €10–30k/yr | ✓ Open source |
| pain.001 version coverage | ✓ v03–v12 + pain.008.001.02 | Broad, vendor-dependent | Mostly SEPA v03-era |
| Data ingestion | ✓ CSV, Excel, SQLite, JSON, Parquet, MT101, GPG | Via integration projects | ✗ Code-level dicts only |
| Validation as a hard gate | ✓ JSON Schema + rulebooks + official XSD | ✓ Core product | Minimal / optional |
| AI-agent interface (MCP) | ✓ 17 tools, local, read-only | ✗ None shipped | ✗ None |
| Editor language server | ✓ pain001-lsp | ✗ None | ✗ None |
| Bank connectivity & support SLAs | ✗ Out of scope by design | ✓ Their core value | ✗ None |
Questions
The five most common — the full FAQ covers treasury, operations, engineering, and audit.
Banks reject malformed payment files, and each rejection costs a repair cycle and sometimes a settlement day. Pain001 converts the data you already have — CSV, Excel, SQLite, JSON, Parquet, or legacy MT101 — into ISO 20022 XML that has already passed JSON Schema checks, IBAN/BIC validation, scheme rulebooks, and the official XSD before submission.
Yes, both of them. Pain001 emits the structured and hybrid postal addresses CBPR+ requires from 14 November 2026, and the MT101 loader converts legacy request-for-transfer flows to pain.001.001.09 — the version that replaces the interbank MT101 relay on the same date. Sources for every deadline are in the 2026 briefing.
pain001-mcp exposes 17 tools: identifier validation, schema inspection, record validation, version migration, MT101 conversion, camt.053 and pain.002 parsing, charset sanitisation, and XML generation. Every tool is read-only and idempotent, transport is local stdio, and no tool can submit a payment — generation and validation only.
Amounts are decimal.Decimal throughout generation, control totals are recomputed rather than trusted, XML parsing routes through defusedxml, containers run non-root, plugin discovery has a kill switch, and the core holds 100% line and branch coverage as a hard CI gate. Nothing phones home; all processing is local.
Nothing, at any scale. The core is dual-licensed Apache-2.0 / MIT; companions are Apache-2.0. The nearest commercial reference point — SWIFT's translation SDK — is publicly listed at €10,000–30,000 per year before integration costs.
Community
Development, issues, and releases are all public. If Pain001 runs in your payment pipeline, telling us makes the project better for everyone — and earns you a place on this page when we publish adopter stories.
Three commands from install to a validated ISO 20022 payment file. Free at any scale, processed entirely on your infrastructure.