twilio-ruby 7.11.1 → 7.11.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGES.md +221 -0
- data/Gemfile.lock +2 -2
- data/README.md +2 -2
- data/lib/rack/twilio_webhook_authentication.rb +45 -2
- data/lib/twilio-ruby/rest/accounts/v1/auth_token_promotion.rb +0 -59
- data/lib/twilio-ruby/rest/accounts/v1/bulk_consents.rb +0 -59
- data/lib/twilio-ruby/rest/accounts/v1/bulk_contacts.rb +0 -59
- data/lib/twilio-ruby/rest/accounts/v1/credential.rb +0 -59
- data/lib/twilio-ruby/rest/accounts/v1/messaging_geopermissions.rb +0 -59
- data/lib/twilio-ruby/rest/accounts/v1/safelist.rb +0 -59
- data/lib/twilio-ruby/rest/accounts/v1/secondary_auth_token.rb +0 -59
- data/lib/twilio-ruby/rest/api/v2010/account/balance.rb +0 -59
- data/lib/twilio-ruby/rest/api/v2010/account/call/payment.rb +0 -59
- data/lib/twilio-ruby/rest/api/v2010/account/call/siprec.rb +0 -59
- data/lib/twilio-ruby/rest/api/v2010/account/call/stream.rb +0 -59
- data/lib/twilio-ruby/rest/api/v2010/account/call/transcription.rb +0 -59
- data/lib/twilio-ruby/rest/api/v2010/account/call/user_defined_message.rb +0 -59
- data/lib/twilio-ruby/rest/api/v2010/account/call/user_defined_message_subscription.rb +0 -59
- data/lib/twilio-ruby/rest/api/v2010/account/message/feedback.rb +0 -59
- data/lib/twilio-ruby/rest/api/v2010/account/message.rb +6 -0
- data/lib/twilio-ruby/rest/api/v2010/account/new_key.rb +0 -59
- data/lib/twilio-ruby/rest/api/v2010/account/new_signing_key.rb +0 -59
- data/lib/twilio-ruby/rest/api/v2010/account/recording/add_on_result/payload/data.rb +0 -59
- data/lib/twilio-ruby/rest/api/v2010/account/sip/domain/auth_types/auth_type_calls.rb +0 -59
- data/lib/twilio-ruby/rest/api/v2010/account/sip/domain/auth_types/auth_type_registrations.rb +0 -59
- data/lib/twilio-ruby/rest/api/v2010/account/sip/domain/auth_types.rb +0 -59
- data/lib/twilio-ruby/rest/api/v2010/account/sip.rb +0 -59
- data/lib/twilio-ruby/rest/api/v2010/account/token.rb +0 -59
- data/lib/twilio-ruby/rest/api/v2010/account/usage.rb +0 -59
- data/lib/twilio-ruby/rest/api/v2010/account/validation_request.rb +0 -59
- data/lib/twilio-ruby/rest/bulkexports/v1/export/job.rb +0 -59
- data/lib/twilio-ruby/rest/bulkexports/v1/export.rb +0 -59
- data/lib/twilio-ruby/rest/bulkexports/v1/export_configuration.rb +0 -59
- data/lib/twilio-ruby/rest/chat/v3/channel.rb +0 -59
- data/lib/twilio-ruby/rest/content/v1/content/approval_create.rb +0 -59
- data/lib/twilio-ruby/rest/content/v1/content/approval_fetch.rb +0 -59
- data/lib/twilio-ruby/rest/conversations/v1/configuration/webhook.rb +0 -59
- data/lib/twilio-ruby/rest/conversations/v1/configuration.rb +0 -59
- data/lib/twilio-ruby/rest/conversations/v1/conversation_with_participants.rb +0 -59
- data/lib/twilio-ruby/rest/conversations/v1/service/configuration/notification.rb +0 -59
- data/lib/twilio-ruby/rest/conversations/v1/service/configuration/webhook.rb +0 -59
- data/lib/twilio-ruby/rest/conversations/v1/service/configuration.rb +0 -59
- data/lib/twilio-ruby/rest/conversations/v1/service/conversation_with_participants.rb +0 -59
- data/lib/twilio-ruby/rest/conversations/v2/action.rb +0 -59
- data/lib/twilio-ruby/rest/conversations/v2/configuration.rb +525 -0
- data/lib/twilio-ruby/rest/conversations/v2/operation.rb +0 -59
- data/lib/twilio-ruby/rest/conversations/v2.rb +10 -4
- data/lib/twilio-ruby/rest/events/v1/schema.rb +0 -59
- data/lib/twilio-ruby/rest/events/v1/sink/sink_test.rb +0 -59
- data/lib/twilio-ruby/rest/events/v1/sink/sink_validate.rb +0 -59
- data/lib/twilio-ruby/rest/flex_api/v1/assessments.rb +12 -14
- data/lib/twilio-ruby/rest/flex_api/v1/configuration.rb +0 -59
- data/lib/twilio-ruby/rest/flex_api/v1/insights_assessments_comment.rb +12 -14
- data/lib/twilio-ruby/rest/flex_api/v1/insights_conversations.rb +12 -14
- data/lib/twilio-ruby/rest/flex_api/v1/insights_questionnaires.rb +12 -14
- data/lib/twilio-ruby/rest/flex_api/v1/insights_questionnaires_category.rb +2 -4
- data/lib/twilio-ruby/rest/flex_api/v1/insights_questionnaires_question.rb +12 -14
- data/lib/twilio-ruby/rest/flex_api/v1/insights_segments.rb +12 -14
- data/lib/twilio-ruby/rest/flex_api/v1/insights_session.rb +0 -59
- data/lib/twilio-ruby/rest/flex_api/v1/insights_settings_answer_sets.rb +0 -59
- data/lib/twilio-ruby/rest/flex_api/v1/insights_settings_comment.rb +0 -59
- data/lib/twilio-ruby/rest/flex_api/v1/insights_user_roles.rb +0 -59
- data/lib/twilio-ruby/rest/flex_api/v1/interaction/interaction_channel/interaction_transfer.rb +0 -59
- data/lib/twilio-ruby/rest/flex_api/v1/interaction.rb +0 -59
- data/lib/twilio-ruby/rest/flex_api/v1/plugin/plugin_versions.rb +2 -4
- data/lib/twilio-ruby/rest/flex_api/v1/plugin.rb +2 -4
- data/lib/twilio-ruby/rest/flex_api/v1/plugin_archive.rb +0 -59
- data/lib/twilio-ruby/rest/flex_api/v1/plugin_configuration/configured_plugin.rb +2 -4
- data/lib/twilio-ruby/rest/flex_api/v1/plugin_configuration.rb +2 -4
- data/lib/twilio-ruby/rest/flex_api/v1/plugin_configuration_archive.rb +0 -59
- data/lib/twilio-ruby/rest/flex_api/v1/plugin_release.rb +2 -4
- data/lib/twilio-ruby/rest/flex_api/v1/plugin_version_archive.rb +0 -59
- data/lib/twilio-ruby/rest/flex_api/v1/provisioning_status.rb +0 -59
- data/lib/twilio-ruby/rest/flex_api/v2/flex_user.rb +0 -59
- data/lib/twilio-ruby/rest/flex_api/v2/web_channels.rb +0 -59
- data/lib/twilio-ruby/rest/frontline_api/v1/user.rb +0 -59
- data/lib/twilio-ruby/rest/iam/v1/api_key.rb +0 -59
- data/lib/twilio-ruby/rest/iam/v1/new_api_key.rb +0 -59
- data/lib/twilio-ruby/rest/iam/v1/o_auth_app.rb +0 -59
- data/lib/twilio-ruby/rest/iam/v1/token.rb +0 -59
- data/lib/twilio-ruby/rest/insights/v1/call/annotation.rb +0 -59
- data/lib/twilio-ruby/rest/insights/v1/call/call_summary.rb +0 -59
- data/lib/twilio-ruby/rest/insights/v1/call.rb +0 -59
- data/lib/twilio-ruby/rest/insights/v1/setting.rb +0 -59
- data/lib/twilio-ruby/rest/insights/v2/inbound.rb +2 -261
- data/lib/twilio-ruby/rest/insights/v2/inbound_report.rb +258 -0
- data/lib/twilio-ruby/rest/insights/v2/outbound.rb +18 -299
- data/lib/twilio-ruby/rest/insights/v2/outbound_report.rb +258 -0
- data/lib/twilio-ruby/rest/insights/v2/report.rb +27 -184
- data/lib/twilio-ruby/rest/insights/v2.rb +14 -4
- data/lib/twilio-ruby/rest/insights/v3/metadata.rb +1 -60
- data/lib/twilio-ruby/rest/insights/v3/query.rb +1 -60
- data/lib/twilio-ruby/rest/insights/v3/query_job.rb +654 -0
- data/lib/twilio-ruby/rest/insights/v3/result.rb +195 -0
- data/lib/twilio-ruby/rest/insights/v3.rb +17 -1
- data/lib/twilio-ruby/rest/intelligence/v2/operator_attachment.rb +0 -59
- data/lib/twilio-ruby/rest/intelligence/v2/operator_attachments.rb +0 -59
- data/lib/twilio-ruby/rest/intelligence/v2/transcript/encrypted_operator_results.rb +0 -59
- data/lib/twilio-ruby/rest/intelligence/v2/transcript/encrypted_sentences.rb +0 -59
- data/lib/twilio-ruby/rest/intelligence/v2/transcript/media.rb +0 -59
- data/lib/twilio-ruby/rest/intelligence/v3/rule_execution.rb +0 -59
- data/lib/twilio-ruby/rest/knowledge/v1/knowledge/knowledge_status.rb +0 -59
- data/lib/twilio-ruby/rest/knowledge/v2/operation.rb +0 -59
- data/lib/twilio-ruby/rest/knowledge/v2/search.rb +0 -59
- data/lib/twilio-ruby/rest/lookups/v1/phone_number.rb +0 -59
- data/lib/twilio-ruby/rest/lookups/v2/bucket.rb +0 -59
- data/lib/twilio-ruby/rest/lookups/v2/lookup_override.rb +0 -59
- data/lib/twilio-ruby/rest/lookups/v2/phone_number.rb +0 -59
- data/lib/twilio-ruby/rest/lookups/v2/query.rb +0 -59
- data/lib/twilio-ruby/rest/lookups/v2/rate_limit.rb +0 -59
- data/lib/twilio-ruby/rest/marketplace/v1/installed_add_on/installed_add_on_usage.rb +0 -59
- data/lib/twilio-ruby/rest/marketplace/v1/module_data.rb +0 -59
- data/lib/twilio-ruby/rest/marketplace/v1/module_data_management.rb +0 -59
- data/lib/twilio-ruby/rest/marketplace/v1/referral_conversion.rb +0 -59
- data/lib/twilio-ruby/rest/memory/v1/bulk.rb +0 -59
- data/lib/twilio-ruby/rest/memory/v1/conversation_summary.rb +2 -4
- data/lib/twilio-ruby/rest/memory/v1/identifier.rb +0 -80
- data/lib/twilio-ruby/rest/memory/v1/identity_resolution_setting.rb +0 -59
- data/lib/twilio-ruby/rest/memory/v1/lookup.rb +0 -59
- data/lib/twilio-ruby/rest/memory/v1/observation.rb +2 -4
- data/lib/twilio-ruby/rest/memory/v1/operation.rb +0 -59
- data/lib/twilio-ruby/rest/memory/v1/recall.rb +0 -59
- data/lib/twilio-ruby/rest/memory/v1/revision.rb +2 -4
- data/lib/twilio-ruby/rest/messaging/v1/brand_registration/brand_registration_otp.rb +0 -59
- data/lib/twilio-ruby/rest/messaging/v1/deactivations.rb +0 -59
- data/lib/twilio-ruby/rest/messaging/v1/domain_certs.rb +0 -59
- data/lib/twilio-ruby/rest/messaging/v1/domain_config.rb +0 -59
- data/lib/twilio-ruby/rest/messaging/v1/domain_config_messaging_service.rb +0 -59
- data/lib/twilio-ruby/rest/messaging/v1/domain_validate_dn.rb +0 -59
- data/lib/twilio-ruby/rest/messaging/v1/external_campaign.rb +0 -59
- data/lib/twilio-ruby/rest/messaging/v1/linkshortening_messaging_service.rb +0 -59
- data/lib/twilio-ruby/rest/messaging/v1/linkshortening_messaging_service_domain_association.rb +0 -59
- data/lib/twilio-ruby/rest/messaging/v1/request_managed_cert.rb +0 -59
- data/lib/twilio-ruby/rest/messaging/v1/service/us_app_to_person.rb +2 -4
- data/lib/twilio-ruby/rest/messaging/v1/service/us_app_to_person_usecase.rb +0 -59
- data/lib/twilio-ruby/rest/messaging/v1/usecase.rb +0 -59
- data/lib/twilio-ruby/rest/messaging/v2/domain_certs.rb +0 -59
- data/lib/twilio-ruby/rest/messaging/v2/typing_indicator.rb +0 -59
- data/lib/twilio-ruby/rest/messaging/v3/typing_indicator.rb +0 -59
- data/lib/twilio-ruby/rest/notify/v1/service/notification.rb +0 -59
- data/lib/twilio-ruby/rest/numbers/v1/bulk_eligibility.rb +0 -59
- data/lib/twilio-ruby/rest/numbers/v1/eligibility.rb +0 -59
- data/lib/twilio-ruby/rest/numbers/v1/embedded_session.rb +0 -59
- data/lib/twilio-ruby/rest/numbers/v1/porting_port_in.rb +0 -59
- data/lib/twilio-ruby/rest/numbers/v1/porting_port_in_phone_number.rb +0 -59
- data/lib/twilio-ruby/rest/numbers/v1/porting_portability.rb +0 -59
- data/lib/twilio-ruby/rest/numbers/v1/porting_webhook_configuration.rb +0 -59
- data/lib/twilio-ruby/rest/numbers/v1/porting_webhook_configuration_delete.rb +0 -59
- data/lib/twilio-ruby/rest/numbers/v1/sender_id_registration.rb +0 -59
- data/lib/twilio-ruby/rest/numbers/v1/sms_verification.rb +0 -59
- data/lib/twilio-ruby/rest/numbers/v1/sms_verification_check.rb +0 -59
- data/lib/twilio-ruby/rest/numbers/v1/voice_verification.rb +0 -59
- data/lib/twilio-ruby/rest/numbers/v1/voice_verification_check.rb +0 -59
- data/lib/twilio-ruby/rest/numbers/v1/webhook.rb +0 -59
- data/lib/twilio-ruby/rest/numbers/v2/bulk_hosted_number_order.rb +0 -59
- data/lib/twilio-ruby/rest/numbers/v2/bundle_clone.rb +0 -59
- data/lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle/replace_items.rb +0 -59
- data/lib/twilio-ruby/rest/numbers/v2/regulatory_compliance.rb +0 -59
- data/lib/twilio-ruby/rest/numbers/v2.rb +0 -16
- data/lib/twilio-ruby/rest/numbers/v3/hosted_number_order.rb +0 -59
- data/lib/twilio-ruby/rest/oauth/v1/authorize.rb +0 -59
- data/lib/twilio-ruby/rest/oauth/v1/token.rb +0 -59
- data/lib/twilio-ruby/rest/oauth/v2/authorize.rb +0 -59
- data/lib/twilio-ruby/rest/oauth/v2/oauth_authorization_server.rb +0 -59
- data/lib/twilio-ruby/rest/oauth/v2/token.rb +2 -61
- data/lib/twilio-ruby/rest/preview/wireless/sim/usage.rb +0 -59
- data/lib/twilio-ruby/rest/preview_iam/v1/authorize.rb +0 -59
- data/lib/twilio-ruby/rest/preview_iam/v1/token.rb +0 -59
- data/lib/twilio-ruby/rest/preview_iam/versionless/organization.rb +0 -59
- data/lib/twilio-ruby/rest/pricing/v1/messaging.rb +0 -59
- data/lib/twilio-ruby/rest/pricing/v1/phone_number.rb +0 -59
- data/lib/twilio-ruby/rest/pricing/v1/voice/number.rb +0 -59
- data/lib/twilio-ruby/rest/pricing/v1/voice.rb +0 -59
- data/lib/twilio-ruby/rest/pricing/v2/number.rb +0 -59
- data/lib/twilio-ruby/rest/pricing/v2/voice/number.rb +0 -59
- data/lib/twilio-ruby/rest/pricing/v2/voice.rb +0 -59
- data/lib/twilio-ruby/rest/routes/v2/phone_number.rb +0 -59
- data/lib/twilio-ruby/rest/routes/v2/sip_domain.rb +0 -59
- data/lib/twilio-ruby/rest/routes/v2/trunk.rb +0 -59
- data/lib/twilio-ruby/rest/routes/v3/phone_number.rb +0 -59
- data/lib/twilio-ruby/rest/serverless/v1/service/build/build_status.rb +0 -59
- data/lib/twilio-ruby/rest/serverless/v1/service/function/function_version/function_version_content.rb +0 -59
- data/lib/twilio-ruby/rest/studio/v1/flow/engagement/engagement_context.rb +0 -59
- data/lib/twilio-ruby/rest/studio/v1/flow/engagement/step/step_context.rb +0 -59
- data/lib/twilio-ruby/rest/studio/v1/flow/execution/execution_context.rb +0 -59
- data/lib/twilio-ruby/rest/studio/v1/flow/execution/execution_step/execution_step_context.rb +0 -59
- data/lib/twilio-ruby/rest/studio/v2/flow/execution/execution_context.rb +0 -59
- data/lib/twilio-ruby/rest/studio/v2/flow/execution/execution_step/execution_step_context.rb +0 -59
- data/lib/twilio-ruby/rest/studio/v2/flow/flow_test_user.rb +0 -59
- data/lib/twilio-ruby/rest/studio/v2/flow_validate.rb +0 -59
- data/lib/twilio-ruby/rest/sync/v1/service/sync_stream/stream_message.rb +0 -59
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue/task_queue_bulk_real_time_statistics.rb +0 -59
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue/task_queue_cumulative_statistics.rb +0 -59
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue/task_queue_real_time_statistics.rb +0 -59
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue/task_queue_statistics.rb +0 -59
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker/worker_statistics.rb +0 -59
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker/workers_cumulative_statistics.rb +0 -59
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker/workers_real_time_statistics.rb +0 -59
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker/workers_statistics.rb +0 -59
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workflow/workflow_cumulative_statistics.rb +0 -59
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workflow/workflow_real_time_statistics.rb +0 -59
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workflow/workflow_statistics.rb +0 -59
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workspace_cumulative_statistics.rb +0 -59
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workspace_real_time_statistics.rb +0 -59
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workspace_statistics.rb +0 -59
- data/lib/twilio-ruby/rest/trunking/v1/trunk/recording.rb +0 -59
- data/lib/twilio-ruby/rest/trusthub/v1/a2p_brand_registration.rb +0 -59
- data/lib/twilio-ruby/rest/trusthub/v1/a2p_brand_registration_embedded_session.rb +0 -59
- data/lib/twilio-ruby/rest/trusthub/v1/a2p_campaign_registration.rb +0 -59
- data/lib/twilio-ruby/rest/trusthub/v1/a2p_campaign_registration_embedded_session.rb +0 -59
- data/lib/twilio-ruby/rest/trusthub/v1/compliance_inquiries.rb +0 -59
- data/lib/twilio-ruby/rest/trusthub/v1/compliance_registration_inquiries.rb +0 -59
- data/lib/twilio-ruby/rest/trusthub/v1/compliance_tollfree_inquiries.rb +0 -59
- data/lib/twilio-ruby/rest/trusthub/v1/customer_profiles_provisional_copy.rb +0 -59
- data/lib/twilio-ruby/rest/trusthub/v1/trust_products_provisional_copy.rb +0 -59
- data/lib/twilio-ruby/rest/verify/v2/form.rb +0 -59
- data/lib/twilio-ruby/rest/verify/v2/safelist.rb +0 -59
- data/lib/twilio-ruby/rest/verify/v2/service/access_token.rb +0 -59
- data/lib/twilio-ruby/rest/verify/v2/service/approve_challenge.rb +0 -59
- data/lib/twilio-ruby/rest/verify/v2/service/entity/challenge/notification.rb +0 -59
- data/lib/twilio-ruby/rest/verify/v2/service/entity/new_factor.rb +0 -59
- data/lib/twilio-ruby/rest/verify/v2/service/new_challenge.rb +3 -62
- data/lib/twilio-ruby/rest/verify/v2/service/new_factor.rb +0 -59
- data/lib/twilio-ruby/rest/verify/v2/service/new_verify_factor.rb +0 -59
- data/lib/twilio-ruby/rest/verify/v2/service/verification.rb +8 -61
- data/lib/twilio-ruby/rest/verify/v2/service/verification_check.rb +0 -59
- data/lib/twilio-ruby/rest/verify/v2/verification_attempts_summary.rb +0 -59
- data/lib/twilio-ruby/rest/video/v1/composition_settings.rb +0 -59
- data/lib/twilio-ruby/rest/video/v1/recording_settings.rb +0 -59
- data/lib/twilio-ruby/rest/video/v1/room/participant/anonymize.rb +0 -59
- data/lib/twilio-ruby/rest/video/v1/room/participant/subscribe_rules.rb +0 -59
- data/lib/twilio-ruby/rest/video/v1/room/recording_rules.rb +0 -59
- data/lib/twilio-ruby/rest/voice/v1/archived_call.rb +0 -59
- data/lib/twilio-ruby/rest/voice/v1/dialing_permissions/bulk_country_update.rb +0 -59
- data/lib/twilio-ruby/rest/voice/v1/dialing_permissions/settings.rb +0 -59
- data/lib/twilio-ruby/rest/voice/v1/dialing_permissions.rb +0 -59
- data/lib/twilio-ruby/rest/voice/v2/account_default_configuration.rb +0 -59
- data/lib/twilio-ruby/rest/voice/v2/configuration/default.rb +0 -59
- data/lib/twilio-ruby/rest/voice/v2/configuration.rb +0 -59
- data/lib/twilio-ruby/rest/voice/v2/recording.rb +0 -59
- data/lib/twilio-ruby/rest/voice/v2/transcription.rb +0 -59
- data/lib/twilio-ruby/rest/voice/v2/type.rb +0 -59
- data/lib/twilio-ruby/rest/voice/v3/transcription.rb +259 -50
- data/lib/twilio-ruby/version.rb +1 -1
- metadata +6 -4
- data/lib/twilio-ruby/rest/memory/v1/event.rb +0 -320
- data/lib/twilio-ruby/rest/numbers/v2/caller_id.rb +0 -515
|
@@ -194,65 +194,6 @@ module Twilio
|
|
|
194
194
|
end
|
|
195
195
|
end
|
|
196
196
|
|
|
197
|
-
class RequestManagedCertPageMetadata < PageMetadata
|
|
198
|
-
attr_reader :request_managed_cert_page
|
|
199
|
-
|
|
200
|
-
def initialize(version, response, solution, limit)
|
|
201
|
-
super(version, response)
|
|
202
|
-
@request_managed_cert_page = []
|
|
203
|
-
@limit = limit
|
|
204
|
-
key = get_key(response.body)
|
|
205
|
-
records = 0
|
|
206
|
-
while( limit != :unset && records < limit )
|
|
207
|
-
@request_managed_cert_page << RequestManagedCertListResponse.new(version, @payload, key, limit - records)
|
|
208
|
-
@payload = self.next_page
|
|
209
|
-
break unless @payload
|
|
210
|
-
records += (@payload.body[key] || []).size
|
|
211
|
-
end
|
|
212
|
-
# Path Solution
|
|
213
|
-
@solution = solution
|
|
214
|
-
end
|
|
215
|
-
|
|
216
|
-
def each
|
|
217
|
-
@request_managed_cert_page.each do |record|
|
|
218
|
-
yield record
|
|
219
|
-
end
|
|
220
|
-
end
|
|
221
|
-
|
|
222
|
-
def to_s
|
|
223
|
-
'<Twilio::REST::Messaging::V1PageMetadata>';
|
|
224
|
-
end
|
|
225
|
-
end
|
|
226
|
-
class RequestManagedCertListResponse < InstanceListResource
|
|
227
|
-
|
|
228
|
-
# @param [Array<RequestManagedCertInstance>] instance
|
|
229
|
-
# @param [Hash{String => Object}] headers
|
|
230
|
-
# @param [Integer] status_code
|
|
231
|
-
def initialize(version, payload, key, limit = :unset)
|
|
232
|
-
data_list = payload.body[key] || []
|
|
233
|
-
if limit != :unset
|
|
234
|
-
data_list = data_list[0, limit]
|
|
235
|
-
end
|
|
236
|
-
@request_managed_cert = data_list.map do |data|
|
|
237
|
-
RequestManagedCertInstance.new(version, data)
|
|
238
|
-
end
|
|
239
|
-
@headers = payload.headers
|
|
240
|
-
@status_code = payload.status_code
|
|
241
|
-
end
|
|
242
|
-
|
|
243
|
-
def request_managed_cert
|
|
244
|
-
@request_managed_cert
|
|
245
|
-
end
|
|
246
|
-
|
|
247
|
-
def headers
|
|
248
|
-
@headers
|
|
249
|
-
end
|
|
250
|
-
|
|
251
|
-
def status_code
|
|
252
|
-
@status_code
|
|
253
|
-
end
|
|
254
|
-
end
|
|
255
|
-
|
|
256
197
|
class RequestManagedCertInstance < InstanceResource
|
|
257
198
|
##
|
|
258
199
|
# Initialize the RequestManagedCertInstance
|
|
@@ -257,11 +257,10 @@ module Twilio
|
|
|
257
257
|
def list_with_metadata(x_twilio_api_version: :unset, limit: nil, page_size: nil)
|
|
258
258
|
limits = @version.read_limits(limit, page_size)
|
|
259
259
|
params = Twilio::Values.of({
|
|
260
|
-
'X-Twilio-Api-Version' => x_twilio_api_version,
|
|
261
260
|
|
|
262
261
|
'PageSize' => limits[:page_size],
|
|
263
262
|
});
|
|
264
|
-
headers = Twilio::Values.of({})
|
|
263
|
+
headers = Twilio::Values.of({ 'X-Twilio-Api-Version' => x_twilio_api_version, })
|
|
265
264
|
|
|
266
265
|
response = @version.page('GET', @uri, params: params, headers: headers)
|
|
267
266
|
|
|
@@ -296,12 +295,11 @@ module Twilio
|
|
|
296
295
|
# @return [Page] Page of UsAppToPersonInstance
|
|
297
296
|
def page(x_twilio_api_version: :unset, page_token: :unset, page_number: :unset,page_size: :unset)
|
|
298
297
|
params = Twilio::Values.of({
|
|
299
|
-
'X-Twilio-Api-Version' => x_twilio_api_version,
|
|
300
298
|
'PageToken' => page_token,
|
|
301
299
|
'Page' => page_number,
|
|
302
300
|
'PageSize' => page_size,
|
|
303
301
|
})
|
|
304
|
-
headers = Twilio::Values.of({})
|
|
302
|
+
headers = Twilio::Values.of({ 'X-Twilio-Api-Version' => x_twilio_api_version, })
|
|
305
303
|
|
|
306
304
|
|
|
307
305
|
|
|
@@ -128,65 +128,6 @@ module Twilio
|
|
|
128
128
|
end
|
|
129
129
|
end
|
|
130
130
|
|
|
131
|
-
class UsAppToPersonUsecasePageMetadata < PageMetadata
|
|
132
|
-
attr_reader :us_app_to_person_usecase_page
|
|
133
|
-
|
|
134
|
-
def initialize(version, response, solution, limit)
|
|
135
|
-
super(version, response)
|
|
136
|
-
@us_app_to_person_usecase_page = []
|
|
137
|
-
@limit = limit
|
|
138
|
-
key = get_key(response.body)
|
|
139
|
-
records = 0
|
|
140
|
-
while( limit != :unset && records < limit )
|
|
141
|
-
@us_app_to_person_usecase_page << UsAppToPersonUsecaseListResponse.new(version, @payload, key, limit - records)
|
|
142
|
-
@payload = self.next_page
|
|
143
|
-
break unless @payload
|
|
144
|
-
records += (@payload.body[key] || []).size
|
|
145
|
-
end
|
|
146
|
-
# Path Solution
|
|
147
|
-
@solution = solution
|
|
148
|
-
end
|
|
149
|
-
|
|
150
|
-
def each
|
|
151
|
-
@us_app_to_person_usecase_page.each do |record|
|
|
152
|
-
yield record
|
|
153
|
-
end
|
|
154
|
-
end
|
|
155
|
-
|
|
156
|
-
def to_s
|
|
157
|
-
'<Twilio::REST::Messaging::V1PageMetadata>';
|
|
158
|
-
end
|
|
159
|
-
end
|
|
160
|
-
class UsAppToPersonUsecaseListResponse < InstanceListResource
|
|
161
|
-
|
|
162
|
-
# @param [Array<UsAppToPersonUsecaseInstance>] instance
|
|
163
|
-
# @param [Hash{String => Object}] headers
|
|
164
|
-
# @param [Integer] status_code
|
|
165
|
-
def initialize(version, payload, key, limit = :unset)
|
|
166
|
-
data_list = payload.body[key] || []
|
|
167
|
-
if limit != :unset
|
|
168
|
-
data_list = data_list[0, limit]
|
|
169
|
-
end
|
|
170
|
-
@us_app_to_person_usecase = data_list.map do |data|
|
|
171
|
-
UsAppToPersonUsecaseInstance.new(version, data)
|
|
172
|
-
end
|
|
173
|
-
@headers = payload.headers
|
|
174
|
-
@status_code = payload.status_code
|
|
175
|
-
end
|
|
176
|
-
|
|
177
|
-
def us_app_to_person_usecase
|
|
178
|
-
@us_app_to_person_usecase
|
|
179
|
-
end
|
|
180
|
-
|
|
181
|
-
def headers
|
|
182
|
-
@headers
|
|
183
|
-
end
|
|
184
|
-
|
|
185
|
-
def status_code
|
|
186
|
-
@status_code
|
|
187
|
-
end
|
|
188
|
-
end
|
|
189
|
-
|
|
190
131
|
class UsAppToPersonUsecaseInstance < InstanceResource
|
|
191
132
|
##
|
|
192
133
|
# Initialize the UsAppToPersonUsecaseInstance
|
|
@@ -112,65 +112,6 @@ module Twilio
|
|
|
112
112
|
end
|
|
113
113
|
end
|
|
114
114
|
|
|
115
|
-
class UsecasePageMetadata < PageMetadata
|
|
116
|
-
attr_reader :usecase_page
|
|
117
|
-
|
|
118
|
-
def initialize(version, response, solution, limit)
|
|
119
|
-
super(version, response)
|
|
120
|
-
@usecase_page = []
|
|
121
|
-
@limit = limit
|
|
122
|
-
key = get_key(response.body)
|
|
123
|
-
records = 0
|
|
124
|
-
while( limit != :unset && records < limit )
|
|
125
|
-
@usecase_page << UsecaseListResponse.new(version, @payload, key, limit - records)
|
|
126
|
-
@payload = self.next_page
|
|
127
|
-
break unless @payload
|
|
128
|
-
records += (@payload.body[key] || []).size
|
|
129
|
-
end
|
|
130
|
-
# Path Solution
|
|
131
|
-
@solution = solution
|
|
132
|
-
end
|
|
133
|
-
|
|
134
|
-
def each
|
|
135
|
-
@usecase_page.each do |record|
|
|
136
|
-
yield record
|
|
137
|
-
end
|
|
138
|
-
end
|
|
139
|
-
|
|
140
|
-
def to_s
|
|
141
|
-
'<Twilio::REST::Messaging::V1PageMetadata>';
|
|
142
|
-
end
|
|
143
|
-
end
|
|
144
|
-
class UsecaseListResponse < InstanceListResource
|
|
145
|
-
|
|
146
|
-
# @param [Array<UsecaseInstance>] instance
|
|
147
|
-
# @param [Hash{String => Object}] headers
|
|
148
|
-
# @param [Integer] status_code
|
|
149
|
-
def initialize(version, payload, key, limit = :unset)
|
|
150
|
-
data_list = payload.body[key] || []
|
|
151
|
-
if limit != :unset
|
|
152
|
-
data_list = data_list[0, limit]
|
|
153
|
-
end
|
|
154
|
-
@usecase = data_list.map do |data|
|
|
155
|
-
UsecaseInstance.new(version, data)
|
|
156
|
-
end
|
|
157
|
-
@headers = payload.headers
|
|
158
|
-
@status_code = payload.status_code
|
|
159
|
-
end
|
|
160
|
-
|
|
161
|
-
def usecase
|
|
162
|
-
@usecase
|
|
163
|
-
end
|
|
164
|
-
|
|
165
|
-
def headers
|
|
166
|
-
@headers
|
|
167
|
-
end
|
|
168
|
-
|
|
169
|
-
def status_code
|
|
170
|
-
@status_code
|
|
171
|
-
end
|
|
172
|
-
end
|
|
173
|
-
|
|
174
115
|
class UsecaseInstance < InstanceResource
|
|
175
116
|
##
|
|
176
117
|
# Initialize the UsecaseInstance
|
|
@@ -194,65 +194,6 @@ module Twilio
|
|
|
194
194
|
end
|
|
195
195
|
end
|
|
196
196
|
|
|
197
|
-
class DomainCertsPageMetadata < PageMetadata
|
|
198
|
-
attr_reader :domain_certs_page
|
|
199
|
-
|
|
200
|
-
def initialize(version, response, solution, limit)
|
|
201
|
-
super(version, response)
|
|
202
|
-
@domain_certs_page = []
|
|
203
|
-
@limit = limit
|
|
204
|
-
key = get_key(response.body)
|
|
205
|
-
records = 0
|
|
206
|
-
while( limit != :unset && records < limit )
|
|
207
|
-
@domain_certs_page << DomainCertsListResponse.new(version, @payload, key, limit - records)
|
|
208
|
-
@payload = self.next_page
|
|
209
|
-
break unless @payload
|
|
210
|
-
records += (@payload.body[key] || []).size
|
|
211
|
-
end
|
|
212
|
-
# Path Solution
|
|
213
|
-
@solution = solution
|
|
214
|
-
end
|
|
215
|
-
|
|
216
|
-
def each
|
|
217
|
-
@domain_certs_page.each do |record|
|
|
218
|
-
yield record
|
|
219
|
-
end
|
|
220
|
-
end
|
|
221
|
-
|
|
222
|
-
def to_s
|
|
223
|
-
'<Twilio::REST::Messaging::V2PageMetadata>';
|
|
224
|
-
end
|
|
225
|
-
end
|
|
226
|
-
class DomainCertsListResponse < InstanceListResource
|
|
227
|
-
|
|
228
|
-
# @param [Array<DomainCertsInstance>] instance
|
|
229
|
-
# @param [Hash{String => Object}] headers
|
|
230
|
-
# @param [Integer] status_code
|
|
231
|
-
def initialize(version, payload, key, limit = :unset)
|
|
232
|
-
data_list = payload.body[key] || []
|
|
233
|
-
if limit != :unset
|
|
234
|
-
data_list = data_list[0, limit]
|
|
235
|
-
end
|
|
236
|
-
@domain_certs = data_list.map do |data|
|
|
237
|
-
DomainCertsInstance.new(version, data)
|
|
238
|
-
end
|
|
239
|
-
@headers = payload.headers
|
|
240
|
-
@status_code = payload.status_code
|
|
241
|
-
end
|
|
242
|
-
|
|
243
|
-
def domain_certs
|
|
244
|
-
@domain_certs
|
|
245
|
-
end
|
|
246
|
-
|
|
247
|
-
def headers
|
|
248
|
-
@headers
|
|
249
|
-
end
|
|
250
|
-
|
|
251
|
-
def status_code
|
|
252
|
-
@status_code
|
|
253
|
-
end
|
|
254
|
-
end
|
|
255
|
-
|
|
256
197
|
class DomainCertsInstance < InstanceResource
|
|
257
198
|
##
|
|
258
199
|
# Initialize the DomainCertsInstance
|
|
@@ -132,65 +132,6 @@ module Twilio
|
|
|
132
132
|
end
|
|
133
133
|
end
|
|
134
134
|
|
|
135
|
-
class TypingIndicatorPageMetadata < PageMetadata
|
|
136
|
-
attr_reader :typing_indicator_page
|
|
137
|
-
|
|
138
|
-
def initialize(version, response, solution, limit)
|
|
139
|
-
super(version, response)
|
|
140
|
-
@typing_indicator_page = []
|
|
141
|
-
@limit = limit
|
|
142
|
-
key = get_key(response.body)
|
|
143
|
-
records = 0
|
|
144
|
-
while( limit != :unset && records < limit )
|
|
145
|
-
@typing_indicator_page << TypingIndicatorListResponse.new(version, @payload, key, limit - records)
|
|
146
|
-
@payload = self.next_page
|
|
147
|
-
break unless @payload
|
|
148
|
-
records += (@payload.body[key] || []).size
|
|
149
|
-
end
|
|
150
|
-
# Path Solution
|
|
151
|
-
@solution = solution
|
|
152
|
-
end
|
|
153
|
-
|
|
154
|
-
def each
|
|
155
|
-
@typing_indicator_page.each do |record|
|
|
156
|
-
yield record
|
|
157
|
-
end
|
|
158
|
-
end
|
|
159
|
-
|
|
160
|
-
def to_s
|
|
161
|
-
'<Twilio::REST::Messaging::V2PageMetadata>';
|
|
162
|
-
end
|
|
163
|
-
end
|
|
164
|
-
class TypingIndicatorListResponse < InstanceListResource
|
|
165
|
-
|
|
166
|
-
# @param [Array<TypingIndicatorInstance>] instance
|
|
167
|
-
# @param [Hash{String => Object}] headers
|
|
168
|
-
# @param [Integer] status_code
|
|
169
|
-
def initialize(version, payload, key, limit = :unset)
|
|
170
|
-
data_list = payload.body[key] || []
|
|
171
|
-
if limit != :unset
|
|
172
|
-
data_list = data_list[0, limit]
|
|
173
|
-
end
|
|
174
|
-
@typing_indicator = data_list.map do |data|
|
|
175
|
-
TypingIndicatorInstance.new(version, data)
|
|
176
|
-
end
|
|
177
|
-
@headers = payload.headers
|
|
178
|
-
@status_code = payload.status_code
|
|
179
|
-
end
|
|
180
|
-
|
|
181
|
-
def typing_indicator
|
|
182
|
-
@typing_indicator
|
|
183
|
-
end
|
|
184
|
-
|
|
185
|
-
def headers
|
|
186
|
-
@headers
|
|
187
|
-
end
|
|
188
|
-
|
|
189
|
-
def status_code
|
|
190
|
-
@status_code
|
|
191
|
-
end
|
|
192
|
-
end
|
|
193
|
-
|
|
194
135
|
class TypingIndicatorInstance < InstanceResource
|
|
195
136
|
##
|
|
196
137
|
# Initialize the TypingIndicatorInstance
|
|
@@ -142,65 +142,6 @@ module Twilio
|
|
|
142
142
|
end
|
|
143
143
|
end
|
|
144
144
|
|
|
145
|
-
class TypingIndicatorPageMetadata < PageMetadata
|
|
146
|
-
attr_reader :typing_indicator_page
|
|
147
|
-
|
|
148
|
-
def initialize(version, response, solution, limit)
|
|
149
|
-
super(version, response)
|
|
150
|
-
@typing_indicator_page = []
|
|
151
|
-
@limit = limit
|
|
152
|
-
key = get_key(response.body)
|
|
153
|
-
records = 0
|
|
154
|
-
while( limit != :unset && records < limit )
|
|
155
|
-
@typing_indicator_page << TypingIndicatorListResponse.new(version, @payload, key, limit - records)
|
|
156
|
-
@payload = self.next_page
|
|
157
|
-
break unless @payload
|
|
158
|
-
records += (@payload.body[key] || []).size
|
|
159
|
-
end
|
|
160
|
-
# Path Solution
|
|
161
|
-
@solution = solution
|
|
162
|
-
end
|
|
163
|
-
|
|
164
|
-
def each
|
|
165
|
-
@typing_indicator_page.each do |record|
|
|
166
|
-
yield record
|
|
167
|
-
end
|
|
168
|
-
end
|
|
169
|
-
|
|
170
|
-
def to_s
|
|
171
|
-
'<Twilio::REST::Messaging::V3PageMetadata>';
|
|
172
|
-
end
|
|
173
|
-
end
|
|
174
|
-
class TypingIndicatorListResponse < InstanceListResource
|
|
175
|
-
|
|
176
|
-
# @param [Array<TypingIndicatorInstance>] instance
|
|
177
|
-
# @param [Hash{String => Object}] headers
|
|
178
|
-
# @param [Integer] status_code
|
|
179
|
-
def initialize(version, payload, key, limit = :unset)
|
|
180
|
-
data_list = payload.body[key] || []
|
|
181
|
-
if limit != :unset
|
|
182
|
-
data_list = data_list[0, limit]
|
|
183
|
-
end
|
|
184
|
-
@typing_indicator = data_list.map do |data|
|
|
185
|
-
TypingIndicatorInstance.new(version, data)
|
|
186
|
-
end
|
|
187
|
-
@headers = payload.headers
|
|
188
|
-
@status_code = payload.status_code
|
|
189
|
-
end
|
|
190
|
-
|
|
191
|
-
def typing_indicator
|
|
192
|
-
@typing_indicator
|
|
193
|
-
end
|
|
194
|
-
|
|
195
|
-
def headers
|
|
196
|
-
@headers
|
|
197
|
-
end
|
|
198
|
-
|
|
199
|
-
def status_code
|
|
200
|
-
@status_code
|
|
201
|
-
end
|
|
202
|
-
end
|
|
203
|
-
|
|
204
145
|
class TypingIndicatorInstance < InstanceResource
|
|
205
146
|
##
|
|
206
147
|
# Initialize the TypingIndicatorInstance
|
|
@@ -232,65 +232,6 @@ module Twilio
|
|
|
232
232
|
end
|
|
233
233
|
end
|
|
234
234
|
|
|
235
|
-
class NotificationPageMetadata < PageMetadata
|
|
236
|
-
attr_reader :notification_page
|
|
237
|
-
|
|
238
|
-
def initialize(version, response, solution, limit)
|
|
239
|
-
super(version, response)
|
|
240
|
-
@notification_page = []
|
|
241
|
-
@limit = limit
|
|
242
|
-
key = get_key(response.body)
|
|
243
|
-
records = 0
|
|
244
|
-
while( limit != :unset && records < limit )
|
|
245
|
-
@notification_page << NotificationListResponse.new(version, @payload, key, limit - records)
|
|
246
|
-
@payload = self.next_page
|
|
247
|
-
break unless @payload
|
|
248
|
-
records += (@payload.body[key] || []).size
|
|
249
|
-
end
|
|
250
|
-
# Path Solution
|
|
251
|
-
@solution = solution
|
|
252
|
-
end
|
|
253
|
-
|
|
254
|
-
def each
|
|
255
|
-
@notification_page.each do |record|
|
|
256
|
-
yield record
|
|
257
|
-
end
|
|
258
|
-
end
|
|
259
|
-
|
|
260
|
-
def to_s
|
|
261
|
-
'<Twilio::REST::Notify::V1PageMetadata>';
|
|
262
|
-
end
|
|
263
|
-
end
|
|
264
|
-
class NotificationListResponse < InstanceListResource
|
|
265
|
-
|
|
266
|
-
# @param [Array<NotificationInstance>] instance
|
|
267
|
-
# @param [Hash{String => Object}] headers
|
|
268
|
-
# @param [Integer] status_code
|
|
269
|
-
def initialize(version, payload, key, limit = :unset)
|
|
270
|
-
data_list = payload.body[key] || []
|
|
271
|
-
if limit != :unset
|
|
272
|
-
data_list = data_list[0, limit]
|
|
273
|
-
end
|
|
274
|
-
@notification = data_list.map do |data|
|
|
275
|
-
NotificationInstance.new(version, data)
|
|
276
|
-
end
|
|
277
|
-
@headers = payload.headers
|
|
278
|
-
@status_code = payload.status_code
|
|
279
|
-
end
|
|
280
|
-
|
|
281
|
-
def notification
|
|
282
|
-
@notification
|
|
283
|
-
end
|
|
284
|
-
|
|
285
|
-
def headers
|
|
286
|
-
@headers
|
|
287
|
-
end
|
|
288
|
-
|
|
289
|
-
def status_code
|
|
290
|
-
@status_code
|
|
291
|
-
end
|
|
292
|
-
end
|
|
293
|
-
|
|
294
235
|
class NotificationInstance < InstanceResource
|
|
295
236
|
##
|
|
296
237
|
# Initialize the NotificationInstance
|
|
@@ -240,65 +240,6 @@ module Twilio
|
|
|
240
240
|
end
|
|
241
241
|
end
|
|
242
242
|
|
|
243
|
-
class BulkEligibilityPageMetadata < PageMetadata
|
|
244
|
-
attr_reader :bulk_eligibility_page
|
|
245
|
-
|
|
246
|
-
def initialize(version, response, solution, limit)
|
|
247
|
-
super(version, response)
|
|
248
|
-
@bulk_eligibility_page = []
|
|
249
|
-
@limit = limit
|
|
250
|
-
key = get_key(response.body)
|
|
251
|
-
records = 0
|
|
252
|
-
while( limit != :unset && records < limit )
|
|
253
|
-
@bulk_eligibility_page << BulkEligibilityListResponse.new(version, @payload, key, limit - records)
|
|
254
|
-
@payload = self.next_page
|
|
255
|
-
break unless @payload
|
|
256
|
-
records += (@payload.body[key] || []).size
|
|
257
|
-
end
|
|
258
|
-
# Path Solution
|
|
259
|
-
@solution = solution
|
|
260
|
-
end
|
|
261
|
-
|
|
262
|
-
def each
|
|
263
|
-
@bulk_eligibility_page.each do |record|
|
|
264
|
-
yield record
|
|
265
|
-
end
|
|
266
|
-
end
|
|
267
|
-
|
|
268
|
-
def to_s
|
|
269
|
-
'<Twilio::REST::Numbers::V1PageMetadata>';
|
|
270
|
-
end
|
|
271
|
-
end
|
|
272
|
-
class BulkEligibilityListResponse < InstanceListResource
|
|
273
|
-
|
|
274
|
-
# @param [Array<BulkEligibilityInstance>] instance
|
|
275
|
-
# @param [Hash{String => Object}] headers
|
|
276
|
-
# @param [Integer] status_code
|
|
277
|
-
def initialize(version, payload, key, limit = :unset)
|
|
278
|
-
data_list = payload.body[key] || []
|
|
279
|
-
if limit != :unset
|
|
280
|
-
data_list = data_list[0, limit]
|
|
281
|
-
end
|
|
282
|
-
@bulk_eligibility = data_list.map do |data|
|
|
283
|
-
BulkEligibilityInstance.new(version, data)
|
|
284
|
-
end
|
|
285
|
-
@headers = payload.headers
|
|
286
|
-
@status_code = payload.status_code
|
|
287
|
-
end
|
|
288
|
-
|
|
289
|
-
def bulk_eligibility
|
|
290
|
-
@bulk_eligibility
|
|
291
|
-
end
|
|
292
|
-
|
|
293
|
-
def headers
|
|
294
|
-
@headers
|
|
295
|
-
end
|
|
296
|
-
|
|
297
|
-
def status_code
|
|
298
|
-
@status_code
|
|
299
|
-
end
|
|
300
|
-
end
|
|
301
|
-
|
|
302
243
|
class BulkEligibilityInstance < InstanceResource
|
|
303
244
|
##
|
|
304
245
|
# Initialize the BulkEligibilityInstance
|
|
@@ -116,65 +116,6 @@ module Twilio
|
|
|
116
116
|
end
|
|
117
117
|
end
|
|
118
118
|
|
|
119
|
-
class EligibilityPageMetadata < PageMetadata
|
|
120
|
-
attr_reader :eligibility_page
|
|
121
|
-
|
|
122
|
-
def initialize(version, response, solution, limit)
|
|
123
|
-
super(version, response)
|
|
124
|
-
@eligibility_page = []
|
|
125
|
-
@limit = limit
|
|
126
|
-
key = get_key(response.body)
|
|
127
|
-
records = 0
|
|
128
|
-
while( limit != :unset && records < limit )
|
|
129
|
-
@eligibility_page << EligibilityListResponse.new(version, @payload, key, limit - records)
|
|
130
|
-
@payload = self.next_page
|
|
131
|
-
break unless @payload
|
|
132
|
-
records += (@payload.body[key] || []).size
|
|
133
|
-
end
|
|
134
|
-
# Path Solution
|
|
135
|
-
@solution = solution
|
|
136
|
-
end
|
|
137
|
-
|
|
138
|
-
def each
|
|
139
|
-
@eligibility_page.each do |record|
|
|
140
|
-
yield record
|
|
141
|
-
end
|
|
142
|
-
end
|
|
143
|
-
|
|
144
|
-
def to_s
|
|
145
|
-
'<Twilio::REST::Numbers::V1PageMetadata>';
|
|
146
|
-
end
|
|
147
|
-
end
|
|
148
|
-
class EligibilityListResponse < InstanceListResource
|
|
149
|
-
|
|
150
|
-
# @param [Array<EligibilityInstance>] instance
|
|
151
|
-
# @param [Hash{String => Object}] headers
|
|
152
|
-
# @param [Integer] status_code
|
|
153
|
-
def initialize(version, payload, key, limit = :unset)
|
|
154
|
-
data_list = payload.body[key] || []
|
|
155
|
-
if limit != :unset
|
|
156
|
-
data_list = data_list[0, limit]
|
|
157
|
-
end
|
|
158
|
-
@eligibility = data_list.map do |data|
|
|
159
|
-
EligibilityInstance.new(version, data)
|
|
160
|
-
end
|
|
161
|
-
@headers = payload.headers
|
|
162
|
-
@status_code = payload.status_code
|
|
163
|
-
end
|
|
164
|
-
|
|
165
|
-
def eligibility
|
|
166
|
-
@eligibility
|
|
167
|
-
end
|
|
168
|
-
|
|
169
|
-
def headers
|
|
170
|
-
@headers
|
|
171
|
-
end
|
|
172
|
-
|
|
173
|
-
def status_code
|
|
174
|
-
@status_code
|
|
175
|
-
end
|
|
176
|
-
end
|
|
177
|
-
|
|
178
119
|
class EligibilityInstance < InstanceResource
|
|
179
120
|
##
|
|
180
121
|
# Initialize the EligibilityInstance
|