# German E-Invoice (XRechnung / ZUGFeRD) Toolkit

> Read and pre-check XRechnung and ZUGFeRD invoices and create XRechnung XML, with offline Python scripts. Not a validator, not tax advice.

German E-Invoice (XRechnung / ZUGFeRD) Toolkit is a free AI agent skill on Agensi by Tim (loehrning.ai), in Finance & Accounting. It loads into your AI agent through the Agensi MCP server, always in its latest approved version.

- Price: Free
- Creator: [Tim (loehrning.ai)](https://www.agensi.io/creators/loehrning)
- Category: [Finance & Accounting](https://www.agensi.io/skills/finance-accounting)
- Version: 2.0.1
- Last updated: 2026-11-29
- Security: scan passed (2026-11-28); every new listing is also reviewed by a person
- Listing: https://www.agensi.io/skills/german-e-invoice-xrechnung-zugferd-toolkit
- Tags: xrechnung, zugferd, e-rechnung, einvoice, en16931, germany, invoicing, vat

## About this skill

A free skill for German e-invoices. It uses Python 3.9+ with the standard library only.

What it does:
- Opens CII or UBL invoice XML, or a PDF with embedded invoice XML (ZUGFeRD / Factur-X). It shows sender, recipient, amounts, due date, payment details, invoice lines (the first 12 in the text view), attachment names and the profile the file declares. Credit notes, self-billed, negative and unknown document types are not presented as a plain request to pay. It can save the embedded XML.
- Pre-checks CII and UBL against a selection of XRechnung 3.0.2 and EN 16931 rules, with two check scripts that give one combined result, after a script step that reads the XML.
- Creates XRechnung 3.0 CII XML from JSON, and can embed one supporting file or add one link per run.
- Asks for your facts and applies a VAT-law decision table to whether an e-invoice is required. It reports unclear and disputed cases as such.
- Checks the shape and check digits of a Leitweg-ID offline. This does not show that the ID exists.
- Includes short notes on rejections, corrections, receiving and keeping invoices, public buyers, and how to run the official KoSIT validator yourself.

Data: the scripts make no network connections. Your AI assistant runs them and reads their output, and any file content it opens, so invoice data can reach your AI provider under that provider's terms. The pre-check writes temporary data files that contain invoice data; the instructions tell the assistant to delete them.

Coverage: this is a partial pre-check, not a validator, and it does not check the XML schema. A result with no must-fix finding does not show that an invoice is correct or will be accepted. Measured on 28.11.2026: no must-fix finding on 86 official XRechnung test files and 34 CEN examples. Injected errors in covered areas were flagged in 67 of 67 CII and 24 of 24 UBL cases; the checker was improved using these tests, so they overstate real coverage. Outside those areas only 7 of 17 injected errors were flagged (6 at first).

Legal content is as of November 2026. It is not tax or legal advice. Re-check it, especially around the end of 2026.

## Requires

- Python 3.9+

## Known limitations

Not a validator and no XML schema check. Only selected rules: most code lists (country, payment, type, address scheme), the VAT ID prefix, element order, unknown elements and other syntax rules are largely missed. Extension and CVD rules are not covered. EXTENDED line rules and totals are not checked, even though the run can end without a must-fix finding. MINIMUM and BASIC WL get a profile verdict only. A missing VAT total in the invoice currency is shown only as a warning. PDF/A-3 conformance and whether the PDF picture matches the data are not checked. Some PDFs cannot be read, which does not show that there is no XML. ZUGFeRD 1.0 details are not read. The builder writes XRechnung CII only (no UBL, PDF/A-3 or sub-lines; VAT categories S, Z, E, AE, K, G, O). In quantity and unit price a dot is always a decimal point, so German '1.190' must be entered as 1190. Attachments can be added to CII only. Whether an e-invoice is required depends on the facts you enter, covers German VAT law only, and leaves public-sector rules to a note and a reference page. Tax rates, the supply itself, bank accounts and parties are not verified. The official Java KoSIT validator was not run during testing, and behaviour with a live agent was not tested. Legal content is as of November 2026 and is not tax or legal advice.

## How to use this skill

1. Connect your AI agent to Agensi once: add the MCP server https://mcp.agensi.io/mcp/auth and sign in with your Agensi account (OAuth, no API key). Steps for Claude, ChatGPT, Claude Code, Codex, Cursor, VS Code and other agents: https://www.agensi.io/docs/mcp-setup
2. Ask your agent: "Use the German E-Invoice (XRechnung / ZUGFeRD) Toolkit skill from Agensi" and describe your task.
3. Your agent loads the skill from Agensi when it needs it. Nothing is downloaded.

## Frequently asked questions

### Is this an e-invoice validator?

No. It runs a partial offline pre-check against a selection of XRechnung 3.0.2 and EN 16931 rules and does not check the XML schema. A result with no must-fix finding does not show that an invoice is correct or will be accepted. The skill includes notes on running the official KoSIT validator yourself.

### Can it read ZUGFeRD PDFs?

It reads the invoice XML embedded in a ZUGFeRD or Factur-X PDF, as well as CII or UBL XML files. Some PDFs cannot be read, which does not show that there is no XML. It does not check PDF/A-3 or whether the PDF picture matches the data.

### Can it create ZUGFeRD PDFs or UBL files?

No. It creates XRechnung 3.0 CII XML from JSON.

### Does it tell me whether I have to send an e-invoice?

It applies a decision table for German VAT law to the facts you enter and says when a case is unclear or disputed. Legal content is as of November 2026. It is not tax or legal advice.

### Does my invoice data leave my computer?

The scripts make no network connections. Your AI assistant runs them and reads their output and any file it opens, so invoice data can reach your AI provider under that provider's terms.

### What do I need?

Python 3.9 or later. The scripts use the standard library only.

---

Source: [Agensi](https://www.agensi.io), the marketplace of skills for AI agents. Any MCP-compatible agent (Claude, ChatGPT, Claude Code, Codex, Cursor, VS Code and more) connects at https://mcp.agensi.io/mcp/auth and signs in with an Agensi account; setup for every agent: https://www.agensi.io/docs/mcp-setup. Append .md to any skill, guide or docs address on agensi.io for its markdown version.
