django-xrechnung
Create validated XRechnung XML and printable PDF invoices in Django.
Bring invoicing into your existing Django project: prepare drafts in admin or Python, review calculated totals, then finalize and download both documents. The app runs the official KoSIT validator locally and renders PDFs with WeasyPrint. XML, PDF, and the validation report are stored together when finalization succeeds.
What it does
- Invoices, credit notes, and corrections: generate XRechnung 3.0.2 documents in UBL 2.1, including credit notes and corrected invoices linked to their originals.
- Flexible VAT: combine German 7% and 19% VAT, exempt lines, and reverse charge with separate tax breakdowns, exemption reasons, and consistent decimal rounding.
- Printable PDFs: produce German invoice layouts with customizable templates, wrapping descriptions, repeated table headers, and page numbers.
- Less repeated data entry: reuse seller, contact, and payment defaults for new drafts without changing existing invoices.
- Controlled issuance: enforce ownership and Django permissions, validate before issuing, and preserve finalized documents against edits through the app.
- Django integration: use the supplied admin, review pages, JSON read endpoints, document downloads, and Python services in your own workflows.
Invoice validation and PDF rendering run on your application host. Invoice data is not uploaded to an external validation service.
Project status
Alpha, under active development. The draft-to-document workflow is implemented, including credit notes and corrections. Automated tests exercise real KoSIT acceptance and rejection, PDF output, permissions, calculations, migrations, and installation from a built wheel.
The current scope covers German sellers and buyers, EUR, standard VAT, exemptions and reverse charge, email electronic addresses, and SEPA transfers to German IBANs. See the supported invoice scenarios for exact limits.
Discounts, charges, attachments, additional countries, and transmission integrations are not yet supported. Settlement tracking and cumulative credit limits remain outside the app. PDFs are separate printable documents; PDF/A and ZUGFeRD/Factur-X output are not supported.
Get started
Install from Codeberg with Git available in your environment:
python -m pip install git+https://codeberg.org/fsbraun/django-xrechnung.git
Follow the first-invoice tutorial to install into a Django project and generate your first XML and PDF. The installation guide covers Java and WeasyPrint's system dependencies.
Documentation
The documentation is organized around tutorials, how-to guides, reference, and explanation:
- Configure seller defaults, manage permissions, and customize PDFs.
- Use VAT exemptions and reverse charge.
- Create credit notes and corrected invoices.
- Look up configuration, Python services, and HTTP endpoints.
- Understand finalization and VAT calculations.
- Develop and test or build the Sphinx documentation.
See the runnable example, changelog, and compatibility and release policy.
License
BSD 3-Clause. KoSIT, WeasyPrint, and system fonts retain their upstream licenses.
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file django_xrechnung-0.1.0.tar.gz.
File metadata
- Download URL: django_xrechnung-0.1.0.tar.gz
- Upload date:
- Size: 82.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via:
twine/7.0.0 CPython/3.12.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
07ab19d961e53967a9af2c12a6a33263bf8efb41e5ea576af357c751d93af527
|
|
| MD5 |
9bd336748918f45b417d72380ef5beee
|
|
| BLAKE2b-256 |
536d797a2851aa9b0305480f4f56c60ef5a4c3f716f59771a4b5bf762aa55082
|
File details
Details for the file django_xrechnung-0.1.0-py3-none-any.whl.
File metadata
- Download URL: django_xrechnung-0.1.0-py3-none-any.whl
- Upload date:
- Size: 39.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via:
twine/7.0.0 CPython/3.12.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
cad4fbe0deaf8ed7d20b2556262ab6a8ca3df789180f501f585f93fb97c6a320
|
|
| MD5 |
d1b37a0a0bdeff3de35f352a3c445313
|
|
| BLAKE2b-256 |
bbe0c710d1cb3fbee4816ee0e780d6bdc0e88cac34b86a8401bf6b1b722cfb6e
|