
Fattura Elettronica IT
io.github.cmendezs由 GitHub 帳號 cmendezs 發布v0.9.1更新於 Oct 27, 2026
Italian e-invoicing: FatturaPA XML/SDI, XSD v1.2.3, Specs 1.9.1, 43 tools. Signing, SDI, archiving.
概覽
義大利 FatturaPA 電子發票 MCP 伺服器:產生、驗證、簽章、提交並歸檔符合 SDI 規範的電子發票。
- 可以做什麼
- 建構發票標頭與內文:傳輸資訊、賣方/買方驗證、增值稅號驗證、單據類型與 Natura 代碼、明細行、稅額彙總、付款條件、附件
- 產生、依官方 XSD 驗證並解析 FatturaPA XML,匯出 JSON,產生 SDI 檔名,計算預扣稅
- 產生並驗證簡易發票(VFSM10),計算 ritenuta d'acconto
- 使用 PKCS#12 憑證進行 XAdES-BES 或 CAdES-BES 簽章
- 透過 SDICoop 向 SDI 提交已簽章發票、查詢狀態、解析通知並送出接受或拒絕
- 以 SHA-256 驗證歸檔發票,並產生移交認證保管機構的 PdV 封裝
- 適用情境
- 適合需要草擬、檢查或提交義大利 B2B、B2G 或跨境 FatturaPA 發票的情境,也適合已取得 SDI 認證、希望在本機完成從 XML 產生到提交與歸檔全流程的使用者。
- 執行需求
- 以本機 Python 套件執行(pip 或 uvx)。選用環境變數:FATTURA_XSD_PATH(本機 XSD 副本)、LOG_LEVEL、CONSERVAZIONE_STORAGE_PATH。SDI 提交與簽章需要 SDI_CERT_PATH(PKCS#12)、SDI_CERT_PASSWORD、SDI_CHANNEL_ID、SDI_ENVIRONMENT,可選 SDI_ENDPOINT_URL;簽章微服務使用 EINVOICING_SIGNER_SOCKET 與 EINVOICING_SIGNER_TOKEN。正式環境使用 SDI 需取得 Agenzia delle Entrate 認證。
安裝
在 SourceWeft 中
- 開啟 儀表板中的 Fattura Elettronica IT,將其新增到工作區。
- 為需要使用其工具的對話啟用該服務。
Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。
其他 MCP 客戶端
參照 儲存庫 中的啟動說明。
README
mcp-fattura-elettronica-it 🇮🇹
[License] [PyPI version] [Python] [mcp-fattura-elettronica-it MCP server] [Listed in italia-mcp-servers]
Introduction
A Python MCP server for Italian electronic invoicing in FatturaPA XML format (SDI / Agenzia delle Entrate standard, XSD v1.2.3, Specifiche Tecniche 1.9.1). It enables AI agents (Claude, IDEs) to generate, validate, and analyze B2B, B2G, and cross-border electronic invoices that are directly compliant with the technical specifications of the Sistema di Interscambio (SDI). It is built on mcp-einvoicing-core, the shared base library for e-invoicing MCP servers.
Note: "Specifiche Tecniche" (the AdE Allegato A controls/codifiche document) and the XSD schema are two separate artefacts with independent version numbers. Specifiche Tecniche 1.9.1 (in force 2026-05-15) does not change the XSD — the bundled schema remains v1.2.3.
This is a Model Context Protocol (MCP) server exposing 43 tools covering the full lifecycle of a FatturaPA XML document: transmission header construction, seller/buyer validation (including Gruppo IVA / VAT-group CodiceFiscale), document type codes (TD01-TD28), line items with AltriDatiGestionali support, VAT summary computation, payment terms, XSD validation against the official Agenzia delle Entrate schema (v1.2.3), XML generation, parsing, JSON export, SDI filename generation, withholding tax (ritenuta d'acconto) calculation, digital signatures (XAdES-BES and CAdES-BES), direct SDI transmission via SDICoop SOAP, SDI notification parsing, and conservazione sostitutiva (legally compliant archiving per AgID). Licensed under Apache 2.0.
Installation
Via PyPI (recommended)
mcp-einvoicing-core is installed automatically as a dependency.
lxml is also required and included, so no extra steps are needed.
Without prior installation, using uvx:
From source
Configuration
The available environment variables are:
Claude Desktop integration
Add the following to your claude_desktop_config.json file:
Cursor integration
Cursor supports MCP servers via stdio. Add the configuration in:
- Global (all projects):
~/.cursor/mcp.json - Project (this repository only):
.cursor/mcp.json
Reload the Cursor window (Ctrl+Shift+P then Reload Window) to apply the changes.
Kiro integration
Kiro supports MCP servers via its dedicated configuration file. Two levels are available:
- Global (all projects):
~/.kiro/settings/mcp.json - Workspace (this repository only):
.kiro/settings/mcp.json
The file is automatically reloaded on save. You can also open the config via the command palette (Cmd+Shift+P / Ctrl+Shift+P) then MCP.
Kiro security tip: rather than writing secrets in plain text, use the syntax
"SDI_CERT_PASSWORD": "${SDI_CERT_PASSWORD}", Kiro resolves shell environment variables at startup.
Available tools
Header: FatturaElettronicaHeader (7 tools)
Body: FatturaElettronicaBody (8 tools)
Global: generation and validation (7 tools)
Simplified invoices: FatturaSemplificata VFSM10 (3 tools)
Simplified invoices (art. 21-bis DPR 633/72) are valid for transactions up to EUR 400
(tax-inclusive). They use a flatter structure than ordinary FatturaPA: no per-line VAT
breakdown, no DatiRiepilogo. Each DatiBeniServizi entry carries its own Descrizione,
Importo, and DatiIVA. The VFSM10 format uses namespace v1.0 and is separate from
the EN 16931 CIUS used by ordinary invoices.
Digital signatures (2 tools)
Both signature formats are accepted by SDI (Specifiche tecniche SDI v1.8.4, section 2.1).
Supports dual mode: signer microservice (keeps keys out of the MCP process) or direct PKCS#12 loading.
Requires cryptography>=42.0.0 (installed via the [xml-sign] extra on mcp-einvoicing-core).
SDI integration (5 tools)
Requires AdE accreditation for production use. Configure via SDI_CERT_PATH, SDI_CERT_PASSWORD,
SDI_ENVIRONMENT (test/production), and SDI_ENDPOINT_URL (override) environment variables.
Conservazione sostitutiva / archiving (5 tools)
Per AgID circolare 65/2014 and DM 17/06/2014, electronic invoices must be archived for a minimum of 10 years. The local filesystem backend is for development only; production requires integration with an AgID-accredited conservazione provider.
Usage examples
Example 1: Generate a complete B2B invoice
Example 2: Professional invoice with withholding tax
Example 3: Look up VAT exemption codes
Architecture
Vendor neutrality
This server implements the standard itself: it builds, validates, and signs the document locally. It is not a client for a commercial invoicing platform, and your signing keys and credentials never leave your own infrastructure.
Invoices go directly to SdI over SDICoop with your own accreditation; no intermediary is involved.
Supported standards
Tests
Contributing
Contributions are welcome — see CONTRIBUTING.md for guidelines.
Other e-invoicing MCP servers
License
This project is distributed under the Apache 2.0 license. See the LICENSE file for full details. For the full version history, see CHANGELOG.md.
來源:README.md,提交 82bb563
工具
0版本歷史
1- v0.9.1最新Sep 16, 2026
評分
已滿足適用檢查項的 50%
該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。
- 近 30 天內可連通25 分
請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。
- 已宣告認證方式10 分
請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。
- 已列出工具15 分
請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。
- 描述必需15 分
- 圖示10 分
- 文件15 分
- 授權條款10 分