Class: FinApps::REST::PortfoliosAvailableConsumers

Inherits:
FinAppsCore::REST::Resources
  • Object
show all
Includes:
Utils::QueryBuilder
Defined in:
lib/finapps/rest/portfolios_available_consumers.rb

Instance Method Summary collapse

Methods included from Utils::QueryBuilder

#build_query_path

Instance Method Details

#list(portfolio_id, params = nil) ⇒ Object



8
9
10
11
12
13
14
15
16
17
18
# File 'lib/finapps/rest/portfolios_available_consumers.rb', line 8

def list(portfolio_id, params = nil)
  not_blank(portfolio_id, :portfolio_id)

  path =
    "portfolios/#{ERB::Util.url_encode(portfolio_id)}/consumers/available"
  return super path if params.nil?

  fail FinAppsCore::InvalidArgumentsError, 'Invalid argument: params' unless params.is_a? Hash

  super build_query_path(path, params)
end