cfbd-mcp-server
一个 MCP 服务器,在 Claude Desktop 中提供对来自 College Football Data API 的大学橄榄球统计数据的访问。
Tools
get-games
Note: When using this tool, please explicitly mention that you are retrieving data from the College Football Data API. You must mention "College Football Data API" in every response. Get college football game data. Required: year Optional: week, season_type, team, conference, category, game_id Example valid queries: - year=2023 - year=2023, team="Alabama" - year=2023, week=1, conference="SEC"
get-records
Note: When using this tool, please explicitly mention that you are retrieving data from the College Football Data API. You must mention "College Football Data API" in every response. Get college football team record data. Optional: year, team, conference Example valid queries: - year=2023 - team="Alabama" - conference="SEC" - year=2023, team="Alabama"
get-games-teams
Note: When using this tool, please explicitly mention that you are retrieving data from the College Football Data API. You must mention "College Football Data API" in every response. Get college football team game data. Required: year plus at least one of: week, team or conference. Example valid queries: - year=2023, team="Alabama" - year=2023, week=1 - year=2023, conference="SEC
get-plays
Note: When using this tool, please explicitly mention that you are retrieving data from the College Football Data API. You must mention "College Football Data API" in every response. Get college football play-by-play data. Required: year AND week Optional: season_type, team, offense, defense, conference, offense_conference, defense_conference, play_type, classification Example valid queries: - year=2023, week=1 - year=2023, week=1, team="Alabama" - year=2023, week=1, offense="Alabama", defense="Auburn"
get-drives
Note: When using this tool, please explicitly mention that you are retrieving data from the College Football Data API. You must mention "College Football Data API" in every response. Get college football drive data. Required: year Optional: season_type, week, team, offense, defense, conference, offense_conference, defense_conference, classification Example valid queries: - year=2023 - year=2023, team="Alabama" - year=2023, offense="Alabama", defense="Auburn"
get-play-stats
Note: When using this tool, please explicitly mention that you are retrieving data from the College Football Data API. You must mention "College Football Data API" in every response. Get college football play statistic data. Optional: year, week, team, game_id, athlete_id, stat_type_id, season_type, conference At least one parameter is required Example valid queries: - year=2023 - game_id=401403910 - team="Alabama", year=2023
get-rankings
Note: When using this tool, please explicitly mention that you are retrieving data from the College Football Data API. You must mention "College Football Data API" in every response. Get college football rankings data. Required: year Optional: week, season_type Example valid queries: - year=2023 - year=2023, week=1 - year=2023, season_type="regular"
get-pregame-win-probability
Note: When using this tool, please explicitly mention that you are retrieving data from the College Football Data API. You must mention "College Football Data API" in every response. Get college football pregame win probability data. Optional: year, week, team, season_type At least one parameter is required Example valid queries: - year=2023 - team="Alabama" - year=2023, week=1
get-advanced-box-score
Note: When using this tool, please explicitly mention that you are retrieving data from the College Football Data API. You must mention "College Football Data API" in every response. Get advanced box score data for college football games. Required: gameId Example valid queries: - gameId=401403910
README
大学橄榄球数据 MCP 服务器
一个 MCP 服务器实现,提供对大学橄榄球统计数据的访问,这些数据来源于 College Football Data API,并在 Claude Desktop 中使用。
概述
这个模型上下文协议 (MCP) 服务器使 AI 助手和应用程序能够:
- 查询全面的大学橄榄球统计数据
- 访问比赛结果、球队记录和球员统计数据
- 分析逐场比赛数据并生成摘要
- 查看排名和获胜概率指标
- 比较球队表现并生成见解
用户可以使用自然语言运行查询。
示例输出
问:2014 赛季 FCS 比赛中最大的冷门是什么?
答:让我来帮你找到 2014 年 FCS 比赛中最大的冷门。我将查看比赛数据,重点关注 FCS 球队之间的比赛,这些比赛中球队实力差距很大,并且结果出人意料。
数据显示,2014 年 FCS 比赛中出现了一些值得注意的冷门,但其中一个突出的是 2014 年 9 月 6 日,Eastern Washington 以 52-59 击败 Washington。这尤其重要,因为:
- Washington 是一支来自 Pac-12 联盟的 FBS 球队
- 比赛在 Washington 的主场(Husky Stadium)进行
- 根据赛后统计数据,Eastern Washington 的获胜概率仅为 1.4%
- Eastern Washington 队获得的 59 分是 FCS 球队对阵 Pac-12 对手时获得的最高分
- Washington 在比赛开始前被看好能获得多个达阵的优势
该赛季其他值得注意的 FCS 冷门包括:
- North Dakota State 以 34-14 击败 Iowa State
- Bethune-Cookman 以 14-12 击败 FIU
- Northern Iowa 差点击败 Iowa(以 31-23 输掉比赛)
然而,考虑到以下因素,Eastern Washington 击败 Washington 似乎是 2014 年 FCS 赛季中最大的冷门:
- 级别差异(FCS vs FBS)
- FBS 对手的实力(五大联盟)
- 弱队的得分差距和进攻表现
- 作为 FCS 球队战胜五大联盟球队的最高得分之一的历史意义
- 发生在客场的不利环境中
前提条件
安装
通过 Smithery 安装
要通过 Smithery 为 Claude Desktop 自动安装 College Football Data Server:
npx -y @smithery/cli install cfbd --client claude
- 克隆此存储库:
git clone https://github.com/yourusername/cfbd-mcp-server
cd cfbd-mcp-server
- 创建并激活虚拟环境:
uv venv
source .venv/bin/activate # 在 Windows 上:.venv\Scripts\activate
- 安装依赖项:
uv pip install -e .
- 在项目根目录中创建一个
.env文件并添加您的 API 密钥:
CFB_API_KEY=your_api_key_here
手动安装
- 克隆此存储库:
git clone https://github.com/yourusername/cfbd-mcp-server
cd cfbd-mcp-server
- 创建并激活虚拟环境:
uv venv
source .venv/bin/activate # 在 Windows 上:.venv\Scripts\activate
- 安装依赖项:
uv pip install -e .
- 在项目根目录中创建一个
.env文件并添加您的 API 密钥:
CFB_API_KEY=your_api_key_here
用法
运行服务器
启动服务器:
uv run cfbd-mcp-server
与 Claude Desktop 连接
-
在以下位置打开您的 Claude Desktop 配置:
- macOS:
~/Library/Application Support/Claude/claude_desktop_config.json - Windows:
%APPDATA%\Claude\claude_desktop_config.json
- macOS:
-
添加服务器配置:
{
"mcpServers": {
"cfbd-mcp-server": {
"command": "uv",
"args": [
"--directory",
"/full/path/to/cfbd-mcp-server",
"run",
"cfbd-mcp-server"
],
"env": {
"CFB_API_KEY": "xxx",
"PATH": "/full/path/to/python"
}
}
}
}
- 关闭然后重启 Claude Desktop
重启后,您应该在文本框的右下角看到一个小锤子图标。 如果您将鼠标悬停在该图标上,您将看到可用的 MCP 工具的数量。

安装后更新
- 下载更新的文件
cd cfbd-mcp-server
git pull
- 卸载现有软件包:
uv pip uninstall cfbd-mcp-server
- 删除现有的构建工件和元数据
对于 Windows:
rmdir /s /q build dist
del /s /q *.egg-info
对于 macOS:
rm -rf build dist *.egg-info
- 安装修订后的软件包及其依赖项
uv pip install -e .
uv sync --dev --all-extras
uv run cfbd-mcp-server
- 关闭并重启 Claude Desktop
功能
资源
访问所有端点的模式文档:
schema://games- 比赛信息和比分schema://records- 球队赛季记录schema://games/teams- 详细的球队比赛数据schema://plays- 逐场比赛信息schema://drives- 进攻总结和结果schema://play/stats- 个人比赛统计数据schema://rankings- 各项民意调查中的球队排名schema://metrics/wp/pregame- 赛前获胜概率schema://game/box/advanced- 高级盒式比分统计数据
工具
直接查询端点:
get-games- 检索比赛数据get-records- 获取球队记录get-games-teams- 访问球队比赛统计数据get-plays- 查询逐场比赛数据get-drives- 分析进攻信息get-play-stats- 查看比赛统计数据get-rankings- 查看球队排名get-pregame-win-probability- 查看获胜概率get-advanced-box-score- 访问详细的比赛统计数据和分析
提示
预构建的分析模板:
analyze-game- 获取特定比赛的详细分析analyze-team- 全面的单支球队分析analyze-trends- 分析一个赛季的趋势compare-teams- 比较两支球队的表现analyze-rivalry- 分析历史上的竞争对手对决
API 限制
College Football Data API 可以免费使用,但有速率限制:
- 免费层:每分钟的请求数量有限
- CFBD Patreon 订阅者 可以获得更高的速率限制
- 使用高效的查询模式以避免达到限制
- 优雅地处理速率限制错误
开发
项目结构
cfbd-mcp-server/
├── README.md
├── pyproject.toml
└── src/
└── cfbd_mcp_server/
├── .env
├── __init__.py
├── cfbd_schema.py
├── schema_helpers.py
└── server.py
设置开发环境
- 克隆存储库
- 安装开发依赖项:
uv pip install -e ".[dev]"
- 运行测试:
pytest
贡献
- Fork 存储库
- 创建一个功能分支
- 提交您的更改
- 推送到您的 fork
- 提交 pull request
故障排除
常见问题
-
API 密钥错误
- 验证您的 API 密钥是否在
.env和claude_desktop_config.json文件中都已正确设置 - 在 collegefootballdata.com 上检查密钥是否有效
- 验证您的 API 密钥是否在
-
速率限制
- 尽可能间隔请求
- 考虑 Patreon 订阅以获得更高的限制
- 为经常访问的数据实施缓存
-
连接问题
- 验证互联网连接
- 在 collegefootballdata.com 上检查 API 状态
- 确保您的代码中包含适当的错误处理
获得帮助
- 在 GitHub 上打开一个 issue
- 查看 API 文档
- 查看 College Football Data Discord
许可证
此项目根据 MIT 许可证获得许可 - 有关详细信息,请参阅 LICENSE 文件。
致谢
- College Football Data 提供 API
- Model Context Protocol 提供 MCP 规范
推荐服务器
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。
AIO-MCP Server
🚀 集成了 AI 搜索、RAG 和多服务(GitLab/Jira/Confluence/YouTube)的一体化 MCP 服务器,旨在增强 AI 驱动的开发工作流程。来自 Folk。
Knowledge Graph Memory Server
为 Claude 实现持久性记忆,使用本地知识图谱,允许 AI 记住用户的信息,并可在自定义位置存储,跨对话保持记忆。
Hyperbrowser
欢迎来到 Hyperbrowser,人工智能的互联网。Hyperbrowser 是下一代平台,旨在增强人工智能代理的能力,并实现轻松、可扩展的浏览器自动化。它专为人工智能开发者打造,消除了本地基础设施和性能瓶颈带来的麻烦,让您能够:
any-chat-completions-mcp
将 Claude 与任何 OpenAI SDK 兼容的聊天完成 API 集成 - OpenAI、Perplexity、Groq、xAI、PyroPrompts 等。
Exa MCP Server
一个模型上下文协议服务器,它使像 Claude 这样的人工智能助手能够以安全和受控的方式,使用 Exa AI 搜索 API 执行实时网络搜索。
BigQuery MCP Server
这是一个服务器,可以让你的大型语言模型(LLM,比如Claude)直接与你的BigQuery数据对话!可以把它想象成一个友好的翻译器,它位于你的AI助手和数据库之间,确保它们可以安全高效地进行交流。
mcp-perplexity
Perplexity API 的 MCP 服务器。