# league-api

> wrapper for RIOT games official League of Legends API

Latest version **2.0.0** (published 2016-04-19) · 0 weekly downloads

## Install

```sh
npm install league-api
pnpm add league-api
yarn add league-api
bun add league-api
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 2.0.0 |
| Published | 2016-04-19 |
| First published | 2013-12-17 |
| Weekly downloads | 0 |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 4 |
| Author | Spencer Moran |
| Maintainers | smoran |
| Keywords | league, riot, riot games, league of legends, lol, lol api, api, wrapper, league api |

## Links

- npm: https://www.npmjs.com/package/league-api
- Repository: https://github.com/smoran02/league-api
- Homepage: https://github.com/smoran02/league-api#readme
- Issues: https://github.com/smoran02/league-api/issues
- npm.io page: https://npm.io/package/league-api

## Recent versions

- 2.0.0 (latest) — 2016-04-19
- 1.0.2 — 2013-12-17
- 1.0.1 — 2013-12-17
- 1.0.0 — 2013-12-17

## README

League-api
=========

This module has ALL the functionality of RIOT's API, in a clear and easy to use format! League-api is a Node.js wrapper for the official RIOT games League of Legends API. Pull requests and feedback are welcome!

##Installation

Install it through npm using the standard:

    $ npm install league-api

##Requirements

Get an API key at http://developer.riotgames.com/

##Usage and Examples

To initialize the module with your api key, use:

    var league_api = require('league-api');
    var league = new league_api('your_api_key');

###Available Methods

Each method takes as parameters some combination of a region, summoner id, summoner name, and then all methods have a callback function as a parameter. Here is an example call to retrieve the stat summary for a given id:

    league.getRecentGames('na', '5908', function(data) {
        console.log(data);
    });

All the functionality of the RIOT League of Legends API is included, and the code is clear to read and modify if you want to add functionality on top of what RIOT offers.

---
_Source: https://npm.io/package/league-api · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
