blizzard_api 0.5.4 → 0.5.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +9 -1
- data/Gemfile.lock +1 -1
- data/README.md +57 -215
- data/lib/blizzard_api/diablo/community/act.rb +2 -2
- data/lib/blizzard_api/diablo/community/artisan.rb +2 -2
- data/lib/blizzard_api/diablo/community/character.rb +2 -2
- data/lib/blizzard_api/diablo/community/follower.rb +1 -1
- data/lib/blizzard_api/diablo/community/item.rb +1 -1
- data/lib/blizzard_api/diablo/community/item_type.rb +2 -2
- data/lib/blizzard_api/diablo/community/profile.rb +4 -4
- data/lib/blizzard_api/diablo/game_data/generic_data_endpoint.rb +3 -3
- data/lib/blizzard_api/hearthstone/game_data/back.rb +1 -1
- data/lib/blizzard_api/hearthstone/game_data/card.rb +2 -2
- data/lib/blizzard_api/hearthstone/game_data/generic_data_endpoint.rb +2 -2
- data/lib/blizzard_api/request.rb +2 -2
- data/lib/blizzard_api/starcraft/community/account.rb +1 -1
- data/lib/blizzard_api/starcraft/community/ladder.rb +2 -2
- data/lib/blizzard_api/starcraft/community/legacy.rb +6 -6
- data/lib/blizzard_api/starcraft/community/profile.rb +5 -5
- data/lib/blizzard_api/starcraft/game_data/league.rb +1 -1
- data/lib/blizzard_api/version.rb +1 -1
- data/lib/blizzard_api/wow.rb +0 -7
- data/lib/blizzard_api/wow/game_data/achievement.rb +3 -3
- data/lib/blizzard_api/wow/game_data/auction.rb +1 -1
- data/lib/blizzard_api/wow/game_data/azerite_essence.rb +1 -1
- data/lib/blizzard_api/wow/game_data/covenant.rb +5 -5
- data/lib/blizzard_api/wow/game_data/creature.rb +6 -6
- data/lib/blizzard_api/wow/game_data/generic_data_endpoint.rb +3 -3
- data/lib/blizzard_api/wow/game_data/guild_crest.rb +2 -2
- data/lib/blizzard_api/wow/game_data/item.rb +6 -6
- data/lib/blizzard_api/wow/game_data/journal.rb +8 -8
- data/lib/blizzard_api/wow/game_data/modified_crafting.rb +4 -4
- data/lib/blizzard_api/wow/game_data/mythic_keystone.rb +6 -6
- data/lib/blizzard_api/wow/game_data/mythic_keystone_affix.rb +1 -1
- data/lib/blizzard_api/wow/game_data/mythic_keystone_leaderboard.rb +2 -2
- data/lib/blizzard_api/wow/game_data/mythic_raid_leaderboard.rb +1 -1
- data/lib/blizzard_api/wow/game_data/pet.rb +4 -4
- data/lib/blizzard_api/wow/game_data/playable_class.rb +4 -4
- data/lib/blizzard_api/wow/game_data/playable_specialization.rb +2 -2
- data/lib/blizzard_api/wow/game_data/profession.rb +4 -4
- data/lib/blizzard_api/wow/game_data/pvp_season.rb +3 -3
- data/lib/blizzard_api/wow/game_data/pvp_tier.rb +1 -1
- data/lib/blizzard_api/wow/game_data/quest.rb +6 -6
- data/lib/blizzard_api/wow/game_data/reputation.rb +4 -4
- data/lib/blizzard_api/wow/game_data/spell.rb +1 -1
- data/lib/blizzard_api/wow/game_data/talent.rb +2 -2
- data/lib/blizzard_api/wow/game_data/tech_talent.rb +3 -3
- data/lib/blizzard_api/wow/game_data/wow_token.rb +1 -1
- data/lib/blizzard_api/wow/profile/character_profile.rb +51 -51
- data/lib/blizzard_api/wow/profile/guild.rb +8 -8
- data/lib/blizzard_api/wow/profile/profile.rb +5 -5
- data/lib/blizzard_api/wow/search/search_request.rb +1 -1
- metadata +2 -2
@@ -30,7 +30,7 @@ module BlizzardApi
|
|
30
30
|
# This method overrides the inherited default behavior to prevent high server load and fetch time
|
31
31
|
#
|
32
32
|
# @!macro response
|
33
|
-
def get(_id,
|
33
|
+
def get(_id, **options)
|
34
34
|
raise BlizzardApi::ApiException, 'This endpoint does not have a get method'
|
35
35
|
end
|
36
36
|
|
@@ -40,7 +40,7 @@ module BlizzardApi
|
|
40
40
|
# @!macro request_options
|
41
41
|
#
|
42
42
|
# @!macro response
|
43
|
-
def expansions(options
|
43
|
+
def expansions(**options)
|
44
44
|
api_request "#{endpoint_uri('expansion')}/index", default_options.merge(options)
|
45
45
|
end
|
46
46
|
|
@@ -51,7 +51,7 @@ module BlizzardApi
|
|
51
51
|
# @!macro request_options
|
52
52
|
#
|
53
53
|
# @!macro response
|
54
|
-
def expansion(id, options
|
54
|
+
def expansion(id, **options)
|
55
55
|
api_request "#{endpoint_uri('expansion')}/#{id}", default_options.merge(options)
|
56
56
|
end
|
57
57
|
|
@@ -61,7 +61,7 @@ module BlizzardApi
|
|
61
61
|
# @!macro request_options
|
62
62
|
#
|
63
63
|
# @!macro response
|
64
|
-
def instances(options
|
64
|
+
def instances(**options)
|
65
65
|
api_request "#{endpoint_uri('instance')}/index", default_options.merge(options)
|
66
66
|
end
|
67
67
|
|
@@ -72,7 +72,7 @@ module BlizzardApi
|
|
72
72
|
# @!macro request_options
|
73
73
|
#
|
74
74
|
# @!macro response
|
75
|
-
def instance(id, options
|
75
|
+
def instance(id, **options)
|
76
76
|
api_request "#{endpoint_uri('instance')}/#{id}", default_options.merge(options)
|
77
77
|
end
|
78
78
|
|
@@ -82,7 +82,7 @@ module BlizzardApi
|
|
82
82
|
# @!macro request_options
|
83
83
|
#
|
84
84
|
# @!macro response
|
85
|
-
def encounters(options
|
85
|
+
def encounters(**options)
|
86
86
|
api_request "#{endpoint_uri('encounter')}/index", default_options.merge(options)
|
87
87
|
end
|
88
88
|
|
@@ -93,7 +93,7 @@ module BlizzardApi
|
|
93
93
|
# @!macro request_options
|
94
94
|
#
|
95
95
|
# @!macro response
|
96
|
-
def encounter(id, options
|
96
|
+
def encounter(id, **options)
|
97
97
|
api_request "#{endpoint_uri('encounter')}/#{id}", default_options.merge(options)
|
98
98
|
end
|
99
99
|
|
@@ -105,7 +105,7 @@ module BlizzardApi
|
|
105
105
|
#
|
106
106
|
# @!macro request_options
|
107
107
|
# @!macro response
|
108
|
-
def encounter_search(page = 1, page_size = 100, options
|
108
|
+
def encounter_search(page = 1, page_size = 100, **options)
|
109
109
|
search_options = SearchComposer.new(page, page_size)
|
110
110
|
yield search_options if block_given?
|
111
111
|
|
@@ -18,7 +18,7 @@ module BlizzardApi
|
|
18
18
|
# Fetch modified crafting category index
|
19
19
|
#
|
20
20
|
# @!macro request_options
|
21
|
-
def categories(options
|
21
|
+
def categories(**options)
|
22
22
|
api_request "#{base_url(:game_data)}/modified-crafting/category/index", default_options.merge(options)
|
23
23
|
end
|
24
24
|
|
@@ -30,7 +30,7 @@ module BlizzardApi
|
|
30
30
|
# @!macro request_options
|
31
31
|
#
|
32
32
|
# @!macro response
|
33
|
-
def category(id, options
|
33
|
+
def category(id, **options)
|
34
34
|
api_request "#{base_url(:game_data)}/modified-crafting/category/#{id}", default_options.merge(options)
|
35
35
|
end
|
36
36
|
|
@@ -38,7 +38,7 @@ module BlizzardApi
|
|
38
38
|
# Fetch modified crafting slot type index
|
39
39
|
#
|
40
40
|
# @!macro request_options
|
41
|
-
def slot_types(options
|
41
|
+
def slot_types(**options)
|
42
42
|
api_request "#{base_url(:game_data)}/modified-crafting/reagent-slot-type/index", default_options.merge(options)
|
43
43
|
end
|
44
44
|
|
@@ -50,7 +50,7 @@ module BlizzardApi
|
|
50
50
|
# @!macro request_options
|
51
51
|
#
|
52
52
|
# @!macro response
|
53
|
-
def slot_type(id, options
|
53
|
+
def slot_type(id, **options)
|
54
54
|
api_request "#{base_url(:game_data)}/modified-crafting/reagent-slot-type/#{id}", default_options.merge(options)
|
55
55
|
end
|
56
56
|
|
@@ -24,7 +24,7 @@ module BlizzardApi
|
|
24
24
|
# @!macro request_options
|
25
25
|
#
|
26
26
|
# @!macro response
|
27
|
-
def dungeons(options
|
27
|
+
def dungeons(**options)
|
28
28
|
api_request "#{endpoint_uri}/dungeon/index", default_options.merge(options)
|
29
29
|
end
|
30
30
|
|
@@ -36,7 +36,7 @@ module BlizzardApi
|
|
36
36
|
# @!macro request_options
|
37
37
|
#
|
38
38
|
# @!macro response
|
39
|
-
def dungeon(id, options
|
39
|
+
def dungeon(id, **options)
|
40
40
|
api_request "#{endpoint_uri}/dungeon/#{id}", default_options.merge(options)
|
41
41
|
end
|
42
42
|
|
@@ -46,7 +46,7 @@ module BlizzardApi
|
|
46
46
|
# @!macro request_options
|
47
47
|
#
|
48
48
|
# @!macro response
|
49
|
-
def periods(options
|
49
|
+
def periods(**options)
|
50
50
|
api_request "#{endpoint_uri}/period/index", default_options.merge(options)
|
51
51
|
end
|
52
52
|
|
@@ -58,7 +58,7 @@ module BlizzardApi
|
|
58
58
|
# @!macro request_options
|
59
59
|
#
|
60
60
|
# @!macro response
|
61
|
-
def period(id, options
|
61
|
+
def period(id, **options)
|
62
62
|
api_request "#{endpoint_uri}/period/#{id}", default_options.merge(options)
|
63
63
|
end
|
64
64
|
|
@@ -68,7 +68,7 @@ module BlizzardApi
|
|
68
68
|
# @!macro request_options
|
69
69
|
#
|
70
70
|
# @!macro response
|
71
|
-
def seasons(options
|
71
|
+
def seasons(**options)
|
72
72
|
api_request "#{endpoint_uri}/season/index", default_options.merge(options)
|
73
73
|
end
|
74
74
|
|
@@ -80,7 +80,7 @@ module BlizzardApi
|
|
80
80
|
# @!macro request_options
|
81
81
|
#
|
82
82
|
# @!macro response
|
83
|
-
def season(id, options
|
83
|
+
def season(id, **options)
|
84
84
|
api_request "#{endpoint_uri}/season/#{id}", default_options.merge(options)
|
85
85
|
end
|
86
86
|
|
@@ -18,7 +18,7 @@ module BlizzardApi
|
|
18
18
|
# @!macro request_options
|
19
19
|
#
|
20
20
|
# @!macro response
|
21
|
-
def index(connected_realm_id, options
|
21
|
+
def index(connected_realm_id, **options)
|
22
22
|
api_request "#{endpoint_uri(connected_realm_id)}/index", default_options(options)
|
23
23
|
end
|
24
24
|
|
@@ -30,7 +30,7 @@ module BlizzardApi
|
|
30
30
|
# @!macro request_options
|
31
31
|
#
|
32
32
|
# @!macro response
|
33
|
-
def get(connected_realm_id, dungeon_id, period, options
|
33
|
+
def get(connected_realm_id, dungeon_id, period, **options)
|
34
34
|
api_request "#{endpoint_uri(connected_realm_id)}/#{dungeon_id}/period/#{period}", default_options(options)
|
35
35
|
end
|
36
36
|
|
@@ -19,7 +19,7 @@ module BlizzardApi
|
|
19
19
|
# @!macro request_options
|
20
20
|
#
|
21
21
|
# @!macro response
|
22
|
-
def get(raid, faction, options
|
22
|
+
def get(raid, faction, **options)
|
23
23
|
opts = options.merge(namespace: :dynamic, ttl: CACHE_DAY)
|
24
24
|
api_request "#{base_url(:game_data)}/leaderboard/hall-of-fame/#{raid}/#{faction}", opts
|
25
25
|
end
|
@@ -18,7 +18,7 @@ module BlizzardApi
|
|
18
18
|
# @!macro request_options
|
19
19
|
#
|
20
20
|
# @!macro response
|
21
|
-
def media(id, options
|
21
|
+
def media(id, **options)
|
22
22
|
api_request "#{base_url(:media)}/pet/#{id}", default_options.merge(options)
|
23
23
|
end
|
24
24
|
|
@@ -28,7 +28,7 @@ module BlizzardApi
|
|
28
28
|
# @!macro request_options
|
29
29
|
#
|
30
30
|
# @!macro response
|
31
|
-
def abilities(options
|
31
|
+
def abilities(**options)
|
32
32
|
api_request "#{endpoint_uri('ability')}/index", default_options.merge(options)
|
33
33
|
end
|
34
34
|
|
@@ -40,7 +40,7 @@ module BlizzardApi
|
|
40
40
|
# @!macro request_options
|
41
41
|
#
|
42
42
|
# @!macro response
|
43
|
-
def ability(id, options
|
43
|
+
def ability(id, **options)
|
44
44
|
api_request "#{endpoint_uri('ability')}/#{id}", default_options.merge(options)
|
45
45
|
end
|
46
46
|
|
@@ -52,7 +52,7 @@ module BlizzardApi
|
|
52
52
|
# @!macro request_options
|
53
53
|
#
|
54
54
|
# @!macro response
|
55
|
-
def ability_media(id, options
|
55
|
+
def ability_media(id, **options)
|
56
56
|
api_request "#{base_url(:media)}/pet-ability/#{id}", default_options.merge(options)
|
57
57
|
end
|
58
58
|
|
@@ -17,7 +17,7 @@ module BlizzardApi
|
|
17
17
|
# @!macro request_options
|
18
18
|
#
|
19
19
|
# @!macro response
|
20
|
-
def talent_slots(id, options
|
20
|
+
def talent_slots(id, **options)
|
21
21
|
api_request "#{endpoint_uri}/#{id}/pvp-talent-slots", default_options.merge(options)
|
22
22
|
end
|
23
23
|
|
@@ -25,7 +25,7 @@ module BlizzardApi
|
|
25
25
|
# @!macro complete
|
26
26
|
#
|
27
27
|
# @option options [Boolean] :classic If set to true, this method will call the classic version
|
28
|
-
def complete(options
|
28
|
+
def complete(**options)
|
29
29
|
index_data = index options
|
30
30
|
[].tap do |classes|
|
31
31
|
index_data[:classes].each do |pclass|
|
@@ -45,7 +45,7 @@ module BlizzardApi
|
|
45
45
|
# @option options [Boolean] :classic If set to true, this method will call the classic version
|
46
46
|
#
|
47
47
|
# @!macro response
|
48
|
-
def get(id, options
|
48
|
+
def get(id, **options)
|
49
49
|
data = api_request "#{endpoint_uri}/#{id}", default_options.merge(options)
|
50
50
|
data[:icon] = get_class_icon data[:media], options
|
51
51
|
data
|
@@ -59,7 +59,7 @@ module BlizzardApi
|
|
59
59
|
# @!macro request_options
|
60
60
|
#
|
61
61
|
# @!macro response
|
62
|
-
def media(id, options
|
62
|
+
def media(id, **options)
|
63
63
|
api_request "#{base_url(:media)}/playable-class/#{id}", default_options.merge(options)
|
64
64
|
end
|
65
65
|
|
@@ -12,7 +12,7 @@ module BlizzardApi
|
|
12
12
|
class PlayableSpecialization < Wow::GenericDataEndpoint
|
13
13
|
##
|
14
14
|
# @!macro complete
|
15
|
-
def complete(options
|
15
|
+
def complete(**options)
|
16
16
|
index_data = index options
|
17
17
|
response_data = OpenStruct.new
|
18
18
|
response_data.character_specializations = character_data(index_data, options)
|
@@ -28,7 +28,7 @@ module BlizzardApi
|
|
28
28
|
# @!macro request_options
|
29
29
|
#
|
30
30
|
# @!macro response
|
31
|
-
def media(id, options
|
31
|
+
def media(id, **options)
|
32
32
|
api_request "#{base_url(:media)}/playable-specialization/#{id}", default_options.merge(options)
|
33
33
|
end
|
34
34
|
|
@@ -18,7 +18,7 @@ module BlizzardApi
|
|
18
18
|
# @!macro request_options
|
19
19
|
#
|
20
20
|
# @!macro response
|
21
|
-
def media(id, options
|
21
|
+
def media(id, **options)
|
22
22
|
api_request "#{base_url(:media)}/profession/#{id}", default_options.merge(options)
|
23
23
|
end
|
24
24
|
|
@@ -31,7 +31,7 @@ module BlizzardApi
|
|
31
31
|
# @!macro request_options
|
32
32
|
#
|
33
33
|
# @!macro response
|
34
|
-
def skill_tier(id, tier_id, options
|
34
|
+
def skill_tier(id, tier_id, **options)
|
35
35
|
api_request "#{base_url(:game_data)}/profession/#{id}/skill-tier/#{tier_id}", default_options.merge(options)
|
36
36
|
end
|
37
37
|
|
@@ -43,7 +43,7 @@ module BlizzardApi
|
|
43
43
|
# @!macro request_options
|
44
44
|
#
|
45
45
|
# @!macro response
|
46
|
-
def recipe(id, options
|
46
|
+
def recipe(id, **options)
|
47
47
|
api_request "#{base_url(:game_data)}/recipe/#{id}", default_options.merge(options)
|
48
48
|
end
|
49
49
|
|
@@ -55,7 +55,7 @@ module BlizzardApi
|
|
55
55
|
# @!macro request_options
|
56
56
|
#
|
57
57
|
# @!macro response
|
58
|
-
def recipe_media(id, options
|
58
|
+
def recipe_media(id, **options)
|
59
59
|
api_request "#{base_url(:media)}/recipe/#{id}", default_options.merge(options)
|
60
60
|
end
|
61
61
|
|
@@ -16,7 +16,7 @@ module BlizzardApi
|
|
16
16
|
# @!macro request_options
|
17
17
|
#
|
18
18
|
# @!macro response
|
19
|
-
def leaderboards(season_id, options
|
19
|
+
def leaderboards(season_id, **options)
|
20
20
|
api_request "#{endpoint_uri}/#{season_id}/pvp-leaderboard/index", default_options.merge(options)
|
21
21
|
end
|
22
22
|
|
@@ -26,7 +26,7 @@ module BlizzardApi
|
|
26
26
|
# @!macro request_options
|
27
27
|
#
|
28
28
|
# @!macro response
|
29
|
-
def leaderboard(season_id, brackets, options
|
29
|
+
def leaderboard(season_id, brackets, **options)
|
30
30
|
api_request "#{endpoint_uri}/#{season_id}/pvp-leaderboard/#{brackets}", default_options.merge(options)
|
31
31
|
end
|
32
32
|
|
@@ -36,7 +36,7 @@ module BlizzardApi
|
|
36
36
|
# @!macro request_options
|
37
37
|
#
|
38
38
|
# @!macro response
|
39
|
-
def rewards(season_id, options
|
39
|
+
def rewards(season_id, **options)
|
40
40
|
api_request "#{endpoint_uri}/#{season_id}/pvp-reward/index", default_options.merge(options)
|
41
41
|
end
|
42
42
|
|
@@ -16,7 +16,7 @@ module BlizzardApi
|
|
16
16
|
# @!macro request_options
|
17
17
|
#
|
18
18
|
# @!macro response
|
19
|
-
def categories(options
|
19
|
+
def categories(**options)
|
20
20
|
api_request "#{endpoint_uri}/category/index", default_options.merge(options)
|
21
21
|
end
|
22
22
|
|
@@ -27,7 +27,7 @@ module BlizzardApi
|
|
27
27
|
# @!macro request_options
|
28
28
|
#
|
29
29
|
# @!macro response
|
30
|
-
def category(id, options
|
30
|
+
def category(id, **options)
|
31
31
|
api_request "#{endpoint_uri}/category/#{id}", default_options.merge(options)
|
32
32
|
end
|
33
33
|
|
@@ -37,7 +37,7 @@ module BlizzardApi
|
|
37
37
|
# @!macro request_options
|
38
38
|
#
|
39
39
|
# @!macro response
|
40
|
-
def areas(options
|
40
|
+
def areas(**options)
|
41
41
|
api_request "#{endpoint_uri}/area/index", default_options.merge(options)
|
42
42
|
end
|
43
43
|
|
@@ -48,7 +48,7 @@ module BlizzardApi
|
|
48
48
|
# @!macro request_options
|
49
49
|
#
|
50
50
|
# @!macro response
|
51
|
-
def area(id, options
|
51
|
+
def area(id, **options)
|
52
52
|
api_request "#{endpoint_uri}/area/#{id}", default_options.merge(options)
|
53
53
|
end
|
54
54
|
|
@@ -58,7 +58,7 @@ module BlizzardApi
|
|
58
58
|
# @!macro request_options
|
59
59
|
#
|
60
60
|
# @!macro response
|
61
|
-
def types(options
|
61
|
+
def types(**options)
|
62
62
|
api_request "#{endpoint_uri}/type/index", default_options.merge(options)
|
63
63
|
end
|
64
64
|
|
@@ -69,7 +69,7 @@ module BlizzardApi
|
|
69
69
|
# @!macro request_options
|
70
70
|
#
|
71
71
|
# @!macro response
|
72
|
-
def type(id, options
|
72
|
+
def type(id, **options)
|
73
73
|
api_request "#{endpoint_uri}/type/#{id}", default_options.merge(options)
|
74
74
|
end
|
75
75
|
|
@@ -32,7 +32,7 @@ module BlizzardApi
|
|
32
32
|
# @!macro request_options
|
33
33
|
#
|
34
34
|
# @!macro response
|
35
|
-
def factions(options
|
35
|
+
def factions(**options)
|
36
36
|
api_request "#{endpoint_uri('faction')}/index", default_options.merge(options)
|
37
37
|
end
|
38
38
|
|
@@ -43,7 +43,7 @@ module BlizzardApi
|
|
43
43
|
# @!macro request_options
|
44
44
|
#
|
45
45
|
# @!macro response
|
46
|
-
def faction(id, options
|
46
|
+
def faction(id, **options)
|
47
47
|
api_request "#{endpoint_uri('faction')}/#{id}", default_options.merge(options)
|
48
48
|
end
|
49
49
|
|
@@ -53,7 +53,7 @@ module BlizzardApi
|
|
53
53
|
# @!macro request_options
|
54
54
|
#
|
55
55
|
# @!macro response
|
56
|
-
def tiers(options
|
56
|
+
def tiers(**options)
|
57
57
|
api_request "#{endpoint_uri('tiers')}/index", default_options.merge(options)
|
58
58
|
end
|
59
59
|
|
@@ -64,7 +64,7 @@ module BlizzardApi
|
|
64
64
|
# @!macro request_options
|
65
65
|
#
|
66
66
|
# @!macro response
|
67
|
-
def tier(id, options
|
67
|
+
def tier(id, **options)
|
68
68
|
api_request "#{endpoint_uri('tiers')}/#{id}", default_options.merge(options)
|
69
69
|
end
|
70
70
|
|