class Twilio::REST::Preview::Sync::ServiceContext::SyncListInstance

PLEASE NOTE that this class contains preview products that are subject to change. Use them with caution. If you currently do not have developer preview access, please contact help@twilio.com.

Public Class Methods

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

Initialize the SyncListInstance @param [Version] version Version that contains the resource @param [Hash] payload payload that contains response from Twilio @param [String] service_sid The service_sid @param [String] sid The sid @return [SyncListInstance] SyncListInstance

Calls superclass method Twilio::REST::InstanceResource::new
    # File lib/twilio-ruby/rest/preview/sync/service/sync_list.rb
266 def initialize(version, payload, service_sid: nil, sid: nil)
267   super(version)
268 
269   # Marshaled Properties
270   @properties = {
271       'sid' => payload['sid'],
272       'unique_name' => payload['unique_name'],
273       'account_sid' => payload['account_sid'],
274       'service_sid' => payload['service_sid'],
275       'url' => payload['url'],
276       'links' => payload['links'],
277       'revision' => payload['revision'],
278       'date_created' => Twilio.deserialize_iso8601_datetime(payload['date_created']),
279       'date_updated' => Twilio.deserialize_iso8601_datetime(payload['date_updated']),
280       'created_by' => payload['created_by'],
281   }
282 
283   # Context
284   @instance_context = nil
285   @params = {'service_sid' => service_sid, 'sid' => sid || @properties['sid'], }
286 end

Public Instance Methods

account_sid() click to toggle source

@return [String] The account_sid

    # File lib/twilio-ruby/rest/preview/sync/service/sync_list.rb
313 def account_sid
314   @properties['account_sid']
315 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 [SyncListContext] SyncListContext for this SyncListInstance

    # File lib/twilio-ruby/rest/preview/sync/service/sync_list.rb
292 def context
293   unless @instance_context
294     @instance_context = SyncListContext.new(@version, @params['service_sid'], @params['sid'], )
295   end
296   @instance_context
297 end
created_by() click to toggle source

@return [String] The created_by

    # File lib/twilio-ruby/rest/preview/sync/service/sync_list.rb
355 def created_by
356   @properties['created_by']
357 end
date_created() click to toggle source

@return [Time] The date_created

    # File lib/twilio-ruby/rest/preview/sync/service/sync_list.rb
343 def date_created
344   @properties['date_created']
345 end
date_updated() click to toggle source

@return [Time] The date_updated

    # File lib/twilio-ruby/rest/preview/sync/service/sync_list.rb
349 def date_updated
350   @properties['date_updated']
351 end
delete() click to toggle source

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

    # File lib/twilio-ruby/rest/preview/sync/service/sync_list.rb
369 def delete
370   context.delete
371 end
fetch() click to toggle source

Fetch the SyncListInstance @return [SyncListInstance] Fetched SyncListInstance

    # File lib/twilio-ruby/rest/preview/sync/service/sync_list.rb
362 def fetch
363   context.fetch
364 end
inspect() click to toggle source

Provide a detailed, user friendly representation

    # File lib/twilio-ruby/rest/preview/sync/service/sync_list.rb
396 def inspect
397   values = @properties.map{|k, v| "#{k}: #{v}"}.join(" ")
398   "<Twilio.Preview.Sync.SyncListInstance #{values}>"
399 end
revision() click to toggle source

@return [String] The revision

    # File lib/twilio-ruby/rest/preview/sync/service/sync_list.rb
337 def revision
338   @properties['revision']
339 end
service_sid() click to toggle source

@return [String] The service_sid

    # File lib/twilio-ruby/rest/preview/sync/service/sync_list.rb
319 def service_sid
320   @properties['service_sid']
321 end
sid() click to toggle source

@return [String] The sid

    # File lib/twilio-ruby/rest/preview/sync/service/sync_list.rb
301 def sid
302   @properties['sid']
303 end
sync_list_items() click to toggle source

Access the sync_list_items @return [sync_list_items] sync_list_items

    # File lib/twilio-ruby/rest/preview/sync/service/sync_list.rb
376 def sync_list_items
377   context.sync_list_items
378 end
sync_list_permissions() click to toggle source

Access the sync_list_permissions @return [sync_list_permissions] sync_list_permissions

    # File lib/twilio-ruby/rest/preview/sync/service/sync_list.rb
383 def sync_list_permissions
384   context.sync_list_permissions
385 end
to_s() click to toggle source

Provide a user friendly representation

    # File lib/twilio-ruby/rest/preview/sync/service/sync_list.rb
389 def to_s
390   values = @params.map{|k, v| "#{k}: #{v}"}.join(" ")
391   "<Twilio.Preview.Sync.SyncListInstance #{values}>"
392 end
unique_name() click to toggle source

@return [String] The unique_name

    # File lib/twilio-ruby/rest/preview/sync/service/sync_list.rb
307 def unique_name
308   @properties['unique_name']
309 end
url() click to toggle source

@return [String] The url

    # File lib/twilio-ruby/rest/preview/sync/service/sync_list.rb
325 def url
326   @properties['url']
327 end