class Twilio::REST::Proxy::V1

Public Class Methods

new(domain) click to toggle source

Initialize the V1 version of Proxy

Calls superclass method Twilio::REST::Version::new
   # File lib/twilio-ruby/rest/proxy/v1.rb
15 def initialize(domain)
16   super
17   @version = 'v1'
18   @services = nil
19 end

Public Instance Methods

services(sid=:unset) click to toggle source

@param [String] sid The Twilio-provided string that uniquely identifies the

Service resource to fetch.

@return [Twilio::REST::Proxy::V1::ServiceContext] if sid was passed. @return [Twilio::REST::Proxy::V1::ServiceList]

   # File lib/twilio-ruby/rest/proxy/v1.rb
26 def services(sid=:unset)
27   if sid.nil?
28       raise ArgumentError, 'sid cannot be nil'
29   end
30   if sid == :unset
31       @services ||= ServiceList.new self
32   else
33       ServiceContext.new(self, sid)
34   end
35 end
to_s() click to toggle source

Provide a user friendly representation

   # File lib/twilio-ruby/rest/proxy/v1.rb
39 def to_s
40   '<Twilio::REST::Proxy::V1>'
41 end