Class: Twilio::REST::Preview::TrustedComms::PhoneCallInstance
- Inherits:
-
InstanceResource
- Object
- InstanceResource
- Twilio::REST::Preview::TrustedComms::PhoneCallInstance
- Defined in:
- lib/twilio-ruby/rest/preview/trusted_comms/phone_call.rb
Overview
PLEASE NOTE that this class contains preview products that are subject to change. Use them with caution. If you currently do not have developer preview access, please contact [email protected].
Instance Method Summary collapse
-
#account_sid ⇒ String
Account Sid.
-
#created_at ⇒ Time
The date this Current Call was created.
-
#from ⇒ String
The originating Phone Number.
-
#initialize(version, payload) ⇒ PhoneCallInstance
constructor
Initialize the PhoneCallInstance.
-
#inspect ⇒ Object
Provide a detailed, user friendly representation.
-
#reason ⇒ String
The business reason for this phone call.
-
#sid ⇒ String
A string that uniquely identifies this Current Call.
-
#to ⇒ String
The terminating Phone Number.
-
#to_s ⇒ Object
Provide a user friendly representation.
-
#url ⇒ String
The URL of this resource.
Constructor Details
#initialize(version, payload) ⇒ PhoneCallInstance
Initialize the PhoneCallInstance
198 199 200 201 202 203 204 205 206 207 208 209 210 211 |
# File 'lib/twilio-ruby/rest/preview/trusted_comms/phone_call.rb', line 198 def initialize(version, payload) super(version) # Marshaled Properties @properties = { 'sid' => payload['sid'], 'account_sid' => payload['account_sid'], 'from' => payload['from'], 'to' => payload['to'], 'reason' => payload['reason'], 'created_at' => Twilio.deserialize_iso8601_datetime(payload['created_at']), 'url' => payload['url'], } end |
Instance Method Details
#account_sid ⇒ String
Returns Account Sid.
221 222 223 |
# File 'lib/twilio-ruby/rest/preview/trusted_comms/phone_call.rb', line 221 def account_sid @properties['account_sid'] end |
#created_at ⇒ Time
Returns The date this Current Call was created.
245 246 247 |
# File 'lib/twilio-ruby/rest/preview/trusted_comms/phone_call.rb', line 245 def created_at @properties['created_at'] end |
#from ⇒ String
Returns The originating Phone Number.
227 228 229 |
# File 'lib/twilio-ruby/rest/preview/trusted_comms/phone_call.rb', line 227 def from @properties['from'] end |
#inspect ⇒ Object
Provide a detailed, user friendly representation
263 264 265 |
# File 'lib/twilio-ruby/rest/preview/trusted_comms/phone_call.rb', line 263 def inspect "<Twilio.Preview.TrustedComms.PhoneCallInstance>" end |
#reason ⇒ String
Returns The business reason for this phone call.
239 240 241 |
# File 'lib/twilio-ruby/rest/preview/trusted_comms/phone_call.rb', line 239 def reason @properties['reason'] end |
#sid ⇒ String
Returns A string that uniquely identifies this Current Call.
215 216 217 |
# File 'lib/twilio-ruby/rest/preview/trusted_comms/phone_call.rb', line 215 def sid @properties['sid'] end |
#to ⇒ String
Returns The terminating Phone Number.
233 234 235 |
# File 'lib/twilio-ruby/rest/preview/trusted_comms/phone_call.rb', line 233 def to @properties['to'] end |
#to_s ⇒ Object
Provide a user friendly representation
257 258 259 |
# File 'lib/twilio-ruby/rest/preview/trusted_comms/phone_call.rb', line 257 def to_s "<Twilio.Preview.TrustedComms.PhoneCallInstance>" end |
#url ⇒ String
Returns The URL of this resource.
251 252 253 |
# File 'lib/twilio-ruby/rest/preview/trusted_comms/phone_call.rb', line 251 def url @properties['url'] end |