twilio-api-sdk 1.0.0
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 +7 -0
- data/LICENSE +28 -0
- data/README.md +213 -0
- data/bin/console +15 -0
- data/lib/twilio_ap_is/api_helper.rb +10 -0
- data/lib/twilio_ap_is/apis/accounts_v1_auth_token_promotion_api.rb +27 -0
- data/lib/twilio_ap_is/apis/accounts_v1_aws_api.rb +137 -0
- data/lib/twilio_ap_is/apis/accounts_v1_bulk_consents_api.rb +41 -0
- data/lib/twilio_ap_is/apis/accounts_v1_bulk_contacts_api.rb +36 -0
- data/lib/twilio_ap_is/apis/accounts_v1_messaging_geopermissions_api.rb +54 -0
- data/lib/twilio_ap_is/apis/accounts_v1_public_key_api.rb +136 -0
- data/lib/twilio_ap_is/apis/accounts_v1_safelist_api.rb +69 -0
- data/lib/twilio_ap_is/apis/accounts_v1_secondary_auth_token_api.rb +39 -0
- data/lib/twilio_ap_is/apis/base_api.rb +67 -0
- data/lib/twilio_ap_is/apis/chat_v3_channel_api.rb +51 -0
- data/lib/twilio_ap_is/apis/conversations_v1_address_configuration_api.rb +218 -0
- data/lib/twilio_ap_is/apis/conversations_v1_binding_api.rb +116 -0
- data/lib/twilio_ap_is/apis/conversations_v1_configuration_api.rb +133 -0
- data/lib/twilio_ap_is/apis/conversations_v1_conversation_api.rb +550 -0
- data/lib/twilio_ap_is/apis/conversations_v1_conversation_with_participants_api.rb +182 -0
- data/lib/twilio_ap_is/apis/conversations_v1_credential_api.rb +189 -0
- data/lib/twilio_ap_is/apis/conversations_v1_delivery_receipt_api.rb +183 -0
- data/lib/twilio_ap_is/apis/conversations_v1_message_api.rb +497 -0
- data/lib/twilio_ap_is/apis/conversations_v1_notification_api.rb +124 -0
- data/lib/twilio_ap_is/apis/conversations_v1_participant_api.rb +546 -0
- data/lib/twilio_ap_is/apis/conversations_v1_participant_conversation_api.rb +99 -0
- data/lib/twilio_ap_is/apis/conversations_v1_role_api.rb +325 -0
- data/lib/twilio_ap_is/apis/conversations_v1_service_api.rb +98 -0
- data/lib/twilio_ap_is/apis/conversations_v1_user_api.rb +364 -0
- data/lib/twilio_ap_is/apis/conversations_v1_user_conversation_api.rb +335 -0
- data/lib/twilio_ap_is/apis/conversations_v1_webhook_api.rb +561 -0
- data/lib/twilio_ap_is/apis/notify_v1_binding_api.rb +186 -0
- data/lib/twilio_ap_is/apis/notify_v1_credential_api.rb +183 -0
- data/lib/twilio_ap_is/apis/notify_v1_notification_api.rb +174 -0
- data/lib/twilio_ap_is/apis/notify_v1_service_api.rb +262 -0
- data/lib/twilio_ap_is/apis/taskrouter_v1_activity_api.rb +177 -0
- data/lib/twilio_ap_is/apis/taskrouter_v1_event_api.rb +125 -0
- data/lib/twilio_ap_is/apis/taskrouter_v1_task_api.rb +310 -0
- data/lib/twilio_ap_is/apis/taskrouter_v1_task_channel_api.rb +173 -0
- data/lib/twilio_ap_is/apis/taskrouter_v1_task_queue_api.rb +232 -0
- data/lib/twilio_ap_is/apis/taskrouter_v1_task_queue_bulk_real_time_statistics_api.rb +36 -0
- data/lib/twilio_ap_is/apis/taskrouter_v1_task_queue_cumulative_statistics_api.rb +63 -0
- data/lib/twilio_ap_is/apis/taskrouter_v1_task_queue_real_time_statistics_api.rb +41 -0
- data/lib/twilio_ap_is/apis/taskrouter_v1_task_queue_statistics_api.rb +63 -0
- data/lib/twilio_ap_is/apis/taskrouter_v1_task_queues_statistics_api.rb +72 -0
- data/lib/twilio_ap_is/apis/taskrouter_v1_task_reservation_api.rb +396 -0
- data/lib/twilio_ap_is/apis/taskrouter_v1_worker_api.rb +232 -0
- data/lib/twilio_ap_is/apis/taskrouter_v1_worker_channel_api.rb +126 -0
- data/lib/twilio_ap_is/apis/taskrouter_v1_worker_reservation_api.rb +385 -0
- data/lib/twilio_ap_is/apis/taskrouter_v1_worker_statistics_api.rb +57 -0
- data/lib/twilio_ap_is/apis/taskrouter_v1_workers_cumulative_statistics_api.rb +51 -0
- data/lib/twilio_ap_is/apis/taskrouter_v1_workers_real_time_statistics_api.rb +35 -0
- data/lib/twilio_ap_is/apis/taskrouter_v1_workers_statistics_api.rb +63 -0
- data/lib/twilio_ap_is/apis/taskrouter_v1_workflow_api.rb +213 -0
- data/lib/twilio_ap_is/apis/taskrouter_v1_workflow_cumulative_statistics_api.rb +68 -0
- data/lib/twilio_ap_is/apis/taskrouter_v1_workflow_real_time_statistics_api.rb +41 -0
- data/lib/twilio_ap_is/apis/taskrouter_v1_workflow_statistics_api.rb +67 -0
- data/lib/twilio_ap_is/apis/taskrouter_v1_workspace_api.rb +225 -0
- data/lib/twilio_ap_is/apis/taskrouter_v1_workspace_cumulative_statistics_api.rb +62 -0
- data/lib/twilio_ap_is/apis/taskrouter_v1_workspace_real_time_statistics_api.rb +35 -0
- data/lib/twilio_ap_is/apis/taskrouter_v1_workspace_statistics_api.rb +61 -0
- data/lib/twilio_ap_is/apis/verify_v2_service_api.rb +178 -0
- data/lib/twilio_ap_is/apis/verify_v2_verification_api.rb +143 -0
- data/lib/twilio_ap_is/apis/verify_v2_verification_check_api.rb +61 -0
- data/lib/twilio_ap_is/client.rb +417 -0
- data/lib/twilio_ap_is/configuration.rb +187 -0
- data/lib/twilio_ap_is/exceptions/api_exception.rb +21 -0
- data/lib/twilio_ap_is/exceptions/v2_services_verifications429_error_exception.rb +63 -0
- data/lib/twilio_ap_is/http/api_response.rb +19 -0
- data/lib/twilio_ap_is/http/auth/basic_auth.rb +62 -0
- data/lib/twilio_ap_is/http/http_call_back.rb +10 -0
- data/lib/twilio_ap_is/http/http_method_enum.rb +10 -0
- data/lib/twilio_ap_is/http/http_request.rb +10 -0
- data/lib/twilio_ap_is/http/http_response.rb +10 -0
- data/lib/twilio_ap_is/http/proxy_settings.rb +22 -0
- data/lib/twilio_ap_is/logging/configuration/api_logging_configuration.rb +186 -0
- data/lib/twilio_ap_is/logging/sdk_logger.rb +17 -0
- data/lib/twilio_ap_is/models/access_token.rb +188 -0
- data/lib/twilio_ap_is/models/access_token_enum_factor_types.rb +26 -0
- data/lib/twilio_ap_is/models/activity.rb +189 -0
- data/lib/twilio_ap_is/models/auth_token_promotion.rb +142 -0
- data/lib/twilio_ap_is/models/base_model.rb +110 -0
- data/lib/twilio_ap_is/models/binding.rb +269 -0
- data/lib/twilio_ap_is/models/binding_binding_type.rb +53 -0
- data/lib/twilio_ap_is/models/bucket.rb +186 -0
- data/lib/twilio_ap_is/models/bulk_consents.rb +83 -0
- data/lib/twilio_ap_is/models/bulk_contacts.rb +83 -0
- data/lib/twilio_ap_is/models/challenge.rb +317 -0
- data/lib/twilio_ap_is/models/challenge_enum_challenge_reasons.rb +41 -0
- data/lib/twilio_ap_is/models/challenge_enum_challenge_statuses.rb +45 -0
- data/lib/twilio_ap_is/models/challenge_enum_factor_types.rb +41 -0
- data/lib/twilio_ap_is/models/channel.rb +249 -0
- data/lib/twilio_ap_is/models/channel_channel_type.rb +36 -0
- data/lib/twilio_ap_is/models/channel_webhook_enabled_type.rb +36 -0
- data/lib/twilio_ap_is/models/configuration.rb +164 -0
- data/lib/twilio_ap_is/models/configuration_address.rb +199 -0
- data/lib/twilio_ap_is/models/configuration_address_auto_creation_type.rb +40 -0
- data/lib/twilio_ap_is/models/configuration_address_method.rb +36 -0
- data/lib/twilio_ap_is/models/configuration_address_type.rb +60 -0
- data/lib/twilio_ap_is/models/configuration_webhook.rb +154 -0
- data/lib/twilio_ap_is/models/configuration_webhook_method.rb +46 -0
- data/lib/twilio_ap_is/models/configuration_webhook_target.rb +37 -0
- data/lib/twilio_ap_is/models/conversation.rb +264 -0
- data/lib/twilio_ap_is/models/conversation_message.rb +268 -0
- data/lib/twilio_ap_is/models/conversation_message_order_type.rb +36 -0
- data/lib/twilio_ap_is/models/conversation_message_receipt.rb +219 -0
- data/lib/twilio_ap_is/models/conversation_message_receipt_delivery_status.rb +49 -0
- data/lib/twilio_ap_is/models/conversation_participant.rb +240 -0
- data/lib/twilio_ap_is/models/conversation_scoped_webhook.rb +178 -0
- data/lib/twilio_ap_is/models/conversation_scoped_webhook_method.rb +36 -0
- data/lib/twilio_ap_is/models/conversation_scoped_webhook_target.rb +40 -0
- data/lib/twilio_ap_is/models/conversation_state.rb +45 -0
- data/lib/twilio_ap_is/models/conversation_webhook_method.rb +36 -0
- data/lib/twilio_ap_is/models/conversation_webhook_target.rb +37 -0
- data/lib/twilio_ap_is/models/conversation_with_participants.rb +264 -0
- data/lib/twilio_ap_is/models/conversation_with_participants_state.rb +45 -0
- data/lib/twilio_ap_is/models/credential.rb +175 -0
- data/lib/twilio_ap_is/models/credential1.rb +174 -0
- data/lib/twilio_ap_is/models/credential_aws.rb +153 -0
- data/lib/twilio_ap_is/models/credential_public_key.rb +153 -0
- data/lib/twilio_ap_is/models/credential_push_type.rb +41 -0
- data/lib/twilio_ap_is/models/entity.rb +177 -0
- data/lib/twilio_ap_is/models/event.rb +270 -0
- data/lib/twilio_ap_is/models/factor.rb +235 -0
- data/lib/twilio_ap_is/models/factor_enum_factor_statuses.rb +36 -0
- data/lib/twilio_ap_is/models/factor_enum_factor_type.rb +40 -0
- data/lib/twilio_ap_is/models/factor_enum_notification_platforms.rb +40 -0
- data/lib/twilio_ap_is/models/factor_enum_totp_algorithms.rb +40 -0
- data/lib/twilio_ap_is/models/form_enum_form_types.rb +26 -0
- data/lib/twilio_ap_is/models/list_activity_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_binding_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_configuration_address_response.rb +95 -0
- data/lib/twilio_ap_is/models/list_conversation_message_receipt_response.rb +95 -0
- data/lib/twilio_ap_is/models/list_conversation_message_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_conversation_participant_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_conversation_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_conversation_scoped_webhook_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_credential_aws_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_credential_public_key_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_credential_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_event_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_participant_conversation_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_role_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_service_binding_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_service_conversation_message_receipt_response.rb +95 -0
- data/lib/twilio_ap_is/models/list_service_conversation_message_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_service_conversation_participant_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_service_conversation_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_service_conversation_scoped_webhook_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_service_participant_conversation_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_service_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_service_role_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_service_user_conversation_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_service_user_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_task_channel_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_task_queue_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_task_queues_statistics_response.rb +95 -0
- data/lib/twilio_ap_is/models/list_task_reservation_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_task_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_user_conversation_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_user_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_worker_channel_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_worker_reservation_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_worker_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_workflow_response.rb +94 -0
- data/lib/twilio_ap_is/models/list_workspace_response.rb +94 -0
- data/lib/twilio_ap_is/models/messaging_configuration.rb +170 -0
- data/lib/twilio_ap_is/models/meta.rb +140 -0
- data/lib/twilio_ap_is/models/msg_geopermissions.rb +86 -0
- data/lib/twilio_ap_is/models/new_factor.rb +277 -0
- data/lib/twilio_ap_is/models/new_factor_enum_factor_statuses.rb +36 -0
- data/lib/twilio_ap_is/models/new_factor_enum_factor_types.rb +40 -0
- data/lib/twilio_ap_is/models/new_factor_enum_notification_platforms.rb +40 -0
- data/lib/twilio_ap_is/models/new_factor_enum_totp_algorithms.rb +40 -0
- data/lib/twilio_ap_is/models/notif_priority.rb +43 -0
- data/lib/twilio_ap_is/models/notification.rb +363 -0
- data/lib/twilio_ap_is/models/notification1.rb +181 -0
- data/lib/twilio_ap_is/models/participant_conversation.rb +325 -0
- data/lib/twilio_ap_is/models/participant_conversation_state.rb +41 -0
- data/lib/twilio_ap_is/models/rate_limit.rb +189 -0
- data/lib/twilio_ap_is/models/role.rb +192 -0
- data/lib/twilio_ap_is/models/role_role_type.rb +40 -0
- data/lib/twilio_ap_is/models/safelist.rb +88 -0
- data/lib/twilio_ap_is/models/safelist1.rb +99 -0
- data/lib/twilio_ap_is/models/secondary_auth_token.rb +145 -0
- data/lib/twilio_ap_is/models/service.rb +164 -0
- data/lib/twilio_ap_is/models/service1.rb +380 -0
- data/lib/twilio_ap_is/models/service2.rb +350 -0
- data/lib/twilio_ap_is/models/service_binding.rb +226 -0
- data/lib/twilio_ap_is/models/service_binding_binding_type.rb +47 -0
- data/lib/twilio_ap_is/models/service_configuration.rb +180 -0
- data/lib/twilio_ap_is/models/service_conversation.rb +264 -0
- data/lib/twilio_ap_is/models/service_conversation_message.rb +282 -0
- data/lib/twilio_ap_is/models/service_conversation_message_order_type.rb +36 -0
- data/lib/twilio_ap_is/models/service_conversation_message_receipt.rb +233 -0
- data/lib/twilio_ap_is/models/service_conversation_message_receipt_delivery_status.rb +49 -0
- data/lib/twilio_ap_is/models/service_conversation_participant.rb +256 -0
- data/lib/twilio_ap_is/models/service_conversation_scoped_webhook.rb +191 -0
- data/lib/twilio_ap_is/models/service_conversation_scoped_webhook_method.rb +36 -0
- data/lib/twilio_ap_is/models/service_conversation_scoped_webhook_target.rb +40 -0
- data/lib/twilio_ap_is/models/service_conversation_state.rb +45 -0
- data/lib/twilio_ap_is/models/service_conversation_with_participants.rb +264 -0
- data/lib/twilio_ap_is/models/service_conversation_with_participants_state.rb +45 -0
- data/lib/twilio_ap_is/models/service_notification.rb +155 -0
- data/lib/twilio_ap_is/models/service_participant_conversation.rb +325 -0
- data/lib/twilio_ap_is/models/service_participant_conversation_state.rb +41 -0
- data/lib/twilio_ap_is/models/service_role.rb +192 -0
- data/lib/twilio_ap_is/models/service_role_role_type.rb +40 -0
- data/lib/twilio_ap_is/models/service_stats_conversations_rate_limiting_errors_source.rb +36 -0
- data/lib/twilio_ap_is/models/service_user.rb +250 -0
- data/lib/twilio_ap_is/models/service_user_conversation.rb +317 -0
- data/lib/twilio_ap_is/models/service_user_conversation_notification_level.rb +37 -0
- data/lib/twilio_ap_is/models/service_user_conversation_state.rb +41 -0
- data/lib/twilio_ap_is/models/service_webhook_configuration.rb +160 -0
- data/lib/twilio_ap_is/models/service_webhook_configuration_method.rb +37 -0
- data/lib/twilio_ap_is/models/stats_twilsock_rate_limiting_errors_source.rb +26 -0
- data/lib/twilio_ap_is/models/task_channel.rb +204 -0
- data/lib/twilio_ap_is/models/task_queue.rb +278 -0
- data/lib/twilio_ap_is/models/task_queue_bulk_real_time_statistics.rb +141 -0
- data/lib/twilio_ap_is/models/task_queue_cumulative.rb +356 -0
- data/lib/twilio_ap_is/models/task_queue_real_time_statistics.rb +250 -0
- data/lib/twilio_ap_is/models/task_queue_statistics.rb +135 -0
- data/lib/twilio_ap_is/models/task_queue_task_order.rb +40 -0
- data/lib/twilio_ap_is/models/task_queues_stats.rb +124 -0
- data/lib/twilio_ap_is/models/task_reservation.rb +210 -0
- data/lib/twilio_ap_is/models/task_reservation_call_status.rb +44 -0
- data/lib/twilio_ap_is/models/task_reservation_conference_event.rb +56 -0
- data/lib/twilio_ap_is/models/task_reservation_status.rb +61 -0
- data/lib/twilio_ap_is/models/task_reservation_supervisor_mode.rb +40 -0
- data/lib/twilio_ap_is/models/task_router_task.rb +394 -0
- data/lib/twilio_ap_is/models/task_status.rb +53 -0
- data/lib/twilio_ap_is/models/user.rb +250 -0
- data/lib/twilio_ap_is/models/user_binding_binding_type.rb +52 -0
- data/lib/twilio_ap_is/models/user_conversation.rb +317 -0
- data/lib/twilio_ap_is/models/user_conversation_notification_level.rb +37 -0
- data/lib/twilio_ap_is/models/user_conversation_state.rb +41 -0
- data/lib/twilio_ap_is/models/v2_form.rb +112 -0
- data/lib/twilio_ap_is/models/verification.rb +262 -0
- data/lib/twilio_ap_is/models/verification_attempt.rb +219 -0
- data/lib/twilio_ap_is/models/verification_attempt_enum_attempt_status.rb +40 -0
- data/lib/twilio_ap_is/models/verification_attempt_enum_call_status.rb +60 -0
- data/lib/twilio_ap_is/models/verification_attempt_enum_channels.rb +49 -0
- data/lib/twilio_ap_is/models/verification_attempt_enum_conversion_status.rb +38 -0
- data/lib/twilio_ap_is/models/verification_attempt_enum_message_status.rb +80 -0
- data/lib/twilio_ap_is/models/verification_attempts.rb +129 -0
- data/lib/twilio_ap_is/models/verification_attempts_summary_enum_channels.rb +48 -0
- data/lib/twilio_ap_is/models/verification_check.rb +231 -0
- data/lib/twilio_ap_is/models/verification_check_enum_channel.rb +50 -0
- data/lib/twilio_ap_is/models/verification_enum_channel.rb +50 -0
- data/lib/twilio_ap_is/models/verification_enum_risk_check.rb +39 -0
- data/lib/twilio_ap_is/models/verification_enum_status.rb +37 -0
- data/lib/twilio_ap_is/models/verification_template.rb +126 -0
- data/lib/twilio_ap_is/models/webhook.rb +222 -0
- data/lib/twilio_ap_is/models/webhook_enum_status.rb +37 -0
- data/lib/twilio_ap_is/models/webhook_enum_version.rb +37 -0
- data/lib/twilio_ap_is/models/worker.rb +247 -0
- data/lib/twilio_ap_is/models/worker_channel.rb +244 -0
- data/lib/twilio_ap_is/models/worker_instance_statistics.rb +122 -0
- data/lib/twilio_ap_is/models/worker_reservation.rb +210 -0
- data/lib/twilio_ap_is/models/worker_reservation_call_status.rb +44 -0
- data/lib/twilio_ap_is/models/worker_reservation_conference_event.rb +56 -0
- data/lib/twilio_ap_is/models/worker_reservation_status.rb +61 -0
- data/lib/twilio_ap_is/models/worker_statistics.rb +122 -0
- data/lib/twilio_ap_is/models/workers_cumulative_statistics.rb +221 -0
- data/lib/twilio_ap_is/models/workers_real_time_statistics.rb +124 -0
- data/lib/twilio_ap_is/models/workflow.rb +247 -0
- data/lib/twilio_ap_is/models/workflow_cumulative_statistics.rb +347 -0
- data/lib/twilio_ap_is/models/workflow_real_time_statistics.rb +173 -0
- data/lib/twilio_ap_is/models/workflow_statistics.rb +135 -0
- data/lib/twilio_ap_is/models/workspace.rb +285 -0
- data/lib/twilio_ap_is/models/workspace_cumulative_statistics.rb +334 -0
- data/lib/twilio_ap_is/models/workspace_queue_order.rb +40 -0
- data/lib/twilio_ap_is/models/workspace_real_time_statistics.rb +185 -0
- data/lib/twilio_ap_is/models/workspace_statistics.rb +122 -0
- data/lib/twilio_ap_is/utilities/date_time_helper.rb +11 -0
- data/lib/twilio_ap_is/utilities/file_wrapper.rb +28 -0
- data/lib/twilio_ap_is.rb +326 -0
- metadata +361 -0
|
@@ -0,0 +1,546 @@
|
|
|
1
|
+
# twilio_ap_is
|
|
2
|
+
#
|
|
3
|
+
# This file was automatically generated by APIMATIC v3.0 (
|
|
4
|
+
# https://www.apimatic.io ).
|
|
5
|
+
|
|
6
|
+
module TwilioApIs
|
|
7
|
+
# ConversationsV1ParticipantApi
|
|
8
|
+
class ConversationsV1ParticipantApi < BaseApi
|
|
9
|
+
# Add a new participant to the conversation
|
|
10
|
+
# @param [String] conversation_sid Required parameter: The unique ID of the
|
|
11
|
+
# [Conversation](https://www.twilio.com/docs/conversations/api/conversation-
|
|
12
|
+
# resource) for this participant.
|
|
13
|
+
# @param [ChannelWebhookEnabledType] x_twilio_webhook_enabled Optional
|
|
14
|
+
# parameter: The X-Twilio-Webhook-Enabled HTTP request header
|
|
15
|
+
# @param [String] identity Optional parameter: A unique string identifier
|
|
16
|
+
# for the conversation participant as [Conversation
|
|
17
|
+
# User](https://www.twilio.com/docs/conversations/api/user-resource). This
|
|
18
|
+
# parameter is non-null if (and only if) the participant is using the
|
|
19
|
+
# Conversations SDK to communicate. Limited to 256 characters.
|
|
20
|
+
# @param [String] messaging_binding_address Optional parameter: The address
|
|
21
|
+
# of the participant's device, e.g. a phone or WhatsApp number. Together
|
|
22
|
+
# with the Proxy address, this determines a participant uniquely. This field
|
|
23
|
+
# (with proxy_address) is only null when the participant is interacting from
|
|
24
|
+
# an SDK endpoint (see the 'identity' field).
|
|
25
|
+
# @param [String] messaging_binding_proxy_address Optional parameter: The
|
|
26
|
+
# address of the Twilio phone number (or WhatsApp number) that the
|
|
27
|
+
# participant is in contact with. This field, together with participant
|
|
28
|
+
# address, is only null when the participant is interacting from an SDK
|
|
29
|
+
# endpoint (see the 'identity' field).
|
|
30
|
+
# @param [DateTime] date_created Optional parameter: The date that this
|
|
31
|
+
# resource was created.
|
|
32
|
+
# @param [DateTime] date_updated Optional parameter: The date that this
|
|
33
|
+
# resource was last updated.
|
|
34
|
+
# @param [String] attributes Optional parameter: An optional string metadata
|
|
35
|
+
# field you can use to store any data you wish. The string value must
|
|
36
|
+
# contain structurally valid JSON if specified. **Note** that if the
|
|
37
|
+
# attributes are not set "{}" will be returned.
|
|
38
|
+
# @param [String] messaging_binding_projected_address Optional parameter:
|
|
39
|
+
# The address of the Twilio phone number that is used in Group MMS.
|
|
40
|
+
# Communication mask for the Conversation participant with Identity.
|
|
41
|
+
# @param [String] role_sid Optional parameter: The SID of a
|
|
42
|
+
# conversation-level
|
|
43
|
+
# [Role](https://www.twilio.com/docs/conversations/api/role-resource) to
|
|
44
|
+
# assign to the participant.
|
|
45
|
+
# @return [ApiResponse] Complete http response with raw body and status code.
|
|
46
|
+
def create_conversation_participant(conversation_sid,
|
|
47
|
+
x_twilio_webhook_enabled: nil,
|
|
48
|
+
identity: nil,
|
|
49
|
+
messaging_binding_address: nil,
|
|
50
|
+
messaging_binding_proxy_address: nil,
|
|
51
|
+
date_created: nil,
|
|
52
|
+
date_updated: nil,
|
|
53
|
+
attributes: nil,
|
|
54
|
+
messaging_binding_projected_address: nil,
|
|
55
|
+
role_sid: nil)
|
|
56
|
+
@api_call
|
|
57
|
+
.request(new_request_builder(HttpMethodEnum::POST,
|
|
58
|
+
'/v1/Conversations/{ConversationSid}/Participants',
|
|
59
|
+
Server::DEFAULT2)
|
|
60
|
+
.template_param(new_parameter(conversation_sid, key: 'ConversationSid')
|
|
61
|
+
.is_required(true)
|
|
62
|
+
.should_encode(true))
|
|
63
|
+
.header_param(new_parameter(x_twilio_webhook_enabled, key: 'X-Twilio-Webhook-Enabled'))
|
|
64
|
+
.form_param(new_parameter(identity, key: 'Identity'))
|
|
65
|
+
.form_param(new_parameter(messaging_binding_address, key: 'MessagingBinding.Address'))
|
|
66
|
+
.form_param(new_parameter(messaging_binding_proxy_address, key: 'MessagingBinding.ProxyAddress'))
|
|
67
|
+
.form_param(new_parameter(date_created, key: 'DateCreated'))
|
|
68
|
+
.form_param(new_parameter(date_updated, key: 'DateUpdated'))
|
|
69
|
+
.form_param(new_parameter(attributes, key: 'Attributes'))
|
|
70
|
+
.form_param(new_parameter(messaging_binding_projected_address, key: 'MessagingBinding.ProjectedAddress'))
|
|
71
|
+
.form_param(new_parameter(role_sid, key: 'RoleSid'))
|
|
72
|
+
.header_param(new_parameter('application/x-www-form-urlencoded', key: 'content-type'))
|
|
73
|
+
.header_param(new_parameter('application/json', key: 'accept'))
|
|
74
|
+
.auth(Single.new('accountSid_authToken')))
|
|
75
|
+
.response(new_response_handler
|
|
76
|
+
.deserializer(APIHelper.method(:custom_type_deserializer))
|
|
77
|
+
.deserialize_into(ConversationParticipant.method(:from_hash))
|
|
78
|
+
.is_api_response(true))
|
|
79
|
+
.execute
|
|
80
|
+
end
|
|
81
|
+
|
|
82
|
+
# Retrieve a list of all participants of the conversation
|
|
83
|
+
# @param [String] conversation_sid Required parameter: The unique ID of the
|
|
84
|
+
# [Conversation](https://www.twilio.com/docs/conversations/api/conversation-
|
|
85
|
+
# resource) for participants.
|
|
86
|
+
# @param [Integer] page_size Optional parameter: How many resources to
|
|
87
|
+
# return in each list page. The default is 50, and the maximum is 100.
|
|
88
|
+
# @param [Integer] page Optional parameter: The page index. This value is
|
|
89
|
+
# simply for client state.
|
|
90
|
+
# @param [String] page_token Optional parameter: The page token. This is
|
|
91
|
+
# provided by the API.
|
|
92
|
+
# @return [ApiResponse] Complete http response with raw body and status code.
|
|
93
|
+
def list_conversation_participant(conversation_sid,
|
|
94
|
+
page_size: nil,
|
|
95
|
+
page: nil,
|
|
96
|
+
page_token: nil)
|
|
97
|
+
@api_call
|
|
98
|
+
.request(new_request_builder(HttpMethodEnum::GET,
|
|
99
|
+
'/v1/Conversations/{ConversationSid}/Participants',
|
|
100
|
+
Server::DEFAULT2)
|
|
101
|
+
.template_param(new_parameter(conversation_sid, key: 'ConversationSid')
|
|
102
|
+
.is_required(true)
|
|
103
|
+
.should_encode(true))
|
|
104
|
+
.query_param(new_parameter(page_size, key: 'PageSize'))
|
|
105
|
+
.query_param(new_parameter(page, key: 'Page'))
|
|
106
|
+
.query_param(new_parameter(page_token, key: 'PageToken'))
|
|
107
|
+
.header_param(new_parameter('application/json', key: 'accept'))
|
|
108
|
+
.auth(Single.new('accountSid_authToken')))
|
|
109
|
+
.response(new_response_handler
|
|
110
|
+
.deserializer(APIHelper.method(:custom_type_deserializer))
|
|
111
|
+
.deserialize_into(ListConversationParticipantResponse.method(:from_hash))
|
|
112
|
+
.is_api_response(true))
|
|
113
|
+
.execute
|
|
114
|
+
end
|
|
115
|
+
|
|
116
|
+
# Update an existing participant in the conversation
|
|
117
|
+
# @param [String] conversation_sid Required parameter: The unique ID of the
|
|
118
|
+
# [Conversation](https://www.twilio.com/docs/conversations/api/conversation-
|
|
119
|
+
# resource) for this participant.
|
|
120
|
+
# @param [String] sid Required parameter: A 34 character string that
|
|
121
|
+
# uniquely identifies this resource.
|
|
122
|
+
# @param [ChannelWebhookEnabledType] x_twilio_webhook_enabled Optional
|
|
123
|
+
# parameter: The X-Twilio-Webhook-Enabled HTTP request header
|
|
124
|
+
# @param [DateTime] date_created Optional parameter: The date that this
|
|
125
|
+
# resource was created.
|
|
126
|
+
# @param [DateTime] date_updated Optional parameter: The date that this
|
|
127
|
+
# resource was last updated.
|
|
128
|
+
# @param [String] attributes Optional parameter: An optional string metadata
|
|
129
|
+
# field you can use to store any data you wish. The string value must
|
|
130
|
+
# contain structurally valid JSON if specified. **Note** that if the
|
|
131
|
+
# attributes are not set "{}" will be returned.
|
|
132
|
+
# @param [String] role_sid Optional parameter: The SID of a
|
|
133
|
+
# conversation-level
|
|
134
|
+
# [Role](https://www.twilio.com/docs/conversations/api/role-resource) to
|
|
135
|
+
# assign to the participant.
|
|
136
|
+
# @param [String] messaging_binding_proxy_address Optional parameter: The
|
|
137
|
+
# address of the Twilio phone number that the participant is in contact
|
|
138
|
+
# with. 'null' value will remove it.
|
|
139
|
+
# @param [String] messaging_binding_projected_address Optional parameter:
|
|
140
|
+
# The address of the Twilio phone number that is used in Group MMS. 'null'
|
|
141
|
+
# value will remove it.
|
|
142
|
+
# @param [String] identity Optional parameter: A unique string identifier
|
|
143
|
+
# for the conversation participant as [Conversation
|
|
144
|
+
# User](https://www.twilio.com/docs/conversations/api/user-resource). This
|
|
145
|
+
# parameter is non-null if (and only if) the participant is using the
|
|
146
|
+
# Conversations SDK to communicate. Limited to 256 characters.
|
|
147
|
+
# @param [Integer] last_read_message_index Optional parameter: Index of last
|
|
148
|
+
# “read” message in the
|
|
149
|
+
# [Conversation](https://www.twilio.com/docs/conversations/api/conversation-
|
|
150
|
+
# resource) for the Participant.
|
|
151
|
+
# @param [String] last_read_timestamp Optional parameter: Timestamp of last
|
|
152
|
+
# “read” message in the
|
|
153
|
+
# [Conversation](https://www.twilio.com/docs/conversations/api/conversation-
|
|
154
|
+
# resource) for the Participant.
|
|
155
|
+
# @return [ApiResponse] Complete http response with raw body and status code.
|
|
156
|
+
def update_conversation_participant(conversation_sid,
|
|
157
|
+
sid,
|
|
158
|
+
x_twilio_webhook_enabled: nil,
|
|
159
|
+
date_created: nil,
|
|
160
|
+
date_updated: nil,
|
|
161
|
+
attributes: nil,
|
|
162
|
+
role_sid: nil,
|
|
163
|
+
messaging_binding_proxy_address: nil,
|
|
164
|
+
messaging_binding_projected_address: nil,
|
|
165
|
+
identity: nil,
|
|
166
|
+
last_read_message_index: nil,
|
|
167
|
+
last_read_timestamp: nil)
|
|
168
|
+
@api_call
|
|
169
|
+
.request(new_request_builder(HttpMethodEnum::POST,
|
|
170
|
+
'/v1/Conversations/{ConversationSid}/Participants/{Sid}',
|
|
171
|
+
Server::DEFAULT2)
|
|
172
|
+
.template_param(new_parameter(conversation_sid, key: 'ConversationSid')
|
|
173
|
+
.is_required(true)
|
|
174
|
+
.should_encode(true))
|
|
175
|
+
.template_param(new_parameter(sid, key: 'Sid')
|
|
176
|
+
.is_required(true)
|
|
177
|
+
.should_encode(true))
|
|
178
|
+
.header_param(new_parameter(x_twilio_webhook_enabled, key: 'X-Twilio-Webhook-Enabled'))
|
|
179
|
+
.form_param(new_parameter(date_created, key: 'DateCreated'))
|
|
180
|
+
.form_param(new_parameter(date_updated, key: 'DateUpdated'))
|
|
181
|
+
.form_param(new_parameter(attributes, key: 'Attributes'))
|
|
182
|
+
.form_param(new_parameter(role_sid, key: 'RoleSid'))
|
|
183
|
+
.form_param(new_parameter(messaging_binding_proxy_address, key: 'MessagingBinding.ProxyAddress'))
|
|
184
|
+
.form_param(new_parameter(messaging_binding_projected_address, key: 'MessagingBinding.ProjectedAddress'))
|
|
185
|
+
.form_param(new_parameter(identity, key: 'Identity'))
|
|
186
|
+
.form_param(new_parameter(last_read_message_index, key: 'LastReadMessageIndex'))
|
|
187
|
+
.form_param(new_parameter(last_read_timestamp, key: 'LastReadTimestamp'))
|
|
188
|
+
.header_param(new_parameter('application/x-www-form-urlencoded', key: 'content-type'))
|
|
189
|
+
.header_param(new_parameter('application/json', key: 'accept'))
|
|
190
|
+
.auth(Single.new('accountSid_authToken')))
|
|
191
|
+
.response(new_response_handler
|
|
192
|
+
.deserializer(APIHelper.method(:custom_type_deserializer))
|
|
193
|
+
.deserialize_into(ConversationParticipant.method(:from_hash))
|
|
194
|
+
.is_api_response(true))
|
|
195
|
+
.execute
|
|
196
|
+
end
|
|
197
|
+
|
|
198
|
+
# Remove a participant from the conversation
|
|
199
|
+
# @param [String] conversation_sid Required parameter: The unique ID of the
|
|
200
|
+
# [Conversation](https://www.twilio.com/docs/conversations/api/conversation-
|
|
201
|
+
# resource) for this participant.
|
|
202
|
+
# @param [String] sid Required parameter: A 34 character string that
|
|
203
|
+
# uniquely identifies this resource.
|
|
204
|
+
# @param [ChannelWebhookEnabledType] x_twilio_webhook_enabled Optional
|
|
205
|
+
# parameter: The X-Twilio-Webhook-Enabled HTTP request header
|
|
206
|
+
# @return [ApiResponse] Complete http response with raw body and status code.
|
|
207
|
+
def delete_conversation_participant(conversation_sid,
|
|
208
|
+
sid,
|
|
209
|
+
x_twilio_webhook_enabled: nil)
|
|
210
|
+
@api_call
|
|
211
|
+
.request(new_request_builder(HttpMethodEnum::DELETE,
|
|
212
|
+
'/v1/Conversations/{ConversationSid}/Participants/{Sid}',
|
|
213
|
+
Server::DEFAULT2)
|
|
214
|
+
.template_param(new_parameter(conversation_sid, key: 'ConversationSid')
|
|
215
|
+
.is_required(true)
|
|
216
|
+
.should_encode(true))
|
|
217
|
+
.template_param(new_parameter(sid, key: 'Sid')
|
|
218
|
+
.is_required(true)
|
|
219
|
+
.should_encode(true))
|
|
220
|
+
.header_param(new_parameter(x_twilio_webhook_enabled, key: 'X-Twilio-Webhook-Enabled'))
|
|
221
|
+
.auth(Single.new('accountSid_authToken')))
|
|
222
|
+
.response(new_response_handler
|
|
223
|
+
.is_response_void(true)
|
|
224
|
+
.is_api_response(true))
|
|
225
|
+
.execute
|
|
226
|
+
end
|
|
227
|
+
|
|
228
|
+
# Fetch a participant of the conversation
|
|
229
|
+
# @param [String] conversation_sid Required parameter: The unique ID of the
|
|
230
|
+
# [Conversation](https://www.twilio.com/docs/conversations/api/conversation-
|
|
231
|
+
# resource) for this participant.
|
|
232
|
+
# @param [String] sid Required parameter: A 34 character string that
|
|
233
|
+
# uniquely identifies this resource. Alternatively, you can pass a
|
|
234
|
+
# Participant's `identity` rather than the SID.
|
|
235
|
+
# @return [ApiResponse] Complete http response with raw body and status code.
|
|
236
|
+
def fetch_conversation_participant(conversation_sid,
|
|
237
|
+
sid)
|
|
238
|
+
@api_call
|
|
239
|
+
.request(new_request_builder(HttpMethodEnum::GET,
|
|
240
|
+
'/v1/Conversations/{ConversationSid}/Participants/{Sid}',
|
|
241
|
+
Server::DEFAULT2)
|
|
242
|
+
.template_param(new_parameter(conversation_sid, key: 'ConversationSid')
|
|
243
|
+
.is_required(true)
|
|
244
|
+
.should_encode(true))
|
|
245
|
+
.template_param(new_parameter(sid, key: 'Sid')
|
|
246
|
+
.is_required(true)
|
|
247
|
+
.should_encode(true))
|
|
248
|
+
.header_param(new_parameter('application/json', key: 'accept'))
|
|
249
|
+
.auth(Single.new('accountSid_authToken')))
|
|
250
|
+
.response(new_response_handler
|
|
251
|
+
.deserializer(APIHelper.method(:custom_type_deserializer))
|
|
252
|
+
.deserialize_into(ConversationParticipant.method(:from_hash))
|
|
253
|
+
.is_api_response(true))
|
|
254
|
+
.execute
|
|
255
|
+
end
|
|
256
|
+
|
|
257
|
+
# Add a new participant to the conversation in a specific service
|
|
258
|
+
# @param [String] chat_service_sid Required parameter: The SID of the
|
|
259
|
+
# [Conversation
|
|
260
|
+
# Service](https://www.twilio.com/docs/conversations/api/service-resource)
|
|
261
|
+
# the Participant resource is associated with.
|
|
262
|
+
# @param [String] conversation_sid Required parameter: The unique ID of the
|
|
263
|
+
# [Conversation](https://www.twilio.com/docs/conversations/api/conversation-
|
|
264
|
+
# resource) for this participant.
|
|
265
|
+
# @param [ChannelWebhookEnabledType] x_twilio_webhook_enabled Optional
|
|
266
|
+
# parameter: The X-Twilio-Webhook-Enabled HTTP request header
|
|
267
|
+
# @param [String] identity Optional parameter: A unique string identifier
|
|
268
|
+
# for the conversation participant as [Conversation
|
|
269
|
+
# User](https://www.twilio.com/docs/conversations/api/user-resource). This
|
|
270
|
+
# parameter is non-null if (and only if) the participant is using the
|
|
271
|
+
# [Conversation SDK](https://www.twilio.com/docs/conversations/sdk-overview)
|
|
272
|
+
# to communicate. Limited to 256 characters.
|
|
273
|
+
# @param [String] messaging_binding_address Optional parameter: The address
|
|
274
|
+
# of the participant's device, e.g. a phone or WhatsApp number. Together
|
|
275
|
+
# with the Proxy address, this determines a participant uniquely. This field
|
|
276
|
+
# (with `proxy_address`) is only null when the participant is interacting
|
|
277
|
+
# from an SDK endpoint (see the `identity` field).
|
|
278
|
+
# @param [String] messaging_binding_proxy_address Optional parameter: The
|
|
279
|
+
# address of the Twilio phone number (or WhatsApp number) that the
|
|
280
|
+
# participant is in contact with. This field, together with participant
|
|
281
|
+
# address, is only null when the participant is interacting from an SDK
|
|
282
|
+
# endpoint (see the `identity` field).
|
|
283
|
+
# @param [DateTime] date_created Optional parameter: The date on which this
|
|
284
|
+
# resource was created.
|
|
285
|
+
# @param [DateTime] date_updated Optional parameter: The date on which this
|
|
286
|
+
# resource was last updated.
|
|
287
|
+
# @param [String] attributes Optional parameter: An optional string metadata
|
|
288
|
+
# field you can use to store any data you wish. The string value must
|
|
289
|
+
# contain structurally valid JSON if specified. **Note** that if the
|
|
290
|
+
# attributes are not set `{}` will be returned.
|
|
291
|
+
# @param [String] messaging_binding_projected_address Optional parameter:
|
|
292
|
+
# The address of the Twilio phone number that is used in Group MMS.
|
|
293
|
+
# @param [String] role_sid Optional parameter: The SID of a
|
|
294
|
+
# conversation-level
|
|
295
|
+
# [Role](https://www.twilio.com/docs/conversations/api/role-resource) to
|
|
296
|
+
# assign to the participant.
|
|
297
|
+
# @return [ApiResponse] Complete http response with raw body and status code.
|
|
298
|
+
def create_service_conversation_participant(chat_service_sid,
|
|
299
|
+
conversation_sid,
|
|
300
|
+
x_twilio_webhook_enabled: nil,
|
|
301
|
+
identity: nil,
|
|
302
|
+
messaging_binding_address: nil,
|
|
303
|
+
messaging_binding_proxy_address: nil,
|
|
304
|
+
date_created: nil,
|
|
305
|
+
date_updated: nil,
|
|
306
|
+
attributes: nil,
|
|
307
|
+
messaging_binding_projected_address: nil,
|
|
308
|
+
role_sid: nil)
|
|
309
|
+
@api_call
|
|
310
|
+
.request(new_request_builder(HttpMethodEnum::POST,
|
|
311
|
+
'/v1/Services/{ChatServiceSid}/Conversations/{ConversationSid}/Participants',
|
|
312
|
+
Server::DEFAULT2)
|
|
313
|
+
.template_param(new_parameter(chat_service_sid, key: 'ChatServiceSid')
|
|
314
|
+
.is_required(true)
|
|
315
|
+
.should_encode(true))
|
|
316
|
+
.template_param(new_parameter(conversation_sid, key: 'ConversationSid')
|
|
317
|
+
.is_required(true)
|
|
318
|
+
.should_encode(true))
|
|
319
|
+
.header_param(new_parameter(x_twilio_webhook_enabled, key: 'X-Twilio-Webhook-Enabled'))
|
|
320
|
+
.form_param(new_parameter(identity, key: 'Identity'))
|
|
321
|
+
.form_param(new_parameter(messaging_binding_address, key: 'MessagingBinding.Address'))
|
|
322
|
+
.form_param(new_parameter(messaging_binding_proxy_address, key: 'MessagingBinding.ProxyAddress'))
|
|
323
|
+
.form_param(new_parameter(date_created, key: 'DateCreated'))
|
|
324
|
+
.form_param(new_parameter(date_updated, key: 'DateUpdated'))
|
|
325
|
+
.form_param(new_parameter(attributes, key: 'Attributes'))
|
|
326
|
+
.form_param(new_parameter(messaging_binding_projected_address, key: 'MessagingBinding.ProjectedAddress'))
|
|
327
|
+
.form_param(new_parameter(role_sid, key: 'RoleSid'))
|
|
328
|
+
.header_param(new_parameter('application/x-www-form-urlencoded', key: 'content-type'))
|
|
329
|
+
.header_param(new_parameter('application/json', key: 'accept'))
|
|
330
|
+
.auth(Single.new('accountSid_authToken')))
|
|
331
|
+
.response(new_response_handler
|
|
332
|
+
.deserializer(APIHelper.method(:custom_type_deserializer))
|
|
333
|
+
.deserialize_into(ServiceConversationParticipant.method(:from_hash))
|
|
334
|
+
.is_api_response(true))
|
|
335
|
+
.execute
|
|
336
|
+
end
|
|
337
|
+
|
|
338
|
+
# Retrieve a list of all participants of the conversation
|
|
339
|
+
# @param [String] chat_service_sid Required parameter: The SID of the
|
|
340
|
+
# [Conversation
|
|
341
|
+
# Service](https://www.twilio.com/docs/conversations/api/service-resource)
|
|
342
|
+
# the Participant resource is associated with.
|
|
343
|
+
# @param [String] conversation_sid Required parameter: The unique ID of the
|
|
344
|
+
# [Conversation](https://www.twilio.com/docs/conversations/api/conversation-
|
|
345
|
+
# resource) for participants.
|
|
346
|
+
# @param [Integer] page_size Optional parameter: How many resources to
|
|
347
|
+
# return in each list page. The default is 50, and the maximum is 100.
|
|
348
|
+
# @param [Integer] page Optional parameter: The page index. This value is
|
|
349
|
+
# simply for client state.
|
|
350
|
+
# @param [String] page_token Optional parameter: The page token. This is
|
|
351
|
+
# provided by the API.
|
|
352
|
+
# @return [ApiResponse] Complete http response with raw body and status code.
|
|
353
|
+
def list_service_conversation_participant(chat_service_sid,
|
|
354
|
+
conversation_sid,
|
|
355
|
+
page_size: nil,
|
|
356
|
+
page: nil,
|
|
357
|
+
page_token: nil)
|
|
358
|
+
@api_call
|
|
359
|
+
.request(new_request_builder(HttpMethodEnum::GET,
|
|
360
|
+
'/v1/Services/{ChatServiceSid}/Conversations/{ConversationSid}/Participants',
|
|
361
|
+
Server::DEFAULT2)
|
|
362
|
+
.template_param(new_parameter(chat_service_sid, key: 'ChatServiceSid')
|
|
363
|
+
.is_required(true)
|
|
364
|
+
.should_encode(true))
|
|
365
|
+
.template_param(new_parameter(conversation_sid, key: 'ConversationSid')
|
|
366
|
+
.is_required(true)
|
|
367
|
+
.should_encode(true))
|
|
368
|
+
.query_param(new_parameter(page_size, key: 'PageSize'))
|
|
369
|
+
.query_param(new_parameter(page, key: 'Page'))
|
|
370
|
+
.query_param(new_parameter(page_token, key: 'PageToken'))
|
|
371
|
+
.header_param(new_parameter('application/json', key: 'accept'))
|
|
372
|
+
.auth(Single.new('accountSid_authToken')))
|
|
373
|
+
.response(new_response_handler
|
|
374
|
+
.deserializer(APIHelper.method(:custom_type_deserializer))
|
|
375
|
+
.deserialize_into(ListServiceConversationParticipantResponse.method(:from_hash))
|
|
376
|
+
.is_api_response(true))
|
|
377
|
+
.execute
|
|
378
|
+
end
|
|
379
|
+
|
|
380
|
+
# Update an existing participant in the conversation
|
|
381
|
+
# @param [String] chat_service_sid Required parameter: The SID of the
|
|
382
|
+
# [Conversation
|
|
383
|
+
# Service](https://www.twilio.com/docs/conversations/api/service-resource)
|
|
384
|
+
# the Participant resource is associated with.
|
|
385
|
+
# @param [String] conversation_sid Required parameter: The unique ID of the
|
|
386
|
+
# [Conversation](https://www.twilio.com/docs/conversations/api/conversation-
|
|
387
|
+
# resource) for this participant.
|
|
388
|
+
# @param [String] sid Required parameter: A 34 character string that
|
|
389
|
+
# uniquely identifies this resource.
|
|
390
|
+
# @param [ChannelWebhookEnabledType] x_twilio_webhook_enabled Optional
|
|
391
|
+
# parameter: The X-Twilio-Webhook-Enabled HTTP request header
|
|
392
|
+
# @param [DateTime] date_created Optional parameter: The date on which this
|
|
393
|
+
# resource was created.
|
|
394
|
+
# @param [DateTime] date_updated Optional parameter: The date on which this
|
|
395
|
+
# resource was last updated.
|
|
396
|
+
# @param [String] identity Optional parameter: A unique string identifier
|
|
397
|
+
# for the conversation participant as [Conversation
|
|
398
|
+
# User](https://www.twilio.com/docs/conversations/api/user-resource). This
|
|
399
|
+
# parameter is non-null if (and only if) the participant is using the
|
|
400
|
+
# [Conversation SDK](https://www.twilio.com/docs/conversations/sdk-overview)
|
|
401
|
+
# to communicate. Limited to 256 characters.
|
|
402
|
+
# @param [String] attributes Optional parameter: An optional string metadata
|
|
403
|
+
# field you can use to store any data you wish. The string value must
|
|
404
|
+
# contain structurally valid JSON if specified. **Note** that if the
|
|
405
|
+
# attributes are not set `{}` will be returned.
|
|
406
|
+
# @param [String] role_sid Optional parameter: The SID of a
|
|
407
|
+
# conversation-level
|
|
408
|
+
# [Role](https://www.twilio.com/docs/conversations/api/role-resource) to
|
|
409
|
+
# assign to the participant.
|
|
410
|
+
# @param [String] messaging_binding_proxy_address Optional parameter: The
|
|
411
|
+
# address of the Twilio phone number that the participant is in contact
|
|
412
|
+
# with. 'null' value will remove it.
|
|
413
|
+
# @param [String] messaging_binding_projected_address Optional parameter:
|
|
414
|
+
# The address of the Twilio phone number that is used in Group MMS. 'null'
|
|
415
|
+
# value will remove it.
|
|
416
|
+
# @param [Integer] last_read_message_index Optional parameter: Index of last
|
|
417
|
+
# “read” message in the
|
|
418
|
+
# [Conversation](https://www.twilio.com/docs/conversations/api/conversation-
|
|
419
|
+
# resource) for the Participant.
|
|
420
|
+
# @param [String] last_read_timestamp Optional parameter: Timestamp of last
|
|
421
|
+
# “read” message in the
|
|
422
|
+
# [Conversation](https://www.twilio.com/docs/conversations/api/conversation-
|
|
423
|
+
# resource) for the Participant.
|
|
424
|
+
# @return [ApiResponse] Complete http response with raw body and status code.
|
|
425
|
+
def update_service_conversation_participant(chat_service_sid,
|
|
426
|
+
conversation_sid,
|
|
427
|
+
sid,
|
|
428
|
+
x_twilio_webhook_enabled: nil,
|
|
429
|
+
date_created: nil,
|
|
430
|
+
date_updated: nil,
|
|
431
|
+
identity: nil,
|
|
432
|
+
attributes: nil,
|
|
433
|
+
role_sid: nil,
|
|
434
|
+
messaging_binding_proxy_address: nil,
|
|
435
|
+
messaging_binding_projected_address: nil,
|
|
436
|
+
last_read_message_index: nil,
|
|
437
|
+
last_read_timestamp: nil)
|
|
438
|
+
@api_call
|
|
439
|
+
.request(new_request_builder(HttpMethodEnum::POST,
|
|
440
|
+
'/v1/Services/{ChatServiceSid}/Conversations/{ConversationSid}/Participants/{Sid}',
|
|
441
|
+
Server::DEFAULT2)
|
|
442
|
+
.template_param(new_parameter(chat_service_sid, key: 'ChatServiceSid')
|
|
443
|
+
.is_required(true)
|
|
444
|
+
.should_encode(true))
|
|
445
|
+
.template_param(new_parameter(conversation_sid, key: 'ConversationSid')
|
|
446
|
+
.is_required(true)
|
|
447
|
+
.should_encode(true))
|
|
448
|
+
.template_param(new_parameter(sid, key: 'Sid')
|
|
449
|
+
.is_required(true)
|
|
450
|
+
.should_encode(true))
|
|
451
|
+
.header_param(new_parameter(x_twilio_webhook_enabled, key: 'X-Twilio-Webhook-Enabled'))
|
|
452
|
+
.form_param(new_parameter(date_created, key: 'DateCreated'))
|
|
453
|
+
.form_param(new_parameter(date_updated, key: 'DateUpdated'))
|
|
454
|
+
.form_param(new_parameter(identity, key: 'Identity'))
|
|
455
|
+
.form_param(new_parameter(attributes, key: 'Attributes'))
|
|
456
|
+
.form_param(new_parameter(role_sid, key: 'RoleSid'))
|
|
457
|
+
.form_param(new_parameter(messaging_binding_proxy_address, key: 'MessagingBinding.ProxyAddress'))
|
|
458
|
+
.form_param(new_parameter(messaging_binding_projected_address, key: 'MessagingBinding.ProjectedAddress'))
|
|
459
|
+
.form_param(new_parameter(last_read_message_index, key: 'LastReadMessageIndex'))
|
|
460
|
+
.form_param(new_parameter(last_read_timestamp, key: 'LastReadTimestamp'))
|
|
461
|
+
.header_param(new_parameter('application/x-www-form-urlencoded', key: 'content-type'))
|
|
462
|
+
.header_param(new_parameter('application/json', key: 'accept'))
|
|
463
|
+
.auth(Single.new('accountSid_authToken')))
|
|
464
|
+
.response(new_response_handler
|
|
465
|
+
.deserializer(APIHelper.method(:custom_type_deserializer))
|
|
466
|
+
.deserialize_into(ServiceConversationParticipant.method(:from_hash))
|
|
467
|
+
.is_api_response(true))
|
|
468
|
+
.execute
|
|
469
|
+
end
|
|
470
|
+
|
|
471
|
+
# Remove a participant from the conversation
|
|
472
|
+
# @param [String] chat_service_sid Required parameter: The SID of the
|
|
473
|
+
# [Conversation
|
|
474
|
+
# Service](https://www.twilio.com/docs/conversations/api/service-resource)
|
|
475
|
+
# the Participant resource is associated with.
|
|
476
|
+
# @param [String] conversation_sid Required parameter: The unique ID of the
|
|
477
|
+
# [Conversation](https://www.twilio.com/docs/conversations/api/conversation-
|
|
478
|
+
# resource) for this participant.
|
|
479
|
+
# @param [String] sid Required parameter: A 34 character string that
|
|
480
|
+
# uniquely identifies this resource.
|
|
481
|
+
# @param [ChannelWebhookEnabledType] x_twilio_webhook_enabled Optional
|
|
482
|
+
# parameter: The X-Twilio-Webhook-Enabled HTTP request header
|
|
483
|
+
# @return [ApiResponse] Complete http response with raw body and status code.
|
|
484
|
+
def delete_service_conversation_participant(chat_service_sid,
|
|
485
|
+
conversation_sid,
|
|
486
|
+
sid,
|
|
487
|
+
x_twilio_webhook_enabled: nil)
|
|
488
|
+
@api_call
|
|
489
|
+
.request(new_request_builder(HttpMethodEnum::DELETE,
|
|
490
|
+
'/v1/Services/{ChatServiceSid}/Conversations/{ConversationSid}/Participants/{Sid}',
|
|
491
|
+
Server::DEFAULT2)
|
|
492
|
+
.template_param(new_parameter(chat_service_sid, key: 'ChatServiceSid')
|
|
493
|
+
.is_required(true)
|
|
494
|
+
.should_encode(true))
|
|
495
|
+
.template_param(new_parameter(conversation_sid, key: 'ConversationSid')
|
|
496
|
+
.is_required(true)
|
|
497
|
+
.should_encode(true))
|
|
498
|
+
.template_param(new_parameter(sid, key: 'Sid')
|
|
499
|
+
.is_required(true)
|
|
500
|
+
.should_encode(true))
|
|
501
|
+
.header_param(new_parameter(x_twilio_webhook_enabled, key: 'X-Twilio-Webhook-Enabled'))
|
|
502
|
+
.auth(Single.new('accountSid_authToken')))
|
|
503
|
+
.response(new_response_handler
|
|
504
|
+
.is_response_void(true)
|
|
505
|
+
.is_api_response(true))
|
|
506
|
+
.execute
|
|
507
|
+
end
|
|
508
|
+
|
|
509
|
+
# Fetch a participant of the conversation
|
|
510
|
+
# @param [String] chat_service_sid Required parameter: The SID of the
|
|
511
|
+
# [Conversation
|
|
512
|
+
# Service](https://www.twilio.com/docs/conversations/api/service-resource)
|
|
513
|
+
# the Participant resource is associated with.
|
|
514
|
+
# @param [String] conversation_sid Required parameter: The unique ID of the
|
|
515
|
+
# [Conversation](https://www.twilio.com/docs/conversations/api/conversation-
|
|
516
|
+
# resource) for this participant.
|
|
517
|
+
# @param [String] sid Required parameter: A 34 character string that
|
|
518
|
+
# uniquely identifies this resource. Alternatively, you can pass a
|
|
519
|
+
# Participant's `identity` rather than the SID.
|
|
520
|
+
# @return [ApiResponse] Complete http response with raw body and status code.
|
|
521
|
+
def fetch_service_conversation_participant(chat_service_sid,
|
|
522
|
+
conversation_sid,
|
|
523
|
+
sid)
|
|
524
|
+
@api_call
|
|
525
|
+
.request(new_request_builder(HttpMethodEnum::GET,
|
|
526
|
+
'/v1/Services/{ChatServiceSid}/Conversations/{ConversationSid}/Participants/{Sid}',
|
|
527
|
+
Server::DEFAULT2)
|
|
528
|
+
.template_param(new_parameter(chat_service_sid, key: 'ChatServiceSid')
|
|
529
|
+
.is_required(true)
|
|
530
|
+
.should_encode(true))
|
|
531
|
+
.template_param(new_parameter(conversation_sid, key: 'ConversationSid')
|
|
532
|
+
.is_required(true)
|
|
533
|
+
.should_encode(true))
|
|
534
|
+
.template_param(new_parameter(sid, key: 'Sid')
|
|
535
|
+
.is_required(true)
|
|
536
|
+
.should_encode(true))
|
|
537
|
+
.header_param(new_parameter('application/json', key: 'accept'))
|
|
538
|
+
.auth(Single.new('accountSid_authToken')))
|
|
539
|
+
.response(new_response_handler
|
|
540
|
+
.deserializer(APIHelper.method(:custom_type_deserializer))
|
|
541
|
+
.deserialize_into(ServiceConversationParticipant.method(:from_hash))
|
|
542
|
+
.is_api_response(true))
|
|
543
|
+
.execute
|
|
544
|
+
end
|
|
545
|
+
end
|
|
546
|
+
end
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
# twilio_ap_is
|
|
2
|
+
#
|
|
3
|
+
# This file was automatically generated by APIMATIC v3.0 (
|
|
4
|
+
# https://www.apimatic.io ).
|
|
5
|
+
|
|
6
|
+
module TwilioApIs
|
|
7
|
+
# ConversationsV1ParticipantConversationApi
|
|
8
|
+
class ConversationsV1ParticipantConversationApi < BaseApi
|
|
9
|
+
# Retrieve a list of all Conversations that this Participant belongs to by
|
|
10
|
+
# identity or by address. Only one parameter should be specified.
|
|
11
|
+
# @param [String] identity Optional parameter: A unique string identifier
|
|
12
|
+
# for the conversation participant as [Conversation
|
|
13
|
+
# User](https://www.twilio.com/docs/conversations/api/user-resource). This
|
|
14
|
+
# parameter is non-null if (and only if) the participant is using the
|
|
15
|
+
# Conversations SDK to communicate. Limited to 256 characters.
|
|
16
|
+
# @param [String] address Optional parameter: A unique string identifier for
|
|
17
|
+
# the conversation participant who's not a Conversation User. This parameter
|
|
18
|
+
# could be found in messaging_binding.address field of Participant resource.
|
|
19
|
+
# It should be url-encoded.
|
|
20
|
+
# @param [Integer] page_size Optional parameter: How many resources to
|
|
21
|
+
# return in each list page. The default is 50, and the maximum is 50.
|
|
22
|
+
# @param [Integer] page Optional parameter: The page index. This value is
|
|
23
|
+
# simply for client state.
|
|
24
|
+
# @param [String] page_token Optional parameter: The page token. This is
|
|
25
|
+
# provided by the API.
|
|
26
|
+
# @return [ApiResponse] Complete http response with raw body and status code.
|
|
27
|
+
def list_participant_conversation(identity: nil,
|
|
28
|
+
address: nil,
|
|
29
|
+
page_size: nil,
|
|
30
|
+
page: nil,
|
|
31
|
+
page_token: nil)
|
|
32
|
+
@api_call
|
|
33
|
+
.request(new_request_builder(HttpMethodEnum::GET,
|
|
34
|
+
'/v1/ParticipantConversations',
|
|
35
|
+
Server::DEFAULT2)
|
|
36
|
+
.query_param(new_parameter(identity, key: 'Identity'))
|
|
37
|
+
.query_param(new_parameter(address, key: 'Address'))
|
|
38
|
+
.query_param(new_parameter(page_size, key: 'PageSize'))
|
|
39
|
+
.query_param(new_parameter(page, key: 'Page'))
|
|
40
|
+
.query_param(new_parameter(page_token, key: 'PageToken'))
|
|
41
|
+
.header_param(new_parameter('application/json', key: 'accept'))
|
|
42
|
+
.auth(Single.new('accountSid_authToken')))
|
|
43
|
+
.response(new_response_handler
|
|
44
|
+
.deserializer(APIHelper.method(:custom_type_deserializer))
|
|
45
|
+
.deserialize_into(ListParticipantConversationResponse.method(:from_hash))
|
|
46
|
+
.is_api_response(true))
|
|
47
|
+
.execute
|
|
48
|
+
end
|
|
49
|
+
|
|
50
|
+
# Retrieve a list of all Conversations that this Participant belongs to by
|
|
51
|
+
# identity or by address. Only one parameter should be specified.
|
|
52
|
+
# @param [String] chat_service_sid Required parameter: The SID of the
|
|
53
|
+
# [Conversation
|
|
54
|
+
# Service](https://www.twilio.com/docs/conversations/api/service-resource)
|
|
55
|
+
# the Participant Conversations resource is associated with.
|
|
56
|
+
# @param [String] identity Optional parameter: A unique string identifier
|
|
57
|
+
# for the conversation participant as [Conversation
|
|
58
|
+
# User](https://www.twilio.com/docs/conversations/api/user-resource). This
|
|
59
|
+
# parameter is non-null if (and only if) the participant is using the
|
|
60
|
+
# Conversations SDK to communicate. Limited to 256 characters.
|
|
61
|
+
# @param [String] address Optional parameter: A unique string identifier for
|
|
62
|
+
# the conversation participant who's not a Conversation User. This parameter
|
|
63
|
+
# could be found in messaging_binding.address field of Participant resource.
|
|
64
|
+
# It should be url-encoded.
|
|
65
|
+
# @param [Integer] page_size Optional parameter: How many resources to
|
|
66
|
+
# return in each list page. The default is 50, and the maximum is 50.
|
|
67
|
+
# @param [Integer] page Optional parameter: The page index. This value is
|
|
68
|
+
# simply for client state.
|
|
69
|
+
# @param [String] page_token Optional parameter: The page token. This is
|
|
70
|
+
# provided by the API.
|
|
71
|
+
# @return [ApiResponse] Complete http response with raw body and status code.
|
|
72
|
+
def list_service_participant_conversation(chat_service_sid,
|
|
73
|
+
identity: nil,
|
|
74
|
+
address: nil,
|
|
75
|
+
page_size: nil,
|
|
76
|
+
page: nil,
|
|
77
|
+
page_token: nil)
|
|
78
|
+
@api_call
|
|
79
|
+
.request(new_request_builder(HttpMethodEnum::GET,
|
|
80
|
+
'/v1/Services/{ChatServiceSid}/ParticipantConversations',
|
|
81
|
+
Server::DEFAULT2)
|
|
82
|
+
.template_param(new_parameter(chat_service_sid, key: 'ChatServiceSid')
|
|
83
|
+
.is_required(true)
|
|
84
|
+
.should_encode(true))
|
|
85
|
+
.query_param(new_parameter(identity, key: 'Identity'))
|
|
86
|
+
.query_param(new_parameter(address, key: 'Address'))
|
|
87
|
+
.query_param(new_parameter(page_size, key: 'PageSize'))
|
|
88
|
+
.query_param(new_parameter(page, key: 'Page'))
|
|
89
|
+
.query_param(new_parameter(page_token, key: 'PageToken'))
|
|
90
|
+
.header_param(new_parameter('application/json', key: 'accept'))
|
|
91
|
+
.auth(Single.new('accountSid_authToken')))
|
|
92
|
+
.response(new_response_handler
|
|
93
|
+
.deserializer(APIHelper.method(:custom_type_deserializer))
|
|
94
|
+
.deserialize_into(ListServiceParticipantConversationResponse.method(:from_hash))
|
|
95
|
+
.is_api_response(true))
|
|
96
|
+
.execute
|
|
97
|
+
end
|
|
98
|
+
end
|
|
99
|
+
end
|