class Twilio::REST::Api::V2010::AccountContext::IncomingPhoneNumberList::LocalInstance

Public Class Methods

new(version, payload, account_sid: nil) click to toggle source

Initialize the LocalInstance @param [Version] version Version that contains the resource @param [Hash] payload payload that contains response from Twilio @param [String] account_sid The SID of the

{Account}[https://www.twilio.com/docs/iam/api/account] that created this
IncomingPhoneNumber resource.

@return [LocalInstance] LocalInstance

Calls superclass method Twilio::REST::InstanceResource::new
    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
298 def initialize(version, payload, account_sid: nil)
299   super(version)
300 
301   # Marshaled Properties
302   @properties = {
303       'account_sid' => payload['account_sid'],
304       'address_sid' => payload['address_sid'],
305       'address_requirements' => payload['address_requirements'],
306       'api_version' => payload['api_version'],
307       'beta' => payload['beta'],
308       'capabilities' => payload['capabilities'],
309       'date_created' => Twilio.deserialize_rfc2822(payload['date_created']),
310       'date_updated' => Twilio.deserialize_rfc2822(payload['date_updated']),
311       'friendly_name' => payload['friendly_name'],
312       'identity_sid' => payload['identity_sid'],
313       'phone_number' => payload['phone_number'],
314       'origin' => payload['origin'],
315       'sid' => payload['sid'],
316       'sms_application_sid' => payload['sms_application_sid'],
317       'sms_fallback_method' => payload['sms_fallback_method'],
318       'sms_fallback_url' => payload['sms_fallback_url'],
319       'sms_method' => payload['sms_method'],
320       'sms_url' => payload['sms_url'],
321       'status_callback' => payload['status_callback'],
322       'status_callback_method' => payload['status_callback_method'],
323       'trunk_sid' => payload['trunk_sid'],
324       'uri' => payload['uri'],
325       'voice_receive_mode' => payload['voice_receive_mode'],
326       'voice_application_sid' => payload['voice_application_sid'],
327       'voice_caller_id_lookup' => payload['voice_caller_id_lookup'],
328       'voice_fallback_method' => payload['voice_fallback_method'],
329       'voice_fallback_url' => payload['voice_fallback_url'],
330       'voice_method' => payload['voice_method'],
331       'voice_url' => payload['voice_url'],
332       'emergency_status' => payload['emergency_status'],
333       'emergency_address_sid' => payload['emergency_address_sid'],
334       'bundle_sid' => payload['bundle_sid'],
335       'status' => payload['status'],
336   }
337 end

Public Instance Methods

account_sid() click to toggle source

@return [String] The SID of the Account that created the resource

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
341 def account_sid
342   @properties['account_sid']
343 end
address_requirements() click to toggle source

@return [local.AddressRequirement] Whether the phone number requires an Address registered with Twilio.

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
353 def address_requirements
354   @properties['address_requirements']
355 end
address_sid() click to toggle source

@return [String] The SID of the Address resource associated with the phone number

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
347 def address_sid
348   @properties['address_sid']
349 end
api_version() click to toggle source

@return [String] The API version used to start a new TwiML session

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
359 def api_version
360   @properties['api_version']
361 end
beta() click to toggle source

@return [Boolean] Whether the phone number is new to the Twilio platform

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
365 def beta
366   @properties['beta']
367 end
bundle_sid() click to toggle source

@return [String] The SID of the Bundle resource associated with number

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
527 def bundle_sid
528   @properties['bundle_sid']
529 end
capabilities() click to toggle source

@return [String] Indicate if a phone can receive calls or messages

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
371 def capabilities
372   @properties['capabilities']
373 end
date_created() click to toggle source

@return [Time] The RFC 2822 date and time in GMT that the resource was created

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
377 def date_created
378   @properties['date_created']
379 end
date_updated() click to toggle source

@return [Time] The RFC 2822 date and time in GMT that the resource was last updated

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
383 def date_updated
384   @properties['date_updated']
385 end
emergency_address_sid() click to toggle source

@return [String] The emergency address configuration to use for emergency calling

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
521 def emergency_address_sid
522   @properties['emergency_address_sid']
523 end
emergency_status() click to toggle source

@return [local.EmergencyStatus] Whether the phone number is enabled for emergency calling

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
515 def emergency_status
516   @properties['emergency_status']
517 end
friendly_name() click to toggle source

@return [String] The string that you assigned to describe the resource

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
389 def friendly_name
390   @properties['friendly_name']
391 end
identity_sid() click to toggle source

@return [String] The SID of the Identity resource associated with number

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
395 def identity_sid
396   @properties['identity_sid']
397 end
inspect() click to toggle source

Provide a detailed, user friendly representation

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
545 def inspect
546   "<Twilio.Api.V2010.LocalInstance>"
547 end
origin() click to toggle source

@return [String] The phone number's origin. Can be twilio or hosted.

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
407 def origin
408   @properties['origin']
409 end
phone_number() click to toggle source

@return [String] The phone number in E.164 format

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
401 def phone_number
402   @properties['phone_number']
403 end
sid() click to toggle source

@return [String] The unique string that identifies the resource

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
413 def sid
414   @properties['sid']
415 end
sms_application_sid() click to toggle source

@return [String] The SID of the Application resource to handle SMS messages

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
419 def sms_application_sid
420   @properties['sms_application_sid']
421 end
sms_fallback_method() click to toggle source

@return [String] The HTTP method used with sms_fallback_url

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
425 def sms_fallback_method
426   @properties['sms_fallback_method']
427 end
sms_fallback_url() click to toggle source

@return [String] The URL that we call when an error occurs while retrieving or executing the TwiML

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
431 def sms_fallback_url
432   @properties['sms_fallback_url']
433 end
sms_method() click to toggle source

@return [String] The HTTP method to use with sms_url

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
437 def sms_method
438   @properties['sms_method']
439 end
sms_url() click to toggle source

@return [String] The URL we call when the phone number receives an incoming SMS message

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
443 def sms_url
444   @properties['sms_url']
445 end
status() click to toggle source

@return [String] The status

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
533 def status
534   @properties['status']
535 end
status_callback() click to toggle source

@return [String] The URL to send status information to your application

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
449 def status_callback
450   @properties['status_callback']
451 end
status_callback_method() click to toggle source

@return [String] The HTTP method we use to call status_callback

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
455 def status_callback_method
456   @properties['status_callback_method']
457 end
to_s() click to toggle source

Provide a user friendly representation

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
539 def to_s
540   "<Twilio.Api.V2010.LocalInstance>"
541 end
trunk_sid() click to toggle source

@return [String] The SID of the Trunk that handles calls to the phone number

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
461 def trunk_sid
462   @properties['trunk_sid']
463 end
uri() click to toggle source

@return [String] The URI of the resource, relative to `api.twilio.com`

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
467 def uri
468   @properties['uri']
469 end
voice_application_sid() click to toggle source

@return [String] The SID of the application that handles calls to the phone number

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
479 def voice_application_sid
480   @properties['voice_application_sid']
481 end
voice_caller_id_lookup() click to toggle source

@return [Boolean] Whether to lookup the caller's name

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
485 def voice_caller_id_lookup
486   @properties['voice_caller_id_lookup']
487 end
voice_fallback_method() click to toggle source

@return [String] The HTTP method used with voice_fallback_url

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
491 def voice_fallback_method
492   @properties['voice_fallback_method']
493 end
voice_fallback_url() click to toggle source

@return [String] The URL we call when an error occurs in TwiML

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
497 def voice_fallback_url
498   @properties['voice_fallback_url']
499 end
voice_method() click to toggle source

@return [String] The HTTP method used with the voice_url

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
503 def voice_method
504   @properties['voice_method']
505 end
voice_receive_mode() click to toggle source

@return [local.VoiceReceiveMode] The voice_receive_mode

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
473 def voice_receive_mode
474   @properties['voice_receive_mode']
475 end
voice_url() click to toggle source

@return [String] The URL we call when this phone number receives a call

    # File lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb
509 def voice_url
510   @properties['voice_url']
511 end