Class: Twilio::REST::Api::V2010::AccountContext::BalanceListResponse
- Inherits:
-
InstanceListResource
- Object
- InstanceListResource
- Twilio::REST::Api::V2010::AccountContext::BalanceListResponse
- Defined in:
- lib/twilio-ruby/rest/api/v2010/account/balance.rb
Instance Method Summary collapse
- #balance ⇒ Object
- #headers ⇒ Object
-
#initialize(version, payload, key, limit = :unset) ⇒ BalanceListResponse
constructor
A new instance of BalanceListResponse.
- #status_code ⇒ Object
Constructor Details
#initialize(version, payload, key, limit = :unset) ⇒ BalanceListResponse
Returns a new instance of BalanceListResponse.
153 154 155 156 157 158 159 160 161 162 163 |
# File 'lib/twilio-ruby/rest/api/v2010/account/balance.rb', line 153 def initialize(version, payload, key, limit = :unset) data_list = payload.body[key] if limit != :unset data_list = data_list[0, limit] end @balance = data_list.map do |data| BalanceInstance.new(version, data) end @headers = payload.headers @status_code = payload.status_code end |
Instance Method Details
#balance ⇒ Object
165 166 167 |
# File 'lib/twilio-ruby/rest/api/v2010/account/balance.rb', line 165 def balance @balance end |
#headers ⇒ Object
169 170 171 |
# File 'lib/twilio-ruby/rest/api/v2010/account/balance.rb', line 169 def headers @headers end |
#status_code ⇒ Object
173 174 175 |
# File 'lib/twilio-ruby/rest/api/v2010/account/balance.rb', line 173 def status_code @status_code end |