Class: DeGiro::GetCashFunds

Inherits:
Object
  • Object
show all
Defined in:
lib/degiro/get_cash_funds.rb

Instance Method Summary collapse

Constructor Details

#initialize(connection) ⇒ GetCashFunds

Returns a new instance of GetCashFunds.



5
6
7
# File 'lib/degiro/get_cash_funds.rb', line 5

def initialize(connection)
  @connection = connection
end

Instance Method Details

#get_cash_fundsObject



9
10
11
12
# File 'lib/degiro/get_cash_funds.rb', line 9

def get_cash_funds
  params = URI.encode_www_form(cashFunds: 0)
  parse_cash_funds(JSON.parse(@connection.get(url(params)).body))
end