Class: Twilio::REST::Accounts::V1::BulkConsentsInstance

Inherits:
InstanceResource show all
Defined in:
lib/twilio-ruby/rest/accounts/v1/bulk_consents.rb

Instance Method Summary collapse

Constructor Details

#initialize(version, payload) ⇒ BulkConsentsInstance

Initialize the BulkConsentsInstance

Parameters:

  • version (Version)

    Version that contains the resource

  • payload (Hash)

    payload that contains response from Twilio

  • account_sid (String)

    The SID of the Account that created this BulkConsents resource.

  • sid (String)

    The SID of the Call resource to fetch.



105
106
107
108
109
110
111
112
# File 'lib/twilio-ruby/rest/accounts/v1/bulk_consents.rb', line 105

def initialize(version, payload )
    super(version)
    
    # Marshaled Properties
    @properties = { 
        'items' => payload['items'],
    }
end

Instance Method Details

#inspectObject

Provide a detailed, user friendly representation



129
130
131
# File 'lib/twilio-ruby/rest/accounts/v1/bulk_consents.rb', line 129

def inspect
    "<Twilio.Accounts.V1.BulkConsentsInstance>"
end

#itemsHash

Returns A list of objects where each object represents the result of processing a ‘correlation_id`. Each object contains the following fields: `correlation_id`, a unique 32-character UUID that maps the response to the original request; `error_code`, an integer where 0 indicates success and any non-zero value represents an error; and `error_messages`, an array of strings describing specific validation errors encountered. If the request is successful, the error_messages array will be empty.

Returns:

  • (Hash)

    A list of objects where each object represents the result of processing a ‘correlation_id`. Each object contains the following fields: `correlation_id`, a unique 32-character UUID that maps the response to the original request; `error_code`, an integer where 0 indicates success and any non-zero value represents an error; and `error_messages`, an array of strings describing specific validation errors encountered. If the request is successful, the error_messages array will be empty.



117
118
119
# File 'lib/twilio-ruby/rest/accounts/v1/bulk_consents.rb', line 117

def items
    @properties['items']
end

#to_sObject

Provide a user friendly representation



123
124
125
# File 'lib/twilio-ruby/rest/accounts/v1/bulk_consents.rb', line 123

def to_s
    "<Twilio.Accounts.V1.BulkConsentsInstance>"
end