Endpoint
Authentication
| Header | Required | Value |
|---|---|---|
X-API-Key | Yes | Your API key (bun_...) |
Overview
Resolve any Brazilian postal code (CEP) to a full address instantly. Bunny’s CEP API returns street name, neighborhood, city, and state for any valid 8-digit CEP, with no formatting required.Use cases
- Auto-fill address forms on checkout
- Validate shipping destinations
- Enrich customer records with location data
- Build delivery area maps
Details
Strip hyphens before passing the CEP. Accepts01310100 or 01310-100. Both work. Returns null fields for CEPs that cover an entire municipality with no specific street.
Path parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
cep | string | Yes | Brazilian postal code (CEP), digits only (e.g. 01310100) |
Response
200 OK
| Field | Type | Description |
|---|---|---|
cep | string | The CEP that was looked up (digits only) |
logradouro | string | Street name |
complemento | string | Address complement (may be empty) |
bairro | string | Neighborhood |
cidade | string | City name |
uf | string | State abbreviation (e.g. SP) |
estado | string | Full state name (e.g. São Paulo) |
regiao | string | Brazilian region (e.g. Sudeste, Nordeste) |

