0.0.1 • Published 4 years ago

riotgamez-api v0.0.1

Weekly downloads
-
License
ISC
Repository
github
Last release
4 years ago

riotgames-api

Hi this is just a wrapper for riot api. Everything was built using riot api routes to make life easier for you to make api calls to riot!

Installation

Install npm package npm install riot-api --save Then get api key here Riot!

PLATFORMPLATFORM-HOSTREGIONREGION-HOST
BRbr1.api.riotgames.comAMERICASamericas.api.riotgames.com
EUNeun1.api.riotgames.comEUROPEeurope.api.riotgames.com
EUWeuw1.api.riotgames.comEUROPEeurope.api.riotgames.com
JPjp1.api.riotgames.comASIAasia.api.riotgames.com
KRkr.api.riotgames.comASIAasia.api.riotgames.com
LANla1.api.riotgames.comAMERICASamericas.api.riotgames.com
LASla2.api.riotgames.comAMERICASamericas.api.riotgames.com
NAna1.api.riotgames.comAMERICASamericas.api.riotgames.com
OCEoc1.api.riotgames.comAMERICASamericas.api.riotgames.com
TRtr1.api.riotgames.comEUROPEeurope.api.riotgames.com
RUru.api.riotgames.comEUROPEeurope.api.riotgames.com
const { Lol } = require('riotgames-api');

const lol = new Lol({ region: 'KR', apikey: 'YOUR API KEY' });
const summonerName = 'Hide on Bush';
// Get League Of Legends Summoner Info By Name
async function getLolSummonerByName(name) {
  const response = await lol.Summoner.summonerByName(name);
  console.log(response);
}

getLolSummonerByName(summonerName);
const { Tft } = require('riotgames-api');

const tft = new Tft({ region: 'NA', apikey: 'YOUR API KEY' });
const summonerName = 'Giuttony';
// Get League Of Legends Summoner Info By Name
async function getTftSummonerByName(name) {
  const response = await tft.Summoner.summonerByName(name);
  console.log(response);
}

getTftSummonerByName(summonerName);
  • tft.
    • Summoner.
    • Match.
    • League.
const { Lor } = require('riotgames-api');

const lor = new lor({ region: 'NA', apikey: 'YOUR API KEY' });
// Get League Of Legends Summoner Info By Name
async function getLorRanked() {
  const response = await lor.Ranked.leaderboards();
  console.log(response);
}

getLorRanked();
  • lor.
    • Ranked.
    • Match.

Contributing

If you want to join and help out. Message me and I can add you to the team! Always willing to get more help to evolve and make it better!

Issues

Report any bug or improvements! Willing to take suggesting too!

Future updates

  • ddragon for image
  • league of legend oauth

Thank You!