Class: Twilio::REST::Content::V1::LegacyContentInstance
- Inherits:
-
InstanceResource
- Object
- InstanceResource
- Twilio::REST::Content::V1::LegacyContentInstance
- Defined in:
- lib/twilio-ruby/rest/content/v1/legacy_content.rb
Instance Method Summary collapse
-
#account_sid ⇒ String
The SID of the [Account](www.twilio.com/docs/usage/api/account) that created Content resource.
-
#date_created ⇒ Time
The date and time in GMT that the resource was created specified in [RFC 2822](www.ietf.org/rfc/rfc2822.txt) format.
-
#date_updated ⇒ Time
The date and time in GMT that the resource was last updated specified in [RFC 2822](www.ietf.org/rfc/rfc2822.txt) format.
-
#friendly_name ⇒ String
A string name used to describe the Content resource.
-
#initialize(version, payload) ⇒ LegacyContentInstance
constructor
Initialize the LegacyContentInstance.
-
#inspect ⇒ Object
Provide a detailed, user friendly representation.
-
#language ⇒ String
Two-letter (ISO 639-1) language code (e.g., en) identifying the language the Content resource is in.
-
#legacy_body ⇒ String
The string body field of the legacy content template associated with this Content resource.
-
#legacy_template_name ⇒ String
The string name of the legacy content template associated with this Content resource, unique across all template names for its account.
-
#sid ⇒ String
The unique string that that we created to identify the Content resource.
-
#to_s ⇒ Object
Provide a user friendly representation.
-
#types ⇒ Hash
The [Content types](www.twilio.com/docs/content-api/content-types-overview) (e.g. twilio/text) for this Content resource.
-
#url ⇒ String
The URL of the resource, relative to
https://content.twilio.com. -
#variables ⇒ Hash
Defines the default placeholder values for variables included in the Content resource.
Constructor Details
#initialize(version, payload) ⇒ LegacyContentInstance
Initialize the LegacyContentInstance
251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 |
# File 'lib/twilio-ruby/rest/content/v1/legacy_content.rb', line 251 def initialize(version, payload ) super(version) # Marshaled Properties @properties = { 'date_created' => Twilio.deserialize_iso8601_datetime(payload['date_created']), 'date_updated' => Twilio.deserialize_iso8601_datetime(payload['date_updated']), 'sid' => payload['sid'], 'account_sid' => payload['account_sid'], 'friendly_name' => payload['friendly_name'], 'language' => payload['language'], 'variables' => payload['variables'], 'types' => payload['types'], 'legacy_template_name' => payload['legacy_template_name'], 'legacy_body' => payload['legacy_body'], 'url' => payload['url'], } end |
Instance Method Details
#account_sid ⇒ String
Returns The SID of the [Account](www.twilio.com/docs/usage/api/account) that created Content resource.
292 293 294 |
# File 'lib/twilio-ruby/rest/content/v1/legacy_content.rb', line 292 def account_sid @properties['account_sid'] end |
#date_created ⇒ Time
Returns The date and time in GMT that the resource was created specified in [RFC 2822](www.ietf.org/rfc/rfc2822.txt) format.
274 275 276 |
# File 'lib/twilio-ruby/rest/content/v1/legacy_content.rb', line 274 def date_created @properties['date_created'] end |
#date_updated ⇒ Time
Returns The date and time in GMT that the resource was last updated specified in [RFC 2822](www.ietf.org/rfc/rfc2822.txt) format.
280 281 282 |
# File 'lib/twilio-ruby/rest/content/v1/legacy_content.rb', line 280 def date_updated @properties['date_updated'] end |
#friendly_name ⇒ String
Returns A string name used to describe the Content resource. Not visible to the end recipient.
298 299 300 |
# File 'lib/twilio-ruby/rest/content/v1/legacy_content.rb', line 298 def friendly_name @properties['friendly_name'] end |
#inspect ⇒ Object
Provide a detailed, user friendly representation
346 347 348 |
# File 'lib/twilio-ruby/rest/content/v1/legacy_content.rb', line 346 def inspect "<Twilio.Content.V1.LegacyContentInstance>" end |
#language ⇒ String
Returns Two-letter (ISO 639-1) language code (e.g., en) identifying the language the Content resource is in.
304 305 306 |
# File 'lib/twilio-ruby/rest/content/v1/legacy_content.rb', line 304 def language @properties['language'] end |
#legacy_body ⇒ String
Returns The string body field of the legacy content template associated with this Content resource.
328 329 330 |
# File 'lib/twilio-ruby/rest/content/v1/legacy_content.rb', line 328 def legacy_body @properties['legacy_body'] end |
#legacy_template_name ⇒ String
Returns The string name of the legacy content template associated with this Content resource, unique across all template names for its account. Only lowercase letters, numbers and underscores are allowed.
322 323 324 |
# File 'lib/twilio-ruby/rest/content/v1/legacy_content.rb', line 322 def legacy_template_name @properties['legacy_template_name'] end |
#sid ⇒ String
Returns The unique string that that we created to identify the Content resource.
286 287 288 |
# File 'lib/twilio-ruby/rest/content/v1/legacy_content.rb', line 286 def sid @properties['sid'] end |
#to_s ⇒ Object
Provide a user friendly representation
340 341 342 |
# File 'lib/twilio-ruby/rest/content/v1/legacy_content.rb', line 340 def to_s "<Twilio.Content.V1.LegacyContentInstance>" end |
#types ⇒ Hash
Returns The [Content types](www.twilio.com/docs/content-api/content-types-overview) (e.g. twilio/text) for this Content resource.
316 317 318 |
# File 'lib/twilio-ruby/rest/content/v1/legacy_content.rb', line 316 def types @properties['types'] end |
#url ⇒ String
Returns The URL of the resource, relative to https://content.twilio.com.
334 335 336 |
# File 'lib/twilio-ruby/rest/content/v1/legacy_content.rb', line 334 def url @properties['url'] end |
#variables ⇒ Hash
Returns Defines the default placeholder values for variables included in the Content resource. e.g. "Customer_Name".
310 311 312 |
# File 'lib/twilio-ruby/rest/content/v1/legacy_content.rb', line 310 def variables @properties['variables'] end |