Class: Twilio::REST::Wireless::V1::UsageRecordInstance
- Inherits:
-
InstanceResource
- Object
- InstanceResource
- Twilio::REST::Wireless::V1::UsageRecordInstance
- Defined in:
- lib/twilio-ruby/rest/wireless/v1/usage_record.rb
Instance Method Summary collapse
-
#account_sid ⇒ String
The unique id of the Account.
-
#commands ⇒ Hash
An object representing the aggregated Commands usage for all SIMs over the period.
-
#data ⇒ Hash
An object representing the aggregated Data usage for all SIMs over the period.
-
#initialize(version, payload) ⇒ UsageRecordInstance
constructor
Initialize the UsageRecordInstance.
-
#inspect ⇒ Object
Provide a detailed, user friendly representation.
-
#period ⇒ Hash
The time period for which usage is reported.
-
#to_s ⇒ Object
Provide a user friendly representation.
Constructor Details
#initialize(version, payload) ⇒ UsageRecordInstance
Initialize the UsageRecordInstance
180 181 182 183 184 185 186 187 188 189 190 |
# File 'lib/twilio-ruby/rest/wireless/v1/usage_record.rb', line 180 def initialize(version, payload) super(version) # Marshaled Properties @properties = { 'account_sid' => payload['account_sid'], 'period' => payload['period'], 'commands' => payload['commands'], 'data' => payload['data'], } end |
Instance Method Details
#account_sid ⇒ String
Returns The unique id of the Account.
194 195 196 |
# File 'lib/twilio-ruby/rest/wireless/v1/usage_record.rb', line 194 def account_sid @properties['account_sid'] end |
#commands ⇒ Hash
Returns An object representing the aggregated Commands usage for all SIMs over the period.
206 207 208 |
# File 'lib/twilio-ruby/rest/wireless/v1/usage_record.rb', line 206 def commands @properties['commands'] end |
#data ⇒ Hash
Returns An object representing the aggregated Data usage for all SIMs over the period.
212 213 214 |
# File 'lib/twilio-ruby/rest/wireless/v1/usage_record.rb', line 212 def data @properties['data'] end |
#inspect ⇒ Object
Provide a detailed, user friendly representation
224 225 226 |
# File 'lib/twilio-ruby/rest/wireless/v1/usage_record.rb', line 224 def inspect "<Twilio.Wireless.V1.UsageRecordInstance>" end |
#period ⇒ Hash
Returns The time period for which usage is reported.
200 201 202 |
# File 'lib/twilio-ruby/rest/wireless/v1/usage_record.rb', line 200 def period @properties['period'] end |
#to_s ⇒ Object
Provide a user friendly representation
218 219 220 |
# File 'lib/twilio-ruby/rest/wireless/v1/usage_record.rb', line 218 def to_s "<Twilio.Wireless.V1.UsageRecordInstance>" end |