Class: Twilio::REST::Pricing

Inherits:
Domain
  • Object
show all
Defined in:
lib/twilio-ruby/rest/pricing.rb,
lib/twilio-ruby/rest/pricing/v1.rb,
lib/twilio-ruby/rest/pricing/v1/voice.rb,
lib/twilio-ruby/rest/pricing/v1/messaging.rb,
lib/twilio-ruby/rest/pricing/v1/phone_number.rb,
lib/twilio-ruby/rest/pricing/v1/voice/number.rb,
lib/twilio-ruby/rest/pricing/v1/voice/country.rb,
lib/twilio-ruby/rest/pricing/v1/messaging/country.rb,
lib/twilio-ruby/rest/pricing/v1/phone_number/country.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) ⇒ Pricing

Initialize the Pricing Domain



12
13
14
15
16
17
18
19
20
21
# File 'lib/twilio-ruby/rest/pricing.rb', line 12

def initialize(twilio)
  super

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

  # Versions
  @v1 = nil
end

Instance Method Details

#messagingTwilio::REST::Pricing::V1::MessagingInstance



31
32
33
# File 'lib/twilio-ruby/rest/pricing.rb', line 31

def messaging
  self.v1.messaging()
end

#phone_numbersTwilio::REST::Pricing::V1::PhoneNumberInstance



37
38
39
# File 'lib/twilio-ruby/rest/pricing.rb', line 37

def phone_numbers
  self.v1.phone_numbers()
end

#to_sObject

Provide a user friendly representation



49
50
51
# File 'lib/twilio-ruby/rest/pricing.rb', line 49

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

#v1Object

Version v1 of pricing



25
26
27
# File 'lib/twilio-ruby/rest/pricing.rb', line 25

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

#voiceTwilio::REST::Pricing::V1::VoiceInstance



43
44
45
# File 'lib/twilio-ruby/rest/pricing.rb', line 43

def voice
  self.v1.voice()
end