twilio-ruby 7.10.4 → 7.10.6
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/.github/workflows/test-and-deploy.yml +1 -1
- data/CHANGES.md +166 -0
- data/README.md +2 -2
- data/lib/twilio-ruby/rest/accounts/v1/auth_token_promotion.rb +2 -2
- data/lib/twilio-ruby/rest/accounts/v1/bulk_consents.rb +3 -3
- data/lib/twilio-ruby/rest/accounts/v1/bulk_contacts.rb +3 -3
- data/lib/twilio-ruby/rest/accounts/v1/credential/aws.rb +18 -10
- data/lib/twilio-ruby/rest/accounts/v1/credential/public_key.rb +18 -10
- data/lib/twilio-ruby/rest/accounts/v1/credential.rb +2 -2
- data/lib/twilio-ruby/rest/accounts/v1/messaging_geopermissions.rb +4 -4
- data/lib/twilio-ruby/rest/accounts/v1/safelist.rb +5 -5
- data/lib/twilio-ruby/rest/accounts/v1/secondary_auth_token.rb +2 -2
- data/lib/twilio-ruby/rest/accounts/v1.rb +11 -2
- data/lib/twilio-ruby/rest/api/v2010/account/address/dependent_phone_number.rb +13 -5
- data/lib/twilio-ruby/rest/api/v2010/account/address.rb +41 -33
- data/lib/twilio-ruby/rest/api/v2010/account/application.rb +61 -53
- data/lib/twilio-ruby/rest/api/v2010/account/authorized_connect_app.rb +13 -5
- data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number_country/local.rb +13 -5
- data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number_country/machine_to_machine.rb +13 -5
- data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number_country/mobile.rb +13 -5
- data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number_country/national.rb +13 -5
- data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number_country/shared_cost.rb +13 -5
- data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number_country/toll_free.rb +13 -5
- data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number_country/voip.rb +13 -5
- data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number_country.rb +13 -5
- data/lib/twilio-ruby/rest/api/v2010/account/balance.rb +2 -2
- data/lib/twilio-ruby/rest/api/v2010/account/call/event.rb +13 -5
- data/lib/twilio-ruby/rest/api/v2010/account/call/notification.rb +13 -5
- data/lib/twilio-ruby/rest/api/v2010/account/call/payment.rb +28 -28
- data/lib/twilio-ruby/rest/api/v2010/account/call/recording.rb +30 -16
- data/lib/twilio-ruby/rest/api/v2010/account/call/siprec.rb +207 -207
- data/lib/twilio-ruby/rest/api/v2010/account/call/stream.rb +207 -207
- data/lib/twilio-ruby/rest/api/v2010/account/call/transcription.rb +27 -21
- data/lib/twilio-ruby/rest/api/v2010/account/call/user_defined_message.rb +4 -4
- data/lib/twilio-ruby/rest/api/v2010/account/call/user_defined_message_subscription.rb +5 -5
- data/lib/twilio-ruby/rest/api/v2010/account/call.rb +73 -59
- data/lib/twilio-ruby/rest/api/v2010/account/conference/participant.rb +93 -79
- data/lib/twilio-ruby/rest/api/v2010/account/conference/recording.rb +17 -9
- data/lib/twilio-ruby/rest/api/v2010/account/conference.rb +19 -11
- data/lib/twilio-ruby/rest/api/v2010/account/connect_app.rb +29 -21
- data/lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/assigned_add_on/assigned_add_on_extension.rb +13 -5
- data/lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/assigned_add_on.rb +14 -6
- data/lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb +36 -28
- data/lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/mobile.rb +36 -28
- data/lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/toll_free.rb +36 -28
- data/lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number.rb +83 -75
- data/lib/twilio-ruby/rest/api/v2010/account/key.rb +15 -7
- data/lib/twilio-ruby/rest/api/v2010/account/message/feedback.rb +3 -3
- data/lib/twilio-ruby/rest/api/v2010/account/message/media.rb +13 -5
- data/lib/twilio-ruby/rest/api/v2010/account/message.rb +47 -33
- data/lib/twilio-ruby/rest/api/v2010/account/new_key.rb +3 -3
- data/lib/twilio-ruby/rest/api/v2010/account/new_signing_key.rb +3 -3
- data/lib/twilio-ruby/rest/api/v2010/account/notification.rb +13 -5
- data/lib/twilio-ruby/rest/api/v2010/account/outgoing_caller_id.rb +15 -7
- data/lib/twilio-ruby/rest/api/v2010/account/queue/member.rb +17 -9
- data/lib/twilio-ruby/rest/api/v2010/account/queue.rb +19 -11
- data/lib/twilio-ruby/rest/api/v2010/account/recording/add_on_result/payload/data.rb +2 -2
- data/lib/twilio-ruby/rest/api/v2010/account/recording/add_on_result/payload.rb +13 -5
- data/lib/twilio-ruby/rest/api/v2010/account/recording/add_on_result.rb +13 -5
- data/lib/twilio-ruby/rest/api/v2010/account/recording/transcription.rb +13 -5
- data/lib/twilio-ruby/rest/api/v2010/account/recording.rb +15 -7
- data/lib/twilio-ruby/rest/api/v2010/account/short_code.rb +25 -17
- data/lib/twilio-ruby/rest/api/v2010/account/signing_key.rb +15 -7
- data/lib/twilio-ruby/rest/api/v2010/account/sip/credential_list/credential.rb +17 -9
- data/lib/twilio-ruby/rest/api/v2010/account/sip/credential_list.rb +16 -8
- data/lib/twilio-ruby/rest/api/v2010/account/sip/domain/auth_types/auth_type_calls/auth_calls_credential_list_mapping.rb +14 -6
- data/lib/twilio-ruby/rest/api/v2010/account/sip/domain/auth_types/auth_type_calls/auth_calls_ip_access_control_list_mapping.rb +14 -6
- data/lib/twilio-ruby/rest/api/v2010/account/sip/domain/auth_types/auth_type_calls.rb +2 -2
- data/lib/twilio-ruby/rest/api/v2010/account/sip/domain/auth_types/auth_type_registrations/auth_registrations_credential_list_mapping.rb +14 -6
- data/lib/twilio-ruby/rest/api/v2010/account/sip/domain/auth_types/auth_type_registrations.rb +2 -2
- data/lib/twilio-ruby/rest/api/v2010/account/sip/domain/auth_types.rb +2 -2
- data/lib/twilio-ruby/rest/api/v2010/account/sip/domain/credential_list_mapping.rb +14 -6
- data/lib/twilio-ruby/rest/api/v2010/account/sip/domain/ip_access_control_list_mapping.rb +14 -6
- data/lib/twilio-ruby/rest/api/v2010/account/sip/domain.rb +52 -44
- data/lib/twilio-ruby/rest/api/v2010/account/sip/ip_access_control_list/ip_address.rb +22 -14
- data/lib/twilio-ruby/rest/api/v2010/account/sip/ip_access_control_list.rb +16 -8
- data/lib/twilio-ruby/rest/api/v2010/account/sip.rb +2 -2
- data/lib/twilio-ruby/rest/api/v2010/account/token.rb +3 -3
- data/lib/twilio-ruby/rest/api/v2010/account/transcription.rb +13 -5
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/all_time.rb +13 -5
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/daily.rb +13 -5
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/last_month.rb +13 -5
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/monthly.rb +13 -5
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/this_month.rb +13 -5
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/today.rb +13 -5
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/yearly.rb +13 -5
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/yesterday.rb +13 -5
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record.rb +13 -5
- data/lib/twilio-ruby/rest/api/v2010/account/usage/trigger.rb +26 -18
- data/lib/twilio-ruby/rest/api/v2010/account/usage.rb +2 -2
- data/lib/twilio-ruby/rest/api/v2010/account/validation_request.rb +8 -8
- data/lib/twilio-ruby/rest/api/v2010/account.rb +18 -10
- data/lib/twilio-ruby/rest/api/v2010.rb +1 -0
- data/lib/twilio-ruby/rest/assistants/v1/assistant/assistants_knowledge.rb +13 -5
- data/lib/twilio-ruby/rest/assistants/v1/assistant/assistants_tool.rb +13 -5
- data/lib/twilio-ruby/rest/assistants/v1/assistant/feedback.rb +13 -5
- data/lib/twilio-ruby/rest/assistants/v1/assistant/message.rb +2 -2
- data/lib/twilio-ruby/rest/assistants/v1/assistant.rb +14 -5
- data/lib/twilio-ruby/rest/assistants/v1/knowledge/chunk.rb +13 -5
- data/lib/twilio-ruby/rest/assistants/v1/knowledge/knowledge_status.rb +2 -2
- data/lib/twilio-ruby/rest/assistants/v1/knowledge.rb +14 -5
- data/lib/twilio-ruby/rest/assistants/v1/policy.rb +13 -5
- data/lib/twilio-ruby/rest/assistants/v1/session/message.rb +13 -5
- data/lib/twilio-ruby/rest/assistants/v1/session.rb +13 -5
- data/lib/twilio-ruby/rest/assistants/v1/tool.rb +14 -5
- data/lib/twilio-ruby/rest/assistants/v1.rb +4 -0
- data/lib/twilio-ruby/rest/bulkexports/v1/export/day.rb +13 -5
- data/lib/twilio-ruby/rest/bulkexports/v1/export/export_custom_job.rb +19 -11
- data/lib/twilio-ruby/rest/bulkexports/v1/export/job.rb +2 -2
- data/lib/twilio-ruby/rest/bulkexports/v1/export.rb +2 -2
- data/lib/twilio-ruby/rest/bulkexports/v1/export_configuration.rb +8 -8
- data/lib/twilio-ruby/rest/bulkexports/v1.rb +2 -0
- data/lib/twilio-ruby/rest/chat/v1/credential.rb +32 -24
- data/lib/twilio-ruby/rest/chat/v1/service/channel/invite.rb +15 -7
- data/lib/twilio-ruby/rest/chat/v1/service/channel/member.rb +19 -11
- data/lib/twilio-ruby/rest/chat/v1/service/channel/message.rb +20 -12
- data/lib/twilio-ruby/rest/chat/v1/service/channel.rb +23 -15
- data/lib/twilio-ruby/rest/chat/v1/service/role.rb +18 -10
- data/lib/twilio-ruby/rest/chat/v1/service/user/user_channel.rb +13 -5
- data/lib/twilio-ruby/rest/chat/v1/service/user.rb +23 -15
- data/lib/twilio-ruby/rest/chat/v1/service.rb +122 -114
- data/lib/twilio-ruby/rest/chat/v1.rb +2 -0
- data/lib/twilio-ruby/rest/chat/v2/credential.rb +32 -24
- data/lib/twilio-ruby/rest/chat/v2/service/binding.rb +13 -5
- data/lib/twilio-ruby/rest/chat/v2/service/channel/invite.rb +15 -7
- data/lib/twilio-ruby/rest/chat/v2/service/channel/member.rb +37 -29
- data/lib/twilio-ruby/rest/chat/v2/service/channel/message.rb +37 -29
- data/lib/twilio-ruby/rest/chat/v2/service/channel/webhook.rb +32 -24
- data/lib/twilio-ruby/rest/chat/v2/service/channel.rb +37 -29
- data/lib/twilio-ruby/rest/chat/v2/service/role.rb +18 -10
- data/lib/twilio-ruby/rest/chat/v2/service/user/user_binding.rb +13 -5
- data/lib/twilio-ruby/rest/chat/v2/service/user/user_channel.rb +21 -13
- data/lib/twilio-ruby/rest/chat/v2/service/user.rb +26 -18
- data/lib/twilio-ruby/rest/chat/v2/service.rb +76 -68
- data/lib/twilio-ruby/rest/chat/v2.rb +2 -0
- data/lib/twilio-ruby/rest/chat/v3/channel.rb +8 -8
- data/lib/twilio-ruby/rest/chat/v3.rb +6 -0
- data/lib/twilio-ruby/rest/client.rb +5 -0
- data/lib/twilio-ruby/rest/content/v1/content/approval_create.rb +2 -2
- data/lib/twilio-ruby/rest/content/v1/content/approval_fetch.rb +2 -2
- data/lib/twilio-ruby/rest/content/v1/content.rb +14 -5
- data/lib/twilio-ruby/rest/content/v1/content_and_approvals.rb +13 -5
- data/lib/twilio-ruby/rest/content/v1/legacy_content.rb +13 -5
- data/lib/twilio-ruby/rest/content/v1.rb +1 -0
- data/lib/twilio-ruby/rest/content/v2/content.rb +13 -5
- data/lib/twilio-ruby/rest/content/v2/content_and_approvals.rb +13 -5
- data/lib/twilio-ruby/rest/conversations/v1/address_configuration.rb +43 -35
- data/lib/twilio-ruby/rest/conversations/v1/configuration/webhook.rb +12 -12
- data/lib/twilio-ruby/rest/conversations/v1/configuration.rb +10 -10
- data/lib/twilio-ruby/rest/conversations/v1/conversation/message/delivery_receipt.rb +13 -5
- data/lib/twilio-ruby/rest/conversations/v1/conversation/message.rb +39 -31
- data/lib/twilio-ruby/rest/conversations/v1/conversation/participant.rb +44 -36
- data/lib/twilio-ruby/rest/conversations/v1/conversation/webhook.rb +30 -22
- data/lib/twilio-ruby/rest/conversations/v1/conversation.rb +51 -43
- data/lib/twilio-ruby/rest/conversations/v1/conversation_with_participants.rb +15 -15
- data/lib/twilio-ruby/rest/conversations/v1/credential.rb +34 -26
- data/lib/twilio-ruby/rest/conversations/v1/participant_conversation.rb +13 -5
- data/lib/twilio-ruby/rest/conversations/v1/role.rb +18 -10
- data/lib/twilio-ruby/rest/conversations/v1/service/binding.rb +13 -5
- data/lib/twilio-ruby/rest/conversations/v1/service/configuration/notification.rb +28 -28
- data/lib/twilio-ruby/rest/conversations/v1/service/configuration/webhook.rb +10 -10
- data/lib/twilio-ruby/rest/conversations/v1/service/configuration.rb +10 -10
- data/lib/twilio-ruby/rest/conversations/v1/service/conversation/message/delivery_receipt.rb +13 -5
- data/lib/twilio-ruby/rest/conversations/v1/service/conversation/message.rb +39 -31
- data/lib/twilio-ruby/rest/conversations/v1/service/conversation/participant.rb +44 -36
- data/lib/twilio-ruby/rest/conversations/v1/service/conversation/webhook.rb +30 -22
- data/lib/twilio-ruby/rest/conversations/v1/service/conversation.rb +51 -43
- data/lib/twilio-ruby/rest/conversations/v1/service/conversation_with_participants.rb +15 -15
- data/lib/twilio-ruby/rest/conversations/v1/service/participant_conversation.rb +13 -5
- data/lib/twilio-ruby/rest/conversations/v1/service/role.rb +18 -10
- data/lib/twilio-ruby/rest/conversations/v1/service/user/user_conversation.rb +19 -11
- data/lib/twilio-ruby/rest/conversations/v1/service/user.rb +28 -20
- data/lib/twilio-ruby/rest/conversations/v1/service.rb +14 -6
- data/lib/twilio-ruby/rest/conversations/v1/user/user_conversation.rb +19 -11
- data/lib/twilio-ruby/rest/conversations/v1/user.rb +28 -20
- data/lib/twilio-ruby/rest/conversations/v1.rb +6 -0
- data/lib/twilio-ruby/rest/conversations/v2/communication.rb +698 -0
- data/lib/twilio-ruby/rest/conversations/v2/configuration.rb +1208 -0
- data/lib/twilio-ruby/rest/conversations/v2/conversation.rb +1365 -0
- data/lib/twilio-ruby/rest/conversations/v2/operation.rb +369 -0
- data/lib/twilio-ruby/rest/conversations/v2/participant.rb +745 -0
- data/lib/twilio-ruby/rest/conversations/v2.rb +126 -0
- data/lib/twilio-ruby/rest/conversations_base.rb +6 -1
- data/lib/twilio-ruby/rest/events/v1/event_type.rb +13 -5
- data/lib/twilio-ruby/rest/events/v1/schema/schema_version.rb +13 -5
- data/lib/twilio-ruby/rest/events/v1/schema.rb +2 -2
- data/lib/twilio-ruby/rest/events/v1/sink/sink_test.rb +2 -2
- data/lib/twilio-ruby/rest/events/v1/sink/sink_validate.rb +3 -3
- data/lib/twilio-ruby/rest/events/v1/sink.rb +18 -10
- data/lib/twilio-ruby/rest/events/v1/subscription/subscribed_event.rb +17 -9
- data/lib/twilio-ruby/rest/events/v1/subscription.rb +18 -10
- data/lib/twilio-ruby/rest/events/v1.rb +4 -0
- data/lib/twilio-ruby/rest/flex_api/v1/assessments.rb +32 -24
- data/lib/twilio-ruby/rest/flex_api/v1/channel.rb +23 -15
- data/lib/twilio-ruby/rest/flex_api/v1/configuration.rb +5 -4
- data/lib/twilio-ruby/rest/flex_api/v1/flex_flow.rb +64 -56
- data/lib/twilio-ruby/rest/flex_api/v1/insights_assessments_comment.rb +20 -12
- data/lib/twilio-ruby/rest/flex_api/v1/insights_conversations.rb +13 -5
- data/lib/twilio-ruby/rest/flex_api/v1/insights_questionnaires.rb +32 -24
- data/lib/twilio-ruby/rest/flex_api/v1/insights_questionnaires_category.rb +21 -13
- data/lib/twilio-ruby/rest/flex_api/v1/insights_questionnaires_question.rb +33 -25
- data/lib/twilio-ruby/rest/flex_api/v1/insights_segments.rb +13 -5
- data/lib/twilio-ruby/rest/flex_api/v1/insights_session.rb +4 -4
- data/lib/twilio-ruby/rest/flex_api/v1/insights_settings_answer_sets.rb +3 -3
- data/lib/twilio-ruby/rest/flex_api/v1/insights_settings_comment.rb +3 -3
- data/lib/twilio-ruby/rest/flex_api/v1/insights_user_roles.rb +4 -4
- data/lib/twilio-ruby/rest/flex_api/v1/interaction/interaction_channel/interaction_channel_invite.rb +14 -6
- data/lib/twilio-ruby/rest/flex_api/v1/interaction/interaction_channel/interaction_channel_participant.rb +18 -10
- data/lib/twilio-ruby/rest/flex_api/v1/interaction/interaction_channel/interaction_transfer.rb +3 -2
- data/lib/twilio-ruby/rest/flex_api/v1/interaction/interaction_channel.rb +17 -9
- data/lib/twilio-ruby/rest/flex_api/v1/interaction.rb +8 -8
- data/lib/twilio-ruby/rest/flex_api/v1/plugin/plugin_versions.rb +27 -19
- data/lib/twilio-ruby/rest/flex_api/v1/plugin.rb +25 -17
- data/lib/twilio-ruby/rest/flex_api/v1/plugin_archive.rb +4 -4
- data/lib/twilio-ruby/rest/flex_api/v1/plugin_configuration/configured_plugin.rb +15 -7
- data/lib/twilio-ruby/rest/flex_api/v1/plugin_configuration.rb +19 -11
- data/lib/twilio-ruby/rest/flex_api/v1/plugin_configuration_archive.rb +4 -4
- data/lib/twilio-ruby/rest/flex_api/v1/plugin_release.rb +17 -9
- data/lib/twilio-ruby/rest/flex_api/v1/plugin_version_archive.rb +4 -4
- data/lib/twilio-ruby/rest/flex_api/v1/provisioning_status.rb +2 -2
- data/lib/twilio-ruby/rest/flex_api/v1/web_channel.rb +23 -15
- data/lib/twilio-ruby/rest/flex_api/v1.rb +19 -6
- data/lib/twilio-ruby/rest/flex_api/v2/flex_user.rb +8 -8
- data/lib/twilio-ruby/rest/flex_api/v2/web_channels.rb +8 -8
- data/lib/twilio-ruby/rest/flex_api/v2.rb +6 -0
- data/lib/twilio-ruby/rest/flex_api_base.rb +6 -1
- data/lib/twilio-ruby/rest/frontline_api/v1/user.rb +10 -10
- data/lib/twilio-ruby/rest/frontline_api/v1.rb +1 -0
- data/lib/twilio-ruby/rest/iam/v1/api_key.rb +6 -6
- data/lib/twilio-ruby/rest/iam/v1/get_api_keys.rb +13 -5
- data/lib/twilio-ruby/rest/iam/v1/new_api_key.rb +6 -6
- data/lib/twilio-ruby/rest/iam/v1/o_auth_app.rb +3 -2
- data/lib/twilio-ruby/rest/iam/v1/role_permission.rb +327 -0
- data/lib/twilio-ruby/rest/iam/v1/token.rb +10 -10
- data/lib/twilio-ruby/rest/iam/v1.rb +17 -0
- data/lib/twilio-ruby/rest/insights/v1/call/annotation.rb +16 -16
- data/lib/twilio-ruby/rest/insights/v1/call/call_summary.rb +14 -14
- data/lib/twilio-ruby/rest/insights/v1/call/event.rb +17 -9
- data/lib/twilio-ruby/rest/insights/v1/call/metric.rb +13 -5
- data/lib/twilio-ruby/rest/insights/v1/call.rb +2 -2
- data/lib/twilio-ruby/rest/insights/v1/call_summaries.rb +23 -15
- data/lib/twilio-ruby/rest/insights/v1/conference/conference_participant.rb +17 -9
- data/lib/twilio-ruby/rest/insights/v1/conference.rb +13 -5
- data/lib/twilio-ruby/rest/insights/v1/room/participant.rb +13 -5
- data/lib/twilio-ruby/rest/insights/v1/room.rb +13 -5
- data/lib/twilio-ruby/rest/insights/v1/setting.rb +10 -10
- data/lib/twilio-ruby/rest/insights/v1.rb +3 -0
- data/lib/twilio-ruby/rest/insights/v2/inbound.rb +21 -12
- data/lib/twilio-ruby/rest/insights/v2/outbound.rb +21 -12
- data/lib/twilio-ruby/rest/insights/v2/report.rb +10 -9
- data/lib/twilio-ruby/rest/insights/v2.rb +3 -0
- data/lib/twilio-ruby/rest/insights/v3/metadata.rb +227 -0
- data/lib/twilio-ruby/rest/insights/v3/query.rb +394 -0
- data/lib/twilio-ruby/rest/insights/v3.rb +46 -0
- data/lib/twilio-ruby/rest/insights_base.rb +5 -0
- data/lib/twilio-ruby/rest/intelligence/v2/custom_operator.rb +22 -14
- data/lib/twilio-ruby/rest/intelligence/v2/operator.rb +13 -5
- data/lib/twilio-ruby/rest/intelligence/v2/operator_attachment.rb +2 -2
- data/lib/twilio-ruby/rest/intelligence/v2/operator_attachments.rb +2 -2
- data/lib/twilio-ruby/rest/intelligence/v2/operator_type.rb +13 -5
- data/lib/twilio-ruby/rest/intelligence/v2/prebuilt_operator.rb +13 -5
- data/lib/twilio-ruby/rest/intelligence/v2/service.rb +43 -35
- data/lib/twilio-ruby/rest/intelligence/v2/transcript/encrypted_operator_results.rb +4 -4
- data/lib/twilio-ruby/rest/intelligence/v2/transcript/encrypted_sentences.rb +4 -4
- data/lib/twilio-ruby/rest/intelligence/v2/transcript/media.rb +4 -4
- data/lib/twilio-ruby/rest/intelligence/v2/transcript/operator_result.rb +15 -7
- data/lib/twilio-ruby/rest/intelligence/v2/transcript/sentence.rb +13 -5
- data/lib/twilio-ruby/rest/intelligence/v2/transcript.rb +17 -9
- data/lib/twilio-ruby/rest/intelligence/v2.rb +13 -0
- data/lib/twilio-ruby/rest/intelligence/v3/configuration.rb +1073 -0
- data/lib/twilio-ruby/rest/intelligence/v3/conversation.rb +602 -0
- data/lib/twilio-ruby/rest/intelligence/v3/operator.rb +784 -0
- data/lib/twilio-ruby/rest/intelligence/v3/operator_result.rb +622 -0
- data/lib/twilio-ruby/rest/intelligence/v3/version.rb +556 -0
- data/lib/twilio-ruby/rest/intelligence/v3.rb +120 -0
- data/lib/twilio-ruby/rest/intelligence_base.rb +6 -1
- data/lib/twilio-ruby/rest/ip_messaging/v1/credential.rb +32 -24
- data/lib/twilio-ruby/rest/ip_messaging/v1/service/channel/invite.rb +15 -7
- data/lib/twilio-ruby/rest/ip_messaging/v1/service/channel/member.rb +19 -11
- data/lib/twilio-ruby/rest/ip_messaging/v1/service/channel/message.rb +20 -12
- data/lib/twilio-ruby/rest/ip_messaging/v1/service/channel.rb +23 -15
- data/lib/twilio-ruby/rest/ip_messaging/v1/service/role.rb +18 -10
- data/lib/twilio-ruby/rest/ip_messaging/v1/service/user/user_channel.rb +13 -5
- data/lib/twilio-ruby/rest/ip_messaging/v1/service/user.rb +23 -15
- data/lib/twilio-ruby/rest/ip_messaging/v1/service.rb +122 -114
- data/lib/twilio-ruby/rest/ip_messaging/v1.rb +2 -0
- data/lib/twilio-ruby/rest/ip_messaging/v2/credential.rb +32 -24
- data/lib/twilio-ruby/rest/ip_messaging/v2/service/binding.rb +13 -5
- data/lib/twilio-ruby/rest/ip_messaging/v2/service/channel/invite.rb +15 -7
- data/lib/twilio-ruby/rest/ip_messaging/v2/service/channel/member.rb +37 -29
- data/lib/twilio-ruby/rest/ip_messaging/v2/service/channel/message.rb +37 -29
- data/lib/twilio-ruby/rest/ip_messaging/v2/service/channel/webhook.rb +32 -24
- data/lib/twilio-ruby/rest/ip_messaging/v2/service/channel.rb +37 -29
- data/lib/twilio-ruby/rest/ip_messaging/v2/service/role.rb +18 -10
- data/lib/twilio-ruby/rest/ip_messaging/v2/service/user/user_binding.rb +13 -5
- data/lib/twilio-ruby/rest/ip_messaging/v2/service/user/user_channel.rb +19 -11
- data/lib/twilio-ruby/rest/ip_messaging/v2/service/user.rb +26 -18
- data/lib/twilio-ruby/rest/ip_messaging/v2/service.rb +76 -68
- data/lib/twilio-ruby/rest/ip_messaging/v2.rb +2 -0
- data/lib/twilio-ruby/rest/knowledge/v1/knowledge/chunk.rb +13 -5
- data/lib/twilio-ruby/rest/knowledge/v1/knowledge/knowledge_status.rb +2 -2
- data/lib/twilio-ruby/rest/knowledge/v1/knowledge.rb +14 -5
- data/lib/twilio-ruby/rest/knowledge/v1.rb +1 -0
- data/lib/twilio-ruby/rest/knowledge/v2/chunk.rb +306 -0
- data/lib/twilio-ruby/rest/knowledge/v2/knowledge.rb +714 -0
- data/lib/twilio-ruby/rest/knowledge/v2/knowledge_basis.rb +739 -0
- data/lib/twilio-ruby/rest/knowledge/v2/operation.rb +376 -0
- data/lib/twilio-ruby/rest/knowledge/v2/search.rb +355 -0
- data/lib/twilio-ruby/rest/knowledge/v2.rb +145 -0
- data/lib/twilio-ruby/rest/knowledge_base.rb +6 -1
- data/lib/twilio-ruby/rest/lookups/v1/phone_number.rb +10 -10
- data/lib/twilio-ruby/rest/lookups/v1.rb +1 -0
- data/lib/twilio-ruby/rest/lookups/v2/bucket.rb +3 -2
- data/lib/twilio-ruby/rest/lookups/v2/lookup_override.rb +4 -2
- data/lib/twilio-ruby/rest/lookups/v2/phone_number.rb +32 -32
- data/lib/twilio-ruby/rest/lookups/v2/query.rb +2 -2
- data/lib/twilio-ruby/rest/lookups/v2/rate_limit.rb +3 -3
- data/lib/twilio-ruby/rest/lookups/v2.rb +13 -0
- data/lib/twilio-ruby/rest/marketplace/v1/available_add_on/available_add_on_extension.rb +13 -5
- data/lib/twilio-ruby/rest/marketplace/v1/available_add_on.rb +13 -5
- data/lib/twilio-ruby/rest/marketplace/v1/installed_add_on/installed_add_on_extension.rb +15 -7
- data/lib/twilio-ruby/rest/marketplace/v1/installed_add_on/installed_add_on_usage.rb +2 -2
- data/lib/twilio-ruby/rest/marketplace/v1/installed_add_on.rb +21 -13
- data/lib/twilio-ruby/rest/marketplace/v1/module_data.rb +4 -4
- data/lib/twilio-ruby/rest/marketplace/v1/module_data_management.rb +16 -16
- data/lib/twilio-ruby/rest/marketplace/v1/referral_conversion.rb +2 -2
- data/lib/twilio-ruby/rest/marketplace/v1.rb +3 -0
- data/lib/twilio-ruby/rest/{flex_api/v1/create_flex_instance.rb → memory/v1/bulk.rb} +104 -124
- data/lib/twilio-ruby/rest/memory/v1/conversation_summary.rb +798 -0
- data/lib/twilio-ruby/rest/memory/v1/data_mapping.rb +843 -0
- data/lib/twilio-ruby/rest/memory/v1/event.rb +320 -0
- data/lib/twilio-ruby/rest/memory/v1/identifier.rb +710 -0
- data/lib/twilio-ruby/rest/memory/v1/identity_resolution_setting.rb +442 -0
- data/lib/twilio-ruby/rest/memory/v1/import.rb +574 -0
- data/lib/twilio-ruby/rest/memory/v1/lookup.rb +250 -0
- data/lib/twilio-ruby/rest/memory/v1/observation.rb +786 -0
- data/lib/twilio-ruby/rest/memory/v1/operation.rb +376 -0
- data/lib/twilio-ruby/rest/memory/v1/profile.rb +636 -0
- data/lib/twilio-ruby/rest/memory/v1/recall.rb +366 -0
- data/lib/twilio-ruby/rest/memory/v1/revision.rb +349 -0
- data/lib/twilio-ruby/rest/memory/v1/store.rb +701 -0
- data/lib/twilio-ruby/rest/memory/v1/trait.rb +336 -0
- data/lib/twilio-ruby/rest/memory/v1/trait_group.rb +904 -0
- data/lib/twilio-ruby/rest/memory/v1.rb +475 -0
- data/lib/twilio-ruby/rest/memory.rb +6 -0
- data/lib/twilio-ruby/rest/memory_base.rb +38 -0
- data/lib/twilio-ruby/rest/messaging/v1/brand_registration/brand_registration_otp.rb +2 -2
- data/lib/twilio-ruby/rest/messaging/v1/brand_registration/brand_vetting.rb +15 -7
- data/lib/twilio-ruby/rest/messaging/v1/brand_registration.rb +18 -10
- data/lib/twilio-ruby/rest/messaging/v1/deactivations.rb +4 -4
- data/lib/twilio-ruby/rest/messaging/v1/domain_certs.rb +4 -4
- data/lib/twilio-ruby/rest/messaging/v1/domain_config.rb +10 -10
- data/lib/twilio-ruby/rest/messaging/v1/domain_config_messaging_service.rb +2 -2
- data/lib/twilio-ruby/rest/messaging/v1/domain_validate_dn.rb +2 -2
- data/lib/twilio-ruby/rest/messaging/v1/external_campaign.rb +5 -5
- data/lib/twilio-ruby/rest/messaging/v1/linkshortening_messaging_service.rb +2 -2
- data/lib/twilio-ruby/rest/messaging/v1/linkshortening_messaging_service_domain_association.rb +2 -2
- data/lib/twilio-ruby/rest/messaging/v1/request_managed_cert.rb +2 -2
- data/lib/twilio-ruby/rest/messaging/v1/service/alpha_sender.rb +14 -6
- data/lib/twilio-ruby/rest/messaging/v1/service/channel_sender.rb +14 -6
- data/lib/twilio-ruby/rest/messaging/v1/service/destination_alpha_sender.rb +15 -7
- data/lib/twilio-ruby/rest/messaging/v1/service/phone_number.rb +14 -6
- data/lib/twilio-ruby/rest/messaging/v1/service/short_code.rb +14 -6
- data/lib/twilio-ruby/rest/messaging/v1/service/us_app_to_person.rb +54 -46
- data/lib/twilio-ruby/rest/messaging/v1/service/us_app_to_person_usecase.rb +3 -3
- data/lib/twilio-ruby/rest/messaging/v1/service.rb +61 -53
- data/lib/twilio-ruby/rest/messaging/v1/tollfree_verification.rb +120 -112
- data/lib/twilio-ruby/rest/messaging/v1/usecase.rb +2 -2
- data/lib/twilio-ruby/rest/messaging/v1.rb +15 -0
- data/lib/twilio-ruby/rest/messaging/v2/channels_sender.rb +22 -7
- data/lib/twilio-ruby/rest/messaging/v2/domain_certs.rb +2 -2
- data/lib/twilio-ruby/rest/messaging/v2/typing_indicator.rb +4 -4
- data/lib/twilio-ruby/rest/messaging/v2.rb +2 -0
- data/lib/twilio-ruby/rest/messaging/v3/typing_indicator.rb +247 -0
- data/lib/twilio-ruby/rest/messaging/v3.rb +40 -0
- data/lib/twilio-ruby/rest/messaging_base.rb +5 -0
- data/lib/twilio-ruby/rest/monitor/v1/alert.rb +13 -5
- data/lib/twilio-ruby/rest/monitor/v1/event.rb +13 -5
- data/lib/twilio-ruby/rest/monitor/v1.rb +2 -0
- data/lib/twilio-ruby/rest/notify/v1/credential.rb +32 -24
- data/lib/twilio-ruby/rest/notify/v1/service/binding.rb +20 -12
- data/lib/twilio-ruby/rest/notify/v1/service/notification.rb +20 -20
- data/lib/twilio-ruby/rest/notify/v1/service.rb +55 -47
- data/lib/twilio-ruby/rest/notify/v1.rb +2 -0
- data/lib/twilio-ruby/rest/numbers/v1/bulk_eligibility.rb +2 -2
- data/lib/twilio-ruby/rest/numbers/v1/eligibility.rb +2 -2
- data/lib/twilio-ruby/rest/numbers/v1/embedded_session.rb +2 -2
- data/lib/twilio-ruby/rest/numbers/v1/porting_all_port_in.rb +13 -5
- data/lib/twilio-ruby/rest/numbers/v1/porting_port_in.rb +2 -2
- data/lib/twilio-ruby/rest/numbers/v1/porting_port_in_phone_number.rb +2 -2
- data/lib/twilio-ruby/rest/numbers/v1/porting_portability.rb +6 -6
- data/lib/twilio-ruby/rest/numbers/v1/porting_webhook_configuration.rb +2 -2
- data/lib/twilio-ruby/rest/numbers/v1/porting_webhook_configuration_delete.rb +2 -2
- data/lib/twilio-ruby/rest/numbers/v1/sender_id_registration.rb +2 -2
- data/lib/twilio-ruby/rest/numbers/v1/signing_request_configuration.rb +13 -5
- data/lib/twilio-ruby/rest/numbers/v1/webhook.rb +2 -2
- data/lib/twilio-ruby/rest/numbers/v1.rb +21 -2
- data/lib/twilio-ruby/rest/numbers/v2/application.rb +13 -5
- data/lib/twilio-ruby/rest/numbers/v2/authorization_document/dependent_hosted_number_order.rb +13 -5
- data/lib/twilio-ruby/rest/numbers/v2/authorization_document.rb +19 -11
- data/lib/twilio-ruby/rest/numbers/v2/bulk_hosted_number_order.rb +4 -4
- data/lib/twilio-ruby/rest/numbers/v2/bundle_clone.rb +8 -8
- data/lib/twilio-ruby/rest/numbers/v2/hosted_number_order.rb +35 -27
- data/lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle/bundle_copy.rb +14 -6
- data/lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle/evaluation.rb +13 -5
- data/lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle/item_assignment.rb +14 -6
- data/lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle/replace_items.rb +3 -3
- data/lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle.rb +29 -21
- data/lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/end_user.rb +20 -12
- data/lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/end_user_type.rb +13 -5
- data/lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/regulation.rb +15 -7
- data/lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/supporting_document.rb +20 -12
- data/lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/supporting_document_type.rb +13 -5
- data/lib/twilio-ruby/rest/numbers/v2/regulatory_compliance.rb +2 -2
- data/lib/twilio-ruby/rest/numbers/v2.rb +5 -0
- data/lib/twilio-ruby/rest/numbers/v3/hosted_number_order.rb +19 -19
- data/lib/twilio-ruby/rest/oauth/v1/authorize.rb +7 -7
- data/lib/twilio-ruby/rest/oauth/v1/token.rb +10 -10
- data/lib/twilio-ruby/rest/oauth/v2/authorize.rb +7 -7
- data/lib/twilio-ruby/rest/oauth/v2/token.rb +11 -11
- data/lib/twilio-ruby/rest/preview/hosted_numbers/authorization_document/dependent_hosted_number_order.rb +13 -5
- data/lib/twilio-ruby/rest/preview/hosted_numbers/authorization_document.rb +33 -25
- data/lib/twilio-ruby/rest/preview/hosted_numbers/hosted_number_order.rb +50 -42
- data/lib/twilio-ruby/rest/preview/hosted_numbers.rb +2 -0
- data/lib/twilio-ruby/rest/preview/marketplace/available_add_on/available_add_on_extension.rb +13 -5
- data/lib/twilio-ruby/rest/preview/marketplace/available_add_on.rb +13 -5
- data/lib/twilio-ruby/rest/preview/marketplace/installed_add_on/installed_add_on_extension.rb +15 -7
- data/lib/twilio-ruby/rest/preview/marketplace/installed_add_on.rb +21 -13
- data/lib/twilio-ruby/rest/preview/marketplace.rb +2 -0
- data/lib/twilio-ruby/rest/preview/wireless/command.rb +20 -12
- data/lib/twilio-ruby/rest/preview/wireless/rate_plan.rb +27 -19
- data/lib/twilio-ruby/rest/preview/wireless/sim/usage.rb +6 -6
- data/lib/twilio-ruby/rest/preview/wireless/sim.rb +45 -37
- data/lib/twilio-ruby/rest/preview/wireless.rb +3 -0
- data/lib/twilio-ruby/rest/preview_iam/v1/authorize.rb +7 -7
- data/lib/twilio-ruby/rest/preview_iam/v1/token.rb +10 -10
- data/lib/twilio-ruby/rest/preview_iam/versionless/organization/account.rb +13 -5
- data/lib/twilio-ruby/rest/preview_iam/versionless/organization/role_assignment.rb +54 -10
- data/lib/twilio-ruby/rest/preview_iam/versionless/organization/user.rb +27 -11
- data/lib/twilio-ruby/rest/preview_iam/versionless/organization.rb +2 -2
- data/lib/twilio-ruby/rest/preview_iam/versionless.rb +1 -0
- data/lib/twilio-ruby/rest/pricing/v1/messaging/country.rb +13 -5
- data/lib/twilio-ruby/rest/pricing/v1/messaging.rb +2 -2
- data/lib/twilio-ruby/rest/pricing/v1/phone_number/country.rb +13 -5
- data/lib/twilio-ruby/rest/pricing/v1/phone_number.rb +2 -2
- data/lib/twilio-ruby/rest/pricing/v1/voice/country.rb +13 -5
- data/lib/twilio-ruby/rest/pricing/v1/voice/number.rb +2 -2
- data/lib/twilio-ruby/rest/pricing/v1/voice.rb +2 -2
- data/lib/twilio-ruby/rest/pricing/v1.rb +22 -4
- data/lib/twilio-ruby/rest/pricing/v2/country.rb +13 -5
- data/lib/twilio-ruby/rest/pricing/v2/number.rb +4 -4
- data/lib/twilio-ruby/rest/pricing/v2/voice/country.rb +13 -5
- data/lib/twilio-ruby/rest/pricing/v2/voice/number.rb +4 -4
- data/lib/twilio-ruby/rest/pricing/v2/voice.rb +2 -2
- data/lib/twilio-ruby/rest/pricing/v2.rb +13 -2
- data/lib/twilio-ruby/rest/proxy/v1/service/phone_number.rb +18 -10
- data/lib/twilio-ruby/rest/proxy/v1/service/session/interaction.rb +13 -5
- data/lib/twilio-ruby/rest/proxy/v1/service/session/participant/message_interaction.rb +15 -7
- data/lib/twilio-ruby/rest/proxy/v1/service/session/participant.rb +17 -9
- data/lib/twilio-ruby/rest/proxy/v1/service/session.rb +25 -17
- data/lib/twilio-ruby/rest/proxy/v1/service.rb +37 -29
- data/lib/twilio-ruby/rest/proxy/v1.rb +1 -0
- data/lib/twilio-ruby/rest/routes/v2/phone_number.rb +6 -6
- data/lib/twilio-ruby/rest/routes/v2/sip_domain.rb +6 -6
- data/lib/twilio-ruby/rest/routes/v2/trunk.rb +6 -6
- data/lib/twilio-ruby/rest/routes/v2.rb +3 -0
- data/lib/twilio-ruby/rest/serverless/v1/service/asset/asset_version.rb +13 -5
- data/lib/twilio-ruby/rest/serverless/v1/service/asset.rb +16 -8
- data/lib/twilio-ruby/rest/serverless/v1/service/build/build_status.rb +2 -2
- data/lib/twilio-ruby/rest/serverless/v1/service/build.rb +17 -9
- data/lib/twilio-ruby/rest/serverless/v1/service/environment/deployment.rb +15 -7
- data/lib/twilio-ruby/rest/serverless/v1/service/environment/log.rb +13 -5
- data/lib/twilio-ruby/rest/serverless/v1/service/environment/variable.rb +19 -11
- data/lib/twilio-ruby/rest/serverless/v1/service/environment.rb +15 -7
- data/lib/twilio-ruby/rest/serverless/v1/service/function/function_version/function_version_content.rb +2 -2
- data/lib/twilio-ruby/rest/serverless/v1/service/function/function_version.rb +13 -5
- data/lib/twilio-ruby/rest/serverless/v1/service/function.rb +16 -8
- data/lib/twilio-ruby/rest/serverless/v1/service.rb +23 -15
- data/lib/twilio-ruby/rest/serverless/v1.rb +1 -0
- data/lib/twilio-ruby/rest/studio/v1/flow/engagement/engagement_context.rb +2 -2
- data/lib/twilio-ruby/rest/studio/v1/flow/engagement/step/step_context.rb +2 -2
- data/lib/twilio-ruby/rest/studio/v1/flow/engagement/step.rb +13 -5
- data/lib/twilio-ruby/rest/studio/v1/flow/engagement.rb +16 -8
- data/lib/twilio-ruby/rest/studio/v1/flow/execution/execution_context.rb +2 -2
- data/lib/twilio-ruby/rest/studio/v1/flow/execution/execution_step/execution_step_context.rb +2 -2
- data/lib/twilio-ruby/rest/studio/v1/flow/execution/execution_step.rb +13 -5
- data/lib/twilio-ruby/rest/studio/v1/flow/execution.rb +18 -10
- data/lib/twilio-ruby/rest/studio/v1/flow.rb +13 -5
- data/lib/twilio-ruby/rest/studio/v1.rb +1 -0
- data/lib/twilio-ruby/rest/studio/v2/flow/execution/execution_context.rb +2 -2
- data/lib/twilio-ruby/rest/studio/v2/flow/execution/execution_step/execution_step_context.rb +2 -2
- data/lib/twilio-ruby/rest/studio/v2/flow/execution/execution_step.rb +13 -5
- data/lib/twilio-ruby/rest/studio/v2/flow/execution.rb +37 -14
- data/lib/twilio-ruby/rest/studio/v2/flow/flow_revision.rb +13 -5
- data/lib/twilio-ruby/rest/studio/v2/flow/flow_test_user.rb +4 -4
- data/lib/twilio-ruby/rest/studio/v2/flow.rb +42 -19
- data/lib/twilio-ruby/rest/studio/v2/flow_validate.rb +6 -6
- data/lib/twilio-ruby/rest/studio/v2.rb +1 -0
- data/lib/twilio-ruby/rest/supersim/v1/esim_profile.rb +17 -9
- data/lib/twilio-ruby/rest/supersim/v1/fleet.rb +36 -28
- data/lib/twilio-ruby/rest/supersim/v1/ip_command.rb +19 -11
- data/lib/twilio-ruby/rest/supersim/v1/network.rb +13 -5
- data/lib/twilio-ruby/rest/supersim/v1/network_access_profile/network_access_profile_network.rb +14 -6
- data/lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb +17 -9
- data/lib/twilio-ruby/rest/supersim/v1/settings_update.rb +13 -5
- data/lib/twilio-ruby/rest/supersim/v1/sim/billing_period.rb +13 -5
- data/lib/twilio-ruby/rest/supersim/v1/sim/sim_ip_address.rb +13 -5
- data/lib/twilio-ruby/rest/supersim/v1/sim.rb +27 -19
- data/lib/twilio-ruby/rest/supersim/v1/sms_command.rb +17 -9
- data/lib/twilio-ruby/rest/supersim/v1/usage_record.rb +13 -5
- data/lib/twilio-ruby/rest/supersim/v1.rb +7 -0
- data/lib/twilio-ruby/rest/sync/v1/service/document/document_permission.rb +19 -11
- data/lib/twilio-ruby/rest/sync/v1/service/document.rb +22 -14
- data/lib/twilio-ruby/rest/sync/v1/service/sync_list/sync_list_item.rb +29 -21
- data/lib/twilio-ruby/rest/sync/v1/service/sync_list/sync_list_permission.rb +19 -11
- data/lib/twilio-ruby/rest/sync/v1/service/sync_list.rb +20 -12
- data/lib/twilio-ruby/rest/sync/v1/service/sync_map/sync_map_item.rb +30 -22
- data/lib/twilio-ruby/rest/sync/v1/service/sync_map/sync_map_permission.rb +19 -11
- data/lib/twilio-ruby/rest/sync/v1/service/sync_map.rb +20 -12
- data/lib/twilio-ruby/rest/sync/v1/service/sync_stream/stream_message.rb +3 -3
- data/lib/twilio-ruby/rest/sync/v1/service/sync_stream.rb +17 -9
- data/lib/twilio-ruby/rest/sync/v1/service.rb +34 -26
- data/lib/twilio-ruby/rest/sync/v1.rb +1 -0
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/activity.rb +17 -9
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/event.rb +13 -5
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task/reservation.rb +123 -115
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task.rb +38 -30
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_channel.rb +20 -12
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue/task_queue_bulk_real_time_statistics.rb +2 -2
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue/task_queue_cumulative_statistics.rb +12 -12
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue/task_queue_real_time_statistics.rb +4 -4
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue/task_queue_statistics.rb +12 -12
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue/task_queues_statistics.rb +13 -5
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue.rb +31 -23
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker/reservation.rb +119 -111
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker/worker_channel.rb +17 -9
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker/worker_statistics.rb +10 -10
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker/workers_cumulative_statistics.rb +10 -10
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker/workers_real_time_statistics.rb +4 -4
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker/workers_statistics.rb +16 -16
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker.rb +28 -20
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workflow/workflow_cumulative_statistics.rb +12 -12
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workflow/workflow_real_time_statistics.rb +4 -4
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workflow/workflow_statistics.rb +12 -12
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workflow.rb +30 -22
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workspace_cumulative_statistics.rb +12 -12
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workspace_real_time_statistics.rb +4 -4
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workspace_statistics.rb +12 -12
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace.rb +33 -25
- data/lib/twilio-ruby/rest/taskrouter/v1.rb +1 -0
- data/lib/twilio-ruby/rest/trunking/v1/trunk/credential_list.rb +14 -6
- data/lib/twilio-ruby/rest/trunking/v1/trunk/ip_access_control_list.rb +14 -6
- data/lib/twilio-ruby/rest/trunking/v1/trunk/origination_url.rb +28 -20
- data/lib/twilio-ruby/rest/trunking/v1/trunk/phone_number.rb +14 -6
- data/lib/twilio-ruby/rest/trunking/v1/trunk/recording.rb +6 -6
- data/lib/twilio-ruby/rest/trunking/v1/trunk.rb +37 -29
- data/lib/twilio-ruby/rest/trunking/v1.rb +1 -0
- data/lib/twilio-ruby/rest/trusthub/v1/compliance_inquiries.rb +9 -9
- data/lib/twilio-ruby/rest/trusthub/v1/compliance_registration_inquiries.rb +45 -45
- data/lib/twilio-ruby/rest/trusthub/v1/compliance_tollfree_inquiries.rb +40 -40
- data/lib/twilio-ruby/rest/trusthub/v1/customer_profiles/customer_profiles_channel_endpoint_assignment.rb +15 -7
- data/lib/twilio-ruby/rest/trusthub/v1/customer_profiles/customer_profiles_entity_assignments.rb +14 -6
- data/lib/twilio-ruby/rest/trusthub/v1/customer_profiles/customer_profiles_evaluations.rb +14 -6
- data/lib/twilio-ruby/rest/trusthub/v1/customer_profiles.rb +25 -17
- data/lib/twilio-ruby/rest/trusthub/v1/end_user.rb +20 -12
- data/lib/twilio-ruby/rest/trusthub/v1/end_user_type.rb +13 -5
- data/lib/twilio-ruby/rest/trusthub/v1/policies.rb +13 -5
- data/lib/twilio-ruby/rest/trusthub/v1/supporting_document.rb +20 -12
- data/lib/twilio-ruby/rest/trusthub/v1/supporting_document_type.rb +13 -5
- data/lib/twilio-ruby/rest/trusthub/v1/trust_products/trust_products_channel_endpoint_assignment.rb +15 -7
- data/lib/twilio-ruby/rest/trusthub/v1/trust_products/trust_products_entity_assignments.rb +14 -6
- data/lib/twilio-ruby/rest/trusthub/v1/trust_products/trust_products_evaluations.rb +14 -6
- data/lib/twilio-ruby/rest/trusthub/v1/trust_products.rb +25 -17
- data/lib/twilio-ruby/rest/trusthub/v1.rb +9 -0
- data/lib/twilio-ruby/rest/verify/v2/form.rb +2 -2
- data/lib/twilio-ruby/rest/verify/v2/safelist.rb +3 -3
- data/lib/twilio-ruby/rest/verify/v2/service/access_token.rb +6 -6
- data/lib/twilio-ruby/rest/verify/v2/service/approve_challenge.rb +9 -9
- data/lib/twilio-ruby/rest/verify/v2/service/entity/challenge/notification.rb +3 -3
- data/lib/twilio-ruby/rest/verify/v2/service/entity/challenge.rb +23 -15
- data/lib/twilio-ruby/rest/verify/v2/service/entity/factor.rb +31 -23
- data/lib/twilio-ruby/rest/verify/v2/service/entity/new_factor.rb +16 -16
- data/lib/twilio-ruby/rest/verify/v2/service/entity.rb +14 -6
- data/lib/twilio-ruby/rest/verify/v2/service/messaging_configuration.rb +17 -9
- data/lib/twilio-ruby/rest/verify/v2/service/new_challenge.rb +10 -9
- data/lib/twilio-ruby/rest/verify/v2/service/new_factor.rb +2 -2
- data/lib/twilio-ruby/rest/verify/v2/service/new_verify_factor.rb +2 -2
- data/lib/twilio-ruby/rest/verify/v2/service/rate_limit/bucket.rb +19 -11
- data/lib/twilio-ruby/rest/verify/v2/service/rate_limit.rb +17 -9
- data/lib/twilio-ruby/rest/verify/v2/service/verification.rb +24 -24
- data/lib/twilio-ruby/rest/verify/v2/service/verification_check.rb +8 -8
- data/lib/twilio-ruby/rest/verify/v2/service/webhook.rb +40 -32
- data/lib/twilio-ruby/rest/verify/v2/service.rb +91 -83
- data/lib/twilio-ruby/rest/verify/v2/template.rb +13 -5
- data/lib/twilio-ruby/rest/verify/v2/verification_attempt.rb +13 -5
- data/lib/twilio-ruby/rest/verify/v2/verification_attempts_summary.rb +14 -14
- data/lib/twilio-ruby/rest/verify/v2.rb +4 -0
- data/lib/twilio-ruby/rest/video/v1/composition.rb +22 -14
- data/lib/twilio-ruby/rest/video/v1/composition_hook.rb +43 -35
- data/lib/twilio-ruby/rest/video/v1/composition_settings.rb +14 -14
- data/lib/twilio-ruby/rest/video/v1/recording.rb +13 -5
- data/lib/twilio-ruby/rest/video/v1/recording_settings.rb +14 -14
- data/lib/twilio-ruby/rest/video/v1/room/participant/anonymize.rb +2 -2
- data/lib/twilio-ruby/rest/video/v1/room/participant/published_track.rb +13 -5
- data/lib/twilio-ruby/rest/video/v1/room/participant/subscribe_rules.rb +3 -3
- data/lib/twilio-ruby/rest/video/v1/room/participant/subscribed_track.rb +13 -5
- data/lib/twilio-ruby/rest/video/v1/room/participant.rb +15 -7
- data/lib/twilio-ruby/rest/video/v1/room/recording_rules.rb +3 -3
- data/lib/twilio-ruby/rest/video/v1/room/room_recording.rb +13 -5
- data/lib/twilio-ruby/rest/video/v1/room/transcriptions.rb +18 -10
- data/lib/twilio-ruby/rest/video/v1/room.rb +32 -24
- data/lib/twilio-ruby/rest/video/v1.rb +4 -0
- data/lib/twilio-ruby/rest/voice/v1/archived_call.rb +2 -2
- data/lib/twilio-ruby/rest/voice/v1/byoc_trunk.rb +43 -35
- data/lib/twilio-ruby/rest/voice/v1/connection_policy/connection_policy_target.rb +28 -20
- data/lib/twilio-ruby/rest/voice/v1/connection_policy.rb +16 -8
- data/lib/twilio-ruby/rest/voice/v1/dialing_permissions/bulk_country_update.rb +3 -3
- data/lib/twilio-ruby/rest/voice/v1/dialing_permissions/country/highrisk_special_prefix.rb +13 -5
- data/lib/twilio-ruby/rest/voice/v1/dialing_permissions/country.rb +13 -5
- data/lib/twilio-ruby/rest/voice/v1/dialing_permissions/settings.rb +4 -4
- data/lib/twilio-ruby/rest/voice/v1/dialing_permissions.rb +2 -2
- data/lib/twilio-ruby/rest/voice/v1/ip_record.rb +18 -10
- data/lib/twilio-ruby/rest/voice/v1/source_ip_mapping.rb +17 -9
- data/lib/twilio-ruby/rest/voice/v1.rb +10 -0
- data/lib/twilio-ruby/rest/voice/v3/transcription.rb +514 -0
- data/lib/twilio-ruby/rest/voice/v3.rb +50 -0
- data/lib/twilio-ruby/rest/voice_base.rb +6 -1
- data/lib/twilio-ruby/rest/wireless/v1/command.rb +20 -12
- data/lib/twilio-ruby/rest/wireless/v1/rate_plan.rb +29 -21
- data/lib/twilio-ruby/rest/wireless/v1/sim/data_session.rb +13 -5
- data/lib/twilio-ruby/rest/wireless/v1/sim/usage_record.rb +13 -5
- data/lib/twilio-ruby/rest/wireless/v1/sim.rb +49 -41
- data/lib/twilio-ruby/rest/wireless/v1/usage_record.rb +13 -5
- data/lib/twilio-ruby/rest/wireless/v1.rb +3 -0
- data/lib/twilio-ruby/twiml/voice_response.rb +20 -11
- data/lib/twilio-ruby/version.rb +1 -1
- data/twilio-ruby.gemspec +1 -1
- metadata +49 -5
|
@@ -0,0 +1,904 @@
|
|
|
1
|
+
##
|
|
2
|
+
# This code was generated by
|
|
3
|
+
# ___ _ _ _ _ _ _ ____ ____ ____ _ ____ ____ _ _ ____ ____ ____ ___ __ __
|
|
4
|
+
# | | | | | | | | | __ | | |__| | __ | __ |___ |\ | |___ |__/ |__| | | | |__/
|
|
5
|
+
# | |_|_| | |___ | |__| |__| | | | |__] |___ | \| |___ | \ | | | |__| | \
|
|
6
|
+
#
|
|
7
|
+
# Twilio Memory API
|
|
8
|
+
# APIs for managing memory stores, profiles, events, and conversational intelligence capabilities.
|
|
9
|
+
#
|
|
10
|
+
# NOTE: This class is auto generated by OpenAPI Generator.
|
|
11
|
+
# https://openapi-generator.tech
|
|
12
|
+
# Do not edit the class manually.
|
|
13
|
+
#
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
module Twilio
|
|
17
|
+
module REST
|
|
18
|
+
class Memory < MemoryBase
|
|
19
|
+
class V1 < Version
|
|
20
|
+
class TraitGroupList < ListResource
|
|
21
|
+
|
|
22
|
+
class PatchTraitGroupRequest
|
|
23
|
+
# @param [description]: [String] Updated description of the Trait Group
|
|
24
|
+
# @param [traits]: [Hash<String, TraitDefinition>] Map of traits to add, update, or remove in this Trait Group, where the key is the trait name. - To update/add a trait: provide the complete TraitDefinition object - To remove a trait: set dataType to an empty string (\"\")
|
|
25
|
+
attr_accessor :description, :traits
|
|
26
|
+
def initialize(payload)
|
|
27
|
+
@description = payload["description"]
|
|
28
|
+
@traits = payload["traits"]
|
|
29
|
+
end
|
|
30
|
+
def to_json(options = {})
|
|
31
|
+
{
|
|
32
|
+
"description": @description,
|
|
33
|
+
"traits": @traits,
|
|
34
|
+
}.to_json(options)
|
|
35
|
+
end
|
|
36
|
+
end
|
|
37
|
+
|
|
38
|
+
class TraitDefinition
|
|
39
|
+
# @param [data_type]: [String] Data type of the Trait, such as STRING, NUMBER, BOOLEAN, ARRAY. For DELETE operations in PATCH requests, set this to an empty string (\"\") to mark the trait for deletion.
|
|
40
|
+
# @param [description]: [String] Description of the Trait, providing additional context or information.
|
|
41
|
+
# @param [id_type_promotion]: [String] The name of the identifier type to promote the trait value to, such as ''email'', ''phone'', ''user_id'', etc. This allows the trait to be mapped to an identifier in Identity Resolution. The identifier type should be configured in the Identity Resolution Settings.
|
|
42
|
+
attr_accessor :data_type, :description, :id_type_promotion
|
|
43
|
+
def initialize(payload)
|
|
44
|
+
@data_type = payload["data_type"]
|
|
45
|
+
@description = payload["description"]
|
|
46
|
+
@id_type_promotion = payload["id_type_promotion"]
|
|
47
|
+
end
|
|
48
|
+
def to_json(options = {})
|
|
49
|
+
{
|
|
50
|
+
"dataType": @data_type,
|
|
51
|
+
"description": @description,
|
|
52
|
+
"idTypePromotion": @id_type_promotion,
|
|
53
|
+
}.to_json(options)
|
|
54
|
+
end
|
|
55
|
+
end
|
|
56
|
+
|
|
57
|
+
class TraitGroupRequest
|
|
58
|
+
# @param [display_name]: [String] Unique name of the Trait Group
|
|
59
|
+
# @param [description]: [String] description of the Trait Group
|
|
60
|
+
# @param [traits]: [Hash<String, TraitGroupCoreTraitsValue>] Map of traits belonging to this Trait Group, keyed by trait name.
|
|
61
|
+
attr_accessor :display_name, :description, :traits
|
|
62
|
+
def initialize(payload)
|
|
63
|
+
@display_name = payload["display_name"]
|
|
64
|
+
@description = payload["description"]
|
|
65
|
+
@traits = payload["traits"]
|
|
66
|
+
end
|
|
67
|
+
def to_json(options = {})
|
|
68
|
+
{
|
|
69
|
+
"displayName": @display_name,
|
|
70
|
+
"description": @description,
|
|
71
|
+
"traits": @traits,
|
|
72
|
+
}.to_json(options)
|
|
73
|
+
end
|
|
74
|
+
end
|
|
75
|
+
|
|
76
|
+
class ValidationRule
|
|
77
|
+
# @param [pattern]: [String] Regex pattern (max 1000 chars)
|
|
78
|
+
# @param [min_length]: [Integer] Minimum string length
|
|
79
|
+
# @param [max_length]: [Integer] Maximum string length
|
|
80
|
+
# @param [rule_type]: [String] Discriminator field indicating this is an array validation rule.
|
|
81
|
+
# @param [min]: [Float] Minimum value
|
|
82
|
+
# @param [max]: [Float] Maximum value
|
|
83
|
+
# @param [min_items]: [Integer] Minimum number of items
|
|
84
|
+
# @param [max_items]: [Integer] Maximum number of items
|
|
85
|
+
attr_accessor :pattern, :min_length, :max_length, :rule_type, :min, :max, :min_items, :max_items
|
|
86
|
+
def initialize(payload)
|
|
87
|
+
@pattern = payload["pattern"]
|
|
88
|
+
@min_length = payload["min_length"]
|
|
89
|
+
@max_length = payload["max_length"]
|
|
90
|
+
@rule_type = payload["rule_type"]
|
|
91
|
+
@min = payload["min"]
|
|
92
|
+
@max = payload["max"]
|
|
93
|
+
@min_items = payload["min_items"]
|
|
94
|
+
@max_items = payload["max_items"]
|
|
95
|
+
end
|
|
96
|
+
def to_json(options = {})
|
|
97
|
+
{
|
|
98
|
+
"pattern": @pattern,
|
|
99
|
+
"minLength": @min_length,
|
|
100
|
+
"maxLength": @max_length,
|
|
101
|
+
"ruleType": @rule_type,
|
|
102
|
+
"min": @min,
|
|
103
|
+
"max": @max,
|
|
104
|
+
"minItems": @min_items,
|
|
105
|
+
"maxItems": @max_items,
|
|
106
|
+
}.to_json(options)
|
|
107
|
+
end
|
|
108
|
+
end
|
|
109
|
+
|
|
110
|
+
|
|
111
|
+
class PatchTraitGroupRequest
|
|
112
|
+
# @param [description]: [String] Updated description of the Trait Group
|
|
113
|
+
# @param [traits]: [Hash<String, TraitDefinition>] Map of traits to add, update, or remove in this Trait Group, where the key is the trait name. - To update/add a trait: provide the complete TraitDefinition object - To remove a trait: set dataType to an empty string (\"\")
|
|
114
|
+
attr_accessor :description, :traits
|
|
115
|
+
def initialize(payload)
|
|
116
|
+
@description = payload["description"]
|
|
117
|
+
@traits = payload["traits"]
|
|
118
|
+
end
|
|
119
|
+
def to_json(options = {})
|
|
120
|
+
{
|
|
121
|
+
"description": @description,
|
|
122
|
+
"traits": @traits,
|
|
123
|
+
}.to_json(options)
|
|
124
|
+
end
|
|
125
|
+
end
|
|
126
|
+
|
|
127
|
+
class TraitDefinition
|
|
128
|
+
# @param [data_type]: [String] Data type of the Trait, such as STRING, NUMBER, BOOLEAN, ARRAY. For DELETE operations in PATCH requests, set this to an empty string (\"\") to mark the trait for deletion.
|
|
129
|
+
# @param [description]: [String] Description of the Trait, providing additional context or information.
|
|
130
|
+
# @param [id_type_promotion]: [String] The name of the identifier type to promote the trait value to, such as ''email'', ''phone'', ''user_id'', etc. This allows the trait to be mapped to an identifier in Identity Resolution. The identifier type should be configured in the Identity Resolution Settings.
|
|
131
|
+
attr_accessor :data_type, :description, :id_type_promotion
|
|
132
|
+
def initialize(payload)
|
|
133
|
+
@data_type = payload["data_type"]
|
|
134
|
+
@description = payload["description"]
|
|
135
|
+
@id_type_promotion = payload["id_type_promotion"]
|
|
136
|
+
end
|
|
137
|
+
def to_json(options = {})
|
|
138
|
+
{
|
|
139
|
+
"dataType": @data_type,
|
|
140
|
+
"description": @description,
|
|
141
|
+
"idTypePromotion": @id_type_promotion,
|
|
142
|
+
}.to_json(options)
|
|
143
|
+
end
|
|
144
|
+
end
|
|
145
|
+
|
|
146
|
+
class TraitGroupRequest
|
|
147
|
+
# @param [display_name]: [String] Unique name of the Trait Group
|
|
148
|
+
# @param [description]: [String] description of the Trait Group
|
|
149
|
+
# @param [traits]: [Hash<String, TraitGroupCoreTraitsValue>] Map of traits belonging to this Trait Group, keyed by trait name.
|
|
150
|
+
attr_accessor :display_name, :description, :traits
|
|
151
|
+
def initialize(payload)
|
|
152
|
+
@display_name = payload["display_name"]
|
|
153
|
+
@description = payload["description"]
|
|
154
|
+
@traits = payload["traits"]
|
|
155
|
+
end
|
|
156
|
+
def to_json(options = {})
|
|
157
|
+
{
|
|
158
|
+
"displayName": @display_name,
|
|
159
|
+
"description": @description,
|
|
160
|
+
"traits": @traits,
|
|
161
|
+
}.to_json(options)
|
|
162
|
+
end
|
|
163
|
+
end
|
|
164
|
+
|
|
165
|
+
class ValidationRule
|
|
166
|
+
# @param [pattern]: [String] Regex pattern (max 1000 chars)
|
|
167
|
+
# @param [min_length]: [Integer] Minimum string length
|
|
168
|
+
# @param [max_length]: [Integer] Maximum string length
|
|
169
|
+
# @param [rule_type]: [String] Discriminator field indicating this is an array validation rule.
|
|
170
|
+
# @param [min]: [Float] Minimum value
|
|
171
|
+
# @param [max]: [Float] Maximum value
|
|
172
|
+
# @param [min_items]: [Integer] Minimum number of items
|
|
173
|
+
# @param [max_items]: [Integer] Maximum number of items
|
|
174
|
+
attr_accessor :pattern, :min_length, :max_length, :rule_type, :min, :max, :min_items, :max_items
|
|
175
|
+
def initialize(payload)
|
|
176
|
+
@pattern = payload["pattern"]
|
|
177
|
+
@min_length = payload["min_length"]
|
|
178
|
+
@max_length = payload["max_length"]
|
|
179
|
+
@rule_type = payload["rule_type"]
|
|
180
|
+
@min = payload["min"]
|
|
181
|
+
@max = payload["max"]
|
|
182
|
+
@min_items = payload["min_items"]
|
|
183
|
+
@max_items = payload["max_items"]
|
|
184
|
+
end
|
|
185
|
+
def to_json(options = {})
|
|
186
|
+
{
|
|
187
|
+
"pattern": @pattern,
|
|
188
|
+
"minLength": @min_length,
|
|
189
|
+
"maxLength": @max_length,
|
|
190
|
+
"ruleType": @rule_type,
|
|
191
|
+
"min": @min,
|
|
192
|
+
"max": @max,
|
|
193
|
+
"minItems": @min_items,
|
|
194
|
+
"maxItems": @max_items,
|
|
195
|
+
}.to_json(options)
|
|
196
|
+
end
|
|
197
|
+
end
|
|
198
|
+
|
|
199
|
+
|
|
200
|
+
##
|
|
201
|
+
# Initialize the TraitGroupList
|
|
202
|
+
# @param [Version] version Version that contains the resource
|
|
203
|
+
# @return [TraitGroupList] TraitGroupList
|
|
204
|
+
def initialize(version, store_id: nil)
|
|
205
|
+
|
|
206
|
+
apiV1Version = ApiV1Version.new version.domain, version
|
|
207
|
+
super(apiV1Version)
|
|
208
|
+
# Path Solution
|
|
209
|
+
@solution = { store_id: store_id }
|
|
210
|
+
@uri = "/ControlPlane/Stores/#{@solution[:store_id]}/TraitGroups"
|
|
211
|
+
|
|
212
|
+
end
|
|
213
|
+
##
|
|
214
|
+
# Create the TraitGroupInstance
|
|
215
|
+
# @param [TraitGroupRequest] trait_group_request
|
|
216
|
+
# @return [TraitGroupInstance] Created TraitGroupInstance
|
|
217
|
+
def create(trait_group_request: :unset
|
|
218
|
+
)
|
|
219
|
+
|
|
220
|
+
headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', })
|
|
221
|
+
headers['Content-Type'] = 'application/json'
|
|
222
|
+
|
|
223
|
+
|
|
224
|
+
|
|
225
|
+
|
|
226
|
+
payload = @version.create('POST', @uri, headers: headers, data: trait_group_request.to_json)
|
|
227
|
+
TraitGroupInstance.new(
|
|
228
|
+
@version,
|
|
229
|
+
payload,
|
|
230
|
+
store_id: @solution[:store_id],
|
|
231
|
+
)
|
|
232
|
+
end
|
|
233
|
+
|
|
234
|
+
##
|
|
235
|
+
# Create the TraitGroupInstanceMetadata
|
|
236
|
+
# @param [TraitGroupRequest] trait_group_request
|
|
237
|
+
# @return [TraitGroupInstance] Created TraitGroupInstance
|
|
238
|
+
def create_with_metadata(trait_group_request: :unset
|
|
239
|
+
)
|
|
240
|
+
|
|
241
|
+
headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', })
|
|
242
|
+
headers['Content-Type'] = 'application/json'
|
|
243
|
+
|
|
244
|
+
|
|
245
|
+
|
|
246
|
+
|
|
247
|
+
response = @version.create_with_metadata('POST', @uri, headers: headers, data: trait_group_request.to_json)
|
|
248
|
+
trait_group_instance = TraitGroupInstance.new(
|
|
249
|
+
@version,
|
|
250
|
+
response.body,
|
|
251
|
+
store_id: @solution[:store_id],
|
|
252
|
+
)
|
|
253
|
+
TraitGroupInstanceMetadata.new(
|
|
254
|
+
@version,
|
|
255
|
+
trait_group_instance,
|
|
256
|
+
response.headers,
|
|
257
|
+
response.status_code
|
|
258
|
+
)
|
|
259
|
+
end
|
|
260
|
+
|
|
261
|
+
|
|
262
|
+
##
|
|
263
|
+
# Lists TraitGroupInstance records from the API as a list.
|
|
264
|
+
# Unlike stream(), this operation is eager and will load `limit` records into
|
|
265
|
+
# memory before returning.
|
|
266
|
+
# @param [Boolean] include_traits Whether to include trait definitions in the response
|
|
267
|
+
# @param [String] page_token The token for the page of results to retrieve.
|
|
268
|
+
# @param [String] order_by Either 'ASC' or 'DESC' to sort results ascending or descending respectively.
|
|
269
|
+
# @param [Integer] limit Upper limit for the number of records to return. stream()
|
|
270
|
+
# guarantees to never return more than limit. Default is no limit
|
|
271
|
+
# @param [Integer] page_size Number of records to fetch per request, when
|
|
272
|
+
# not set will use the default value of 50 records. If no page_size is defined
|
|
273
|
+
# but a limit is defined, stream() will attempt to read the limit with the most
|
|
274
|
+
# efficient page size, i.e. min(limit, 1000)
|
|
275
|
+
# @return [Array] Array of up to limit results
|
|
276
|
+
def list(include_traits: :unset, page_token: :unset, order_by: :unset, limit: nil, page_size: nil)
|
|
277
|
+
self.stream(
|
|
278
|
+
include_traits: include_traits,
|
|
279
|
+
page_token: page_token,
|
|
280
|
+
order_by: order_by,
|
|
281
|
+
limit: limit,
|
|
282
|
+
page_size: page_size
|
|
283
|
+
).entries
|
|
284
|
+
end
|
|
285
|
+
|
|
286
|
+
##
|
|
287
|
+
# Streams Instance records from the API as an Enumerable.
|
|
288
|
+
# This operation lazily loads records as efficiently as possible until the limit
|
|
289
|
+
# is reached.
|
|
290
|
+
# @param [Boolean] include_traits Whether to include trait definitions in the response
|
|
291
|
+
# @param [String] page_token The token for the page of results to retrieve.
|
|
292
|
+
# @param [String] order_by Either 'ASC' or 'DESC' to sort results ascending or descending respectively.
|
|
293
|
+
# @param [Integer] limit Upper limit for the number of records to return. stream()
|
|
294
|
+
# guarantees to never return more than limit. Default is no limit
|
|
295
|
+
# @param [Integer] page_size Number of records to fetch per request, when
|
|
296
|
+
# not set will use the default value of 50 records. If no page_size is defined
|
|
297
|
+
# but a limit is defined, stream() will attempt to read the limit with the most
|
|
298
|
+
# efficient page size, i.e. min(limit, 1000)
|
|
299
|
+
# @return [Enumerable] Enumerable that will yield up to limit results
|
|
300
|
+
def stream(include_traits: :unset, page_token: :unset, order_by: :unset, limit: nil, page_size: nil)
|
|
301
|
+
limits = @version.read_limits(limit, page_size)
|
|
302
|
+
|
|
303
|
+
page = self.page(
|
|
304
|
+
include_traits: include_traits,
|
|
305
|
+
page_token: page_token,
|
|
306
|
+
order_by: order_by,
|
|
307
|
+
page_size: limits[:page_size], )
|
|
308
|
+
|
|
309
|
+
return [].each if page.nil?
|
|
310
|
+
|
|
311
|
+
result = @version.stream(page, limit: limits[:limit], page_limit: limits[:page_limit])
|
|
312
|
+
return [].each if result.nil?
|
|
313
|
+
result
|
|
314
|
+
end
|
|
315
|
+
|
|
316
|
+
##
|
|
317
|
+
# Lists TraitGroupPageMetadata records from the API as a list.
|
|
318
|
+
# @param [Boolean] include_traits Whether to include trait definitions in the response
|
|
319
|
+
# @param [String] page_token The token for the page of results to retrieve.
|
|
320
|
+
# @param [String] order_by Either 'ASC' or 'DESC' to sort results ascending or descending respectively.
|
|
321
|
+
# @param [Integer] limit Upper limit for the number of records to return. stream()
|
|
322
|
+
# guarantees to never return more than limit. Default is no limit
|
|
323
|
+
# @param [Integer] page_size Number of records to fetch per request, when
|
|
324
|
+
# not set will use the default value of 50 records. If no page_size is defined
|
|
325
|
+
# but a limit is defined, stream() will attempt to read the limit with the most
|
|
326
|
+
# efficient page size, i.e. min(limit, 1000)
|
|
327
|
+
# @return [Array] Array of up to limit results
|
|
328
|
+
def list_with_metadata(include_traits: :unset, page_token: :unset, order_by: :unset, limit: nil, page_size: nil)
|
|
329
|
+
limits = @version.read_limits(limit, page_size)
|
|
330
|
+
params = Twilio::Values.of({
|
|
331
|
+
'includeTraits' => include_traits,
|
|
332
|
+
'pageToken' => page_token,
|
|
333
|
+
'orderBy' => order_by,
|
|
334
|
+
|
|
335
|
+
'PageSize' => limits[:page_size],
|
|
336
|
+
});
|
|
337
|
+
headers = Twilio::Values.of({})
|
|
338
|
+
|
|
339
|
+
response = @version.page('GET', @uri, params: params, headers: headers)
|
|
340
|
+
|
|
341
|
+
TraitGroupPageMetadata.new(@version, response, @solution, limits[:limit])
|
|
342
|
+
end
|
|
343
|
+
|
|
344
|
+
##
|
|
345
|
+
# When passed a block, yields TraitGroupInstance records from the API.
|
|
346
|
+
# This operation lazily loads records as efficiently as possible until the limit
|
|
347
|
+
# is reached.
|
|
348
|
+
def each
|
|
349
|
+
limits = @version.read_limits
|
|
350
|
+
|
|
351
|
+
page = self.page(page_size: limits[:page_size], )
|
|
352
|
+
|
|
353
|
+
return [].each if page.nil?
|
|
354
|
+
|
|
355
|
+
result = @version.stream(page,
|
|
356
|
+
limit: limits[:limit],
|
|
357
|
+
page_limit: limits[:page_limit])
|
|
358
|
+
return [].each if result.nil?
|
|
359
|
+
result.each {|x| yield x}
|
|
360
|
+
end
|
|
361
|
+
|
|
362
|
+
##
|
|
363
|
+
# Retrieve a single page of TraitGroupInstance records from the API.
|
|
364
|
+
# Request is executed immediately.
|
|
365
|
+
# @param [Boolean] include_traits Whether to include trait definitions in the response
|
|
366
|
+
# @param [String] page_token The token for the page of results to retrieve.
|
|
367
|
+
# @param [String] order_by Either 'ASC' or 'DESC' to sort results ascending or descending respectively.
|
|
368
|
+
|
|
369
|
+
# @return [Page] Page of TraitGroupInstance
|
|
370
|
+
def page(include_traits: :unset, page_token: :unset, order_by: :unset, page_size: :unset)
|
|
371
|
+
params = Twilio::Values.of({
|
|
372
|
+
'includeTraits' => include_traits,
|
|
373
|
+
'pageToken' => page_token,
|
|
374
|
+
'orderBy' => order_by,
|
|
375
|
+
'PageSize' => page_size,
|
|
376
|
+
})
|
|
377
|
+
headers = Twilio::Values.of({})
|
|
378
|
+
|
|
379
|
+
|
|
380
|
+
|
|
381
|
+
response = @version.page('GET', @uri, params: params, headers: headers)
|
|
382
|
+
|
|
383
|
+
TraitGroupPage.new(@version, response, @solution)
|
|
384
|
+
end
|
|
385
|
+
|
|
386
|
+
##
|
|
387
|
+
# Retrieve a single page of TraitGroupInstance records from the API.
|
|
388
|
+
# Request is executed immediately.
|
|
389
|
+
# @param [String] target_url API-generated URL for the requested results page
|
|
390
|
+
# @return [Page] Page of TraitGroupInstance
|
|
391
|
+
def get_page(target_url)
|
|
392
|
+
response = @version.domain.request(
|
|
393
|
+
'GET',
|
|
394
|
+
target_url
|
|
395
|
+
)
|
|
396
|
+
TraitGroupPage.new(@version, response, @solution)
|
|
397
|
+
end
|
|
398
|
+
|
|
399
|
+
|
|
400
|
+
|
|
401
|
+
# Provide a user friendly representation
|
|
402
|
+
def to_s
|
|
403
|
+
'#<Twilio.Memory.V1.TraitGroupList>'
|
|
404
|
+
end
|
|
405
|
+
end
|
|
406
|
+
|
|
407
|
+
|
|
408
|
+
class TraitGroupContext < InstanceContext
|
|
409
|
+
##
|
|
410
|
+
# Initialize the TraitGroupContext
|
|
411
|
+
# @param [Version] version Version that contains the resource
|
|
412
|
+
# @param [String] store_id A unique Memory Store ID using Twilio Type ID (TTID) format
|
|
413
|
+
# @param [String] trait_group_name A unique Name of the TraitGroup
|
|
414
|
+
# @return [TraitGroupContext] TraitGroupContext
|
|
415
|
+
def initialize(version, store_id, trait_group_name)
|
|
416
|
+
|
|
417
|
+
apiV1Version = ApiV1Version.new version.domain, version
|
|
418
|
+
super(apiV1Version)
|
|
419
|
+
|
|
420
|
+
# Path Solution
|
|
421
|
+
@solution = { store_id: store_id, trait_group_name: trait_group_name, }
|
|
422
|
+
@uri = "/ControlPlane/Stores/#{@solution[:store_id]}/TraitGroups/#{@solution[:trait_group_name]}"
|
|
423
|
+
|
|
424
|
+
|
|
425
|
+
end
|
|
426
|
+
##
|
|
427
|
+
# Delete the TraitGroupInstance
|
|
428
|
+
# @return [Boolean] True if delete succeeds, false otherwise
|
|
429
|
+
def delete
|
|
430
|
+
|
|
431
|
+
headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', })
|
|
432
|
+
|
|
433
|
+
|
|
434
|
+
|
|
435
|
+
response = @version.delete_with_metadata('DELETE', @uri, headers: headers)
|
|
436
|
+
TraitGroupInstance.new(
|
|
437
|
+
@version,
|
|
438
|
+
response.body,
|
|
439
|
+
store_id: @solution[:store_id],
|
|
440
|
+
trait_group_name: @solution[:trait_group_name],
|
|
441
|
+
)
|
|
442
|
+
|
|
443
|
+
end
|
|
444
|
+
|
|
445
|
+
##
|
|
446
|
+
# Delete the TraitGroupInstanceMetadata
|
|
447
|
+
# @return [Boolean] True if delete succeeds, false otherwise
|
|
448
|
+
def delete_with_metadata
|
|
449
|
+
|
|
450
|
+
headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', })
|
|
451
|
+
|
|
452
|
+
|
|
453
|
+
|
|
454
|
+
response = @version.delete_with_metadata('DELETE', @uri, headers: headers)
|
|
455
|
+
traitGroup_instance = TraitGroupInstance.new(
|
|
456
|
+
@version,
|
|
457
|
+
response.body,
|
|
458
|
+
account_sid: @solution[:account_sid],
|
|
459
|
+
sid: @solution[:sid],
|
|
460
|
+
)
|
|
461
|
+
TraitGroupInstanceMetadata.new(@version, traitGroup_instance, response.headers, response.status_code)
|
|
462
|
+
end
|
|
463
|
+
|
|
464
|
+
##
|
|
465
|
+
# Fetch the TraitGroupInstance
|
|
466
|
+
# @param [Boolean] include_traits Whether to include trait definitions in the response
|
|
467
|
+
# @param [String] page_size The maximum number of items to return per page, maximum of 100.
|
|
468
|
+
# @param [String] page_token The token for the page of results to retrieve.
|
|
469
|
+
# @param [String] order_by Either 'ASC' or 'DESC' to sort results ascending or descending respectively.
|
|
470
|
+
# @return [TraitGroupInstance] Fetched TraitGroupInstance
|
|
471
|
+
def fetch(
|
|
472
|
+
include_traits: :unset,
|
|
473
|
+
page_size: :unset,
|
|
474
|
+
page_token: :unset,
|
|
475
|
+
order_by: :unset
|
|
476
|
+
)
|
|
477
|
+
|
|
478
|
+
params = Twilio::Values.of({
|
|
479
|
+
'includeTraits' => include_traits,
|
|
480
|
+
'pageSize' => page_size,
|
|
481
|
+
'pageToken' => page_token,
|
|
482
|
+
'orderBy' => order_by,
|
|
483
|
+
})
|
|
484
|
+
headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', })
|
|
485
|
+
|
|
486
|
+
|
|
487
|
+
|
|
488
|
+
|
|
489
|
+
|
|
490
|
+
payload = @version.fetch('GET', @uri, params: params, headers: headers)
|
|
491
|
+
TraitGroupInstance.new(
|
|
492
|
+
@version,
|
|
493
|
+
payload,
|
|
494
|
+
store_id: @solution[:store_id],
|
|
495
|
+
trait_group_name: @solution[:trait_group_name],
|
|
496
|
+
)
|
|
497
|
+
end
|
|
498
|
+
|
|
499
|
+
##
|
|
500
|
+
# Fetch the TraitGroupInstanceMetadata
|
|
501
|
+
# @param [Boolean] include_traits Whether to include trait definitions in the response
|
|
502
|
+
# @param [String] page_size The maximum number of items to return per page, maximum of 100.
|
|
503
|
+
# @param [String] page_token The token for the page of results to retrieve.
|
|
504
|
+
# @param [String] order_by Either 'ASC' or 'DESC' to sort results ascending or descending respectively.
|
|
505
|
+
# @return [TraitGroupInstance] Fetched TraitGroupInstance
|
|
506
|
+
def fetch_with_metadata(
|
|
507
|
+
include_traits: :unset,
|
|
508
|
+
page_size: :unset,
|
|
509
|
+
page_token: :unset,
|
|
510
|
+
order_by: :unset
|
|
511
|
+
)
|
|
512
|
+
|
|
513
|
+
params = Twilio::Values.of({
|
|
514
|
+
'includeTraits' => include_traits,
|
|
515
|
+
'pageSize' => page_size,
|
|
516
|
+
'pageToken' => page_token,
|
|
517
|
+
'orderBy' => order_by,
|
|
518
|
+
})
|
|
519
|
+
headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', })
|
|
520
|
+
|
|
521
|
+
|
|
522
|
+
|
|
523
|
+
|
|
524
|
+
|
|
525
|
+
response = @version.fetch_with_metadata('GET', @uri, params: params, headers: headers)
|
|
526
|
+
trait_group_instance = TraitGroupInstance.new(
|
|
527
|
+
@version,
|
|
528
|
+
response.body,
|
|
529
|
+
store_id: @solution[:store_id],
|
|
530
|
+
trait_group_name: @solution[:trait_group_name],
|
|
531
|
+
)
|
|
532
|
+
TraitGroupInstanceMetadata.new(
|
|
533
|
+
@version,
|
|
534
|
+
trait_group_instance,
|
|
535
|
+
response.headers,
|
|
536
|
+
response.status_code
|
|
537
|
+
)
|
|
538
|
+
end
|
|
539
|
+
|
|
540
|
+
##
|
|
541
|
+
# Patch the TraitGroupInstance
|
|
542
|
+
# @param [String] if_match Allows for optimistic concurrency control by making the request conditional. Server will only act if the resource's current Entity Tag (ETag) matches the one provided, preventing accidental overwrites.
|
|
543
|
+
# @param [PatchTraitGroupRequest] patch_trait_group_request
|
|
544
|
+
# @return [TraitGroupInstance] Patched TraitGroupInstance
|
|
545
|
+
def patch(
|
|
546
|
+
if_match: :unset,
|
|
547
|
+
patch_trait_group_request: :unset
|
|
548
|
+
)
|
|
549
|
+
|
|
550
|
+
headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', 'If-Match' => if_match, })
|
|
551
|
+
headers['Content-Type'] = 'application/json'
|
|
552
|
+
|
|
553
|
+
|
|
554
|
+
|
|
555
|
+
|
|
556
|
+
payload = @version.patch('PATCH', @uri, headers: headers, data: patch_trait_group_request.to_json)
|
|
557
|
+
TraitGroupInstance.new(
|
|
558
|
+
@version,
|
|
559
|
+
payload,
|
|
560
|
+
store_id: @solution[:store_id],
|
|
561
|
+
trait_group_name: @solution[:trait_group_name],
|
|
562
|
+
)
|
|
563
|
+
end
|
|
564
|
+
|
|
565
|
+
##
|
|
566
|
+
# Patch the TraitGroupInstanceMetadata
|
|
567
|
+
# @param [String] if_match Allows for optimistic concurrency control by making the request conditional. Server will only act if the resource's current Entity Tag (ETag) matches the one provided, preventing accidental overwrites.
|
|
568
|
+
# @param [PatchTraitGroupRequest] patch_trait_group_request
|
|
569
|
+
# @return [TraitGroupInstance] Patchd TraitGroupInstance
|
|
570
|
+
def patch_with_metadata(
|
|
571
|
+
if_match: :unset,
|
|
572
|
+
patch_trait_group_request: :unset
|
|
573
|
+
)
|
|
574
|
+
|
|
575
|
+
headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', 'If-Match' => if_match, })
|
|
576
|
+
headers['Content-Type'] = 'application/json'
|
|
577
|
+
|
|
578
|
+
|
|
579
|
+
|
|
580
|
+
|
|
581
|
+
response = @version.patch_with_metadata('PATCH', @uri, headers: headers, data: patch_trait_group_request.to_json)
|
|
582
|
+
trait_group_instance = TraitGroupInstance.new(
|
|
583
|
+
@version,
|
|
584
|
+
response.body,
|
|
585
|
+
store_id: @solution[:store_id],
|
|
586
|
+
trait_group_name: @solution[:trait_group_name],
|
|
587
|
+
)
|
|
588
|
+
TraitGroupInstanceMetadata.new(
|
|
589
|
+
@version,
|
|
590
|
+
trait_group_instance,
|
|
591
|
+
response.headers,
|
|
592
|
+
response.status_code
|
|
593
|
+
)
|
|
594
|
+
end
|
|
595
|
+
|
|
596
|
+
|
|
597
|
+
##
|
|
598
|
+
# Provide a user friendly representation
|
|
599
|
+
def to_s
|
|
600
|
+
context = @solution.map{|k, v| "#{k}: #{v}"}.join(',')
|
|
601
|
+
"#<Twilio.Memory.V1.TraitGroupContext #{context}>"
|
|
602
|
+
end
|
|
603
|
+
|
|
604
|
+
##
|
|
605
|
+
# Provide a detailed, user friendly representation
|
|
606
|
+
def inspect
|
|
607
|
+
context = @solution.map{|k, v| "#{k}: #{v}"}.join(',')
|
|
608
|
+
"#<Twilio.Memory.V1.TraitGroupContext #{context}>"
|
|
609
|
+
end
|
|
610
|
+
end
|
|
611
|
+
|
|
612
|
+
class TraitGroupInstanceMetadata < InstanceResourceMetadata
|
|
613
|
+
##
|
|
614
|
+
# Initializes a new TraitGroupInstanceMetadata.
|
|
615
|
+
# @param [Version] version Version that contains the resource
|
|
616
|
+
# @param [}TraitGroupInstance] trait_group_instance The instance associated with the metadata.
|
|
617
|
+
# @param [Hash] headers Header object with response headers.
|
|
618
|
+
# @param [Integer] status_code The HTTP status code of the response.
|
|
619
|
+
# @return [TraitGroupInstanceMetadata] The initialized instance with metadata.
|
|
620
|
+
def initialize(version, trait_group_instance, headers, status_code)
|
|
621
|
+
super(version, headers, status_code)
|
|
622
|
+
@trait_group_instance = trait_group_instance
|
|
623
|
+
end
|
|
624
|
+
|
|
625
|
+
def trait_group
|
|
626
|
+
@trait_group_instance
|
|
627
|
+
end
|
|
628
|
+
|
|
629
|
+
def headers
|
|
630
|
+
@headers
|
|
631
|
+
end
|
|
632
|
+
|
|
633
|
+
def status_code
|
|
634
|
+
@status_code
|
|
635
|
+
end
|
|
636
|
+
|
|
637
|
+
def to_s
|
|
638
|
+
"<Twilio.Api.V2010.TraitGroupInstanceMetadata status=#{@status_code}>"
|
|
639
|
+
end
|
|
640
|
+
end
|
|
641
|
+
|
|
642
|
+
class TraitGroupListResponse < InstanceListResource
|
|
643
|
+
# @param [Array<TraitGroupInstance>] instance
|
|
644
|
+
# @param [Hash{String => Object}] headers
|
|
645
|
+
# @param [Integer] status_code
|
|
646
|
+
def initialize(version, payload, key)
|
|
647
|
+
@trait_group_instance = payload.body[key].map do |data|
|
|
648
|
+
TraitGroupInstance.new(version, data)
|
|
649
|
+
end
|
|
650
|
+
@headers = payload.headers
|
|
651
|
+
@status_code = payload.status_code
|
|
652
|
+
end
|
|
653
|
+
|
|
654
|
+
def trait_group_instance
|
|
655
|
+
@instance
|
|
656
|
+
end
|
|
657
|
+
end
|
|
658
|
+
|
|
659
|
+
class TraitGroupPage < TokenPage
|
|
660
|
+
##
|
|
661
|
+
# Initialize the TraitGroupPage
|
|
662
|
+
# @param [Version] version Version that contains the resource
|
|
663
|
+
# @param [Response] response Response from the API
|
|
664
|
+
# @param [Hash] solution Path solution for the resource
|
|
665
|
+
# @return [TraitGroupPage] TraitGroupPage
|
|
666
|
+
def initialize(version, response, solution)
|
|
667
|
+
|
|
668
|
+
apiV1Version = ApiV1Version.new version.domain, version
|
|
669
|
+
super(apiV1Version, response)
|
|
670
|
+
|
|
671
|
+
# Path Solution
|
|
672
|
+
@solution = solution
|
|
673
|
+
end
|
|
674
|
+
|
|
675
|
+
##
|
|
676
|
+
# Build an instance of TraitGroupInstance
|
|
677
|
+
# @param [Hash] payload Payload response from the API
|
|
678
|
+
# @return [TraitGroupInstance] TraitGroupInstance
|
|
679
|
+
def get_instance(payload)
|
|
680
|
+
TraitGroupInstance.new(@version, payload, store_id: @solution[:store_id])
|
|
681
|
+
end
|
|
682
|
+
|
|
683
|
+
##
|
|
684
|
+
# Provide a user friendly representation
|
|
685
|
+
def to_s
|
|
686
|
+
'<Twilio.Memory.V1.TraitGroupPage>'
|
|
687
|
+
end
|
|
688
|
+
end
|
|
689
|
+
|
|
690
|
+
class TraitGroupPageMetadata < PageMetadata
|
|
691
|
+
attr_reader :trait_group_page
|
|
692
|
+
|
|
693
|
+
def initialize(version, response, solution, limit)
|
|
694
|
+
super(version, response)
|
|
695
|
+
@trait_group_page = []
|
|
696
|
+
@limit = limit
|
|
697
|
+
key = get_key(response.body)
|
|
698
|
+
records = 0
|
|
699
|
+
while( limit != :unset && records < limit )
|
|
700
|
+
@trait_group_page << TraitGroupListResponse.new(version, @payload, key, limit - records)
|
|
701
|
+
@payload = self.next_page
|
|
702
|
+
break unless @payload
|
|
703
|
+
records += (@payload.body[key] || []).size
|
|
704
|
+
end
|
|
705
|
+
# Path Solution
|
|
706
|
+
@solution = solution
|
|
707
|
+
end
|
|
708
|
+
|
|
709
|
+
def each
|
|
710
|
+
@trait_group_page.each do |record|
|
|
711
|
+
yield record
|
|
712
|
+
end
|
|
713
|
+
end
|
|
714
|
+
|
|
715
|
+
def to_s
|
|
716
|
+
'<Twilio::REST::Memory::V1PageMetadata>';
|
|
717
|
+
end
|
|
718
|
+
end
|
|
719
|
+
class TraitGroupListResponse < InstanceListResource
|
|
720
|
+
|
|
721
|
+
# @param [Array<TraitGroupInstance>] instance
|
|
722
|
+
# @param [Hash{String => Object}] headers
|
|
723
|
+
# @param [Integer] status_code
|
|
724
|
+
def initialize(version, payload, key, limit = :unset)
|
|
725
|
+
data_list = payload.body[key] || []
|
|
726
|
+
if limit != :unset
|
|
727
|
+
data_list = data_list[0, limit]
|
|
728
|
+
end
|
|
729
|
+
@trait_group = data_list.map do |data|
|
|
730
|
+
TraitGroupInstance.new(version, data)
|
|
731
|
+
end
|
|
732
|
+
@headers = payload.headers
|
|
733
|
+
@status_code = payload.status_code
|
|
734
|
+
end
|
|
735
|
+
|
|
736
|
+
def trait_group
|
|
737
|
+
@trait_group
|
|
738
|
+
end
|
|
739
|
+
|
|
740
|
+
def headers
|
|
741
|
+
@headers
|
|
742
|
+
end
|
|
743
|
+
|
|
744
|
+
def status_code
|
|
745
|
+
@status_code
|
|
746
|
+
end
|
|
747
|
+
end
|
|
748
|
+
|
|
749
|
+
class TraitGroupInstance < InstanceResource
|
|
750
|
+
##
|
|
751
|
+
# Initialize the TraitGroupInstance
|
|
752
|
+
# @param [Version] version Version that contains the resource
|
|
753
|
+
# @param [Hash] payload payload that contains response from Twilio
|
|
754
|
+
# @param [String] account_sid The SID of the
|
|
755
|
+
# {Account}[https://www.twilio.com/docs/iam/api/account] that created this TraitGroup
|
|
756
|
+
# resource.
|
|
757
|
+
# @param [String] sid The SID of the Call resource to fetch.
|
|
758
|
+
# @return [TraitGroupInstance] TraitGroupInstance
|
|
759
|
+
def initialize(version, payload , store_id: nil, trait_group_name: nil)
|
|
760
|
+
|
|
761
|
+
apiV1Version = ApiV1Version.new version.domain, version
|
|
762
|
+
super(apiV1Version)
|
|
763
|
+
|
|
764
|
+
# Marshaled Properties
|
|
765
|
+
@properties = {
|
|
766
|
+
'message' => payload['message'],
|
|
767
|
+
'status_url' => payload['status_url'],
|
|
768
|
+
'trait_group' => payload['trait_group'],
|
|
769
|
+
'meta' => payload['meta'],
|
|
770
|
+
'display_name' => payload['display_name'],
|
|
771
|
+
'description' => payload['description'],
|
|
772
|
+
'traits' => payload['traits'],
|
|
773
|
+
'version' => payload['version'] == nil ? payload['version'] : payload['version'].to_i,
|
|
774
|
+
}
|
|
775
|
+
|
|
776
|
+
# Context
|
|
777
|
+
@instance_context = nil
|
|
778
|
+
@params = { 'store_id' => store_id || @properties['store_id'] ,'trait_group_name' => trait_group_name || @properties['trait_group_name'] , }
|
|
779
|
+
end
|
|
780
|
+
|
|
781
|
+
##
|
|
782
|
+
# Generate an instance context for the instance, the context is capable of
|
|
783
|
+
# performing various actions. All instance actions are proxied to the context
|
|
784
|
+
# @return [TraitGroupContext] CallContext for this CallInstance
|
|
785
|
+
def context
|
|
786
|
+
unless @instance_context
|
|
787
|
+
@instance_context = TraitGroupContext.new(@version , @params['store_id'], @params['trait_group_name'])
|
|
788
|
+
end
|
|
789
|
+
@instance_context
|
|
790
|
+
end
|
|
791
|
+
|
|
792
|
+
##
|
|
793
|
+
# @return [String]
|
|
794
|
+
def message
|
|
795
|
+
@properties['message']
|
|
796
|
+
end
|
|
797
|
+
|
|
798
|
+
##
|
|
799
|
+
# @return [String] URI to check operation status.
|
|
800
|
+
def status_url
|
|
801
|
+
@properties['status_url']
|
|
802
|
+
end
|
|
803
|
+
|
|
804
|
+
##
|
|
805
|
+
# @return [TraitGroup]
|
|
806
|
+
def trait_group
|
|
807
|
+
@properties['trait_group']
|
|
808
|
+
end
|
|
809
|
+
|
|
810
|
+
##
|
|
811
|
+
# @return [Meta]
|
|
812
|
+
def meta
|
|
813
|
+
@properties['meta']
|
|
814
|
+
end
|
|
815
|
+
|
|
816
|
+
##
|
|
817
|
+
# @return [String] Provides a unique and addressable name to be assigned to this Trait Group
|
|
818
|
+
def display_name
|
|
819
|
+
@properties['display_name']
|
|
820
|
+
end
|
|
821
|
+
|
|
822
|
+
##
|
|
823
|
+
# @return [String] description of the Trait Group
|
|
824
|
+
def description
|
|
825
|
+
@properties['description']
|
|
826
|
+
end
|
|
827
|
+
|
|
828
|
+
##
|
|
829
|
+
# @return [Hash<String, TraitGroupCoreTraitsValue>] Map of traits that are part of this Trait Group, where the key is the trait name and the value is the trait's definition.
|
|
830
|
+
def traits
|
|
831
|
+
@properties['traits']
|
|
832
|
+
end
|
|
833
|
+
|
|
834
|
+
##
|
|
835
|
+
# @return [String] The current version number of the Trait Group. Incremented on each successful update.
|
|
836
|
+
def version
|
|
837
|
+
@properties['version']
|
|
838
|
+
end
|
|
839
|
+
|
|
840
|
+
##
|
|
841
|
+
# Delete the TraitGroupInstance
|
|
842
|
+
# @return [Boolean] True if delete succeeds, false otherwise
|
|
843
|
+
def delete
|
|
844
|
+
|
|
845
|
+
context.delete
|
|
846
|
+
end
|
|
847
|
+
|
|
848
|
+
##
|
|
849
|
+
# Fetch the TraitGroupInstance
|
|
850
|
+
# @param [Boolean] include_traits Whether to include trait definitions in the response
|
|
851
|
+
# @param [String] page_size The maximum number of items to return per page, maximum of 100.
|
|
852
|
+
# @param [String] page_token The token for the page of results to retrieve.
|
|
853
|
+
# @param [String] order_by Either 'ASC' or 'DESC' to sort results ascending or descending respectively.
|
|
854
|
+
# @return [TraitGroupInstance] Fetched TraitGroupInstance
|
|
855
|
+
def fetch(
|
|
856
|
+
include_traits: :unset,
|
|
857
|
+
page_size: :unset,
|
|
858
|
+
page_token: :unset,
|
|
859
|
+
order_by: :unset
|
|
860
|
+
)
|
|
861
|
+
|
|
862
|
+
context.fetch(
|
|
863
|
+
include_traits: include_traits,
|
|
864
|
+
page_size: page_size,
|
|
865
|
+
page_token: page_token,
|
|
866
|
+
order_by: order_by,
|
|
867
|
+
)
|
|
868
|
+
end
|
|
869
|
+
|
|
870
|
+
##
|
|
871
|
+
# Patch the TraitGroupInstance
|
|
872
|
+
# @param [String] if_match Allows for optimistic concurrency control by making the request conditional. Server will only act if the resource's current Entity Tag (ETag) matches the one provided, preventing accidental overwrites.
|
|
873
|
+
# @param [PatchTraitGroupRequest] patch_trait_group_request
|
|
874
|
+
# @return [TraitGroupInstance] Patched TraitGroupInstance
|
|
875
|
+
def patch(
|
|
876
|
+
if_match: :unset,
|
|
877
|
+
patch_trait_group_request: :unset
|
|
878
|
+
)
|
|
879
|
+
|
|
880
|
+
context.patch(
|
|
881
|
+
if_match: if_match,
|
|
882
|
+
patch_trait_group_request: patch_trait_group_request,
|
|
883
|
+
)
|
|
884
|
+
end
|
|
885
|
+
|
|
886
|
+
##
|
|
887
|
+
# Provide a user friendly representation
|
|
888
|
+
def to_s
|
|
889
|
+
values = @params.map{|k, v| "#{k}: #{v}"}.join(" ")
|
|
890
|
+
"<Twilio.Memory.V1.TraitGroupInstance #{values}>"
|
|
891
|
+
end
|
|
892
|
+
|
|
893
|
+
##
|
|
894
|
+
# Provide a detailed, user friendly representation
|
|
895
|
+
def inspect
|
|
896
|
+
values = @properties.map{|k, v| "#{k}: #{v}"}.join(" ")
|
|
897
|
+
"<Twilio.Memory.V1.TraitGroupInstance #{values}>"
|
|
898
|
+
end
|
|
899
|
+
end
|
|
900
|
+
|
|
901
|
+
end
|
|
902
|
+
end
|
|
903
|
+
end
|
|
904
|
+
end
|