
Security News
Axios Supply Chain Attack Reaches OpenAI macOS Signing Pipeline, Forces Certificate Rotation
OpenAI rotated macOS signing certificates after a malicious Axios package reached its CI pipeline in a broader software supply chain attack.
lol-stats-api
Advanced tools
A configurable League of Legends API. It uses the official developer's API offered by Riot Games, so you will need an API key to be able to use it. Here's the complete documentation of their API. In the documentation below there will be references to the official methods used for each route.
lol-stats-api is installable via:
To start the API server run the following command:
node run 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 default API key to be used for the calls, the port on which the API will run, the default region to be used for the API calls and the caching strategy.
You can change the provided API configuration at any time, simply by running:
npm run resetconfig
The API's calls are mapped to various API methods from Riot Game's documentation. All URLs can accept apiKey and region as query string parameters, if you want to do calls for a different region or with a different key than the specified defaults.
/account/:accountId/account/:accountId/matchlist/account/:accountId/matchlist/recent/champions/champions/:id/featured-games/leagues/challenger/leagues/master/matches/:id/matches/:matchId/timeline/static/champions/static/champions/:id/static/items/static/items/:id/static/languages/static/language-strings/static/maps/static/masteries/static/masteries/:id/static/profile-icons/static/realms/static/runes/static/runes/:id/static/spells/static/spells/:id/static/versions/status/summoner/:summonerId/activeGame/summoner/:summonerId/championMastery/summoner/:summonerId/championMastery/score/summoner/:summonerId/championMastery/:championId/summoner/summoner/:id/summoner/:summonerId/leagues/summoner/:summonerId/leagues/positions/summoner/:summonerId/masteries/summoner/:summonerId/runes/clear-cache/account/:accountId/clear-cache/summoner/:summonerIdRetrieves a summoner by accountId.
Retrieves matchlist by accountId.
Querystring parameters
season - Comma-separated list of season ids to use for filtering matchlist.
queue - Comma-separated list of ranked queue types to use for filtering matchlist.
beginIndex - The begin index to use for fetching games.
beginTime - The begin time to use for fetching games specified as epoch milliseconds.
endTime - The end time to use for fetching games specified as epoch milliseconds.
endIndex - The end index to use for fetching games.
Retrieves matchlist for last 20 matches played on given accountId.
Retrieves the status of all champions.
Querystring parameters
freeToPlay - Filter param to revireve only free to play champions.
Retrieves the status of given champion id.
Retrieves a list of featured games.
Retrieves the challenger tier leagues
Querystring parameters
queue - The queue type.
Retrieves the master tier leagues
Querystring parameters
queue - The queue type.
Retrieves a match by its id.
Retrieves a match's timeline by matchId.
Retrieves champion list.
Querystring parameters
locale - Locale code for returned data (e.g., en_US, es_ES). If not specified, the default locale for the region is used.
version - Data dragon version for returned data. If not specified, the latest version for the region is used. List of valid versions can be obtained from the /versions endpoint.
dataById - If specified as true, the returned data map will use the champions' id as the keys. If not specified or specified as false, the returned data map will use the champions' keys instead.
champData - Tags to return additional data. Only id, key, name, and title are returned by default if this parameter isn't specified. To return all additional data, use the tag 'all'.
Retrieves a champion by its id.
Querystring parameters
locale - Locale code for returned data (e.g., en_US, es_ES). If not specified, the default locale for the region is used.
version - Data dragon version for returned data. If not specified, the latest version for the region is used. List of valid versions can be obtained from the /versions endpoint.
champData - Tags to return additional data. Only id, key, name, and title are returned by default if this parameter isn't specified. To return all additional data, use the tag 'all'.
Retrieves a list of all items in the game.
Querystring parameters
locale - Locale code for returned data (e.g., en_US, es_ES). If not specified, the default locale for the region is used.
version - Data dragon version for returned data. If not specified, the latest version for the region is used. List of valid versions can be obtained from the /versions endpoint.
itemData - Tags to return additional data. Only id, name, plaintext, group, and description are returned by default if this parameter isn't specified. To return all additional data, use the tag 'all'.
Retrieves an item by id.
Querystring parameters
locale - Locale code for returned data (e.g., en_US, es_ES). If not specified, the default locale for the region is used.
version - Data dragon version for returned data. If not specified, the latest version for the region is used. List of valid versions can be obtained from the /versions endpoint.
itemData - Tags to return additional data. Only id, name, plaintext, group, and description are returned by default if this parameter isn't specified. To return all additional data, use the tag 'all'.
Retrieves supported languages data.
Querystring parameters
locale - Locale code for returned data (e.g., en_US, es_ES). If not specified, the default locale for the region is used.
version - Data dragon version for returned data. If not specified, the latest version for the region is used. List of valid versions can be obtained from the /versions endpoint.
Retrieves language string data.
Querystring parameters
locale - Locale code for returned data (e.g., en_US, es_ES). If not specified, the default locale for the region is used.
version - Data dragon version for returned data. If not specified, the latest version for the region is used. List of valid versions can be obtained from the /versions endpoint.
Retrieves map data.
Querystring parameters
locale - Locale code for returned data (e.g., en_US, es_ES). If not specified, the default locale for the region is used.
version - Data dragon version for returned data. If not specified, the latest version for the region is used. List of valid versions can be obtained from the /versions endpoint.
Retrieves the masteries list.
Querystring parameters
locale - Locale code for returned data (e.g., en_US, es_ES). If not specified, the default locale for the region is used.
version - Data dragon version for returned data. If not specified, the latest version for the region is used. List of valid versions can be obtained from the /versions endpoint.
masteryData - Tags to return additional data. Only id, name, and description are returned by default if this parameter isn't specified. To return all additional data, use the tag 'all'
Retrieves a mastery item by id.
Querystring parameters
locale - Locale code for returned data (e.g., en_US, es_ES). If not specified, the default locale for the region is used.
version - Data dragon version for returned data. If not specified, the latest version for the region is used. List of valid versions can be obtained from the /versions endpoint.
masteryData - Tags to return additional data. Only id, name, and description are returned by default if this parameter isn't specified. To return all additional data, use the tag 'all'
Retrieves profile icons data.
Querystring parameters
locale - Locale code for returned data (e.g., en_US, es_ES). If not specified, the default locale for the region is used.
version - Data dragon version for returned data. If not specified, the latest version for the region is used. List of valid versions can be obtained from the /versions endpoint.
Retrieves realm data.
Querystring parameters
locale - Locale code for returned data (e.g., en_US, es_ES). If not specified, the default locale for the region is used.
version - Data dragon version for returned data. If not specified, the latest version for the region is used. List of valid versions can be obtained from the /versions endpoint.
Retrieves all runes in game.
Querystring parameters
locale - Locale code for returned data (e.g., en_US, es_ES). If not specified, the default locale for the region is used.
version - Data dragon version for returned data. If not specified, the latest version for the region is used. List of valid versions can be obtained from the /versions endpoint.
runeData - Tags to return additional data. Only id, name, rune, and description are returned by default if this parameter isn't specified. To return all additional data, use the tag 'all'.
Retrieves a rune by id.
Querystring parameters
locale - Locale code for returned data (e.g., en_US, es_ES). If not specified, the default locale for the region is used.
version - Data dragon version for returned data. If not specified, the latest version for the region is used. List of valid versions can be obtained from the /versions endpoint.
runeData - Tags to return additional data. Only id, name, rune, and description are returned by default if this parameter isn't specified. To return all additional data, use the tag 'all'.
Retrieves all summoner spells in game.
Querystring parameters
locale - Locale code for returned data (e.g., en_US, es_ES). If not specified, the default locale for the region is used.
version - Data dragon version for returned data. If not specified, the latest version for the region is used. List of valid versions can be obtained from the /versions endpoint.
dataById - If specified, the returned data map will use the spells' id as the keys. If not specified or specified as false, the returned data map will use the spells' keys instead.
spellData - Tags to return additional data. Only type, version, data, id, key, name, description, and summonerLevel are returned by default if this parameter isn't specified. To return all additional data, use the tag 'all'.
Retrieves a summoner spell by id.
Querystring parameters
locale - Locale code for returned data (e.g., en_US, es_ES). If not specified, the default locale for the region is used.
version - Data dragon version for returned data. If not specified, the latest version for the region is used. List of valid versions can be obtained from the /versions endpoint.
spellData - Tags to return additional data. Only type, version, data, id, key, name, description, and summonerLevel are returned by default if this parameter isn't specified. To return all additional data, use the tag 'all'.
Possible values: "all" | "cooldown" | "cooldownBurn" | "cost" | "costBurn" | "costType" | "effect" | "effectBurn" | "image" | "key" | "leveltip" | "maxrank" | "modes" | "range" | "rangeBurn" | "resource" | "sanitizedDescription" | "sanitizedTooltip" | "tooltip" | "vars"
Retrieves version data.
Retrieves the list of available regions.
Retrieves a summoner based on name, id or accountId.
Querystring parameters
name - The name of the summoner
id - The Id of the summoner
accountId - The account id of the summoner
Retrieves a summoner by id.
Retrieves active game information for the given summonerId.
Retrieves all champion mastery entries by summonerId.
Retrieves a champion mastery entry by summonerId and championId.
Retrieves the total champion mastery score by summonerId.
Retrieves leagues in all queues for a given summonerId.
Retrieves league positions in all queues for a given summonerId.
Get mastery pages for a given summonerId.
Get rune pages for a given summonerId.
Clears the cache for a given accountId.
Clears the cache for a given summonerId.
FAQs
A configurable League of Legends API
We found that lol-stats-api demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
OpenAI rotated macOS signing certificates after a malicious Axios package reached its CI pipeline in a broader software supply chain attack.

Security News
Open source is under attack because of how much value it creates. It has been the foundation of every major software innovation for the last three decades. This is not the time to walk away from it.

Security News
Socket CEO Feross Aboukhadijeh breaks down how North Korea hijacked Axios and what it means for the future of software supply chain security.