Csstats APIcsstats.org ↗
Access CS2 player profiles, match history, leaderboards, ban stats, and heatmap data from csstats.gg via a single structured API.
What is the Csstats API?
The csstats.gg API exposes 7 endpoints covering CS2 player profiles, match history, leaderboards, and ban statistics. The get_player_profile endpoint returns a detailed stats object including weapon breakdowns, map performance, recent 10-match trends, rank history with ADR and Premier rating over time, and a player's current ban status — all keyed by SteamID64.
curl -X POST 'https://api.parse.bot/scraper/8e04485d-f2ca-441f-a18c-e1d6ac48b195/search_player' \
-H 'X-API-Key: $PARSE_API_KEY' \
-H 'Content-Type: application/json' \
-d '{
"query": "76561198088771412"
}'Typed, relational, agent-ready
A generated client with real types, enums, and the links between objects — the structure a flat JSON response can't carry. Autocompletes in your editor and reads cleanly to coding agents.
- Fully typed · autocompletes
- Objects link to objects
- Typed errors & pagination
Typed Python client. Set up the SDK in your uv project, then pull this API’s typed client:
uv add parse-sdk uv run parse init uv run parse add --marketplace csstats-org-api
uv run parse add --marketplace pulls a pinned snapshot of this canonical API — it won’t change underneath you. To customize it, subscribe and swap to your own copy.
"""
CSStats.gg API Client
Get your API key from: https://parse.bot/settings
Analyze CS2 player performance, check match heatmaps, browse leaderboards,
and track daily ban statistics.
"""
from parse_apis.cs_stats_api import CSStats, LeaderboardType, PlayerNotFound
cs = CSStats()
# Search for a player by Steam ID and inspect their profile
player = cs.players.search(query="76561198088771412")
print(player.username, player.steam_id, player.ban_status)
# Access rank history entries
for entry in player.rank_history:
print(entry.date, entry.premier, entry.adr)
# Get the player's match list via the instance method
match_list = player.matches()
print(match_list.total_matches)
for match_summary in match_list.matches:
print(match_summary.match_id, match_summary.url)
# Get full match details with heatmap data
match = cs.matches.get(match_id="139794175")
print(match.match_id, match.match_info.title)
# Browse the premier leaderboard using the enum
leaderboard = cs.leaderboards.get(type=LeaderboardType.PREMIER)
print(leaderboard.type)
for lb_player in leaderboard.players:
print(lb_player.rank, lb_player.username, lb_player.steam_id)
# Check daily ban statistics
ban_report = cs.banreports.get()
for ban in ban_report.daily_bans:
print(ban.date, ban.num)
# Typed error handling for player lookup
try:
profile = cs.players.get(steam_id="00000000000000000")
print(profile.username)
except PlayerNotFound as exc:
print(f"Player not found: {exc}")
print("exercised: players.search / players.get / player.matches / matches.get / leaderboards.get / banreports.get")
Search for a player by Steam ID, Steam Profile Link, or Custom Steam URL. Returns the player's full profile including stats, weapon stats, map stats, and rank history. The query is resolved to a SteamID64 and the full profile is fetched. Players without CS2 match data will return empty stats and rank_history.
| Param | Type | Description |
|---|---|---|
| queryrequired | string | Steam ID (e.g. 76561198088771412), Steam Profile Link, or Custom Steam URL |
{
"type": "object",
"fields": {
"stats": "object containing overall stats, totals, weapons, maps, past10, best, and matches",
"avatar": "string or null, avatar image URL",
"steam_id": "string, the player's SteamID64",
"username": "string or null, player display name",
"ban_status": "string, ban status such as 'Clean'",
"rank_history": "array of rank history entries with date, adr, premier, csrank, faceit"
},
"sample": {
"data": {
"stats": {
"best": {
"rank": 39069
},
"maps": {
"overall": {}
},
"rank": 38727,
"past10": [],
"totals": {
"overall": {
"wins": 726,
"games": 967
}
},
"matches": [
139794175
],
"overall": {
"hs": 56,
"wr": 75,
"adr": 98,
"kpd": 1.58,
"rating": 1.52
},
"weapons": {
"overall": {}
},
"comp_wins": 264
},
"avatar": null,
"steam_id": "76561198088771412",
"username": "AceaS",
"ban_status": "Clean",
"rank_history": [
{
"adr": 86,
"date": 1695850598000,
"csrank": null,
"faceit": null,
"premier": 0
}
]
},
"status": "success"
}
}About the Csstats API
Player Profiles and Stats
Use search_player or get_player_profile to retrieve a full CS2 player profile by SteamID64, Steam profile URL, or custom URL. Both endpoints return the same response shape: a stats object with sub-keys for totals, weapons, maps, past10, best, and matches, plus avatar, username, ban_status, and a rank_history array. Each rank_history entry includes date, adr, premier, csrank, and faceit fields, letting you reconstruct a player's rating trajectory. Players with no recorded CS2 matches return empty stats and rank_history without an error.
Match History and Heatmaps
get_player_matches returns a paginated list of recent match IDs and a total_matches count for a given SteamID64. Feed those match_id values into get_match_details to retrieve per-match heatmap coordinate arrays — kills, deaths, shots, damage, hurt, smoke, flash, and he — useful for spatial analysis or visualization. Match info includes a match_title via the match_info object.
Leaderboards and Ban Statistics
get_leaderboard returns a ranked list of players for the premier leaderboard type, with each entry containing rank, steam_id, and username. get_ban_stats returns 30 days of global daily VAC and Game Ban counts as a daily_bans array of {date, num} objects, giving a rolling view of ban activity across the CS2 player base.
Social Graph
get_player_played_with retrieves the list of players a given Steam user has shared matches with, including shared stats. The endpoint supports pagination via an offset parameter, and each returned player entry includes a vac field indicating ban status.
The Csstats API is a managed, monitored endpoint for csstats.org — not a raw scraper you maintain. Every endpoint is automatically health-checked on a schedule, and when csstats.org changes and a check fails, the API is automatically queued for repair and re-verified. It is built to keep working as the site underneath it changes.
This isn't an official csstats.org API — it's an independent, maintained REST wrapper over public data. Where the source has no official API (or only a limited one), Parse gives you a stable contract over a source that never promised one, and keeps it current. Need a new endpoint or field? You can revise it yourself in plain English and the agent rebuilds it against the live site in minutes — contributing the change back to the shared API is free.
Will this API break when the source site changes?+
Is this an official API from the source site?+
Can I fix or extend this API myself if I need a new endpoint or field?+
What happens if I call an endpoint that has an issue?+
- Build a CS2 stat tracker that displays a player's Premier rating trend using rank_history entries over time
- Render in-game kill and death heatmaps from get_match_details coordinate arrays for a specific match
- Monitor a team roster's ban_status fields to flag newly VAC-banned accounts
- Populate a leaderboard widget using get_leaderboard premier rankings with steam_id and username
- Analyze weapon performance across a player's profile using the weapons sub-key in the stats object
- Track global VAC ban volume trends by polling get_ban_stats daily_bans over rolling 30-day windows
- Map a player's frequent teammates using get_player_played_with to identify squad patterns
| Tier | Price | Credits/month | Rate limit |
|---|---|---|---|
| Free | $0/mo | 100 | 5 req/min |
| Hobby | $30/mo | 1,000 | 20 req/min |
| Developer | $100/mo | 5,000 | 100 req/min |
One credit = one API call regardless of which marketplace API you call. Exceeding the rate limit returns a 429 response. Authenticate with the X-API-Key header.