Class: Twilio::REST::Voice

Inherits:
Domain
  • Object
show all
Defined in:
lib/twilio-ruby/rest/voice.rb,
lib/twilio-ruby/rest/voice/v1.rb,
lib/twilio-ruby/rest/voice/v1/ip_record.rb,
lib/twilio-ruby/rest/voice/v1/byoc_trunk.rb,
lib/twilio-ruby/rest/voice/v1/connection_policy.rb,
lib/twilio-ruby/rest/voice/v1/source_ip_mapping.rb,
lib/twilio-ruby/rest/voice/v1/dialing_permissions.rb,
lib/twilio-ruby/rest/voice/v1/dialing_permissions/country.rb,
lib/twilio-ruby/rest/voice/v1/dialing_permissions/settings.rb,
lib/twilio-ruby/rest/voice/v1/dialing_permissions/bulk_country_update.rb,
lib/twilio-ruby/rest/voice/v1/connection_policy/connection_policy_target.rb,
lib/twilio-ruby/rest/voice/v1/dialing_permissions/country/highrisk_special_prefix.rb

Defined Under Namespace

Classes: V1

Instance Attribute Summary

Attributes inherited from Domain

#client

Instance Method Summary collapse

Methods inherited from Domain

#absolute_url, #request

Constructor Details

#initialize(twilio) ⇒ Voice

Initialize the Voice Domain


14
15
16
17
18
19
20
21
22
23
# File 'lib/twilio-ruby/rest/voice.rb', line 14

def initialize(twilio)
  super

  @base_url = 'https://voice.twilio.com'
  @host = 'voice.twilio.com'
  @port = 443

  # Versions
  @v1 = nil
end

Instance Method Details

#byoc_trunks(sid = :unset) ⇒ Twilio::REST::Voice::V1::ByocTrunkInstance, Twilio::REST::Voice::V1::ByocTrunkList

Parameters:

  • sid (String) (defaults to: :unset)

    The unique string that that we created to identify the BYOC Trunk resource.

Returns:


36
37
38
# File 'lib/twilio-ruby/rest/voice.rb', line 36

def byoc_trunks(sid=:unset)
  self.v1.byoc_trunks(sid)
end

#connection_policies(sid = :unset) ⇒ Twilio::REST::Voice::V1::ConnectionPolicyInstance, Twilio::REST::Voice::V1::ConnectionPolicyList

Parameters:

  • sid (String) (defaults to: :unset)

    The unique string that we created to identify the Connection Policy resource.

Returns:


45
46
47
# File 'lib/twilio-ruby/rest/voice.rb', line 45

def connection_policies(sid=:unset)
  self.v1.connection_policies(sid)
end

#dialing_permissionsTwilio::REST::Voice::V1::DialingPermissionsInstance


51
52
53
# File 'lib/twilio-ruby/rest/voice.rb', line 51

def dialing_permissions
  self.v1.dialing_permissions()
end

#ip_records(sid = :unset) ⇒ Twilio::REST::Voice::V1::IpRecordInstance, Twilio::REST::Voice::V1::IpRecordList

Parameters:

  • sid (String) (defaults to: :unset)

    The unique string that we created to identify the IP Record resource.

Returns:


60
61
62
# File 'lib/twilio-ruby/rest/voice.rb', line 60

def ip_records(sid=:unset)
  self.v1.ip_records(sid)
end

#source_ip_mappings(sid = :unset) ⇒ Twilio::REST::Voice::V1::SourceIpMappingInstance, Twilio::REST::Voice::V1::SourceIpMappingList

Parameters:

  • sid (String) (defaults to: :unset)

    The unique string that we created to identify the IP Record resource.

Returns:


69
70
71
# File 'lib/twilio-ruby/rest/voice.rb', line 69

def source_ip_mappings(sid=:unset)
  self.v1.source_ip_mappings(sid)
end

#to_sObject

Provide a user friendly representation


75
76
77
# File 'lib/twilio-ruby/rest/voice.rb', line 75

def to_s
  '#<Twilio::REST::Voice>'
end

#v1Object

Version v1 of voice


27
28
29
# File 'lib/twilio-ruby/rest/voice.rb', line 27

def v1
  @v1 ||= V1.new self
end