Chemist v0.4.0 Chemist.ChampionMastery

Uses championmastery API.

Summary

Functions

Contains Champion Mastery information for a player’s single champion; retrieved by player id and champion id

Contains a list of Champion Mastery information for all a player’s champions; retrieved by player id

Contains an integer with Champion Mastery score for a player; retrieved by player id

Contains a list of Champion Mastery information for a player’s top champions; retrieved by player id

Functions

champion(region, player_id, champion_id)

Contains Champion Mastery information for a player’s single champion; retrieved by player id and champion id.

Sample output:

{:ok,
 %{"championId" => 36, "championLevel" => 4, "championPoints" => 12917,
   "championPointsSinceLastLevel" => 317,
   "championPointsUntilNextLevel" => 8683, "chestGranted" => false,
   "lastPlayTime" => 1481350108000, "playerId" => 51666047,
   "tokensEarned" => 0}}
champions(region, player_id)

Contains a list of Champion Mastery information for all a player’s champions; retrieved by player id.

Sample output:

{:ok,
 [%{"championId" => 104, "championLevel" => 5,
    "championPoints" => 152302, "championPointsSinceLastLevel" => 130702, 
    "championPointsUntilNextLevel" => 0, "chestGranted" => true,
    "lastPlayTime" => 1487921982000, "playerId" => 51666047,
    "tokensEarned" => 2}, ...
score(region, player_id)

Contains an integer with Champion Mastery score for a player; retrieved by player id.

Sample output:

{:ok, 195}
top_champions(region, player_id, opts \\ %{})

Contains a list of Champion Mastery information for a player’s top champions; retrieved by player id.

Default opts:

  • count: 3

    • Number of entries to retrieve

Sample output (default options):

{:ok,
 [%{"championId" => 104, "championLevel" => 5,
    "championPoints" => 152302, "championPointsSinceLastLevel" => 130702, 
    "championPointsUntilNextLevel" => 0, "chestGranted" => true,
    "lastPlayTime" => 1487921982000, "playerId" => 51666047,
    "tokensEarned" => 2}, ...