Open-source electronic invoicing for Italian freelancers - CLI-first with AI workflows
Project description
OpenFatture 🧾
Open-source electronic invoicing for Italian freelancers — built around a CLI-first workflow, AI automation, and payment reconciliation.
📘 For the consolidated v1.1.0 documentation, visit the docs hub at
docs/README.mdand the release notes indocs/releases/.
Quick Links
docs/README.md– Documentation hub and navigation indexdocs/QUICKSTART.md– Extended quickstart (15-minute setup walkthrough)QUICKSTART.md– Quickstart (5-minute CLI tour)docs/releases/v1.1.0.md– Latest release notesdocs/releases/v1.0.1.md– Upcoming AI cash flow upgrade (in progress)CHANGELOG.md– Full change logdocs/history/ROADMAP.md– Roadmap and phase breakdowndocs/reports/TEST_RESULTS_SUMMARY.md– Test and coverage reportCONTRIBUTING.md– Contribution guidelines
Highlights
- Core invoicing – Generates FatturaPA XML v1.9, handles PEC delivery to SDI, supports digital signatures, and validates automatically.
- Payment & reconciliation – Multi-bank imports, intelligent reconciliation, and configurable reminders (
docs/PAYMENT_TRACKING.md). - AI workflows – Chat assistant, VAT guidance, and description generation powered by OpenAI, Anthropic, or Ollama (
examples/AI_CHAT_ASSISTANT.md). - Developer experience – Modern Python toolchain (uv, Typer, Pydantic), 117 automated tests with CI coverage gate at 50% (targeting 60%), plus Docker and Makefile automation.
- Compliance & operations – GDPR-ready logging, professional email templates, and turnkey PEC workflows.
Demo Library
- Scenario A — Setup & configuration: https://github.com/user-attachments/assets/scenario_a_onboarding.mp4
- Scenario B — Professional invoicing: https://github.com/user-attachments/assets/scenario_b_invoice.mp4
- Scenario C — AI Assistant with local Ollama: https://github.com/user-attachments/assets/scenario_c_ai.mp4
- Scenario D — Batch operations & analytics: https://github.com/user-attachments/assets/scenario_d_batch.mp4
- Scenario E — PEC integration & SDI notifications: https://github.com/user-attachments/assets/scenario_e_pec.mp4
- Additional assets live in
media/output/(videos) andmedia/screenshots/(images)
Getting Started
Prerequisites
- Python 3.12 or later
- uv package manager
- PEC mailbox credentials (for SDI delivery)
- Optional: digital signature certificate (PKCS#12)
Installation & Setup
git clone https://github.com/gianlucamazza/openfatture.git
cd openfatture
uv sync
cp .env.example .env
Populate .env with company data, PEC credentials, and notification settings (see docs/CONFIGURATION.md), then initialise the database:
uv run python -c "from openfatture.storage.database.session import init_db; init_db()"
Next Steps
- Follow the extended quickstart in
docs/QUICKSTART.mdor the slim walkthrough inQUICKSTART.md. - Review the complete CLI catalogue in
docs/CLI_REFERENCE.md. - Explore
docs/PAYMENT_TRACKING.mdto master reconciliation and reminders.
Usage
CLI Examples
uv run openfatture fattura crea
uv run openfatture payment reconcile
uv run openfatture --interactive
Python API
from openfatture.storage.database.models import Fattura
from openfatture.core.xml.generator import FatturaXMLGenerator
from openfatture.utils.email.sender import TemplatePECSender
from openfatture.utils.config import get_settings
invoice = Fattura(...) # See QUICKSTART for complete examples
xml_tree = FatturaXMLGenerator(invoice).generate()
TemplatePECSender(settings=get_settings()).send_invoice_to_sdi(
invoice,
xml_path="invoice.xml",
signed=False,
)
More examples live in the examples/ directory.
Documentation
docs/README.md– Navigation index for guides, diagrams, and releasesdocs/CONFIGURATION.md– Complete.envand settings referencedocs/AI_ARCHITECTURE.md– AI agent architecture and integrationsdocs/PAYMENT_TRACKING.md– Reconciliation workflows and remindersdocs/ARCHITECTURE_DIAGRAMS.md– Mermaid diagrams of the platform
Development
- Install dev extras and pre-commit hooks:
uv sync --all-extrasanduv run pre-commit install - Run the tests:
uv run python -m pytest(coverage:uv run python -m pytest --cov=openfatture) - CI/CD, automation, and media workflows are documented in
docs/DEVELOPMENT.md,docs/operations/SETUP_CI_CD.md, and related guides
Project Status
- Latest stable release:
docs/releases/v1.0.1.md(AI Cash Flow Upgrade) - Detailed roadmap and phase summaries:
docs/history/ROADMAP.mdanddocs/history/PHASE_*_SUMMARY.md - Current focus: AI orchestration (Phase 4) and production hardening (Phase 6)
Contributing & License
Contributions are welcome! Read CONTRIBUTING.md and open an issue for substantial proposals. OpenFatture ships under the MIT License (see LICENSE).
Support
- Documentation:
docs/README.md, quickstart guides, and theexamples/directory - Community: GitHub Discussions
- Bugs & feature requests: GitHub Issues
- Email: info@gianlucamazza.it
Disclaimer
The software is provided “as-is” for educational and production use. Ensure compliance with Italian tax regulations and consult a certified accountant when in doubt.
Made with ❤️ by freelancers, for freelancers.
Project details
Release history Release notifications | RSS feed
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 openfatture-1.1.0.tar.gz.
File metadata
- Download URL: openfatture-1.1.0.tar.gz
- Upload date:
- Size: 7.5 MB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
174cb927cd86e9ee897eeedde935fae20441eb4c291983851503586545310131
|
|
| MD5 |
8a3c5c1173dc41696891ef8e8b0a21b2
|
|
| BLAKE2b-256 |
c13db8f90c2c0a5966b75fa57a384fd3ef4f008a3cdcdba5a730ecf5eaccedd2
|
File details
Details for the file openfatture-1.1.0-py3-none-any.whl.
File metadata
- Download URL: openfatture-1.1.0-py3-none-any.whl
- Upload date:
- Size: 431.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7fe527d4ef2950ef06e659fc8ad977e57a23f1f52498c034c68696697f7d9668
|
|
| MD5 |
d230298d48e83a551f06fcd3ee0fcf2a
|
|
| BLAKE2b-256 |
fca3874fcf2c07f2a43608dc89ff1814f7c00f2de2cfbc24e567997e40a13abe
|