Class: Raas::RaasClient

Inherits:
Object
  • Object
show all
Defined in:
lib/raas/raas_client.rb

Instance Method Summary collapse

Constructor Details

#initialize(platform_name: 'QAPlatform2', platform_key: 'apYPfT6HNONpDRUj3CLGWYt7gvIHONpDRUYPfT6Hj') ⇒ RaasClient

Initializer with authentication and configuration parameters



48
49
50
51
# File 'lib/raas/raas_client.rb', line 48

def initialize(platform_name: 'QAPlatform2', platform_key: 'apYPfT6HNONpDRUj3CLGWYt7gvIHONpDRUYPfT6Hj')
  Configuration.platform_name = platform_name if platform_name
  Configuration.platform_key = platform_key if platform_key
end

Instance Method Details

#accountsAccountsController

Singleton access to accounts controller

Returns:



7
8
9
# File 'lib/raas/raas_client.rb', line 7

def accounts
  AccountsController.instance
end

#catalogCatalogController

Singleton access to catalog controller

Returns:



19
20
21
# File 'lib/raas/raas_client.rb', line 19

def catalog
  CatalogController.instance
end

#configConfiguration

Returns the configuration class for easy access

Returns:



43
44
45
# File 'lib/raas/raas_client.rb', line 43

def config
  Configuration
end

#customersCustomersController

Singleton access to customers controller

Returns:



37
38
39
# File 'lib/raas/raas_client.rb', line 37

def customers
  CustomersController.instance
end

#exchange_ratesExchangeRatesController

Singleton access to exchange_rates controller

Returns:



25
26
27
# File 'lib/raas/raas_client.rb', line 25

def exchange_rates
  ExchangeRatesController.instance
end

#ordersOrdersController

Singleton access to orders controller

Returns:



13
14
15
# File 'lib/raas/raas_client.rb', line 13

def orders
  OrdersController.instance
end

#statusStatusController

Singleton access to status controller

Returns:



31
32
33
# File 'lib/raas/raas_client.rb', line 31

def status
  StatusController.instance
end