This skill uses a Python script to query Dota 2 data via the OpenDota API, focused on common player, match, hero, team, league and pro-scene workflows.
Use the script from the installed skill directory. Do not assume the current working directory is the skill root unless it has been verified.
python ~/.claude/skills/dota2-stats-skill/scripts/dota2_query.py <command> [args]
python ~/.openclaw/plugin-skills/dota2-stats-skill/scripts/dota2_query.py <command> [args]
When already inside this skill directory, the shorter form is also valid:
python scripts/dota2_query.py <command> [args]
The script uses only the Python standard library, so no pip install is required. It needs network access to https://api.opendota.com/api and uses browser-like HTTP headers to reduce 403 risk.
search first, then player and usually recent .match .recent for a quick view, or matches --limit N for a filtered list.wl with filters such as --days N, --hero_id N, or ranked lobby --lobby_type 7.heroes .hero_matchups .hero_rankings .pro_matches, pro_players, teams, team , or leagues.live.constants .python scripts/dota2_query.py search <name> # Search for a player (SLOW: 1-2 min)
python scripts/dota2_query.py player <account_id> # Player info/rank/winrate
python scripts/dota2_query.py wl <id> [--days/--hero_id/--lobby_type] # Win/loss stats
python scripts/dota2_query.py recent <id> # Recent ~20 matches
python scripts/dota2_query.py matches <id> [--limit/--hero_id/--days] # Full match history
python scripts/dota2_query.py heroes <id> [--limit N] # Hero usage stats
python scripts/dota2_query.py peers <id> [--limit N] # Frequent teammates
python scripts/dota2_query.py totals <id> [filters] # Career totals (kills/assists etc)
python scripts/dota2_query.py counts <id> # Categorized stats
python scripts/dota2_query.py rankings <id> # Player hero rankings
python scripts/dota2_query.py ratings <id> # Rank history
python scripts/dota2_query.py refresh <id> # Refresh player data
python scripts/dota2_query.py match <match_id> # Single match details (10 players)
python scripts/dota2_query.py hero_list # All heroes list
python scripts/dota2_query.py hero_stats # Global hero stats
python scripts/dota2_query.py hero_matchups <hero_id> # Hero matchup winrates
python scripts/dota2_query.py hero_rankings <hero_id> # Hero leaderboard (Top players)
python scripts/dota2_query.py benchmarks <hero_id> # Hero performance benchmarks
python scripts/dota2_query.py pro_players # Pro players list
python scripts/dota2_query.py pro_matches [--limit N] # Pro matches
python scripts/dota2_query.py public_matches [--min_rank] # Public matches
python scripts/dota2_query.py live # Live matches
python scripts/dota2_query.py teams [--limit N] # Teams list
python scripts/dota2_query.py team <team_id> # Team details+roster+matches
python scripts/dota2_query.py leagues # Leagues list
python scripts/dota2_query.py constants <resource> # Game constants (heroes/items etc)
python scripts/dota2_query.py find_matches --teamA 1,2 --teamB 3,4 # Search by hero lineup
--days N — Last N days
--hero_id N — Specific hero ID
--lobby_type N — Lobby type (7=Ranked)
--game_mode N — Game mode
--limit N — Limit results
--lang zh|en — Output language (default Chinese)
search → Get account_id
player → View basic info
recent → View recent matches
The tool automatically converts 64-bit Steam IDs to 32-bit Account IDs. You can pass either format.
| Tier | English | 中文 |
|------|---------|------|
| 1 | Herald | 先锋 |
| 2 | Guardian | 卫士 |
| 3 | Crusader | 中军 |
| 4 | Archon | 统帅 |
| 5 | Legend | 传奇 |
| 6 | Ancient | 万古流芳 |
| 7 | Divine | 超凡入圣 |
| 8 | Immortal | 冠绝一世 |
--lang en for English, --lang zh for Chinesesearch command can be slow because the OpenDota search endpoint may take a while. When invoking this command, remind the user that it may take some time. If the user already knows the player's Dota 2 account ID, suggest using player directly for faster results共 1 个版本