Class: Twilio::REST::Verify::V2::TemplateInstance

Inherits:
InstanceResource show all
Defined in:
lib/twilio-ruby/rest/verify/v2/template.rb

Instance Method Summary collapse

Constructor Details

#initialize(version, payload) ⇒ TemplateInstance

Initialize the TemplateInstance

Parameters:

  • version (Version)

    Version that contains the resource

  • payload (Hash)

    payload that contains response from Twilio


155
156
157
158
159
160
161
162
163
164
165
# File 'lib/twilio-ruby/rest/verify/v2/template.rb', line 155

def initialize(version, payload)
  super(version)

  # Marshaled Properties
  @properties = {
      'sid' => payload['sid'],
      'account_sid' => payload['account_sid'],
      'friendly_name' => payload['friendly_name'],
      'translations' => payload['translations'],
  }
end

Instance Method Details

#account_sidString

Returns Account Sid.

Returns:

  • (String)

    Account Sid


175
176
177
# File 'lib/twilio-ruby/rest/verify/v2/template.rb', line 175

def 
  @properties['account_sid']
end

#friendly_nameString

Returns A string to describe the verification template.

Returns:

  • (String)

    A string to describe the verification template


181
182
183
# File 'lib/twilio-ruby/rest/verify/v2/template.rb', line 181

def friendly_name
  @properties['friendly_name']
end

#inspectObject

Provide a detailed, user friendly representation


199
200
201
# File 'lib/twilio-ruby/rest/verify/v2/template.rb', line 199

def inspect
  "<Twilio.Verify.V2.TemplateInstance>"
end

#sidString

Returns A string that uniquely identifies this Template.

Returns:

  • (String)

    A string that uniquely identifies this Template


169
170
171
# File 'lib/twilio-ruby/rest/verify/v2/template.rb', line 169

def sid
  @properties['sid']
end

#to_sObject

Provide a user friendly representation


193
194
195
# File 'lib/twilio-ruby/rest/verify/v2/template.rb', line 193

def to_s
  "<Twilio.Verify.V2.TemplateInstance>"
end

#translationsHash

Returns Object with the template translations.

Returns:

  • (Hash)

    Object with the template translations.


187
188
189
# File 'lib/twilio-ruby/rest/verify/v2/template.rb', line 187

def translations
  @properties['translations']
end