Skip to main content

Esta biblioteca acessa o site dos Correios para fazer pesquisa por CEP.

USO

>>> from cep import Correios
>>> c = Correios()
>>> resultados = c.consulta('Juarez')
>>> len(resultados)
100
>>> resultados[64]
{'Localidade': u'Jo\xe3o Pessoa', 'Bairro': u'Torre', 'UF': u'PB', 'Logradouro': u'Avenida Juarez T\xe1vora - de 1147/1148 a 1911/', 'CEP': u'58040-021'}
>>> c.detalhe(64)
{'Localidade': u'Jo\xe3o Pessoa', 'Bairro': u'Torre', 'UF': u'PB', 'Logradouro': u'Avenida Juarez T\xe1vora - de 1147/1148 a 1911/1912', 'CEP': u'58040-021'}
>>> c.consulta('91370000', primeiro=True)
{'Localidade': u'Porto Alegre', 'Bairro': u'Vila Ipiranga', 'UF': u'RS', 'Logradouro': u'Rua Alberto Silva - at\xe9 965/966', 'CEP': u'91370-000'}

REQUIREMENTS

  • BeautifulSoup

LICENSE

  • MIT License

TODO

  • Documentação

  • Criar setup.py e registrar no PyPi

  • Hospedar API pública (json/xml)

Metadata

Release files for cep 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for cep 0.1.1
File Size Uploaded
cep-0.1.1.tar.gz 2.9 kB Details

Release files / cep-0.1.1.tar.gz

Download URL cep-0.1.1.tar.gz
Size 2.9 kB
Tags Source
SHA-256 checksum
How to use checksums
9bce0359c2d3919cdc74dba6eff9ff635318446fb758cbf687ef410ad24c0097
BLAKE2b-256 checksum
How to use checksums
98a51988ade3867cb45b8d51fd3a0d9f58c89c06c9b78241d0e0785eb388aaf3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release history Release notifications | RSS feed

This release

0.1.1 This release

1 release file

0.1

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page