BrazilCEP
About | Install | Quick Start | Documentation | Contribute | Credits
About
BrazilCEP is a minimalist and easy-to-use Python library designed to query CEP (Postal Address Code) data.
Its goal is to provide a unified query interface for multiple search services, simplifying the integration of Python applications with these services.
Currently, it supports several CEP APIs:
Install
To install the latest stable release of BrazilCEP, use pip:
pip install brazilcep
Quick Start
Making a request is straightforward. Start by importing the BrazilCEP module:
>>> import brazilcep
Next, use the get_address_from_cep function to query any CEP:
>>> address = brazilcep.get_address_from_cep('37503-130')
The result is a dictionary containing the address details:
>>> address
{
'district': 'rua abc',
'cep': '37503130',
'city': 'city ABC',
'street': 'str',
'uf': 'str',
'complement': 'str',
}
The CEP must always be provided as a string.
Asynchronous Requests with BrazilCEP
BrazilCEP (version >= 7.0.0) also supports asynchronous operations , allowing you to retrieve address information for a given CEP without blocking your application. This is particularly useful for web applications or services that require high responsiveness.
To perform an asynchronous request, use the async_get_address_from_cep function:
import asyncio
import brazilcep
async def main():
address = await brazilcep.async_get_address_from_cep('37503-130')
print(address)
asyncio.run(main())
Documentation
Comprehensive documentation for BrazilCEP is available on ReadTheDocs.
Contribute
To contribute, follow the guidelines outlined here.
Credits
Copyright (C) 2016-2024 by Michell Stuttgart
Metadata
Release files for brazilcep 7.0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| brazilcep-7.0.1.tar.gz | 16.5 kB | With provenance | Details for brazilcep-7.0.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| brazilcep-7.0.1-py3-none-any.whl | Python 3 | none | any | Details for brazilcep-7.0.1-py3-none-any.whl |
Total release size: 31.7 kB
Release files / brazilcep-7.0.1.tar.gz
| Download URL | brazilcep-7.0.1.tar.gz |
|---|---|
| Size | 16.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
1797dbc462be48a5bcb95853a735d6a4450e172ece3a3dedb2972c656b71dc98
|
|
BLAKE2b-256 checksum How to use checksums |
417f59c96238ef36418166975c51a471577cfb6a644d0eebe1b74998e80b1a4d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.12.9
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Aug 16, 2025.
Transparency logRelease files / brazilcep-7.0.1-py3-none-any.whl
| Download URL | brazilcep-7.0.1-py3-none-any.whl |
|---|---|
| Size | 15.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
74391e3ea8d4011c6dc2f1b97dc401fd727405e789fcce6558057257f1858a3a
|
|
BLAKE2b-256 checksum How to use checksums |
310bf75f8d8d8e8d287e492398d7488052fe1eee775fd9086e0a3f2663003371
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.12.9
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Aug 16, 2025.
Transparency logSecurity for brazilcep 7.0.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
All 2 files in this release have been uploaded with provenance metadata.
Attestation for brazilcep-7.0.1.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Aug 16, 2025.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.