Pipeline 1 · BGG scraping
BGG XML API → SQLite. Rate-limited at 2 req/sec. Ban-sensitive.
The scraper hits BoardGameGeek's XML API 2 — specifically the /thing endpoint — and lands raw game data in data/bgg.sqlite. It's the only path in the project that talks to BGG.
How it runs
python scripts/refresh_bgg.py # default: top 2000 by 2019-rank seed
python -m src.scraper -n 5000 # broader pull
The seed list lives in data/seed/bgg_ranks_2019.csv. We refresh against that historical anchor so rank-trajectory deltas remain comparable across runs.
Rate limit (load-bearing)
2 requests per second, hard cap. Going faster gets the API token banned. The scraper enforces this in src/scraper.py; never bypass it. If a scrape needs to be faster, reduce the seed list, not the delay.
When BGG returns 202 Accepted, the response is queued — the scraper retries with backoff. 429 means we're already over the limit; back off harder.
What's stored
Each /thing response is parsed into the game table plus join tables game_mechanism and game_category. The mechanism and category lookup tables are populated incidentally as new IDs appear.
Key columns on game:
bayesaverage,averageweight,usersrated— the quantitative signalplayingtime,minplayers,maxplayers— eligibility filter inputsrank— current BGG rankfetched_at— provenance for reproducibility checks
What's not scraped (yet)
- Mechanism descriptions. The
/thingendpoint returns mechanism IDs but no body text. Descriptions are an open scrape — they live on BGG's web pages, not the XML API. Pending a safe endpoint, themechanismtable holds id + name only. - Forum / comment data. Out of scope.
- Image assets. We don't fetch box art.
Most recently scraped
Last 10 games to land in the game table.
| Name | Year | Rank | Bayes | Weight | Fetched |
|---|---|---|---|---|---|
| Star Wars: The Deckbuilding Game ↗ | 2023 | 219 | 7.33 | 2.04 | 1d ago |
| 20 Strong: Nemesis ↗ | 2026 | — | 0.00 | 3.00 | 1d ago |
| Orloj: The Prague Astronomical Clock ↗ | 2025 | 1722 | 6.34 | 3.55 | 1d ago |
| Dune: Imperium ↗ | 2020 | 6 | 8.22 | 3.08 | 1d ago |
| Slay the Spire: The Board Game ↗ | 2024 | 17 | 8.02 | 2.90 | 1d ago |
| Endeavor: Deep Sea ↗ | 2024 | 83 | 7.65 | 2.92 | 1d ago |
| Star Trek: Captain's Chair ↗ | 2025 | 852 | 6.73 | 4.04 | 1d ago |
| Voidfall ↗ | 2023 | 86 | 7.64 | 4.61 | 1d ago |
| Lost Ruins of Arnak ↗ | 2020 | 30 | 7.92 | 2.93 | 1d ago |
| The Elder Scrolls: Betrayal of the Second Era ↗ | 2025 | 223 | 7.33 | 4.07 | 1d ago |