无缝查询来自巴西资源的各种数据。通过统一接口访问邮政编码、区号、银行、节假日、税收等方面的信息。轻松地用来自 BrasilAPI 的丰富且更新的数据增强您的AI代理和应用程序。
查看完整的官方文档,请访问 BrasilAPI 文档。
此服务器提供了查询BrasilAPI中所有可用端点的工具。在内部,它使用这个JS客户端与API通信:https://github.com/WillianAgostini/brasilapi-js
查看 Smithery 中的工具页面,以检查和测试每个工具。
安装依赖项:
npm install
构建服务器:
npm run build
开发时自动重建:
npm run watch
由于MCP服务器通过标准I/O进行通信,调试可能会很具有挑战性。我们推荐使用 MCP Inspector,它作为包脚本提供:
npm run inspector
生成更新的构建并进行检查:
npm run build-and-inspect
Inspector 将提供一个URL,以便您可以在浏览器中访问调试工具。
通过 Smithery 自动运行服务器:
npx -y @smithery/cli install @mauricio-cantu/brasil-api-mcp-server
npx -y @smithery/cli@latest install @mauricio-cantu/brasil-api-mcp-server --client claude
查看 Smithery 中的服务器页面,获取其他集成选项,如Cursor等。
下载此项目后,您可以使用 node 运行服务器:
node /绝对路径/to/brasil-api-mcp-server/build/index.js
项目根目录下还有一个Dockerfile,如果您想构建和运行镜像的话。
您可以使用Smithery检查此MCP服务器的功能:
npx -y @smithery/cli@latest inspect @mauricio-cantu/brasil-api-mcp-server
这将显示所有可用工具及其参数以及如何使用它们。
src/
├── apiClient/ # BrasilAPI 客户端
├── tools/ # 工具实现
├── types/ # 接口和类型
├── utils/ # 实用函数
└── index.ts # MCP 主文件(服务器设置和工具列表)