Class: Huntress::API
- Inherits:
-
Object
- Object
- Huntress::API
- Includes:
- Authentication, Connection, WrAPI::Authentication, WrAPI::Connection, WrAPI::Request
- Defined in:
- lib/huntress/api.rb
Direct Known Subclasses
Instance Method Summary collapse
- #config ⇒ Object
-
#initialize(options = {}) ⇒ API
constructor
Creates a new API and copies settings from singleton.
Methods included from Authentication
Constructor Details
#initialize(options = {}) ⇒ API
Creates a new API and copies settings from singleton
14 15 16 17 18 19 |
# File 'lib/huntress/api.rb', line 14 def initialize( = {}) = Huntress..merge() WrAPI::Configuration::VALID_OPTIONS_KEYS.each do |key| send("#{key}=", [key]) end end |
Instance Method Details
#config ⇒ Object
21 22 23 24 25 26 27 |
# File 'lib/huntress/api.rb', line 21 def config conf = {} WrAPI::Configuration::VALID_OPTIONS_KEYS.each do |key| conf[key] = send key end conf end |