Class: RelicLink::Coh3::Client
- Inherits:
-
Object
- Object
- RelicLink::Coh3::Client
- Includes:
- Api::Endpoints, Faraday::Connection, Util, Faraday::Request
- Defined in:
- lib/relic_link/coh3/client.rb
Overview
Main entrypoint for the CoH3 API. Create a new instance of this class in order to begin querying the CoH3 API.
Class Method Summary collapse
-
.config ⇒ Object
Current config module.
-
.configure ⇒ Object
Set configuration options.
Instance Method Summary collapse
-
#initialize(options = {}) ⇒ Client
constructor
Initializes a new client.
Methods included from Util
Methods included from Api::Endpoints::Stats
Methods included from Api::Endpoints::Replays
Methods included from Api::Endpoints::Matches
#recent_match_history, #recent_match_history_by_profile_id
Methods included from Api::Endpoints::Leaderboards
#available_leaderboards, #leaderboard
Methods included from Faraday::Request
Constructor Details
#initialize(options = {}) ⇒ Client
Initializes a new client.
25 26 27 28 29 30 |
# File 'lib/relic_link/coh3/client.rb', line 25 def initialize( = {}) RelicLink::Coh3::Config::ATTRIBUTES.each do |key| send("#{key}=", .fetch(key, RelicLink::Coh3.config.send(key))) end @logger ||= RelicLink::Coh3::Config.logger || RelicLink::Logger.default end |