# Speedrun API
> Video-game speedrunning data as an API, powered by speedrun.com — the central community hub where players submit and rank their fastest completions of video games. This API turns that catalogue into clean JSON. /v1/games?name=mario searches the game database, returning each game's id, name, abbreviation, release year and weblink. /v1/categories?game=o1y9wo6q lists a game's run categories — the different ways a game is raced, such as Any%, 100%, 120 Star or Glitchless — with each category's id, type and the rules that define a valid run. /v1/leaderboard?game=o1y9wo6q&category=wkpoo02r returns the leaderboard for a game and category: the ranked runs with the runner name(s), the finish time both in seconds and in human-readable form (e.g. 1h 35m 14s), the date of the run and a link to the run video where available (top caps how many runs, 1-100). The natural flow is games to categories to leaderboard. Ideal for gaming dashboards and record trackers, stream overlays and bots, esports and community sites, and data analysis of speedrunning trends. Game and category ids are speedrun.com ids (e.g. game o1y9wo6q = Super Mario 64). Data from speedrun.com (free to use).

## Authentication
All requests require your oanor API key in the `x-oanor-key` header. Get one at https://www.oanor.com/developer/keys.

```bash
curl -H "x-oanor-key: oanor_live_…" "https://api.oanor.com/speedrun-api/..."
```

## Pricing
- **Free** (Free) — 2,800 calls/Mo, 2 req/s
- **Starter** ($6/Mo) — 46,000 calls/Mo, 5 req/s
- **Pro** ($18/Mo) — 195,000 calls/Mo, 12 req/s
- **Mega** ($47/Mo) — 720,000 calls/Mo, 35 req/s

## Endpoints

### Speedrun

#### `GET /v1/categories` — A game run categories

**Parameters:**
- `game` (query, required, string) — Game id (from /v1/games), e.g. o1y9wo6q Example: `o1y9wo6q`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/speedrun-api/v1/categories?game=o1y9wo6q"
```

**Response:**
```json
{
    "data": {
        "game": "o1y9wo6q",
        "count": 6,
        "categories": [
            {
                "id": "zdnq4oqd",
                "name": "Stage RTA",
                "type": "per-level",
                "rules": "# General Rules (updated 10/16/2023) The goal of Stage RTA is to collect all 7 stars within a given stage (the 6 named stars on the star select screen and the 100 coin star). Stage RTA generally follows the same rules as those listed under the main Game Rules with the addition of the following: - You must start your run from the star select menu on the relevant stage (e.g. starting from level rese",
                "weblink": "https://www.speedrun.com/sm64/levels?h=Stage_RTA&x=zdnq4oqd"
            },
            {
                "id": "wkpoo02r",
                "name": "120 Star",
                "type": "per-game",
                "rules": "# 120 Star Rules Beat the game while collecting all 120 stars with the following restrictions: ## ## Gameplay Restrictions: - None",
                "weblink": "https://www.speedrun.com/sm64?h=120_Star&x=wkpoo02r"
            },
            {
                "id": "7dgrrxk4",
                "name": "70 Star",
                "type": "per-game",
                "rules": "# 70 Star Rules Beat the game as quickly as possible with the following restrictions: ## Gameplay Restrictions: - All forms of [BLJ](https://ukikipedia.net/wiki/Backwards_Long_Jump) are banned - All forms of [MIPS clipping](https://ukiki
…(truncated, see openapi.json for full schema)
```

#### `GET /v1/games` — Search games

**Parameters:**
- `name` (query, required, string) — Game name, e.g. mario Example: `mario`
- `limit` (query, optional, string) — Max results (1-50)

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/speedrun-api/v1/games?name=mario"
```

**Response:**
```json
{
    "data": {
        "count": 10,
        "games": [
            {
                "id": "m1mezg4d",
                "name": "New Super Mario Game",
                "weblink": "https://www.speedrun.com/nsmg",
                "released": 2026,
                "abbreviation": "nsmg"
            },
            {
                "id": "yd477mgd",
                "name": "64 Mario in Baldi's Basics Classic",
                "weblink": "https://www.speedrun.com/64_Mario_in_Baldis_Basics_Classic",
                "released": 2026,
                "abbreviation": "64_Mario_in_Baldis_Basics_Classic"
            },
            {
                "id": "k6q9p291",
                "name": "Super Mario Odyssey Boss Rush",
                "weblink": "https://www.speedrun.com/SMOBR",
                "released": 2026,
                "abbreviation": "SMOBR"
            },
            {
                "id": "9d37wr06",
                "name": "Super Mario Bros. Daredevil Edition",
                "weblink": "https://www.speedrun.com/smbde",
                "released": 2026,
                "abbreviation": "smbde"
            },
            {
                "id": "yd47oqxd",
                "name": "Mario Tennis Fever",
                "weblink": "https://www.speedrun.com/Mario_Tennis_Fever",
                "released": 2026,
                "abbreviation": "Mario_Tennis_Fever"
            },
            {
                "id": "9doko0k1",
                "name": "Super Mario Bros 0.5",
  
…(truncated, see openapi.json for full schema)
```

#### `GET /v1/leaderboard` — Leaderboard for game + category

**Parameters:**
- `game` (query, required, string) — Game id, e.g. o1y9wo6q Example: `o1y9wo6q`
- `category` (query, required, string) — Category id (from /v1/categories), e.g. wkpoo02r Example: `wkpoo02r`
- `top` (query, optional, string) — Max runs (1-100)

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/speedrun-api/v1/leaderboard?game=o1y9wo6q&category=wkpoo02r"
```

**Response:**
```json
{
    "data": {
        "game": "o1y9wo6q",
        "count": 10,
        "category": "wkpoo02r",
        "leaderboard": [
            {
                "date": "2026-04-26",
                "rank": 1,
                "time": "1h 35m 14s",
                "video": "https://www.youtube.com/watch?v=KboxS9NNFJMhttps://youtu.be/KboxS9NNFJM",
                "players": [
                    "Suigi"
                ],
                "time_seconds": 5714
            },
            {
                "date": "2025-08-11",
                "rank": 2,
                "time": "1h 35m 30s",
                "video": "https://www.youtube.com/watch?v=sjKi6aruFVs?t=1",
                "players": [
                    "Karin"
                ],
                "time_seconds": 5730
            },
            {
                "date": "2025-03-19",
                "rank": 2,
                "time": "1h 35m 30s",
                "video": null,
                "players": [
                    "anonymous "
                ],
                "time_seconds": 5730
            },
            {
                "date": "2026-03-15",
                "rank": 4,
                "time": "1h 35m 55s",
                "video": "https://youtu.be/lpzLPLvCK94",
                "players": [
                    "Parsee02"
                ],
                "time_seconds": 5755
            },
            {
                "date": "2026-05-19",
                "rank": 4,
                "time": "1h 35m 55s",
         
…(truncated, see openapi.json for full schema)
```

### Meta

#### `GET /v1/meta` — Usage notes

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/speedrun-api/v1/meta"
```

**Response:**
```json
{
    "data": {
        "note": "Video-game speedrunning data from speedrun.com, the central community hub for competitive fastest-completion runs. /v1/games?name=mario = search games, returning each game's id, name, abbreviation, release year and weblink; /v1/categories?game=o1y9wo6q = a game's run categories (e.g. Any%, 120 Star, 100%) with their ids, type and rules; /v1/leaderboard?game=o1y9wo6q&category=wkpoo02r = the leaderboard for a game+category, returning the ranked runs with the runner name(s), finish time (in seconds and human-readable), run date and video link (top caps how many, 1-100). Get a game id from /v1/games, then a category id from /v1/categories, then the leaderboard. Data from speedrun.com (free to use). Ideal for gaming dashboards, record trackers, stream overlays and community bots.",
        "source": "speedrun.com API (speedrun.com/api/v1)",
        "endpoints": [
            "/v1/games",
            "/v1/categories",
            "/v1/leaderboard",
            "/v1/meta"
        ]
    },
    "meta": {
        "timestamp": "2026-06-01T16:23:41.445Z",
        "request_id": "4825cb14-c7b0-40f8-9c68-9105640100df"
    },
    "status": "ok",
    "message": "Meta retrieved",
    "success": true
}
```


---
Marketplace page: https://www.oanor.com/api/speedrun-api
OpenAPI spec: https://www.oanor.com/api/speedrun-api/openapi.json
