LoLBot is a Discord bot built upon discord.js and the Twisted wrapper for Riot API. It offers commands to view stats and information about a League of Legends player. TFT support is not avaliable right now
/rank summoner_name: XXX region: XXX
- Get the current ranked season of the requested player
/profile summoner_name: XXX region: XXX
- Get the profile information of the requested player
/top_mastery summoner_name: XXX region: XXX
- Get the top five mastery champions for the requested player (if the player has only played less than five champs, it will return the number of champions played)
/current_match summoner_name: XXX region: XXX
- Get the current match information of the given player (returns nothing if the player isn't in a PUBLIC match)
If the player doesn't exist, in general or in the requested region, LoLBot will return an error.
- Clone this repository:
git clone https://github.com/Camerxxn/LOLBot.git
- Navigate to
./bot
and create a new file called.env
- Create a discord bot (tutorial)
- Get the bot token (don't share it with anyone)
- Get the bot client ID
- Get a Riot API key here (these reset every so often if you don't have a registered application)
- Edit the
.env
file, it should look like this
BOT_TOKEN=YOUR_TOKEN
BOT_CLIENT_ID=YOUR_CLIENT_ID
RIOT_API_KEY=YOUR_API_KEY
- Run
npm install
(this installs the dependencies for the project) - Run
npm run build
- Finally,
npm run start
- Your bot should be setup :)
- Navigate to
./frontend
- Create a
.env
file - Get your discord bot client ID and paste it into the
.env
file
DISCORD_INVITE=https://discord.com/api/oauth2/authorize?client_id=[YOUR_CLIENT_ID_HERE]&permissions=277025482816&scope=bot
- Run
npm i
- Run
npm run build
- Run
npm run start