How baeora/riot_api_tools works
Riot API Tools helps users collect and explore League of Legends SoloQ, Champions Queue, and professional stage-game data. The main workflow is to fetch or scrape match and draft data, transform it into analysis-ready tables, and upsert it into PostgreSQL; users can then query SoloQ records. Champions Queue also has a local scraping-and-analysis branch. Shared utilities provide database setup and game-data lookups. The graph reflects the sampled code and README; some subsystem details are documented or indexed but not shown in full excerpts.
Main entry points: champions_queue.py CQ analysis · update_table.py Table updates · soloq.py SoloQ queries · core.py Game data utilities
Components 15
Data collection
- SoloQ API fetch
tools/LoLAPI/soloq.py - CQ scraper
tools/scripts/lol_get/cq/cq_scraper.py - CQ match data
tools/scripts/lol_get/cq/CSVs/champions_queue.csv - Draft cleaner
tools/scripts/lol_get/drafts.py
Data analysis
- CQ analysis
tools/scripts/lol_get/champions_queue.py - SoloQ queries
tools/scripts/lol_get/soloq.py
Persistence
- Table updates
tools/SQL/update_table.py - Database helpers
tools/SQL/database_utils.py - PostgreSQL
Shared utilities
- Game data utilities
tools/common/core.py - Normalization maps
tools/common/dictionaries.py
Other components
- User
- Riot API
- Champions Queue site
- Leaguepedia
Connections 19
- User → Table updates: requests updates
README.md - Table updates → SoloQ API fetch: fetches ladder and matches
tools/SQL/update_table.py - SoloQ API fetch → Riot API: requests Riot data
tools/LoLAPI/soloq.py - Table updates → Draft cleaner: cleans draft data
tools/SQL/update_table.py - Draft cleaner → Leaguepedia: reads draft pages
tools/scripts/lol_get/drafts.py - User → CQ analysis: explores CQ data
README.md - CQ analysis → CQ scraper: uses scraper
tools/scripts/lol_get/champions_queue.py - CQ scraper → Champions Queue site: scrapes matches
tools/scripts/lol_get/cq/cq_scraper.py - CQ analysis → CQ match data: reads match data
tools/scripts/lol_get/champions_queue.py - User → SoloQ queries: queries game data
README.md - SoloQ queries → PostgreSQL: queries SoloQ records
tools/scripts/lol_get/soloq.py - Table updates → Database helpers: upserts tables
tools/SQL/update_table.py - Database helpers → PostgreSQL: writes records
tools/SQL/database_utils.py - Table updates → PostgreSQL: reads existing tables
tools/SQL/update_table.py - SoloQ queries → Normalization maps: normalizes roles
tools/scripts/lol_get/soloq.py - CQ analysis → Game data utilities: uses date helpers
tools/scripts/lol_get/champions_queue.py - CQ analysis → Normalization maps: normalizes names
tools/scripts/lol_get/champions_queue.py - Game data utilities → PostgreSQL: configures connection
tools/common/core.py - Game data utilities → Normalization maps: uses lookup maps
tools/common/core.py