多API聚合服务

Multi-MCPs是一个模型上下文协议(MCP)服务器,聚合多个第三方API并将其作为统一的MCP工具暴露出来,支持OpenWeather、Google Maps/Places、NewsAPI等10种常用外部服务。

  • by TaylorChen
  • TypeScript
  • 本地部署
  • 更新于
在 GitHub 查看 taylorchen/muti-mcps

使用说明

多MCP

Multi-MCP是一个模型上下文协议(MCP)服务器,它聚合了多个第三方API,并将其作为统一的MCP工具公开。它附带了对十大常用外部服务的开箱即用支持:OpenWeather、谷歌地图/地点、NewsAPI、GitHub、Notion、Trello、Spotify、Twilio、Unsplash和CoinGecko。

安装

npm i

跑

构建:

npm run build

作为MCP服务器(stdio)运行:

npx @modelcontextprotocol/inspector build/index.js

配置

通过环境变量提供凭据或 config/api-configs.json。环境变量优先于文件值。

示例 config/api-configs.json:

{
  "OPENWEATHER_API_KEY": "...",
  "GOOGLE_API_KEY": "...",
  "NEWS_API_KEY": "...",
  "GITHUB_TOKEN": "...",
  "NOTION_TOKEN": "...",
  "TRELLO_KEY": "...",
  "TRELLO_TOKEN": "...",
  "SPOTIFY_CLIENT_ID": "...",
  "SPOTIFY_CLIENT_SECRET": "...",
  "TWILIO_ACCOUNT_SID": "...",
  "TWILIO_AUTH_TOKEN": "...",
  "UNSPLASH_ACCESS_KEY": "..."
}

您还可以使用以下命令指向自定义配置文件:

export MUTI_MCPS_CONFIG=/abs/path/to/api-configs.json

可用工具(选择)

  • 天气: get_current_weather, get_weather_forecast, get_weather_alerts
  • 地图: search_places, get_directions, geocode_address
  • 新闻: get_top_headlines, search_news, get_sources
  • github: search_repositories, get_repository_info, create_issue, list_commits
  • 概念: query_database, create_page, update_page, search_pages
  • 特雷洛: get_boards, create_card, update_card, get_board_cards
  • Spotify: search_tracks, get_track_info, create_playlist, add_tracks_to_playlist
  • 提里奥: send_sms, make_call, get_message_history
  • 未喷涂: search_photos, get_random_photo, get_photo_details
  • CoinGecko: get_coin_price, get_trending_coins, get_market_data

注意:即使缺少凭据,也会列出工具;如果未配置所需的凭据,调用将失败并显示明确的错误。

许可证

该项目根据MIT许可证获得许可。看 LICENSE 了解详情。