Skip to content

tests codecov python versions pypi license contributors pypi-downloads

Brazil Fiscal Report

Python library for generating Brazilian auxiliary fiscal documents in PDF from XML documents.

Supported Documents

Preview Document XML Source
DANFE preview DANFE — Documento Auxiliar da Nota Fiscal Eletrônica NF-e
DANFE Etiqueta preview DANFE Simplificado – Etiqueta — DANFE reduzido para etiquetas de envio NF-e
DACTE preview DACTE — Documento Auxiliar do Conhecimento de Transporte Eletrônico CT-e
DAMDFE preview DAMDFE — Documento Auxiliar do Manifesto Eletrônico de Documentos Fiscais MDF-e
DACCe preview DACCe — Documento Auxiliar da Carta de Correção Eletrônica CC-e
DANFSe preview DANFSe — Documento Auxiliar da Nota Fiscal de Serviços Eletrônica NFS-e
DANFCe preview DANFCe — Documento Auxiliar da Nota Fiscal de Consumidor Eletrônica NFC-e

Usage Modes

1. Python Code

For full customization and integration, use the library directly in Python. Configure margins, fonts, receipt positions, and more for each document type.

Get started

2. CLI (Command Line)

For quick PDF generation from the terminal with a simple config.yaml file.

CLI documentation

3. Try it Online

Upload your fiscal XML and get the PDF instantly — no installation needed.

Try it online

Dependencies

  • FPDF2 - PDF creation library for Python
  • phonenumbers - Phone number formatting
  • python-barcode - Barcode generation
  • qrcode - QR code generation (DANFE, DACTE, DAMDFE, DANFSe and DANFCe)