Class: Twilio::REST::Chat
- Defined in:
- lib/twilio-ruby/rest/chat.rb,
lib/twilio-ruby/rest/chat/v1.rb,
lib/twilio-ruby/rest/chat/v2.rb,
lib/twilio-ruby/rest/chat/v1/service.rb,
lib/twilio-ruby/rest/chat/v2/service.rb,
lib/twilio-ruby/rest/chat/v1/credential.rb,
lib/twilio-ruby/rest/chat/v2/credential.rb,
lib/twilio-ruby/rest/chat/v1/service/role.rb,
lib/twilio-ruby/rest/chat/v1/service/user.rb,
lib/twilio-ruby/rest/chat/v2/service/role.rb,
lib/twilio-ruby/rest/chat/v2/service/user.rb,
lib/twilio-ruby/rest/chat/v1/service/channel.rb,
lib/twilio-ruby/rest/chat/v2/service/channel.rb,
lib/twilio-ruby/rest/chat/v1/service/channel/invite.rb,
lib/twilio-ruby/rest/chat/v1/service/channel/member.rb,
lib/twilio-ruby/rest/chat/v2/service/channel/invite.rb,
lib/twilio-ruby/rest/chat/v2/service/channel/member.rb,
lib/twilio-ruby/rest/chat/v1/service/channel/message.rb,
lib/twilio-ruby/rest/chat/v2/service/channel/message.rb,
lib/twilio-ruby/rest/chat/v1/service/user/user_channel.rb,
lib/twilio-ruby/rest/chat/v2/service/user/user_channel.rb
Defined Under Namespace
Instance Attribute Summary
Attributes inherited from Domain
Instance Method Summary collapse
- #credentials(sid = :unset) ⇒ Twilio::REST::Chat::V2::CredentialInstance, Twilio::REST::Chat::V2::CredentialList
-
#initialize(twilio) ⇒ Chat
constructor
Initialize the Chat Domain.
- #services(sid = :unset) ⇒ Twilio::REST::Chat::V2::ServiceInstance, Twilio::REST::Chat::V2::ServiceList
-
#to_s ⇒ Object
Provide a user friendly representation.
-
#v1 ⇒ Object
Version v1 of chat.
-
#v2 ⇒ Object
Version v2 of chat.
Methods inherited from Domain
Constructor Details
#initialize(twilio) ⇒ Chat
Initialize the Chat Domain
12 13 14 15 16 17 18 19 20 21 22 |
# File 'lib/twilio-ruby/rest/chat.rb', line 12 def initialize(twilio) super @base_url = 'https://chat.twilio.com' @host = 'chat.twilio.com' @port = 443 # Versions @v1 = nil @v2 = nil end |
Instance Method Details
#credentials(sid = :unset) ⇒ Twilio::REST::Chat::V2::CredentialInstance, Twilio::REST::Chat::V2::CredentialList
40 41 42 |
# File 'lib/twilio-ruby/rest/chat.rb', line 40 def credentials(sid=:unset) self.v2.credentials(sid) end |
#services(sid = :unset) ⇒ Twilio::REST::Chat::V2::ServiceInstance, Twilio::REST::Chat::V2::ServiceList
48 49 50 |
# File 'lib/twilio-ruby/rest/chat.rb', line 48 def services(sid=:unset) self.v2.services(sid) end |
#to_s ⇒ Object
Provide a user friendly representation
54 55 56 |
# File 'lib/twilio-ruby/rest/chat.rb', line 54 def to_s '#<Twilio::REST::Chat>' end |
#v1 ⇒ Object
Version v1 of chat
26 27 28 |
# File 'lib/twilio-ruby/rest/chat.rb', line 26 def v1 @v1 ||= V1.new self end |
#v2 ⇒ Object
Version v2 of chat
32 33 34 |
# File 'lib/twilio-ruby/rest/chat.rb', line 32 def v2 @v2 ||= V2.new self end |