Biblioteca para baixar NFSe do Ambiente Nacional (ADN)
Project description
NFSe Nacional
Biblioteca Python para baixar Notas Fiscais de Serviço Eletrônicas (NFSe) do Ambiente de Dados Nacional (ADN).
Instalação
Você pode instalar a biblioteca via PyPI:
pip install dfe-nfse
Uso
Para utilizar a biblioteca, você precisa de um certificado digital A1 (.pfx) e sua respectiva senha.
from nfse import download_nfse
cnpj = "00000000000000"
nsu = 100
output_path = "./notas"
cert_path = "/caminho/para/seu/certificado.pfx"
cert_password = "sua_senha_aqui"
resultado = download_nfse(
cnpj=cnpj,
nsu=nsu,
output_path=output_path,
cert_path=cert_path,
cert_password=cert_password
)
print(resultado)
Requisitos
- Python 3.6+
- requests
- cryptography
Estrutura
Os arquivos XML baixados serão organizados em pastas por ano e mês (ex: 2024.01) dentro do diretório de saída especificado.
Licença
MIT
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 dfe_nfse-0.1.0.tar.gz.
File metadata
- Download URL: dfe_nfse-0.1.0.tar.gz
- Upload date:
- Size: 4.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d61c77ae5f8ff1936fe0a5fb17c351ed9e0119419bf0508c2956abbe6f760a7d
|
|
| MD5 |
666fe89bafc6ac888d97c497c9d6693b
|
|
| BLAKE2b-256 |
2fde9b3258bfe7dac79b539f856369bea1531ca8319dd78ac0c3f5118cd993df
|
File details
Details for the file dfe_nfse-0.1.0-py3-none-any.whl.
File metadata
- Download URL: dfe_nfse-0.1.0-py3-none-any.whl
- Upload date:
- Size: 4.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b9ed14de7f9ad4f7f5e2d60dd8f4a88dcf56ad098d515f2b0f71a44cbffc6f02
|
|
| MD5 |
1575be5fd2dbbac23cea4450a00cfadc
|
|
| BLAKE2b-256 |
42e8655a992ddaacf5632d772428e350687c3a131e7c65d840f780e27276b517
|