Class: Twilio::REST::PricingBase

Inherits:
Domain
  • Object
show all
Defined in:
lib/twilio-ruby/rest/pricing_base.rb

Direct Known Subclasses

Pricing

Instance Attribute Summary

Attributes inherited from Domain

#client

Instance Method Summary collapse

Methods inherited from Domain

#absolute_url, #request

Constructor Details

#initialize(twilio) ⇒ PricingBase

Initialize pricing domain

Parameters:

  • twilio
    • The twilio client



19
20
21
22
23
24
25
26
# File 'lib/twilio-ruby/rest/pricing_base.rb', line 19

def initialize(twilio)
  super(twilio)
  @base_url =  "https://pricing.twilio.com"
  @host = "pricing.twilio.com"
  @port = 443
  @v1 = nil
  @v2 = nil
end

Instance Method Details

#to_sObject

Provide a user friendly representation



38
39
40
# File 'lib/twilio-ruby/rest/pricing_base.rb', line 38

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

#v1Object



28
29
30
# File 'lib/twilio-ruby/rest/pricing_base.rb', line 28

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

#v2Object



32
33
34
# File 'lib/twilio-ruby/rest/pricing_base.rb', line 32

def v2
  @v2 ||= Pricing::V2.new self
end