Class: Twilio::REST::Content

Inherits:
Domain
  • Object
show all
Defined in:
lib/twilio-ruby/rest/content.rb,
lib/twilio-ruby/rest/content/v1.rb,
lib/twilio-ruby/rest/content/v1/content.rb,
lib/twilio-ruby/rest/content/v1/legacy_content.rb,
lib/twilio-ruby/rest/content/v1/content_and_approvals.rb,
lib/twilio-ruby/rest/content/v1/content/approval_fetch.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) ⇒ Content

Initialize the Content Domain



14
15
16
17
18
19
20
21
22
23
# File 'lib/twilio-ruby/rest/content.rb', line 14

def initialize(twilio)
  super

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

  # Versions
  @v1 = nil
end

Instance Method Details

#content_and_approvalsTwilio::REST::Content::V1::ContentAndApprovalsInstance



42
43
44
# File 'lib/twilio-ruby/rest/content.rb', line 42

def content_and_approvals
  self.v1.content_and_approvals()
end

#contents(sid = :unset) ⇒ Twilio::REST::Content::V1::ContentInstance, Twilio::REST::Content::V1::ContentList

Parameters:

  • sid (String) (defaults to: :unset)

    The unique string that that we created to identify the Content resource.

Returns:



36
37
38
# File 'lib/twilio-ruby/rest/content.rb', line 36

def contents(sid=:unset)
  self.v1.contents(sid)
end

#legacy_contentsTwilio::REST::Content::V1::LegacyContentInstance



48
49
50
# File 'lib/twilio-ruby/rest/content.rb', line 48

def legacy_contents
  self.v1.legacy_contents()
end

#to_sObject

Provide a user friendly representation



54
55
56
# File 'lib/twilio-ruby/rest/content.rb', line 54

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

#v1Object

Version v1 of content



27
28
29
# File 'lib/twilio-ruby/rest/content.rb', line 27

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