Module: IEX::Api::Sectors

Defined in:
lib/iex/api/sectors.rb

Class Method Summary collapse

Class Method Details

.connection(symbol) ⇒ Object



8
9
10
11
12
13
# File 'lib/iex/api/sectors.rb', line 8

def self.connection(symbol)
  IEX::Api.default_connection [
    symbol,
    'sector-performance'
  ].compact.join('/')
end

.get(symbol) ⇒ Object



4
5
6
# File 'lib/iex/api/sectors.rb', line 4

def self.get(symbol)
  connection(symbol).get.body
end