Home

Awesome

Riot API Tools

Greeting

Hello! Thank you for being interested, if you are new to coding - a lot of this will seem a bit overwhelming but remember you can always reach out to me via Discord @Beora.

If you'd like more indepth instruction and tools, I'll be building upon this repo and hosting educational live streams over on my Patreon

Table of Contents

Overview

These tools were made with beginners in mind to help open access to the Riot API while also featuring some scraping techniques for non-API related data.

This project aims to make it easier for all people to work with data for

Usage

The code that I have written here requires a Riot Production Key in order to really function properly - because of this, you won't be able to get updated data using the tools in this repo (because you'd very quickly run into API limits).

BUT

I've included 3 .parquet files with Ladder, SoloQ and Stage data as of December 21, 2023

You can upsert these to your PostgreSQL database for now using the update_table_ functions in SQL.update_table, just make sure to set from_parquet to True

Once you've got the data in your PostgreSQL database, the world is your oyster! I included some miscellaneous functions that can do different things, poke around and see what you can find / build upon!

If you're interested in more, I'll be releasing updates to this on my Patreon and I'll try to upload daily parquet updates for people who aren't able to grab a prod key (for now, until I can find a webapp solution to automate the process)

Installation

Preparation

Before installing, complete the following tasks:

Install

Once you have finished the above tasks, navigate to the directory you'd like to work in and do the following:

That should be everything. If you run into errors or spot anything that I missed, please reach out!

Riot API Endpoints

If you are curious what other Riot API endpoints are out there for you to play around with, you can find them here!

The ones I use in this project are

Once the League V4 endpoint updates to V5 I will likely sunset Summoner V4 as it will no longer be needed

Take a look around, bring one of the api functions in LoLAPI.soloq into a python notebook and replace some of the code with a new endpoint and see what happens!

Version Notes

For version notes, please see /tools/version_notes.txt! That is where I'll be putting all of my updates

Not exactly industry standard but that's how I like to do it. Enjoy!

License

MIT License

Copyright (c) 2023 Beora

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.