class Twilio::REST::Chat
Public Class Methods
new(twilio)
click to toggle source
Calls superclass method
Twilio::REST::Domain::new
# File lib/twilio-ruby/rest/chat.rb 14 def initialize(twilio) 15 super 16 17 @base_url = 'https://chat.twilio.com' 18 @host = 'chat.twilio.com' 19 @port = 443 20 21 # Versions 22 @v1 = nil 23 @v2 = nil 24 end
Public Instance Methods
credentials(sid=:unset)
click to toggle source
@param [String] sid The unique string that we created to identify the Credential
resource.
@return [Twilio::REST::Chat::V2::CredentialInstance] if sid was passed. @return [Twilio::REST::Chat::V2::CredentialList]
# File lib/twilio-ruby/rest/chat.rb 43 def credentials(sid=:unset) 44 self.v2.credentials(sid) 45 end
services(sid=:unset)
click to toggle source
@param [String] sid The unique string that we created to identify the Service
resource.
@return [Twilio::REST::Chat::V2::ServiceInstance] if sid was passed. @return [Twilio::REST::Chat::V2::ServiceList]
# File lib/twilio-ruby/rest/chat.rb 52 def services(sid=:unset) 53 self.v2.services(sid) 54 end
to_s()
click to toggle source
Provide a user friendly representation
# File lib/twilio-ruby/rest/chat.rb 58 def to_s 59 '#<Twilio::REST::Chat>' 60 end
v1()
click to toggle source
Version
v1 of chat
# File lib/twilio-ruby/rest/chat.rb 28 def v1 29 @v1 ||= V1.new self 30 end
v2()
click to toggle source
Version
v2 of chat
# File lib/twilio-ruby/rest/chat.rb 34 def v2 35 @v2 ||= V2.new self 36 end