用于微软 Bing 搜索 API 集成的模型上下文协议(MCP)服务器,允许AI助手执行网页、新闻和图像搜索。

uv venv
source .venv/bin/activate # 在 Windows 上:.venv\Scripts\activate
uv pip install -e .
设置所需的环境变量:
export BING_API_KEY="your-bing-api-key"
export BING_API_URL="https://api.bing.microsoft.com/" # 可选
对于 Windows:
set BING_API_KEY=your-bing-api-key
set BING_API_URL=https://api.bing.microsoft.com/
uvx bing-search-mcp
在您的 Claude Desktop 配置文件中添加以下内容(在 macOS 上为 ~/Library/Application Support/Claude/claude_desktop_config.json,在 Windows 上为 %APPDATA%\Claude\claude_desktop_config.json):
{
"mcpServers": {
"bing-search": {
"command": "uvx",
"args": [
"/path/to/your/bing-search-mcp"
],
"env": {
"BING_API_KEY": "your-bing-api-key"
}
}
}
}

通用信息、网站和内容的网页搜索。
bing_web_search(query: str, count: int = 10, offset: int = 0, market: str = "en-US")
新闻文章和当前事件的搜索。
bing_news_search(query: str, count: int = 10, market: str = "en-US", freshness: str = "Day")
图像搜索。
bing_image_search(query: str, count: int = 10, market: str = "en-US")