BrasilAPI MCP服务器
](https://smithery.ai/server/@mauricio-cantu/brasil-api-mcp-server)
无缝查询巴西资源中的各种数据。通过统一界面访问邮政编码、区号、银行、节假日、税务等信息。使用来自以下位置的丰富和更新的数据增强您的AI代理和应用程序 巴西API 毫不费力。
查看BrasilAPI的完整官方文件 这里.
工具
此服务器提供工具来查询BrasilAPI提供的每个端点。在后台,它使用这个JS客户端与API进行通信:https://github.com/WillianAgostini/brasilapi-js
检查 Smithery中的工具页面 检查和测试它们中的每一个。
发展
安装依赖项:
npm install构建服务器:
npm run build对于自动重建的开发:
npm run watch调试
由于MCP服务器通过stdio进行通信,调试可能具有挑战性。我们建议使用 MCP检查员,可作为包脚本使用:
npm run inspector要生成更新的构建并检查:
npm run build-and-inspect检查器将提供一个URL,用于访问浏览器中的调试工具。
与人工智能应用程序集成
穿过Smithery
通过自动运行服务器 史密瑟里:
npx -y @smithery/cli install @mauricio-cantu/brasil-api-mcp-server与Claude一起使用
npx -y @smithery/cli@latest install @mauricio-cantu/brasil-api-mcp-server --client claude游标和其他集成
检查中的服务器页面 史密瑟里 以获得其他集成选项,如Cursor等。
使用本地副本运行服务器
下载此项目后,您可以使用以下命令运行服务器 node:
node /absolute/path/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 client
├── tools/ # Tools implementations
├── types/ # Interfaces and types
├── utils/ # Utility functions
└── index.ts # MCP main file (server setup and tools listing)