lol-esports-api
An API for the eSports side of League of Legends. It uses the eSports API offered by lolesports.
Download
lol-esports-api is installable via:
Getting started
To start the API server run the following command:
npm start
You will have to do a one time configuration to be able to use the API. At the prompt you will be asked for the port
on which the API will run.
Resetting the configuration
You can change the provided API configuration at any time, simply by running:
npm run reset
Documentation
Routes
/news
/leagues
/leagues/:leagueId
/tournaments
/tournaments/:tournamentId
/tournaments/:tournamentId/standings
/tournaments/:tournamentId/schedule
/tournaments/:tournamentId/leaders/:stat
/tournaments/:tournamentId/stats/fantasy
/tournaments/:tournamentId/stats/players
/tournaments/:tournamentId/stats/players/:playerId
/tournaments/:tournamentId/stats/players/:playerId/champs
/series
/series/:seriesId
/matches/:matchId
/games/:gameId
/teams/:teamId
/teams/:teamId/stats
/players/:playerId
/players/:playerId/stats
/programming
/programming/:blockId
/programming/week/:date
### /news
Returns the latest news.
Querystring parameters
limit
- The maximum amount of news to return, if omitted, limit will default to 10, max of 50.offset
- The numbers of articles to skip.category
- The taxonomy identifier to filter results with. Omit to return all taxonomies.language
- The language to limit the news articles to.
### /leagues
Returns basic information on all existing leagues.
### /leagues/:leagueId
Returns basic information about a league.
### /tournaments
Returns basic information about all tournaments including contestants, and beginning and end dates.
### /tournaments/:tournamentId
Returns basic information about a tournament including contestants, and beginning and end dates
### /tournaments/:tournamentId/standings
Returns the standings for the specified tournament.
### /tournaments/:tournamentId/schedule
Returns the schedule of matches for the specified tournament.
Querystring parameters
teamId
- ID of a team you want to view the schedule for.finished
- Whether or not to include finished games.future
- Whether or not to include future games.live
- Whether or not to include live games.
### /tournaments/:tournamentId/leaders/:stat
Returns the greatest stat for the specified tournament.
### /tournaments/:tournamentId/stats/fantasy
Returns fantasy stats for the specified tournament.
Querystring parameters
dateBegin
- Filter the start dates to a particular date.dateEnd
- Filter the end dates to a particular date.
### /tournaments/:tournamentId/stats/players
Returns kda, average gold and gpm for all players.
### /tournaments/:tournamentId/stats/players/:playerId
Returns kda, average gold and gpm for a player.
### /tournaments/:tournamentId/stats/players/:playerId/champs
Returns kda, average gold and gpm for a player on different champions.
### /series
Returns basic information on all existing series.
### /series/:seriesId
Returns basic information about a series.
### /matches/:matchId
Returns basic information about a match including name, tournament information, and live streams.
### /games/:gameId
Returns basic information about a game including players, tournament information, and videos on demand.
### /teams/:teamId
Returns basic information about a team including players, name, and profile url.
Querystring parameters
expandPlayers
- Instead of each player element returning limited data, fully expand each player element to contain the results of a player api call for that player.
### /teams/:teamId/stats
Returns a team's stats for the entire tournament or tournament series.
Querystring parameters
tournamentId
- ID of the tournament you want to filter by.
### /players/:playerId
Returns basic information about a player including name, bio, and profile url.
### /players/:playerId/stats
Returns a player's stats for the entire tournament or tournament series.
Querystring parameters
tournamentId
- ID of the tournament you want to filter by.
### /programming
Returns all programming blocks.
Querystring parameters
expandMatches
- Instead of each matches element returning a simple array of integers, fully expand each matches element to contain the results of a match api call for each match found.limit
- The limit of the blocks to return. Only applicable to next and prev methodsmethod
- The method to execute.- Possible values: all | time | next | prev.
time
- The time to start for programming blocks.tournamentId
- ID of the tournament you want to filter by.winner
- Whether or not to show the winner.
### /programming/:blockId
Returns a programming block.
Querystring parameters
expandMatches
- Instead of each matches element returning a simple array of integers, fully expand each matches element to contain the results of a match api call for each match found.
### /programming/week/:date
Returns a week's programming blocks.
:date
must follow the YYYY-MM-DD format.
Querystring parameters
offset
- Date offset [-]NNNN