Google 航班MCP服务器
为Google Flights提供数据访问接口的MCP服务器,支持查询航班信息、筛选时间和价格。
快速入门
环境准备
- 安装最新版Claude桌面端或Cursor。
- 克隆本仓库并安装
uv
工具:- MacOS:
curl -LsSf https://astral.sh/uv/install.sh | sh
- Windows:
powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"
- MacOS:
配置MCP服务器
-
编辑配置文件(Claude Desktop路径:
~/Library/Application Support/Claude/claude_desktop_config.json
;Cursor路径:~/.cursor/mcp.json
)。 -
添加以下内容并替换实际路径:
{ "mcpServers": { "flights": { "command": "/ABSOLUTE/PATH/.local/bin/uv", "args": [ "--directory", "/ABSOLUTE/PATH/TO/PARENT/FOLDER", "run", "flights.py" ] } } }
-
重启应用以加载配置。
测试功能
- 查询示例:从亚特兰大到上海的航班选项(2026年1月1日)。
- 筛选航班时间:显示洛杉矶今天晚上8点后的航班。
更多说明请参考官方文档。