blizzard_api 0.3.1 → 0.3.2

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.
@@ -1,38 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module BlizzardApi
4
- module Wow
5
- ##
6
- # This class allows access to World of Warcraft playable races
7
- #
8
- # @see https://develop.battle.net/documentation/api-reference/world-of-warcraft-game-data-api
9
- #
10
- # You can get an instance of this class using the default region as follows:
11
- # race = BlizzardApi::Wow.race
12
- class Race < Wow::GenericDataEndpoint
13
- ##
14
- # Returns a index of playable races
15
- #
16
- # @!macro request_options
17
- # @option options [Boolean] :use_community_endpoint If set to true, this method will call the community endpoint
18
- # instead of the data endpoint https://develop.battle.net/documentation/api-reference/world-of-warcraft-community-api
19
- # @option options [Boolean] :classic If set to true, this method will call the classic version
20
- #
21
- # @!macro response
22
- def index(options = {})
23
- return super options unless options.include? :use_community_endpoint
24
-
25
- api_request "#{base_url(:community)}/data/character/races", { ttl: CACHE_TRIMESTER }.merge(options)
26
- end
27
-
28
- protected
29
-
30
- def endpoint_setup
31
- @endpoint = 'playable-race'
32
- @namespace = :static
33
- @collection = 'races'
34
- @ttl = CACHE_TRIMESTER
35
- end
36
- end
37
- end
38
- end
@@ -1,23 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module BlizzardApi
4
- module Wow
5
- ##
6
- # This class allows access to World of Warcraft reputation
7
- #
8
- # @see https://develop.battle.net/documentation/api-reference/world-of-warcraft-game-data-api
9
- #
10
- # You can get an instance of this class using the default region as follows:
11
- # api_instance = BlizzardApi::Wow.creature
12
- class ReputationFaction < Wow::GenericDataEndpoint
13
- protected
14
-
15
- def endpoint_setup
16
- @endpoint = 'reputation-faction'
17
- @namespace = :static
18
- @collection = 'achievements'
19
- @ttl = CACHE_TRIMESTER
20
- end
21
- end
22
- end
23
- end