blizzard_api 0.5.1 → 0.5.6

Sign up to get free protection for your applications and to get access to all the features.
Files changed (58) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/ruby.yml +21 -0
  3. data/CHANGELOG.md +22 -0
  4. data/Gemfile.lock +16 -16
  5. data/README.md +58 -218
  6. data/blizzard_api.gemspec +6 -4
  7. data/lib/blizzard_api/diablo/community/act.rb +2 -2
  8. data/lib/blizzard_api/diablo/community/artisan.rb +2 -2
  9. data/lib/blizzard_api/diablo/community/character.rb +2 -2
  10. data/lib/blizzard_api/diablo/community/follower.rb +1 -1
  11. data/lib/blizzard_api/diablo/community/item.rb +1 -1
  12. data/lib/blizzard_api/diablo/community/item_type.rb +2 -2
  13. data/lib/blizzard_api/diablo/community/profile.rb +4 -4
  14. data/lib/blizzard_api/diablo/game_data/generic_data_endpoint.rb +3 -3
  15. data/lib/blizzard_api/hearthstone/game_data/back.rb +1 -1
  16. data/lib/blizzard_api/hearthstone/game_data/card.rb +2 -2
  17. data/lib/blizzard_api/hearthstone/game_data/generic_data_endpoint.rb +2 -2
  18. data/lib/blizzard_api/request.rb +3 -3
  19. data/lib/blizzard_api/starcraft.rb +7 -0
  20. data/lib/blizzard_api/starcraft/community/account.rb +1 -1
  21. data/lib/blizzard_api/starcraft/community/ladder.rb +2 -2
  22. data/lib/blizzard_api/starcraft/community/legacy.rb +88 -0
  23. data/lib/blizzard_api/starcraft/community/profile.rb +5 -5
  24. data/lib/blizzard_api/starcraft/game_data/league.rb +1 -1
  25. data/lib/blizzard_api/version.rb +1 -1
  26. data/lib/blizzard_api/wow.rb +16 -7
  27. data/lib/blizzard_api/wow/game_data/achievement.rb +3 -3
  28. data/lib/blizzard_api/wow/game_data/auction.rb +1 -1
  29. data/lib/blizzard_api/wow/game_data/azerite_essence.rb +1 -1
  30. data/lib/blizzard_api/wow/game_data/covenant.rb +79 -0
  31. data/lib/blizzard_api/wow/game_data/creature.rb +6 -6
  32. data/lib/blizzard_api/wow/game_data/generic_data_endpoint.rb +3 -3
  33. data/lib/blizzard_api/wow/game_data/guild_crest.rb +2 -2
  34. data/lib/blizzard_api/wow/game_data/item.rb +6 -6
  35. data/lib/blizzard_api/wow/game_data/journal.rb +8 -8
  36. data/lib/blizzard_api/wow/game_data/modified_crafting.rb +4 -4
  37. data/lib/blizzard_api/wow/game_data/mythic_keystone.rb +6 -6
  38. data/lib/blizzard_api/wow/game_data/mythic_keystone_affix.rb +1 -1
  39. data/lib/blizzard_api/wow/game_data/mythic_keystone_leaderboard.rb +2 -2
  40. data/lib/blizzard_api/wow/game_data/mythic_raid_leaderboard.rb +1 -1
  41. data/lib/blizzard_api/wow/game_data/pet.rb +4 -4
  42. data/lib/blizzard_api/wow/game_data/playable_class.rb +4 -4
  43. data/lib/blizzard_api/wow/game_data/playable_specialization.rb +2 -2
  44. data/lib/blizzard_api/wow/game_data/profession.rb +4 -4
  45. data/lib/blizzard_api/wow/game_data/pvp_season.rb +3 -3
  46. data/lib/blizzard_api/wow/game_data/pvp_tier.rb +1 -1
  47. data/lib/blizzard_api/wow/game_data/quest.rb +6 -6
  48. data/lib/blizzard_api/wow/game_data/reputation.rb +4 -4
  49. data/lib/blizzard_api/wow/game_data/spell.rb +1 -1
  50. data/lib/blizzard_api/wow/game_data/talent.rb +2 -2
  51. data/lib/blizzard_api/wow/game_data/tech_talent.rb +57 -0
  52. data/lib/blizzard_api/wow/game_data/wow_token.rb +1 -1
  53. data/lib/blizzard_api/wow/profile/character_profile.rb +63 -49
  54. data/lib/blizzard_api/wow/profile/guild.rb +8 -8
  55. data/lib/blizzard_api/wow/profile/profile.rb +5 -5
  56. data/lib/blizzard_api/wow/search/search_request.rb +1 -1
  57. metadata +13 -8
  58. data/.gitlab-ci.yml +0 -12
@@ -20,7 +20,7 @@ module BlizzardApi
20
20
  # @!macro request_options
21
21
  #
22
22
  # @!macro response
23
- def get(realm, guild, options = {})
23
+ def get(realm, guild, **options)
24
24
  guild_request(realm, guild, options)
25
25
  end
26
26
 
@@ -33,8 +33,8 @@ module BlizzardApi
33
33
  # @!macro request_options
34
34
  #
35
35
  # @!macro response
36
- def roster(realm, guild, options = {})
37
- guild_request realm, guild, options, 'roster'
36
+ def roster(realm, guild, **options)
37
+ guild_request realm, guild, 'roster', options
38
38
  end
39
39
 
40
40
  ##
@@ -45,8 +45,8 @@ module BlizzardApi
45
45
  # @!macro request_options
46
46
  #
47
47
  # @!macro response
48
- def achievements(realm, guild, options = {})
49
- guild_request realm, guild, options, 'achievements'
48
+ def achievements(realm, guild, **options)
49
+ guild_request realm, guild, 'achievements', options
50
50
  end
51
51
 
52
52
  ##
@@ -57,13 +57,13 @@ module BlizzardApi
57
57
  # @!macro request_options
58
58
  #
59
59
  # @!macro response
60
- def activity(realm, guild, options = {})
61
- guild_request realm, guild, options, 'activity'
60
+ def activity(realm, guild, **options)
61
+ guild_request realm, guild, 'activity', options
62
62
  end
63
63
 
64
64
  private
65
65
 
66
- def guild_request(realm, guild, options = {}, variant = nil)
66
+ def guild_request(realm, guild, variant = nil, **options)
67
67
  realm = string_to_slug(realm)
68
68
  guild = string_to_slug(guild)
69
69
  url = "#{base_url(:game_data)}/guild/#{realm}/#{guild}"
@@ -18,7 +18,7 @@ module BlizzardApi
18
18
  # @!macro request_options
19
19
  #
20
20
  # @!macro response
21
- def get(options = {})
21
+ def get(**options)
22
22
  api_request base_url(:user_profile).to_s, 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 protected_character(realm_id, character_id, options = {})
31
+ def protected_character(realm_id, character_id, **options)
32
32
  api_request "#{base_url(:user_profile)}/protected-character/#{realm_id}-#{character_id}", default_options.merge(options)
33
33
  end
34
34
 
@@ -38,7 +38,7 @@ module BlizzardApi
38
38
  # @!macro request_options
39
39
  #
40
40
  # @!macro response
41
- def collection(options = {})
41
+ def collection(**options)
42
42
  api_request "#{base_url(:user_profile)}/collections", default_options.merge(options)
43
43
  end
44
44
 
@@ -48,7 +48,7 @@ module BlizzardApi
48
48
  # @!macro request_options
49
49
  #
50
50
  # @!macro response
51
- def mounts(options = {})
51
+ def mounts(**options)
52
52
  api_request "#{base_url(:user_profile)}/collections/mounts", 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 pets(options = {})
61
+ def pets(**options)
62
62
  api_request "#{base_url(:user_profile)}/collections/pets", default_options.merge(options)
63
63
  end
64
64
 
@@ -13,7 +13,7 @@ module BlizzardApi
13
13
  #
14
14
  # @!macro request_options
15
15
  # @!macro response
16
- def search(page = 1, page_size = 100, options = {})
16
+ def search(page = 1, page_size = 100, **options)
17
17
  search_options = SearchComposer.new(page, page_size)
18
18
  yield search_options if block_given?
19
19
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: blizzard_api
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.1
4
+ version: 0.5.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Francis Schiavo
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2020-10-24 00:00:00.000000000 Z
11
+ date: 2021-05-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: redis
@@ -102,13 +102,13 @@ dependencies:
102
102
  version: '0'
103
103
  description: This is a simple interface to obtain data from Blizzard API
104
104
  email:
105
- - francis.schiavo@francisschiavo.com
105
+ - francis@schiavo.dev
106
106
  executables: []
107
107
  extensions: []
108
108
  extra_rdoc_files: []
109
109
  files:
110
+ - ".github/workflows/ruby.yml"
110
111
  - ".gitignore"
111
- - ".gitlab-ci.yml"
112
112
  - ".rubocop.yml"
113
113
  - ".rubocop_todo.yml"
114
114
  - CHANGELOG.md
@@ -146,6 +146,7 @@ files:
146
146
  - lib/blizzard_api/starcraft.rb
147
147
  - lib/blizzard_api/starcraft/community/account.rb
148
148
  - lib/blizzard_api/starcraft/community/ladder.rb
149
+ - lib/blizzard_api/starcraft/community/legacy.rb
149
150
  - lib/blizzard_api/starcraft/community/profile.rb
150
151
  - lib/blizzard_api/starcraft/game_data/league.rb
151
152
  - lib/blizzard_api/starcraft/request.rb
@@ -155,6 +156,7 @@ files:
155
156
  - lib/blizzard_api/wow/game_data/auction.rb
156
157
  - lib/blizzard_api/wow/game_data/azerite_essence.rb
157
158
  - lib/blizzard_api/wow/game_data/connected_realm.rb
159
+ - lib/blizzard_api/wow/game_data/covenant.rb
158
160
  - lib/blizzard_api/wow/game_data/creature.rb
159
161
  - lib/blizzard_api/wow/game_data/generic_data_endpoint.rb
160
162
  - lib/blizzard_api/wow/game_data/guild_crest.rb
@@ -181,6 +183,7 @@ files:
181
183
  - lib/blizzard_api/wow/game_data/reputation.rb
182
184
  - lib/blizzard_api/wow/game_data/spell.rb
183
185
  - lib/blizzard_api/wow/game_data/talent.rb
186
+ - lib/blizzard_api/wow/game_data/tech_talent.rb
184
187
  - lib/blizzard_api/wow/game_data/title.rb
185
188
  - lib/blizzard_api/wow/game_data/wow_token.rb
186
189
  - lib/blizzard_api/wow/profile/character_profile.rb
@@ -190,13 +193,15 @@ files:
190
193
  - lib/blizzard_api/wow/search/search_composer.rb
191
194
  - lib/blizzard_api/wow/search/search_request.rb
192
195
  - lib/blizzard_api/wow/slug.rb
193
- homepage: https://gitlab.com/francisschiavo/blizzard_api
196
+ homepage: https://github.com/francis-schiavo/blizzard_api
194
197
  licenses:
195
198
  - MIT
196
199
  metadata:
197
- homepage_uri: https://gitlab.com/francisschiavo/blizzard_api
198
- source_code_uri: https://gitlab.com/francisschiavo/blizzard_api
199
- changelog_uri: https://gitlab.com/francisschiavo/blizzard_api/blob/master/CHANGELOG.md
200
+ homepage_uri: https://github.com/francis-schiavo/blizzard_api
201
+ source_code_uri: https://github.com/francis-schiavo/blizzard_api
202
+ bug_tracker_uri: https://github.com/francis-schiavo/blizzard_api/issues
203
+ changelog_uri: https://github.com/francis-schiavo/blizzard_api/blob/master/CHANGELOG.md
204
+ documentation_uri: https://rubydoc.info/gems/blizzard_api
200
205
  post_install_message:
201
206
  rdoc_options: []
202
207
  require_paths:
data/.gitlab-ci.yml DELETED
@@ -1,12 +0,0 @@
1
- image: ruby:2.6
2
-
3
- stages:
4
- - test
5
-
6
- test:
7
- stage: test
8
- script:
9
- - gem install bundler -v 2.1.2
10
- - bundle install
11
- - rubocop
12
- - rake