Skip to main content
|stdio| B["pain001-mcp"]
B -->|delegates to| C["pain001"]
C -->|render + validate| D["ISO 20022 pain.001 XML"]

---

## When not to use pain001-mcp

- **You're not driving an MCP-aware agent.** Use the CLI
  (`pain001 …`) or the REST API (`pain001 serve`) directly — both expose
  the same surface with less indirection.
- **You need editor diagnostics, not agent tools.** Use
  [`pain001-lsp`](https://pypi.org/project/pain001-lsp/) — it speaks
  the Language Server Protocol to VS Code, Neovim, Helix, Emacs, etc.
- **You need to extend the tool surface in-tree.** The companion
  [`pain001[mcp]`](https://github.com/sebastienrousseau/pain001) extra
  exposes the same FastMCP instance and is easier to fork inside an
  organisation's pain001 install.

---

## Development

`pain001-mcp` uses [Poetry](https://python-poetry.org/) and
[mise](https://mise.jdx.dev/).

```bash
git clone https://github.com/sebastienrousseau/pain001-mcp.git
cd pain001-mcp
mise install
poetry install

A Makefile orchestrates the quality gates (kept in lockstep with CI):

Target What it runs
make check All gates (REQUIRED before commit)
make test pytest --cov=pain001_mcp --cov-branch --cov-fail-under=100
make lint ruff check + black --check
make type-check mypy --strict
make docs interrogate --fail-under=100 (docstring coverage)

Current state (v0.0.57): 71 tests passing, 100% line + branch coverage against a 100% enforced floor, mypy --strict clean, interrogate 100%.


Security

  • No filesystem writes from tools. generate_message and generate_message_from_file return the XML as a string; no tool writes to disk.
  • XML parsing of camt.053 and pain.002 is routed through defusedxml (via the core pain001 library); XXE and entity expansion are rejected.
  • Validation failures are returned as structured {"error": ...} payloads — never as stack traces — so the agent never sees an internal path leak.
  • Dependencies are pinned via poetry.lock and audited by pip-audit and Bandit in CI.

To report a vulnerability, please use GitHub private vulnerability reporting rather than a public issue.


Documentation


Contributing

Contributions are welcome — see the contributing instructions. Thanks to all the contributors who have helped build pain001-mcp.


Related MCP Servers

Part of the ISO 20022 MCP Suite — open-source, Apache-2.0 licensed MCP servers for banking and financial-services AI agents:

Server Purpose
pacs008-mcp Generate, validate, parse & scheme-check ISO 20022 pacs.008 FI-to-FI credit transfers + Nov-2026 address linting
camt053-mcp Parse & reconcile ISO 20022 camt.053 bank-to-customer statements — CBPR+/HVPS+ ready
acmt001-mcp Generate & validate ISO 20022 acmt account-management messages
bankstatementparser-mcp Parse bank statements (BAI2, MT940/MT942, CAMT.053, OFX, CSV) into structured transactions
noyalib-mcp Lossless YAML 1.2 parsing, formatting & validation (Rust, 100% spec compliance)

MCP Registry

mcp-name: io.github.sebastienrousseau/pain001-mcp


License

Licensed under the Apache License, Version 2.0. Any contribution submitted for inclusion shall be licensed as above, without additional terms.


pain001.com · PyPI · GitHub

Release files for pain001-mcp 0.0.63

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pain001-mcp 0.0.63
File Size Uploaded
pain001_mcp-0.0.63.tar.gz 31.6 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for pain001-mcp 0.0.63
File Interpreter ABI Platform
pain001_mcp-0.0.63-py3-none-any.whl Python 3 none any Details

Total release size:59.9 kB

Release files / pain001_mcp-0.0.63.tar.gz

Download URL pain001_mcp-0.0.63.tar.gz
Size 31.6 kB
Tags Source
SHA-256 checksum
How to use checksums
55a85a774e2832123d7a89c8ed708da7a25701f47e0696c1d3632aae2dc4af40
BLAKE2b-256 checksum
How to use checksums
993de950acfa8d915837fac86381dffa44819f98678dfe1233103056f71e834f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 29, 2026.

Transparency log

Release files / pain001_mcp-0.0.63-py3-none-any.whl

Download URL pain001_mcp-0.0.63-py3-none-any.whl
Size 28.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f4516f256104ad1ecb4994938c7f95d0dba719eb48f6c48b0e49693b71dcdd8b
BLAKE2b-256 checksum
How to use checksums
f399d651706d1ec5c150abe91b1acec679fb7c45993ddfa9527baa036f661904
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 29, 2026.

Transparency log

Release history Release notifications | RSS feed

0.0.70

2 release files

0.0.69

2 release files

0.0.68

2 release files

0.0.67

2 release files

0.0.66

2 release files

0.0.65

2 release files

This release

0.0.63 This release

2 release files

0.0.62

2 release files

0.0.61

2 release files

0.0.60

2 release files

0.0.59

2 release files

0.0.58

2 release files

0.0.57

2 release files

0.0.56

2 release files

0.0.55

2 release files

0.0.53

2 release files

0.0.52

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page