ruby-lol 0.11.3 → 0.11.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 77a500af537598d7885bb8bac87410706d618411
4
- data.tar.gz: b5e6f8ec3ea5dce404de1131e7d9e9cfdaf0c451
3
+ metadata.gz: 702b526977a6a3d499ce46227ffdf98e427bef49
4
+ data.tar.gz: 141f63026546fb577d7a8884701dd8c2f876de25
5
5
  SHA512:
6
- metadata.gz: bffcecfb6ce9f91534ce59cd29c4e52493c4f43537784c5c4a0ce9a706e825dfa94b4c5993223ddd2efabd27d21d2531d181693a9f011d850d6ce410a6cde393
7
- data.tar.gz: 2ef7a10cf60ccd60654ad628fd3df57356545b390ae9b9ffe23c6d5607f549614a63c63dd670de4289acdd26793b780f6bdb7b7fd84fdcb03d1824e4a17a52b0
6
+ metadata.gz: 3537964af54b161ce56e0fad56abcb3daf5314abccb6bf8ce28239868f703cad0f6db30338fad28813aadc85a4316f63c3cac9b5300bdb89b1dacd52c470ca44
7
+ data.tar.gz: 7e00ccfc883b89c0eb86daf68b650e26641d12cfc7993ad3cc2c4ed90815d199ec50a9987a7a9171954b99e6d212057b8e3983ded00d8acf92727600d12ef209
@@ -73,6 +73,11 @@ module Lol
73
73
  @featured_games ||= FeaturedGamesRequest.new(api_key, region, cache_store)
74
74
  end
75
75
 
76
+ # @return [TournamentProviderRequest]
77
+ def tournament
78
+ @tournament ||= TournamentProviderRequest.new(api_key, region, cache_store)
79
+ end
80
+
76
81
  # Initializes a Lol::Client
77
82
  # @param api_key [String]
78
83
  # @param options [Hash]
@@ -34,6 +34,8 @@ module Lol
34
34
  def extract_raw_status response
35
35
  if response.is_a?(Hash) && response['status']
36
36
  response['status']['message']
37
+ elsif response.respond_to?(:response)
38
+ "#{response.response.code} #{response.response.message}"
37
39
  else
38
40
  "Unknown Error"
39
41
  end
@@ -44,6 +44,11 @@ module Lol
44
44
  League.new(league_json)
45
45
  end
46
46
 
47
+ def master(game_queue_type="RANKED_SOLO_5x5")
48
+ league_json = perform_request(api_url('league/master', { :type => game_queue_type }))
49
+ League.new(league_json)
50
+ end
51
+
47
52
  private
48
53
 
49
54
  def perform_league_request(partial_url)
@@ -38,6 +38,18 @@ module Lol
38
38
  "#{url}?#{api_query_string params}"
39
39
  end
40
40
 
41
+ def post_api_url path, params = {}
42
+ {
43
+ url: api_url(path, params),
44
+ options: {
45
+ headers: {
46
+ "X-Riot-Token" => api_key,
47
+ "Content-Type" => "application/json"
48
+ }
49
+ }
50
+ }
51
+ end
52
+
41
53
  def api_base_url
42
54
  "https://#{region}.api.pvp.net"
43
55
  end
@@ -56,20 +68,24 @@ module Lol
56
68
 
57
69
  # Calls the API via HTTParty and handles errors
58
70
  # @param url [String] the url to call
71
+ # @param verb [Symbol] HTTP verb to use. Defaults to :get
72
+ # @param body [Hash] Body for POST request
73
+ # @param options [Hash] Options passed to HTTParty
59
74
  # @return [String] raw response of the call
60
- def perform_request url
61
- if cached? && result = store.get(clean_url(url))
75
+ def perform_request url, verb = :get, body = {}, options = {}
76
+ if cached? && result = store.get("#{clean_url(url)}#{options.inspect}")
62
77
  return JSON.parse(result)
63
78
  end
64
79
 
65
- response = self.class.get(url)
80
+ params = verb == :post ? [url, options.merge({body: body.to_json})] : url
81
+ response = self.class.send(verb, *params)
66
82
  if response.respond_to?(:code) && !(200...300).include?(response.code)
67
83
  raise NotFound.new("404 Not Found") if response.not_found?
68
84
  raise TooManyRequests.new('429 Rate limit exceeded') if response.code == 429
69
85
  raise InvalidAPIResponse.new(url, response)
70
86
  end
71
87
 
72
- store.setex clean_url(url), ttl, response.to_json if cached?
88
+ store.setex "#{clean_url(url)}#{options.inspect}", ttl, response.to_json if cached?
73
89
 
74
90
  response
75
91
  end
@@ -0,0 +1,81 @@
1
+ module Lol
2
+ class TournamentProviderRequest < Request
3
+ # Returns the supported API Version
4
+ # @return [String] the supported api version
5
+ def self.api_version
6
+ "v1"
7
+ end
8
+
9
+ def api_base_url
10
+ "https://global.api.pvp.net"
11
+ end
12
+
13
+ # Returns a full url for an API call
14
+ # @param path [String] API path to call
15
+ # @return [String] full fledged url
16
+ def api_url path, params = {}
17
+ url = "#{api_base_url}/tournament/public/#{self.class.api_version}/#{path}"
18
+ end
19
+
20
+ def tournament_request path, body
21
+ pau = post_api_url path
22
+ perform_request(pau[:url], :post, body, pau[:options]).body
23
+ end
24
+
25
+ # Returns a tournament code
26
+ # @param tournament_id [Integer] Tournament ID
27
+ # @param count [Integer] Number of tournament codes to generate
28
+ # @param options [Hash] Tournament Code options hash
29
+ # @option options [Integer] :team_size Team Size 1-5
30
+ # @option options [Array] :allowed_summoner_ids SummonerIds spec
31
+ # @option options [String] :game_lobby_name Not used for now
32
+ # @option options [String] :spectator_type NONE, LOBBYONLY, ALL
33
+ # @option options [String] :password Game Lobby password, mandatory
34
+ # @option options [String] :pick_type BLIND_PICK, DRAFT_MODE, ALL_RANDOM, TOURNAMENT_DRAFT
35
+ # @option options [String] :map_type SUMMONERS_RIFT, CRYSTAL_SCAR, HOWLING_ABYSS
36
+ # @option options [String] :metadata Optional metadata String
37
+ def code tournament_id, count = 1, options = {}
38
+ team_size = options.delete(:team_size) || 5
39
+ allowed_summoner_ids = options.delete(:allowed_summoner_ids)
40
+ game_lobby_name = options.delete(:game_lobby_name) || "Lobby"
41
+ spectator_type = options.delete(:spectator_type) || "ALL"
42
+ password = options.delete(:password)
43
+ pick_type = options.delete(:pick_type) || "TOURNAMENT_DRAFT"
44
+ map_type = options.delete(:map_type) || "SUMMONERS_RIFT"
45
+ metadata = options.delete(:metadata)
46
+
47
+ body = {
48
+ teamSize: team_size,
49
+ gameLobbyName: game_lobby_name,
50
+ spectatorType: spectator_type,
51
+ pickType: pick_type,
52
+ mapType: map_type
53
+ }
54
+
55
+ body.merge!({allowedSummonerIds: allowed_summoner_ids}) if allowed_summoner_ids
56
+ body.merge!({metadata: metadata}) if metadata
57
+ body.merge!({password: password}) if password
58
+
59
+ params = URI.encode_www_form({tournamentId: tournament_id, count: count})
60
+ JSON.parse(tournament_request "code?#{params}", body)
61
+ end
62
+
63
+ def provider region, url
64
+ tournament_request "provider", {region: region, url: url}
65
+ end
66
+
67
+ def tournament name, provider
68
+ tournament_request "tournament", {name: name, providerId: provider}
69
+ end
70
+
71
+ # Returns a list of the recent games played by a summoner
72
+ # @param summoner_id [Fixnum] Summoner id
73
+ # @return [Array] an array of games
74
+ def recent summoner_id
75
+ summoner_api_path = "game/by-summoner/#{summoner_id}/recent"
76
+ perform_request(api_url(summoner_api_path))["games"].map do |game_data|
77
+ Game.new game_data
78
+ end
79
+ end
80
+ end
81
+ end
@@ -1,3 +1,3 @@
1
1
  module Lol
2
- VERSION = "0.11.3"
2
+ VERSION = "0.11.4"
3
3
  end
@@ -0,0 +1 @@
1
+ {"name":"Miss Fortune's Weaponmasters","tier":"MASTER","queue":"RANKED_SOLO_5x5","entries":[{"playerOrTeamId":"20732941","playerOrTeamName":"Charlietea","division":"I","leaguePoints":647,"wins":394,"isHotStreak":true,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19331430","playerOrTeamName":"Séncux","division":"I","leaguePoints":359,"wins":459,"isHotStreak":true,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"37802452","playerOrTeamName":"Best Elise Korea","division":"I","leaguePoints":511,"wins":146,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19820922","playerOrTeamName":"verybiglama","division":"I","leaguePoints":475,"wins":467,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"27388233","playerOrTeamName":"Dragons Trukika","division":"I","leaguePoints":391,"wins":394,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"22559479","playerOrTeamName":"VP Piter Pokir","division":"I","leaguePoints":474,"wins":556,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"173273","playerOrTeamName":"M Squeeze","division":"I","leaguePoints":158,"wins":438,"isHotStreak":true,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"24415613","playerOrTeamName":"BX3 Energy","division":"I","leaguePoints":470,"wins":231,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"206429","playerOrTeamName":"GIANTS Adryh","division":"I","leaguePoints":385,"wins":485,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"19783349","playerOrTeamName":"ti0101","division":"I","leaguePoints":459,"wins":273,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"21268676","playerOrTeamName":"Fatlind","division":"I","leaguePoints":30,"wins":372,"isHotStreak":true,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"20782709","playerOrTeamName":"SK Zytan","division":"I","leaguePoints":416,"wins":462,"isHotStreak":true,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"37748436","playerOrTeamName":"Alphari","division":"I","leaguePoints":353,"wins":645,"isHotStreak":true,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"21653685","playerOrTeamName":"SirNukesAlot","division":"I","leaguePoints":543,"wins":461,"isHotStreak":true,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"33507226","playerOrTeamName":"Hoodboss","division":"I","leaguePoints":0,"wins":703,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"24397234","playerOrTeamName":"I Am FeBooVeN","division":"I","leaguePoints":551,"wins":617,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"38436818","playerOrTeamName":"NéeGodbro","division":"I","leaguePoints":333,"wins":111,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"22136916","playerOrTeamName":"SHC kaSing","division":"I","leaguePoints":573,"wins":563,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"21999355","playerOrTeamName":"Exileh","division":"I","leaguePoints":471,"wins":566,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19177792","playerOrTeamName":"HawkDon reborn","division":"I","leaguePoints":476,"wins":590,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19467621","playerOrTeamName":"Crykee","division":"I","leaguePoints":618,"wins":560,"isHotStreak":true,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19603230","playerOrTeamName":"Moopz1","division":"I","leaguePoints":740,"wins":396,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"32317426","playerOrTeamName":"Jiizuké","division":"I","leaguePoints":549,"wins":475,"isHotStreak":true,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"83180","playerOrTeamName":"GSI Steeelbackkk","division":"I","leaguePoints":533,"wins":330,"isHotStreak":true,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19846786","playerOrTeamName":"G2 Yuuki60","division":"I","leaguePoints":0,"wins":511,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"21418085","playerOrTeamName":"pD avenuee","division":"I","leaguePoints":404,"wins":232,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"25532701","playerOrTeamName":"UOL Hylissang","division":"I","leaguePoints":678,"wins":357,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"37973309","playerOrTeamName":"LittanY","division":"I","leaguePoints":274,"wins":315,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"34858129","playerOrTeamName":"DP Naru","division":"I","leaguePoints":430,"wins":319,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"22349506","playerOrTeamName":"Gstv","division":"I","leaguePoints":384,"wins":549,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"25126971","playerOrTeamName":"tivity","division":"I","leaguePoints":517,"wins":684,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19814737","playerOrTeamName":"FTWPRO Kepe","division":"I","leaguePoints":0,"wins":501,"isHotStreak":true,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"41521265","playerOrTeamName":"Konektiv","division":"I","leaguePoints":913,"wins":393,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"20969330","playerOrTeamName":"CL Akrobatik","division":"I","leaguePoints":385,"wins":215,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"22769499","playerOrTeamName":"KJANEKK","division":"I","leaguePoints":363,"wins":279,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"52207792","playerOrTeamName":"NieLubieGrzybów","division":"I","leaguePoints":475,"wins":688,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19829477","playerOrTeamName":"PkD NoXiAK","division":"I","leaguePoints":488,"wins":513,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19543261","playerOrTeamName":"Svenskeren","division":"I","leaguePoints":637,"wins":379,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"35452243","playerOrTeamName":"NG TZeeD","division":"I","leaguePoints":468,"wins":282,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"20661661","playerOrTeamName":"AweZolf","division":"I","leaguePoints":456,"wins":104,"isHotStreak":true,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"20070878","playerOrTeamName":"Cloud9 Voidle","division":"I","leaguePoints":1302,"wins":126,"isHotStreak":true,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"21800660","playerOrTeamName":"Gambit niQ","division":"I","leaguePoints":1242,"wins":224,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"216216","playerOrTeamName":"ºwewillfailerº","division":"I","leaguePoints":443,"wins":154,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"21001130","playerOrTeamName":"H2k Odoamne","division":"I","leaguePoints":675,"wins":454,"isHotStreak":true,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"20281274","playerOrTeamName":"Shadino","division":"I","leaguePoints":154,"wins":347,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"22455406","playerOrTeamName":"SHC Impaler","division":"I","leaguePoints":396,"wins":418,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"20313290","playerOrTeamName":"Níels XD","division":"I","leaguePoints":1173,"wins":714,"isHotStreak":true,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"25168519","playerOrTeamName":"Disney Sent Me","division":"I","leaguePoints":441,"wins":547,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"20656837","playerOrTeamName":"NiP Cabochard","division":"I","leaguePoints":115,"wins":645,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"19047300","playerOrTeamName":"synC Caps","division":"I","leaguePoints":274,"wins":801,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"42808417","playerOrTeamName":"HeaQ v1","division":"I","leaguePoints":62,"wins":362,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"22659036","playerOrTeamName":"flejmthrower","division":"I","leaguePoints":265,"wins":426,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"42359083","playerOrTeamName":"Ana","division":"I","leaguePoints":760,"wins":472,"isHotStreak":true,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"50847058","playerOrTeamName":"Tuikki","division":"I","leaguePoints":518,"wins":236,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"49055793","playerOrTeamName":"Jébus","division":"I","leaguePoints":20,"wins":504,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"53137197","playerOrTeamName":"Qas0","division":"I","leaguePoints":502,"wins":473,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"33037228","playerOrTeamName":"Treatzftw","division":"I","leaguePoints":602,"wins":172,"isHotStreak":true,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"23796520","playerOrTeamName":"IlIllIlIIlIIlIlI","division":"I","leaguePoints":253,"wins":718,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"27408923","playerOrTeamName":"Candyfloss","division":"I","leaguePoints":574,"wins":524,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"21886914","playerOrTeamName":"Xerxe","division":"I","leaguePoints":656,"wins":873,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19662872","playerOrTeamName":"zzbaT","division":"I","leaguePoints":324,"wins":265,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"20412771","playerOrTeamName":"Myw","division":"I","leaguePoints":0,"wins":197,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"20320114","playerOrTeamName":"H2k Trashy","division":"I","leaguePoints":540,"wins":511,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19751300","playerOrTeamName":"SDG Kialys","division":"I","leaguePoints":28,"wins":175,"isHotStreak":true,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"27426799","playerOrTeamName":"GSI Taikki","division":"I","leaguePoints":636,"wins":219,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19372857","playerOrTeamName":"Airwaks","division":"I","leaguePoints":385,"wins":414,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"43860734","playerOrTeamName":"I Have High IQ","division":"I","leaguePoints":526,"wins":389,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19154570","playerOrTeamName":"Kerp","division":"I","leaguePoints":861,"wins":375,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"44888296","playerOrTeamName":"The Krislund","division":"I","leaguePoints":405,"wins":268,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"25716965","playerOrTeamName":"Nero Mr Universe","division":"I","leaguePoints":29,"wins":386,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"45997317","playerOrTeamName":"HornyJlZZPotato","division":"I","leaguePoints":446,"wins":244,"isHotStreak":true,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"155861","playerOrTeamName":"TrashBag Dioud","division":"I","leaguePoints":486,"wins":238,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19895891","playerOrTeamName":"ATN Koi","division":"I","leaguePoints":38,"wins":447,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"19859377","playerOrTeamName":"ErlendVHolm","division":"I","leaguePoints":675,"wins":978,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"20068646","playerOrTeamName":"CW Soren","division":"I","leaguePoints":562,"wins":599,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19423272","playerOrTeamName":"mCon Realdevil","division":"I","leaguePoints":45,"wins":552,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"44256848","playerOrTeamName":"Warwick or Mid","division":"I","leaguePoints":40,"wins":142,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"22430915","playerOrTeamName":"M Creaton","division":"I","leaguePoints":420,"wins":324,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"20110023","playerOrTeamName":"ZvenE","division":"I","leaguePoints":278,"wins":617,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"20322986","playerOrTeamName":"Shafu","division":"I","leaguePoints":506,"wins":688,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"22281234","playerOrTeamName":"Eldiov","division":"I","leaguePoints":473,"wins":471,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"20452273","playerOrTeamName":"Equilibre","division":"I","leaguePoints":428,"wins":741,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"48508","playerOrTeamName":"tDarka","division":"I","leaguePoints":381,"wins":504,"isHotStreak":true,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"400320","playerOrTeamName":"eStar Yurner0s","division":"I","leaguePoints":442,"wins":265,"isHotStreak":true,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19806326","playerOrTeamName":"GIANTS xPePii","division":"I","leaguePoints":468,"wins":307,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"20185790","playerOrTeamName":"Fawkez","division":"I","leaguePoints":234,"wins":591,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"40179793","playerOrTeamName":"Lotzewat","division":"I","leaguePoints":378,"wins":711,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"23925674","playerOrTeamName":"Nut in my Butt","division":"I","leaguePoints":428,"wins":531,"isHotStreak":true,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"20410096","playerOrTeamName":"Hjärnans smurf","division":"I","leaguePoints":659,"wins":403,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"35454505","playerOrTeamName":"Abariaa","division":"I","leaguePoints":532,"wins":691,"isHotStreak":true,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19524719","playerOrTeamName":"ESC noway4u","division":"I","leaguePoints":0,"wins":182,"isHotStreak":true,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"18998411","playerOrTeamName":"Meziljie","division":"I","leaguePoints":500,"wins":365,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"44746989","playerOrTeamName":"Babunia","division":"I","leaguePoints":266,"wins":579,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"21714748","playerOrTeamName":"SHC MrRalleZ","division":"I","leaguePoints":719,"wins":370,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"20540387","playerOrTeamName":"cptrofl","division":"I","leaguePoints":646,"wins":366,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"22103886","playerOrTeamName":"n Sedrion","division":"I","leaguePoints":372,"wins":551,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19923074","playerOrTeamName":"Polyokov","division":"I","leaguePoints":510,"wins":857,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"20277878","playerOrTeamName":"DJOKOZOR","division":"I","leaguePoints":560,"wins":339,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"33484086","playerOrTeamName":"LeChase","division":"I","leaguePoints":248,"wins":602,"isHotStreak":true,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"22006654","playerOrTeamName":"bog igri etoi","division":"I","leaguePoints":351,"wins":324,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"35047682","playerOrTeamName":"Christian Dahl","division":"I","leaguePoints":403,"wins":388,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"20965425","playerOrTeamName":"Broxah","division":"I","leaguePoints":529,"wins":279,"isHotStreak":true,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"23942839","playerOrTeamName":"FORG1VEN658","division":"I","leaguePoints":712,"wins":228,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"43211669","playerOrTeamName":"Zednic","division":"I","leaguePoints":482,"wins":380,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"26302331","playerOrTeamName":"mCon Dominus","division":"I","leaguePoints":487,"wins":303,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"18998522","playerOrTeamName":"M GòB","division":"I","leaguePoints":588,"wins":602,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"31558666","playerOrTeamName":"G2 k0u","division":"I","leaguePoints":754,"wins":394,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"20237432","playerOrTeamName":"LordKevko","division":"I","leaguePoints":411,"wins":694,"isHotStreak":true,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"23717140","playerOrTeamName":"CW WooIite","division":"I","leaguePoints":7,"wins":324,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"224765","playerOrTeamName":"The Death jke","division":"I","leaguePoints":623,"wins":179,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19247270","playerOrTeamName":"6969696969696 XD","division":"I","leaguePoints":607,"wins":320,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"40560749","playerOrTeamName":"SHC SELFIE","division":"I","leaguePoints":758,"wins":349,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"20918894","playerOrTeamName":"Nandisko","division":"I","leaguePoints":487,"wins":519,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"22447540","playerOrTeamName":"Godbro Oniichan","division":"I","leaguePoints":755,"wins":392,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19531813","playerOrTeamName":"Froggen","division":"I","leaguePoints":670,"wins":348,"isHotStreak":true,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19479122","playerOrTeamName":"ROCCAT Overpow","division":"I","leaguePoints":530,"wins":369,"isHotStreak":true,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"60457315","playerOrTeamName":"LCSLEVELJUNGLER","division":"I","leaguePoints":331,"wins":198,"isHotStreak":true,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"27452132","playerOrTeamName":"Cab","division":"I","leaguePoints":385,"wins":896,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19240537","playerOrTeamName":"Kektz","division":"I","leaguePoints":554,"wins":247,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"20828788","playerOrTeamName":"SK Jesse","division":"I","leaguePoints":683,"wins":397,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19053274","playerOrTeamName":"KILLER GODMODE","division":"I","leaguePoints":563,"wins":295,"isHotStreak":true,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"57587216","playerOrTeamName":"steeelbackmaker1","division":"I","leaguePoints":561,"wins":304,"isHotStreak":true,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"24516174","playerOrTeamName":"Flamer354","division":"I","leaguePoints":0,"wins":627,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"35802137","playerOrTeamName":"DandyChap","division":"I","leaguePoints":131,"wins":445,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"23026014","playerOrTeamName":"Ladooscuro","division":"I","leaguePoints":552,"wins":645,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"56670514","playerOrTeamName":"Apdo Dog2","division":"I","leaguePoints":1606,"wins":210,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19984760","playerOrTeamName":"CL Jzzzzz","division":"I","leaguePoints":360,"wins":210,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"46597451","playerOrTeamName":"cakebaker33","division":"I","leaguePoints":475,"wins":264,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19315857","playerOrTeamName":"Chatbotté","division":"I","leaguePoints":685,"wins":249,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"37087925","playerOrTeamName":"Fury III","division":"I","leaguePoints":503,"wins":653,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19751358","playerOrTeamName":"Kikis","division":"I","leaguePoints":878,"wins":464,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"23216751","playerOrTeamName":"CW Ducky","division":"I","leaguePoints":535,"wins":599,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"23336605","playerOrTeamName":"afa spedd","division":"I","leaguePoints":371,"wins":281,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"23607365","playerOrTeamName":"Mímer","division":"I","leaguePoints":593,"wins":179,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19320211","playerOrTeamName":"Chatbott","division":"I","leaguePoints":259,"wins":221,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"52199791","playerOrTeamName":"shripel","division":"I","leaguePoints":430,"wins":525,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"23180483","playerOrTeamName":"Jupe","division":"I","leaguePoints":439,"wins":783,"isHotStreak":true,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"20073590","playerOrTeamName":"Rüven fanboy","division":"I","leaguePoints":507,"wins":239,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"22325769","playerOrTeamName":"King at Mid","division":"I","leaguePoints":214,"wins":885,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"20074071","playerOrTeamName":"GaBaNo","division":"I","leaguePoints":469,"wins":217,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19559802","playerOrTeamName":"Ballogala","division":"I","leaguePoints":9,"wins":174,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"20429674","playerOrTeamName":"Irode","division":"I","leaguePoints":545,"wins":299,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"29919341","playerOrTeamName":"La Fee Clochette","division":"I","leaguePoints":526,"wins":435,"isHotStreak":true,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"44748697","playerOrTeamName":"Sebeks","division":"I","leaguePoints":368,"wins":550,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"21469743","playerOrTeamName":"SPARTA Spontexx","division":"I","leaguePoints":846,"wins":170,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"23436923","playerOrTeamName":"UOL PowerOfEvil","division":"I","leaguePoints":253,"wins":361,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"19752521","playerOrTeamName":"spifld","division":"I","leaguePoints":421,"wins":1031,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19191806","playerOrTeamName":"ImSoFresh kB","division":"I","leaguePoints":447,"wins":361,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"20783177","playerOrTeamName":"katatafish v2","division":"I","leaguePoints":0,"wins":527,"isHotStreak":true,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"19642904","playerOrTeamName":"azerty1","division":"I","leaguePoints":638,"wins":342,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"28944895","playerOrTeamName":"beansu","division":"I","leaguePoints":252,"wins":559,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"23197739","playerOrTeamName":"DD Warrior Lady","division":"I","leaguePoints":463,"wins":330,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"23800212","playerOrTeamName":"XellBrah","division":"I","leaguePoints":416,"wins":356,"isHotStreak":true,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"21681171","playerOrTeamName":"Wunderwear","division":"I","leaguePoints":147,"wins":558,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"20400470","playerOrTeamName":"RAZER XtaZouu","division":"I","leaguePoints":447,"wins":576,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"360987","playerOrTeamName":"Vendetta3","division":"I","leaguePoints":516,"wins":874,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"23717587","playerOrTeamName":"Kobbe","division":"I","leaguePoints":574,"wins":404,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19315465","playerOrTeamName":"NiP Alex Ichy","division":"I","leaguePoints":673,"wins":502,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"20845535","playerOrTeamName":"HWA Stomaged","division":"I","leaguePoints":285,"wins":472,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"20773332","playerOrTeamName":"WhoYYou","division":"I","leaguePoints":452,"wins":417,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"21112717","playerOrTeamName":"WhiteKnight108","division":"I","leaguePoints":1432,"wins":282,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19111161","playerOrTeamName":"toder1","division":"I","leaguePoints":300,"wins":632,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"18994167","playerOrTeamName":"Phones","division":"I","leaguePoints":562,"wins":233,"isHotStreak":true,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"29171077","playerOrTeamName":"Demacia","division":"I","leaguePoints":367,"wins":524,"isHotStreak":true,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"20234739","playerOrTeamName":"GG BenQ Diamond","division":"I","leaguePoints":48,"wins":276,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"20308708","playerOrTeamName":"UOL Gilius","division":"I","leaguePoints":606,"wins":847,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"18985411","playerOrTeamName":"lhazballz","division":"I","leaguePoints":414,"wins":368,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19538899","playerOrTeamName":"RNX Steve","division":"I","leaguePoints":494,"wins":391,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"21687341","playerOrTeamName":"Rüven","division":"I","leaguePoints":126,"wins":265,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"20101413","playerOrTeamName":"WF Thaldrin","division":"I","leaguePoints":706,"wins":499,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"33377461","playerOrTeamName":"Äir","division":"I","leaguePoints":130,"wins":422,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"309109","playerOrTeamName":"Nyph","division":"I","leaguePoints":660,"wins":212,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19777679","playerOrTeamName":"The Barney D","division":"I","leaguePoints":628,"wins":301,"isHotStreak":true,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"20093613","playerOrTeamName":"GamersLegends","division":"I","leaguePoints":15,"wins":427,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"20350141","playerOrTeamName":"Toastman134","division":"I","leaguePoints":224,"wins":275,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"19291685","playerOrTeamName":"Huikee Masa","division":"I","leaguePoints":518,"wins":635,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"20228479","playerOrTeamName":"SPARTA Lounet","division":"I","leaguePoints":141,"wins":386,"isHotStreak":true,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"19149907","playerOrTeamName":"Salsa Samux","division":"I","leaguePoints":437,"wins":327,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"22565154","playerOrTeamName":"MlodyIsOnFIREq","division":"I","leaguePoints":376,"wins":573,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"25232789","playerOrTeamName":"Aniheyi","division":"I","leaguePoints":552,"wins":102,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"21784863","playerOrTeamName":"CJ bebe","division":"I","leaguePoints":503,"wins":277,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"20050482","playerOrTeamName":"loulex","division":"I","leaguePoints":154,"wins":1171,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"30115925","playerOrTeamName":"šo be odegos","division":"I","leaguePoints":538,"wins":521,"isHotStreak":true,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"53107007","playerOrTeamName":"GosuPepperIsBack","division":"I","leaguePoints":533,"wins":455,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19193510","playerOrTeamName":"Prohari","division":"I","leaguePoints":353,"wins":555,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"21109620","playerOrTeamName":"Dorís","division":"I","leaguePoints":499,"wins":321,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"27427030","playerOrTeamName":"Achúu","division":"I","leaguePoints":357,"wins":648,"isHotStreak":true,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"18988326","playerOrTeamName":"Calsot","division":"I","leaguePoints":363,"wins":259,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19183115","playerOrTeamName":"BigG00se","division":"I","leaguePoints":447,"wins":656,"isHotStreak":true,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"22952858","playerOrTeamName":"H2k Hjärnan IV20","division":"I","leaguePoints":1082,"wins":183,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"24233921","playerOrTeamName":"Infused geoBear","division":"I","leaguePoints":726,"wins":368,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19052258","playerOrTeamName":"Neramun","division":"I","leaguePoints":517,"wins":231,"isHotStreak":false,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"19987785","playerOrTeamName":"Swaglord H1iva","division":"I","leaguePoints":719,"wins":310,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"21071845","playerOrTeamName":"ROCCAT Jankos","division":"I","leaguePoints":1113,"wins":215,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"21310977","playerOrTeamName":"HWA Zéitnot","division":"I","leaguePoints":433,"wins":625,"isHotStreak":true,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"21045313","playerOrTeamName":"Mikyx","division":"I","leaguePoints":218,"wins":614,"isHotStreak":false,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"52312462","playerOrTeamName":"GSI PerkZ","division":"I","leaguePoints":488,"wins":507,"isHotStreak":true,"isVeteran":false,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"27528620","playerOrTeamName":"Baxauer","division":"I","leaguePoints":678,"wins":589,"isHotStreak":true,"isVeteran":true,"isFreshBlood":false,"isInactive":false},{"playerOrTeamId":"22940942","playerOrTeamName":"Màrker","division":"I","leaguePoints":223,"wins":411,"isHotStreak":true,"isVeteran":false,"isFreshBlood":true,"isInactive":false},{"playerOrTeamId":"30657524","playerOrTeamName":"H2k Febiven","division":"I","leaguePoints":928,"wins":381,"isHotStreak":false,"isVeteran":true,"isFreshBlood":false,"isInactive":false}]}
@@ -84,4 +84,14 @@ describe LeagueRequest do
84
84
  end
85
85
  end
86
86
 
87
+ describe '#master' do
88
+ subject { request.master('RANKED_SOLO_5x5')}
89
+
90
+ before(:each) { stub_request(request, 'league-master', 'league/master', { :type => 'RANKED_SOLO_5x5'})}
91
+
92
+ it 'returns League' do
93
+ expect(subject.class).to eq(League)
94
+ end
95
+ end
96
+
87
97
  end
@@ -58,6 +58,13 @@ describe Request do
58
58
  expect { subject.perform_request "foo?api_key=asd"}.to raise_error(TooManyRequests)
59
59
  end
60
60
 
61
+ context "post requests" do
62
+ it "supports post" do
63
+ expect(subject.class).to receive(:post).and_return(true)
64
+ expect { subject.perform_request "http://foo.com", :post }.not_to raise_error
65
+ end
66
+ end
67
+
61
68
  context "caching" do
62
69
  before :all do
63
70
  class FakeRedis < Redis
@@ -96,7 +103,7 @@ describe Request do
96
103
  end
97
104
 
98
105
  it "sets ttl" do
99
- expect(fake_redis.get("/foo?:ttl")).to eq(60)
106
+ expect(fake_redis.get("/foo?{}:ttl")).to eq(60)
100
107
  end
101
108
 
102
109
  it "uses clean urls" do
@@ -138,6 +145,39 @@ describe Request do
138
145
  end
139
146
  end
140
147
 
148
+ describe "post_api_url" do
149
+ let(:pau) { subject.post_api_url "/foo" }
150
+
151
+ it "returns an hash" do
152
+ expect(pau).to be_a(Hash)
153
+ end
154
+
155
+ it "contains an url key" do
156
+ expect(pau).to have_key(:url)
157
+ end
158
+
159
+ it "contains an options key" do
160
+ expect(pau).to have_key(:options)
161
+ end
162
+
163
+ it "contains a header key in options" do
164
+ expect(pau[:options]).to have_key(:headers)
165
+ end
166
+
167
+ it "returns the api key in an header" do
168
+ expect(pau[:options][:headers]).to have_key("X-Riot-Token")
169
+ expect(pau[:options][:headers]["X-Riot-Token"]).to eq(subject.api_key)
170
+ end
171
+
172
+ it "includes a content-type header" do
173
+ expect(pau[:options][:headers]["Content-Type"]).to eq("application/json")
174
+ end
175
+
176
+ it "uses api_url for the url part" do
177
+ expect(pau[:url]).to eq(subject.api_url "/foo")
178
+ end
179
+ end
180
+
141
181
  describe "#api_base_url" do
142
182
  it "returns the base domain" do
143
183
  expect(subject.api_base_url).to eq "https://euw.api.pvp.net"
@@ -0,0 +1,40 @@
1
+ require "spec_helper"
2
+ require "lol"
3
+
4
+ include Lol
5
+
6
+ describe TournamentProviderRequest do
7
+ it "inherits from Request" do
8
+ expect(TournamentProviderRequest.ancestors[1]).to eq(Request)
9
+ end
10
+
11
+ let(:request) { TournamentProviderRequest.new("api_key", "euw") }
12
+
13
+ describe "#api_url" do
14
+ subject { request.api_url "foo/bar"}
15
+
16
+ it "matches the tournament api paths" do
17
+ expect(subject).to eq("https://global.api.pvp.net/tournament/public/#{TournamentProviderRequest.api_version}/foo/bar")
18
+ end
19
+ end
20
+
21
+ describe "#provider" do
22
+ subject { request.provider("EUW", "https://foo.com") }
23
+
24
+ # before(:each) { stub_request(request, 'tournament', "tournament/public/#/recent") }
25
+
26
+ # it 'returns an array' do
27
+ # expect(subject).to be_a(Array)
28
+ # end
29
+ #
30
+ # it 'returns an array of Games' do
31
+ # expect(subject.map(&:class).uniq).to eq([Game])
32
+ # end
33
+ #
34
+ # it 'fetches games from the API' do
35
+ # fixture = load_fixture('game', GameRequest.api_version)
36
+ # expect(subject.size).to eq(fixture['games'].size)
37
+ # end
38
+ end
39
+
40
+ end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ruby-lol
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.11.3
4
+ version: 0.11.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Giovanni Intini
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-07-22 00:00:00.000000000 Z
11
+ date: 2015-09-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -310,6 +310,7 @@ files:
310
310
  - lib/lol/team_member.rb
311
311
  - lib/lol/team_request.rb
312
312
  - lib/lol/team_statistic.rb
313
+ - lib/lol/tournament_provider_request.rb
313
314
  - lib/lol/version.rb
314
315
  - ruby-lol.gemspec
315
316
  - spec/acceptance_spec.rb
@@ -348,6 +349,7 @@ files:
348
349
  - spec/fixtures/v2.5/get-league-challenger.json
349
350
  - spec/fixtures/v2.5/get-league-entry-by-team.json
350
351
  - spec/fixtures/v2.5/get-league-entry.json
352
+ - spec/fixtures/v2.5/get-league-master.json
351
353
  - spec/fixtures/v2.5/get-league.json
352
354
  - spec/lol/champion_request_spec.rb
353
355
  - spec/lol/champion_spec.rb
@@ -385,6 +387,7 @@ files:
385
387
  - spec/lol/team_request_spec.rb
386
388
  - spec/lol/team_spec.rb
387
389
  - spec/lol/team_statistic_spec.rb
390
+ - spec/lol/tournament_provider_request_spec.rb
388
391
  - spec/spec_helper.rb
389
392
  - spec/support/helpers.rb
390
393
  - spec/support/model_helpers.rb
@@ -408,7 +411,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
408
411
  version: '0'
409
412
  requirements: []
410
413
  rubyforge_project:
411
- rubygems_version: 2.4.3
414
+ rubygems_version: 2.4.8
412
415
  signing_key:
413
416
  specification_version: 4
414
417
  summary: Ruby wrapper to Riot Games API
@@ -449,6 +452,7 @@ test_files:
449
452
  - spec/fixtures/v2.5/get-league-challenger.json
450
453
  - spec/fixtures/v2.5/get-league-entry-by-team.json
451
454
  - spec/fixtures/v2.5/get-league-entry.json
455
+ - spec/fixtures/v2.5/get-league-master.json
452
456
  - spec/fixtures/v2.5/get-league.json
453
457
  - spec/lol/champion_request_spec.rb
454
458
  - spec/lol/champion_spec.rb
@@ -486,6 +490,7 @@ test_files:
486
490
  - spec/lol/team_request_spec.rb
487
491
  - spec/lol/team_spec.rb
488
492
  - spec/lol/team_statistic_spec.rb
493
+ - spec/lol/tournament_provider_request_spec.rb
489
494
  - spec/spec_helper.rb
490
495
  - spec/support/helpers.rb
491
496
  - spec/support/model_helpers.rb