mcp-server-brasil
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@mcp-server-brasil consulta CNPJ 11.222.333/0001-81"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
mcp-server-brasil
Brazilian data APIs as MCP tools. Look up CNPJ, CEP, and live exchange rates (USD/BRL, EUR/BRL) from inside any MCP-compatible client -- Claude Desktop, Cursor, Windsurf, and more.
No API keys required. All sources are free and public (ReceitaWS, ViaCEP, AwesomeAPI).
Features
Tool | Source | What it returns |
| ReceitaWS | Company name, trade name, status, capital, address, partners |
| ViaCEP | Street, neighborhood, city, state, IBGE code, area code |
| AwesomeAPI | Bid/ask, high/low, daily variation for USD and EUR |
In-memory cache on every tool -- avoids duplicate requests and respects ReceitaWS rate limits
Input normalization -- CNPJ/CEP work with or without punctuation
Built-in validation -- rejects malformed CNPJ/CEP before hitting the network
Rate-limit guard -- auto-throttles requests to ReceitaWS (2 s minimum interval)
Zero config, zero API keys
Related MCP server: cnpjaberto
Quick Start
Requirements: Node 18+
git clone https://github.com/davi713albano-coder/mcp-server-brasil.git
cd mcp-server-brasil
npm install
npm run buildThe server runs over stdio and is meant to be launched by an MCP client -- not manually.
MCP Integration
Claude Desktop
Edit claude_desktop_config.json:
OS | Path |
macOS |
|
Windows |
|
{
"mcpServers": {
"brasil": {
"command": "node",
"args": ["/absolute/path/to/mcp-server-brasil/dist/index.js"]
}
}
}Or via npx (once published to npm):
{
"mcpServers": {
"brasil": {
"command": "npx",
"args": ["mcp-server-brasil"]
}
}
}Restart Claude Desktop after editing.
Cursor
Add to .cursor/mcp.json in your project or global config:
{
"mcpServers": {
"brasil": {
"command": "node",
"args": ["/absolute/path/to/mcp-server-brasil/dist/index.js"]
}
}
}Windsurf / Other MCP Clients
Any client that supports the MCP stdio transport can launch the server the same way. Point the command at node and the first arg at dist/index.js.
API Reference
consulta_cnpj
Looks up a Brazilian company by its CNPJ registration number.
Parameters:
Name | Type | Required | Description |
| string | Yes | 14-digit CNPJ, with or without punctuation |
Example request:
{
"cnpj": "00.000.000/0001-91"
}Example response:
{
"cnpj": "00.000.000/0001-91",
"razao_social": "EMPRESA EXEMPLO LTDA",
"nome_fantasia": "EXEMPLO",
"situacao": "ATIVA",
"data_abertura": "01/01/2000",
"natureza_juridica": "Ltda",
"capital_social": "1000000.00",
"atividade_principal": "Comercio de Exemplo",
"endereco": {
"logradouro": "Rua Exemplo",
"numero": "123",
"complemento": "Sala 4",
"bairro": "Centro",
"cidade": "Sao Paulo",
"estado": "SP",
"cep": "01000-000"
},
"telefone": "(11) 0000-0000",
"email": "contato@exemplo.com",
"sociedades": [
{ "nome": "Joao Silva", "qualificacao": "Socio-Administrador" }
],
"ultima_atualizacao": "01/01/2024"
}consulta_cep
Looks up a Brazilian postal code (CEP) and returns the associated address.
Parameters:
Name | Type | Required | Description |
| string | Yes | 8-digit CEP, with or without hyphen |
Example request:
{
"cep": "01001-000"
}Example response:
{
"cep": "01001-000",
"logradouro": "Praca da Se",
"complemento": "lado impar",
"bairro": "Se",
"cidade": "Sao Paulo",
"estado": "Sao Paulo",
"uf": "SP",
"ibge": "3550308",
"ddd": "11"
}cotacao_dolar
Returns the latest USD/BRL and EUR/BRL exchange rates. No parameters required.
Example response:
{
"dolar": {
"moeda": "USD/BRL",
"compra": 5.05,
"venda": 5.06,
"alta": 5.11,
"baixa": 5.04,
"variacao": -0.47,
"atualizado_em": "01/01/2024, 15:30:00"
},
"euro": {
"moeda": "EUR/BRL",
"compra": 5.45,
"venda": 5.46,
"alta": 5.51,
"baixa": 5.45,
"variacao": 0.12,
"atualizado_em": "01/01/2024, 15:30:00"
}
}Configuration
No environment variables or API keys are needed. The server uses free public APIs:
Tool | Upstream API | Rate limit |
| 3 requests / min (free tier). The server auto-throttles to 2 s between calls and caches results in memory. | |
| Generous; results are cached in memory | |
| 20 requests / min (free); results are not cached (live rates) |
Development
# install dependencies
npm install
# build TypeScript
npm run build
# watch mode
npm run devRoadmap
CPF lookup (with proper authentication)
Vehicle plate lookup (SINESP API)
Docker image for easy deployment
Unit tests
TTL-based cache eviction
npm publish for
npxsupport
Contributing
PRs are welcome. To add a new API tool:
Create
src/your-tool.tswithvalidaandconsultarexportsRegister it in
src/index.tsinside theTOOLSarray and theswitchhandlerOpen a PR with a clear description of the tool and its upstream API
License
Available Tools
3 toolsconsulta_cepA
Consulta endereço pelo CEP usando ViaCEP. Retorna logradouro, bairro, cidade, estado.
Inputs: cep (required).
consulta_cnpjA
Consulta dados de empresa pelo CNPJ (ReceitaWS). Retorna razão social, atividade principal, capital social, situação, endereço, sócios etc.
Inputs: cnpj (required).
cotacao_dolarA
Cotação atual do dólar e euro em relação ao BRL (AwesomeAPI).
Inputs: no named parameters.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 3 tools
Each tool has a unique and clearly distinct purpose: one for address lookup by CEP, one for company data by CNPJ, and one for currency exchange rates. There is no overlap in functionality.
Two tools use the 'consulta_' prefix (query), while the third uses 'cotacao_' (rate). While all are descriptive and in snake_case, the prefix inconsistency is a minor deviation from a uniform pattern.
With 3 tools, the server is slightly on the smaller side but still within a reasonable range for a focused query service. The number of tools matches the server's apparent scope of providing common Brazilian data lookups.
The server covers three common Brazilian data queries (address, company, exchange rate) without obvious missing operations for its intended read-only purpose. Minor gaps like historical rates or additional data types exist but do not hinder basic usage.
Maintenance
Related MCP Connectors
CNPJ Brazil MCP — Brazilian company-registry (Receita Federal) lookup via minhareceita.org, an…
Company by CNPJ, CEP, holidays, area codes, banks, NCM, Selic, CDI and IPCA, and CPF and CNPJ checks
Brazilian fiscal MCP server - issue NF-e, NFC-e, NFS-e, CT-e, MDF-e and DC-e via SEFAZ.
Official remote MCP server for Brazilian company data (CNPJ): lookup, filtered search, contacts and partners with masked CPF. 70M CNPJs, base of Aug 2026; updated monthly, with the base date in every response. https://cnpj.ia.br/?utm_source=glama&utm_medium=listing
Related MCP Servers
- AlicenseAqualityDmaintenanceAn MCP server that enables querying detailed address information from Brazilian postal codes (CEPs) via the ViaCEP API, returning data such as street names, neighborhoods, cities, states, regions, and IBGE codes.212MIT

cnpjabertoofficial
AlicenseNot gradedqualityCmaintenanceMCP server for querying Brazilian CNPJ company data, including partner graphs, address/contact joins, CNAE statistics, and national/annual overviews.1MIT- FlicenseNot gradedqualityDmaintenanceAn MCP server that provides a tool to query Brazilian postal codes (CEPs) via the ViaCEP API, returning address details such as street, neighborhood, city, and state.-
- AlicenseNot gradedqualityDmaintenanceMCP server for querying Brazilian postal codes (CEP) from the official Correios source, supporting read-only lookups via natural language in any MCP-compatible client.MIT