VeriFactu

io.github.ArceeDev由 GitHub 帳號 ArceeDev 發布v0.1.0更新於 Nov 7, 2026

Audit VERI*FACTU hash chains, build the AEAT tax QR, build and validate Facturae 3.2.2 invoices.

已驗證Streamable HTTP可網頁執行金融開發者工具商業與電商

概覽

AI 產生的概覽

稽核西班牙 VERI*FACTU 發票雜湊鏈、產生 AEAT 稅務 QR 碼,並建立或驗證 Facturae 3.2.2 發票。

可以做什麼
  • 稽核 VERI*FACTU 紀錄鏈(JSON 或匯出的 XML):SHA-256 指紋、前後連結、重複、作廢、格式
  • 計算單筆紀錄的指紋並顯示實際被雜湊的字串
  • 產生 AEAT 稅務 QR 連結與 PNG/SVG 圖片及列印規則
  • 依一般發票資料建立未簽章的 Facturae 3.2.2 XML
  • 驗證 Facturae 檔案:XSD、算術、NIF、DIR3 角色與簽章是否存在
  • 查詢法規期限,以及 NIF 檢查、QR 連結檢查、額度餘額等免費輔助功能
適用情境
適合記帳事務所、會計與發票軟體團隊,用來檢查西班牙開票系統產出的紀錄、準備 Facturae 資料,或在申報、寄送發票前確認 VERI*FACTU 期限。
執行需求
需要 KEYFLINT_LICENSE 中的 KeyFlint 授權(LIC-...),付費工具必需。可作為託管端點透過 OAuth 使用,或以 uvx 從 PyPI 套件 verifactu-keyflint-mcp 在本機執行;多買家託管模式使用 Bearer 授權標頭。選用變數可設定價格、公鑰、結帳網址與最大輸入大小。
安裝前請注意
付費工具每次呼叫會消耗額度,會產生費用;授權金鑰須妥善保管。它不是開票系統:不儲存任何紀錄,也不會向 AEAT 送出資料。產生的 Facturae XML 未簽章,送往 FACe 或 B2B 平台前須以開立方憑證簽章。期限資訊應以 BOE 為準。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 VeriFactu,將其新增到工作區。
  2. 連接 所需的 憑證。它們會被私密儲存,絕不會在公開頁面上展示。
  3. 為需要使用其工具的對話啟用該服務。

Web executable,透過 Streamable HTTP。 遠端服務在工作區中設定後即可從網頁執行環境執行。

交給代理程式安裝

把這段提示詞貼上到 Claude Code、Codex、Cursor 等代理程式,或 SourceWeft 對話中。代理程式會讀取該伺服器的安裝指南,先向你展示發布者、端點和登入方式,經你同意後再把它新增到你的客戶端。金鑰不會寫進任何命令。

閱讀 https://sourceweft.com/mcp/io.github.ArceeDev%2Fverifactu-mcp/install.md,並按其中說明把這個 MCP 伺服器接入我的客戶端。修改任何設定之前,先告訴我它的發布者、端點和登入方式,等我確認。不要把 API 金鑰寫進命令或我會提交的檔案;問我金鑰應從哪裡取得。

檢視代理程式所依據的安裝指南

其他 MCP 客戶端

把它新增到你客戶端的 mcpServers 設定中。 客戶端會在首次連接時完成 OAuth 登入。

{
  "mcpServers": {
    "verifactu": {
      "type": "http",
      "url": "https://mcp.keyflint.dev/verifactu/mcp"
    }
  }
}

README

verifactu-mcp

On PyPI as verifactu-keyflint-mcp (the name verifactu-mcp belongs to another project).

MCP server for Spanish invoicing compliance, built for AI agents working for gestorías, accountants and invoicing-software teams. Offline and stateless: nothing is stored and nothing is sent to the AEAT.

  • Audit VERI*FACTU chains: recompute the SHA-256 fingerprint (huella) of every record (alta and anulación) exactly as the AEAT specifies, and check that each record links to the previous one. Works on JSON records or on the XML any invoicing program exports (validated against the official SuministroLR.xsd).
  • AEAT tax QR: URL and PNG/SVG image (error correction M) for VERI*FACTU and non-VERI*FACTU systems, production or test portal, with the printing rules.
  • Facturae 3.2.2: build an invoice from plain data (totals, VAT breakdown, IRPF withholding, recargo de equivalencia, DIR3 codes for FACe, IBAN) and validate any Facturae file: official XSD, the arithmetic FACe checks, NIFs, DIR3 roles and signature presence.

The fingerprint code is tested against the three reference vectors published by the AEAT.

Tools

ToolCreditsWhat it does
validate_invoice_chain3Audit a chain of records (JSON, up to 20,000): fingerprints, links, PrimerRegistro, duplicates, cancellations of unknown invoices, timestamps, NIF/date/amount/TipoFactura formats. continues_from audits a chain in pieces.
validate_verifactu_xml3Same audit on exported XML (RegFactuSistemaFacturacion, SOAP envelope or any XML with RegistroAlta/RegistroAnulacion), plus XSD validation.
verifactu_hash1Fingerprint of one record, with the exact string hashed.
generate_verifactu_qr1Tax QR URL + image + printing rules.
build_facturae3Facturae 3.2.2 XML (unsigned) from plain invoice data, XSD-validated.
validate_facturae2XSD + arithmetic + NIF + DIR3 + signature check of a Facturae file.
verifactu_calendarfreeDeadlines in force and what is pending in the BOE, with sources.
check_qr_url, validate_nif, pricing, credits_balancefreeHelpers.

Unreadable or invalid input is never charged; a tool that fails after charging is refunded.

Install

Claude Desktop / Claude Code / Cursor (mcpServers entry):

json
{  "verifactu": {    "command": "uvx",    "args": ["--from", "verifactu-keyflint-mcp", "verifactu-mcp"],    "env": { "KEYFLINT_LICENSE": "LIC-..." }  }}

Hosted (one server, many buyers): verifactu-mcp --http or the Dockerfile; each request carries Authorization: Bearer LIC-....

Environment: KEYFLINT_LICENSE, KEYFLINT_URL, KEYFLINT_PUBLIC_KEYS, KEYFLINT_CHECKOUT_URL, VERIFACTU_PRICES (e.g. validate_invoice_chain=5,build_facturae=4), VERIFACTU_MAX_BYTES (default 10 MB).

Visual cards (MCP Apps)

In Claude, ChatGPT, VS Code and Goose every paid tool and credits_balance renders as an interactive card in the chat: credit balance with a refill bar and a buy button, or a result summary (key figures, issues, table preview and credits charged). It is the ui://verifactu/card.html resource, self-contained with no network access. Other clients keep getting the same JSON as before.

Legal status (checked 2026-11-05)

  • VERI*FACTU (RD 1007/2023, Orden HAC/1177/2024; dates from RD-ley 15/2025): 1 Jan 2027 for corporate income tax payers, 1 Jul 2027 for everyone else. Hacienda announced on 5 Oct 2026 a further delay to October 2028, not yet published in the BOE. Taxpayers on SII and the foral territories are out of scope.
  • Mandatory B2B e-invoicing (RD 238/2026, Orden HAC/1028/2026): 6 Oct 2027 for turnover above 8 M EUR, 6 Oct 2028 for the rest; EN 16931 in UBL, CII, EDIFACT or Facturae.
  • Facturae with XAdES signature is mandatory for invoices to public administrations through FACe.

verifactu_calendar returns this with sources. Always confirm in the BOE.

Scope and limits

  • Not an invoicing system (SIF): it keeps no records, sends nothing to the AEAT and does not replace the producer's declaración responsable. Use it to check what a SIF produced, or to prepare data.
  • build_facturae produces unsigned XML. Sign it (XAdES-EPES) with the issuer's certificate before sending to FACe or a B2B platform. Corrective invoices (InvoiceClass OR) and batches are validated but not built yet.
  • If a stored fingerprint only matches after removing trailing zeros from the amounts, it is reported as a warning (correcta_sin_ceros): the record was generated with amounts written differently from the XML.

Sources

  • AEAT, Detalle de las especificaciones técnicas para generación de la huella o hash de los registros de facturación (reference vectors in tests/test_core.py).
  • AEAT, Características del QR y especificaciones del servicio de cotejo.
  • AEAT web service schemas SuministroLR.xsd / SuministroInformacion.xsd, and Facturaev3_2_2.xsd (facturae.gob.es), bundled in src/verifactu_mcp/schemas/ with the W3C xmldsig schema.

Development

bash
pip install -e '.[test]'pytest -q

Business Source License 1.1. Source available; production use needs a KeyFlint license (or must be non-commercial). Each version becomes Apache 2.0 four years after release. See LICENSE. The bundled XSD files belong to their publishers (AEAT, Ministerio de Hacienda, W3C).

來源:README.md,提交 1831b88

工具

0
該伺服器需要登入,因此 SourceWeft 無法在沒有帳號的情況下讀取其工具,也未收錄。已連接帳號所能看到的內容可能因帳號及其權限而異。

版本歷史

1
  1. v0.1.0最新Nov 7, 2026

評分

已滿足適用檢查項的 75%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通必需25 分
  • 已宣告認證方式必需10 分
  • 已列出工具15 分

    請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。

  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分

    請在儲存庫或註冊中心條目中宣告授權條款。