Class: Brapi::Resources::V2::Fii

Inherits:
Brapi::Resource show all
Includes:
Paginated
Defined in:
lib/brapi/resources/v2/fii.rb

Constant Summary

Constants included from Paginated

Paginated::DEFAULT_MAX_PAGES

Instance Attribute Summary

Attributes inherited from Brapi::Resource

#client

Instance Method Summary collapse

Methods included from Paginated

included

Methods inherited from Brapi::Resource

#initialize

Constructor Details

This class inherits a constructor from Brapi::Resource

Instance Method Details

#dividends(symbols, **params) ⇒ Object

GET /api/v2/fii/dividends?symbols=…



30
31
32
33
# File 'lib/brapi/resources/v2/fii.rb', line 30

def dividends(symbols, **params)
  raw = get("/api/v2/fii/dividends", params: params.merge(symbols: format_symbols(symbols)))
  Brapi::Models::V2::FiiDividendsResponse.from_h(raw)
end

#historical(symbols, **params) ⇒ Object

GET /api/v2/fii/historical?symbols=…



24
25
26
27
# File 'lib/brapi/resources/v2/fii.rb', line 24

def historical(symbols, **params)
  raw = get("/api/v2/fii/historical", params: params.merge(symbols: format_symbols(symbols)))
  Brapi::Models::V2::FiiHistoricalResponse.from_h(raw)
end

#indicators(symbols, **params) ⇒ Object

GET /api/v2/fii/indicators?symbols=…



18
19
20
21
# File 'lib/brapi/resources/v2/fii.rb', line 18

def indicators(symbols, **params)
  raw = get("/api/v2/fii/indicators", params: params.merge(symbols: format_symbols(symbols)))
  Brapi::Models::V2::FiiIndicatorsResponse.from_h(raw)
end

#list(**params) ⇒ Object

GET /api/v2/fii/list



12
13
14
15
# File 'lib/brapi/resources/v2/fii.rb', line 12

def list(**params)
  raw = get("/api/v2/fii/list", params: params)
  Brapi::Models::V2::FiiListResponse.from_h(raw)
end