Class: GenesisClient::Client

Inherits:
Object
  • Object
show all
Includes:
Devices, RemoteActions
Defined in:
lib/genesis_client/client.rb

Instance Method Summary collapse

Methods included from RemoteActions

#create_remote_action_log, #remote_action, #remote_actions, #update_remote_action

Methods included from Devices

#create_device_log, #device, #devices, #update_device

Constructor Details

#initialize(options = {}) ⇒ Client

Returns a new instance of Client.

Raises:

  • (ArgumentError)


7
8
9
10
11
12
# File 'lib/genesis_client/client.rb', line 7

def initialize(options = {})
  @endpoint = options[:endpoint].to_s
  @token = options[:token].to_s
  raise ArgumentError, ":endpoint can't be blank" if @endpoint.empty?
  raise ArgumentError, ":token can't be blank" if @token.empty?
end