# BrasilAPI API

> BrasilAPI API on Apizie: 4 endpoints (Postal code, Company, Banks, Holidays) returned as clean JSON through one API key. 4 endpoints are live now. Call it over REST at https://zieapi.vercel.app/v1/open-data:brasilapi/{endpoint} or from Claude, ChatGPT and Cursor through the Apizie MCP server. Free plan: 1,000 requests a month.

- Project key: `open-data:brasilapi`
- Category: Open Data
- Status: live
- Source: https://brasilapi.com.br/docs
- Page: https://zieapi.vercel.app/api/open-data/brasilapi
- OpenAPI: https://zieapi.vercel.app/api/open-data/brasilapi/openapi.json

Brazilian public data in one API: postal codes (CEP), banks, holidays, company registry (CNPJ) and area codes.

## Endpoints

### Postal code
`GET https://zieapi.vercel.app/v1/open-data:brasilapi/cep`

| Parameter | Type | Required | Description |
|---|---|---|---|
| cep | string | yes |  |

### Company
`GET https://zieapi.vercel.app/v1/open-data:brasilapi/cnpj`

| Parameter | Type | Required | Description |
|---|---|---|---|
| cnpj | string | yes |  |

### Banks
`GET https://zieapi.vercel.app/v1/open-data:brasilapi/banks`

### Holidays
`GET https://zieapi.vercel.app/v1/open-data:brasilapi/holidays`

| Parameter | Type | Required | Description |
|---|---|---|---|
| year | integer | yes |  |

## Example
```
curl "https://zieapi.vercel.app/v1/open-data:brasilapi/cep" \
  -H "x-api-key: $APIZIE_KEY"
```

## FAQ

### How do I call the BrasilAPI API?
Create a free Apizie key, then send GET https://zieapi.vercel.app/v1/open-data:brasilapi/cep with the header x-api-key. Every endpoint returns { project, data, timestamp }.

### Is the BrasilAPI API free on Apizie?
Yes. The Free plan includes 1,000 requests a month at 100 requests a minute, no credit card.

### Can AI agents use the BrasilAPI API?
Yes. Add the Apizie MCP server (https://zieapi.vercel.app/mcp) to Claude, ChatGPT, Cursor or VS Code, then ask in plain language. The agent calls run_scraper with project key open-data:brasilapi.

### What is the status of the BrasilAPI API?
Live: works with just an Apizie key
