Model Context Protocol server for the speedrun.com API — games, leaderboards, world records, players and personal bests.
Project description
speedrun-mcp
A Model Context Protocol server for speedrun.com. It lets an AI assistant query games, categories, leaderboards, world records, players and their personal bests — e.g. "What's the current Super Mario 64 16-star world record, and who holds it?"
Built on speedrun.com's official, public REST API. No account or API key required (the read endpoints are open); results are shaped into compact, model-friendly JSON (player ids resolved to names, durations formatted, subcategory variables labeled).
Tools
| Tool | What it does |
|---|---|
search_games |
Fuzzy-search games by name → ids & abbreviations |
get_game |
A game's details plus its categories (and optionally levels) |
list_categories |
A game's categories (Any%, 120 Star, …) with rules |
list_variables |
Subcategory/filter variables and their value ids |
list_platforms / list_regions |
Platform / region ids for the platform/region leaderboard filters |
get_leaderboard |
A ranked leaderboard (top N; filter by variable / platform / region / timing) |
get_world_record |
The current #1 run for a game/category, plus any runs tied for first |
search_users |
Find players by username (partial, fuzzy match) |
get_user_personal_bests |
A player's PBs across all games |
get_run |
Details of a single run |
A typical flow: search_games → list_categories (and list_variables for
subcategories) → get_leaderboard / get_world_record. Use list_platforms /
list_regions when you need an id for the platform / region filters.
Install & run
Requires Python 3.10+.
# from PyPI (once published)
pipx install speedrun-mcp # or: uv tool install speedrun-mcp
# from source
git clone https://github.com/williamcodes/speedrun-mcp
cd speedrun-mcp
pip install -e .
The server speaks MCP over stdio:
speedrun-mcp # console script
python -m speedrun_mcp # equivalent
Use with Claude Desktop / Claude Code
Add to your MCP client config (e.g. claude_desktop_config.json):
{
"mcpServers": {
"speedrun": {
"command": "speedrun-mcp"
}
}
}
If you installed from source into a virtualenv, point command at that
interpreter, e.g. "command": "/path/to/.venv/bin/speedrun-mcp".
For Claude Code:
claude mcp add speedrun -- speedrun-mcp
Notes & limits
- Read-only. Submitting or moderating runs requires an authenticated speedrun.com session and is intentionally out of scope.
- Rate limit: speedrun.com allows 100 requests/minute per IP and responds with HTTP 420 when exceeded; the client surfaces a clear error if you hit it.
- Game and category arguments accept either an id (
o1y9wo6q) or an abbreviation (sm64). For precise subcategory leaderboards (e.g.16 Star), discover the variable/value ids withlist_variablesand passvariables={variable_id: value_id}. - Errors are explanatory. Invalid ids/filters raise an error that includes
speedrun.com's own message — e.g. passing a
levelto a full-game category returns "The selected category is for full-game runs, but a level was selected."
Output shape
- Times reflect the leaderboard's sort timing. When you pass
timing(realtime/realtime_noloads/ingame), the reportedtime/time_secondsmatch that ranking, not the game's default timing. get_leaderboardreturnsreturned_runs(the number of runs returned, bounded bytopand ties — not the full board size) and arunslist with resolved player names, formatted times, and labeled subcategories.get_world_recordreturnsworld_record(the place-1 run, ornullif the board is empty) plustied(a list of any other runs sharing first place).get_user_personal_bestsreturnsreturned(how many came back, capped bylimit) andtotal_available(the player's true PB count), plus thepersonal_bestslist with game/category names and resolved players.
Development
pip install -e ".[dev]"
pytest -m "not network" # unit tests (offline)
pytest # include live-API tests
ruff check .
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file speedrun_mcp-0.1.0.tar.gz.
File metadata
- Download URL: speedrun_mcp-0.1.0.tar.gz
- Upload date:
- Size: 18.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
dd2e73134bfafb67c22f733e6ef045473537761e471843ac29daa7de750ec5f9
|
|
| MD5 |
aeeaf03838df312124fa5f485c64990d
|
|
| BLAKE2b-256 |
a4bb4ccf2fd4a29830d770fff590be762935c23bc39b5579fbb64d8a29bc84d2
|
Provenance
The following attestation bundles were made for speedrun_mcp-0.1.0.tar.gz:
Publisher:
publish.yml on williamcodes/speedrun-mcp
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
speedrun_mcp-0.1.0.tar.gz -
Subject digest:
dd2e73134bfafb67c22f733e6ef045473537761e471843ac29daa7de750ec5f9 - Sigstore transparency entry: 1913426469
- Sigstore integration time:
-
Permalink:
williamcodes/speedrun-mcp@ed4d92447435266228ca1d131f9a53fc7e3b19ee -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/williamcodes
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@ed4d92447435266228ca1d131f9a53fc7e3b19ee -
Trigger Event:
release
-
Statement type:
File details
Details for the file speedrun_mcp-0.1.0-py3-none-any.whl.
File metadata
- Download URL: speedrun_mcp-0.1.0-py3-none-any.whl
- Upload date:
- Size: 14.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f176f91d7f4442049ef3b4102621e058d0e5a18d4a270bc9abe7e1dbe50a5f4e
|
|
| MD5 |
ab44f9cfaea64b91b2d34267f612f186
|
|
| BLAKE2b-256 |
26ca5b2518663a3f866e6c5cbc6cd44c4f1cc963d3a4ab66510cbb0bead509f4
|
Provenance
The following attestation bundles were made for speedrun_mcp-0.1.0-py3-none-any.whl:
Publisher:
publish.yml on williamcodes/speedrun-mcp
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
speedrun_mcp-0.1.0-py3-none-any.whl -
Subject digest:
f176f91d7f4442049ef3b4102621e058d0e5a18d4a270bc9abe7e1dbe50a5f4e - Sigstore transparency entry: 1913426586
- Sigstore integration time:
-
Permalink:
williamcodes/speedrun-mcp@ed4d92447435266228ca1d131f9a53fc7e3b19ee -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/williamcodes
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@ed4d92447435266228ca1d131f9a53fc7e3b19ee -
Trigger Event:
release
-
Statement type: