Firstcycling Mcp 服务器
概览
什么是 FirstCycling MCP?
FirstCycling MCP(模型上下文协议)是一个提供与职业自行车相关的全面数据的服务器。它是检索职业自行车手、比赛结果和各种自行车赛事信息的宝贵资源。该协议旨在便于访问自行车数据,使其成为对自行车领域感兴趣的爱好者、研究人员和开发人员的重要工具。
FirstCycling MCP 的特点
- 全面数据访问:用户可以访问包括自行车手档案、比赛结果和历史数据在内的广泛数据。
- 用户友好的界面:该服务器设计直观,允许用户轻松导航并检索所需信息。
- 实时更新:提供的数据定期更新,以确保准确性和相关性,反映自行车世界中的最新事件和统计数据。
- 开源:作为一个公共存储库,它鼓励社区的协作和贡献,增强可用数据的丰富性。
- 灵活集成:MCP 可以集成到各种应用程序中,使其成为开发人员将自行车数据纳入项目的多功能工具。
如何使用 FirstCycling MCP
- 访问存储库:访问 FirstCycling MCP GitHub 页面 以探索可用资源和文档。
- 克隆存储库:使用 Git 将存储库克隆到本地计算机进行开发和测试。
git clone https://github.com/r-huijts/firstcycling-mcp.git
- 探索 API:熟悉文档中提供的 API 端点,以了解如何检索所需的数据。
- 集成到您的应用程序中:在您的应用程序中使用数据,无论是用于分析、展示还是进一步开发。
- 贡献:如果您有改进或额外数据要分享,请考虑向存储库贡献。
常见问题解答
问:我可以使用 FirstCycling MCP 检索什么类型的数据?
答:您可以检索有关职业自行车手、比赛结果、历史数据等的信息。
问:FirstCycling MCP 是免费使用的吗?
答:是的,它是一个开放源代码项目,供公众使用。
问:数据更新的频率如何?
答:数据定期更新,以确保反映自行车世界中最新的信息。
问:我可以为 FirstCycling MCP 项目做贡献吗?
答:当然可以!欢迎贡献。您可以分叉存储库,进行更改并提交拉取请求。
问:开发人员是否有可用的文档?
答:是的,存储库中提供了详细的文档,以帮助开发人员有效使用 MCP。
详情
FirstCycling MCP Server
This is a Model Context Protocol (MCP) server that provides professional cycling data from FirstCycling. It allows you to retrieve comprehensive information about professional cyclists, race results, race details, and historical cycling data.
Features
This MCP server offers rich access to professional cycling data, providing tools for:
- Finding information about professional cyclists
- Retrieving race results and details
- Exploring historical race data
- Analyzing rider performance and career progression
- Accessing information about cycling teams and competitions
Real-World Use Cases
With this MCP server, you can use Claude to:
Rider Analysis
- Performance Tracking: "How has Tadej Pogačar performed in the Tour de France over the years?"
- Career Progression: "Show me the team history and career progression of Wout van Aert."
- Specialization Analysis: "What are Mathieu van der Poel's results in Monument classics?"
- Victory Analysis: "List all WorldTour victories for Jonas Vingegaard."
- Historical Comparison: "Compare the Grand Tour results of Primož Roglič and Jonas Vingegaard."
Race Research
- Recent Results: "Show me the results of the 2023 Paris-Roubaix."
- Historical Context: "Who are the youngest and oldest winners of the Tour of Flanders?"
- Team Analysis: "Get the startlist for the 2023 Tour de France with detailed team information."
- Race Statistics: "Show me the victory table for Liège-Bastogne-Liège. Who has won it the most times?"
- Stage Information: "Can you show me the stage profiles for the 2023 Giro d'Italia?"
Sports Journalism
- "Create a detailed profile of Remco Evenepoel for a cycling magazine article."
- "Write a preview for the upcoming Tour de France based on the recent results of top contenders like Tadej Pogačar and Jonas Vingegaard."
- "Analyze the evolution of Tom Pidcock's career based on his race results and team history."
Cycling Education
- "Explain what makes the Monument classics special using data about their history and winners."
- "Create an educational summary about Grand Tours and their significance in professional cycling."
- "Describe the typical career progression of a professional cyclist using examples from the data."
Requirements
- Python 3.10 or higher
uv
package manager (recommended)- Dependencies as listed in
pyproject.toml
, including:- mcp
- beautifulsoup4
- lxml
- pandas
- slumber
- and other packages for web scraping and data processing
Setup
- Clone this repository
- Create and activate a virtual environment:
uv venv source .venv/bin/activate # On macOS/Linux # or .venv\Scripts\activate # On Windows
- Install dependencies:
uv pip install -e .
FirstCycling API
This server uses the FirstCycling API, which has been integrated directly into the project. The API provides methods to fetch data from the FirstCycling website through web scraping.
MCP Tools
The server exposes the following tools through the Model Context Protocol:
Rider Information
| Tool | Description |
||-|
| get_rider_info
| Get basic biographical information about a rider including nationality, birthdate, weight, height, and current team |
| get_rider_best_results
| Retrieve a rider's best career results, sorted by importance |
| get_rider_grand_tour_results
| Get a rider's results in Grand Tours (Tour de France, Giro d'Italia, Vuelta a España) |
| get_rider_monument_results
| Retrieve a rider's results in cycling's Monument classics |
| get_rider_team_and_ranking
| Get a rider's team history and UCI ranking evolution over time |
| get_rider_race_history
| Retrieve a rider's complete race participation history, optionally filtered by year |
| get_rider_one_day_races
| Get a rider's results in one-day races, optionally filtered by year |
| get_rider_stage_races
| Get a rider's results in multi-day stage races, optionally filtered by year |
| get_rider_teams
| Retrieve the complete team history of a rider throughout their career |
| get_rider_victories
| Get a list of a rider's career victories, with optional filters for WorldTour or UCI races |
Race Information
| Tool | Description |
||-|
| get_race_results
| Retrieve results for a specific race edition by race ID and year |
| get_race_overview
| Get general information about a race including history, records, and past winners |
| get_race_stage_profiles
| Retrieve stage profiles and details for multi-stage races |
| get_race_startlist
| Get the startlist for a specific race edition with detailed or basic team information |
| get_race_victory_table
| Retrieve the all-time victory table for a race showing riders with most wins |
| get_race_year_by_year
| Get year-by-year results for a race with optional classification filter |
| get_race_youngest_oldest_winners
| Retrieve information about the youngest and oldest winners of a race |
| get_race_stage_victories
| Get information about stage victories in multi-stage races |
Search Tools
| Tool | Description |
||-|
| search_rider
| Search for riders by name, returning their IDs and basic information |
| search_race
| Search for races by name, returning their IDs and basic information |
Usage
Development Mode
You can test the server with MCP Inspector by running:
uv run mcp dev firstcycling.py
This will start the server and open the MCP Inspector in your browser, allowing you to test the available tools.
Integration with Claude for Desktop
To integrate this server with Claude for Desktop:
-
Edit the Claude for Desktop config file, located at:
- macOS:
~/Library/Application Support/Claude/claude_desktop_config.json
- Windows:
%APPDATA%\Claude\claude_desktop_config.json
- macOS:
-
Add the server to your configuration:
{ "mcpServers": { "firstcycling": { "command": "uv", "args": ["--directory", "/path/to/server/directory", "run", "firstcycling.py"] } } }
-
Restart Claude for Desktop
License
MIT
Server配置
{
"mcpServers": {
"firstcycling-mcp": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"ghcr.io/metorial/mcp-container--r-huijts--firstcycling-mcp--firstcycling-mcp",
"python -m firstcycling"
],
"env": {}
}
}
}