class Twilio::REST::Numbers::V2::RegulatoryComplianceList::SupportingDocumentInstance

Public Class Methods

new(version, payload, sid: nil) click to toggle source

Initialize the SupportingDocumentInstance @param [Version] version Version that contains the resource @param [Hash] payload payload that contains response from Twilio @param [String] sid The unique string created by Twilio to identify the

Supporting Document resource.

@return [SupportingDocumentInstance] SupportingDocumentInstance

Calls superclass method Twilio::REST::InstanceResource::new
    # File lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/supporting_document.rb
235 def initialize(version, payload, sid: nil)
236   super(version)
237 
238   # Marshaled Properties
239   @properties = {
240       'sid' => payload['sid'],
241       'account_sid' => payload['account_sid'],
242       'friendly_name' => payload['friendly_name'],
243       'mime_type' => payload['mime_type'],
244       'status' => payload['status'],
245       'type' => payload['type'],
246       'attributes' => payload['attributes'],
247       'date_created' => Twilio.deserialize_iso8601_datetime(payload['date_created']),
248       'date_updated' => Twilio.deserialize_iso8601_datetime(payload['date_updated']),
249       'url' => payload['url'],
250   }
251 
252   # Context
253   @instance_context = nil
254   @params = {'sid' => sid || @properties['sid'], }
255 end

Public Instance Methods

account_sid() click to toggle source

@return [String] The SID of the Account that created the resource

    # File lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/supporting_document.rb
276 def account_sid
277   @properties['account_sid']
278 end
attributes() click to toggle source

@return [Hash] The set of parameters that compose the Supporting Documents resource

    # File lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/supporting_document.rb
306 def attributes
307   @properties['attributes']
308 end
context() click to toggle source

Generate an instance context for the instance, the context is capable of performing various actions. All instance actions are proxied to the context @return [SupportingDocumentContext] SupportingDocumentContext for this SupportingDocumentInstance

    # File lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/supporting_document.rb
261 def context
262   unless @instance_context
263     @instance_context = SupportingDocumentContext.new(@version, @params['sid'], )
264   end
265   @instance_context
266 end
date_created() click to toggle source

@return [Time] The ISO 8601 date and time in GMT when the resource was created

    # File lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/supporting_document.rb
312 def date_created
313   @properties['date_created']
314 end
date_updated() click to toggle source

@return [Time] The ISO 8601 date and time in GMT when the resource was last updated

    # File lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/supporting_document.rb
318 def date_updated
319   @properties['date_updated']
320 end
delete() click to toggle source

Delete the SupportingDocumentInstance @return [Boolean] true if delete succeeds, false otherwise

    # File lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/supporting_document.rb
349 def delete
350   context.delete
351 end
fetch() click to toggle source

Fetch the SupportingDocumentInstance @return [SupportingDocumentInstance] Fetched SupportingDocumentInstance

    # File lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/supporting_document.rb
331 def fetch
332   context.fetch
333 end
friendly_name() click to toggle source

@return [String] The string that you assigned to describe the resource

    # File lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/supporting_document.rb
282 def friendly_name
283   @properties['friendly_name']
284 end
inspect() click to toggle source

Provide a detailed, user friendly representation

    # File lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/supporting_document.rb
362 def inspect
363   values = @properties.map{|k, v| "#{k}: #{v}"}.join(" ")
364   "<Twilio.Numbers.V2.SupportingDocumentInstance #{values}>"
365 end
mime_type() click to toggle source

@return [String] The image type of the file

    # File lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/supporting_document.rb
288 def mime_type
289   @properties['mime_type']
290 end
sid() click to toggle source

@return [String] The unique string that identifies the resource

    # File lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/supporting_document.rb
270 def sid
271   @properties['sid']
272 end
status() click to toggle source

@return [supporting_document.Status] The verification status of the Supporting Document resource

    # File lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/supporting_document.rb
294 def status
295   @properties['status']
296 end
to_s() click to toggle source

Provide a user friendly representation

    # File lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/supporting_document.rb
355 def to_s
356   values = @params.map{|k, v| "#{k}: #{v}"}.join(" ")
357   "<Twilio.Numbers.V2.SupportingDocumentInstance #{values}>"
358 end
type() click to toggle source

@return [String] The type of the Supporting Document

    # File lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/supporting_document.rb
300 def type
301   @properties['type']
302 end
update(friendly_name: :unset, attributes: :unset) click to toggle source

Update the SupportingDocumentInstance @param [String] friendly_name The string that you assigned to describe the

resource.

@param [Hash] attributes The set of parameters that are the attributes of the

Supporting Document resource which are derived Supporting Document Types.

@return [SupportingDocumentInstance] Updated SupportingDocumentInstance

    # File lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/supporting_document.rb
342 def update(friendly_name: :unset, attributes: :unset)
343   context.update(friendly_name: friendly_name, attributes: attributes, )
344 end
url() click to toggle source

@return [String] The absolute URL of the Supporting Document resource

    # File lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/supporting_document.rb
324 def url
325   @properties['url']
326 end