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,270 @@
|
|
|
1
|
+
# twilio_ap_is
|
|
2
|
+
#
|
|
3
|
+
# This file was automatically generated by APIMATIC v3.0 (
|
|
4
|
+
# https://www.apimatic.io ).
|
|
5
|
+
|
|
6
|
+
require 'date'
|
|
7
|
+
module TwilioApIs
|
|
8
|
+
# Event Model.
|
|
9
|
+
class Event < BaseModel
|
|
10
|
+
SKIP = Object.new
|
|
11
|
+
private_constant :SKIP
|
|
12
|
+
|
|
13
|
+
# The SID of the [Account](https://www.twilio.com/docs/iam/api/account) that
|
|
14
|
+
# created the Event resource.
|
|
15
|
+
# @return [String]
|
|
16
|
+
attr_accessor :account_sid
|
|
17
|
+
|
|
18
|
+
# The SID of the resource that triggered the event.
|
|
19
|
+
# @return [String]
|
|
20
|
+
attr_accessor :actor_sid
|
|
21
|
+
|
|
22
|
+
# The type of resource that triggered the event.
|
|
23
|
+
# @return [String]
|
|
24
|
+
attr_accessor :actor_type
|
|
25
|
+
|
|
26
|
+
# The absolute URL of the resource that triggered the event.
|
|
27
|
+
# @return [String]
|
|
28
|
+
attr_accessor :actor_url
|
|
29
|
+
|
|
30
|
+
# A description of the event.
|
|
31
|
+
# @return [String]
|
|
32
|
+
attr_accessor :description
|
|
33
|
+
|
|
34
|
+
# Data about the event. For more information, see [Event
|
|
35
|
+
# types](https://www.twilio.com/docs/taskrouter/api/event#event-types).
|
|
36
|
+
# @return [Object]
|
|
37
|
+
attr_accessor :event_data
|
|
38
|
+
|
|
39
|
+
# The time the event was sent, specified in [ISO
|
|
40
|
+
# 8601](https://en.wikipedia.org/wiki/ISO_8601) format.
|
|
41
|
+
# @return [DateTime]
|
|
42
|
+
attr_accessor :event_date
|
|
43
|
+
|
|
44
|
+
# The time the event was sent in milliseconds.
|
|
45
|
+
# @return [Integer]
|
|
46
|
+
attr_accessor :event_date_ms
|
|
47
|
+
|
|
48
|
+
# The identifier for the event.
|
|
49
|
+
# @return [String]
|
|
50
|
+
attr_accessor :event_type
|
|
51
|
+
|
|
52
|
+
# The SID of the object the event is most relevant to, such as a TaskSid,
|
|
53
|
+
# ReservationSid, or a WorkerSid.
|
|
54
|
+
# @return [String]
|
|
55
|
+
attr_accessor :resource_sid
|
|
56
|
+
|
|
57
|
+
# The type of object the event is most relevant to, such as a Task,
|
|
58
|
+
# Reservation, or a Worker).
|
|
59
|
+
# @return [String]
|
|
60
|
+
attr_accessor :resource_type
|
|
61
|
+
|
|
62
|
+
# The URL of the resource the event is most relevant to.
|
|
63
|
+
# @return [String]
|
|
64
|
+
attr_accessor :resource_url
|
|
65
|
+
|
|
66
|
+
# The unique string that we created to identify the Event resource.
|
|
67
|
+
# @return [String]
|
|
68
|
+
attr_accessor :sid
|
|
69
|
+
|
|
70
|
+
# Where the Event originated.
|
|
71
|
+
# @return [String]
|
|
72
|
+
attr_accessor :source
|
|
73
|
+
|
|
74
|
+
# The IP from which the Event originated.
|
|
75
|
+
# @return [String]
|
|
76
|
+
attr_accessor :source_ip_address
|
|
77
|
+
|
|
78
|
+
# The absolute URL of the Event resource.
|
|
79
|
+
# @return [String]
|
|
80
|
+
attr_accessor :url
|
|
81
|
+
|
|
82
|
+
# The SID of the Workspace that contains the Event.
|
|
83
|
+
# @return [String]
|
|
84
|
+
attr_accessor :workspace_sid
|
|
85
|
+
|
|
86
|
+
# A mapping from model property names to API property names.
|
|
87
|
+
def self.names
|
|
88
|
+
@_hash = {} if @_hash.nil?
|
|
89
|
+
@_hash['account_sid'] = 'account_sid'
|
|
90
|
+
@_hash['actor_sid'] = 'actor_sid'
|
|
91
|
+
@_hash['actor_type'] = 'actor_type'
|
|
92
|
+
@_hash['actor_url'] = 'actor_url'
|
|
93
|
+
@_hash['description'] = 'description'
|
|
94
|
+
@_hash['event_data'] = 'event_data'
|
|
95
|
+
@_hash['event_date'] = 'event_date'
|
|
96
|
+
@_hash['event_date_ms'] = 'event_date_ms'
|
|
97
|
+
@_hash['event_type'] = 'event_type'
|
|
98
|
+
@_hash['resource_sid'] = 'resource_sid'
|
|
99
|
+
@_hash['resource_type'] = 'resource_type'
|
|
100
|
+
@_hash['resource_url'] = 'resource_url'
|
|
101
|
+
@_hash['sid'] = 'sid'
|
|
102
|
+
@_hash['source'] = 'source'
|
|
103
|
+
@_hash['source_ip_address'] = 'source_ip_address'
|
|
104
|
+
@_hash['url'] = 'url'
|
|
105
|
+
@_hash['workspace_sid'] = 'workspace_sid'
|
|
106
|
+
@_hash
|
|
107
|
+
end
|
|
108
|
+
|
|
109
|
+
# An array for optional fields
|
|
110
|
+
def self.optionals
|
|
111
|
+
%w[
|
|
112
|
+
account_sid
|
|
113
|
+
actor_sid
|
|
114
|
+
actor_type
|
|
115
|
+
actor_url
|
|
116
|
+
description
|
|
117
|
+
event_data
|
|
118
|
+
event_date
|
|
119
|
+
event_date_ms
|
|
120
|
+
event_type
|
|
121
|
+
resource_sid
|
|
122
|
+
resource_type
|
|
123
|
+
resource_url
|
|
124
|
+
sid
|
|
125
|
+
source
|
|
126
|
+
source_ip_address
|
|
127
|
+
url
|
|
128
|
+
workspace_sid
|
|
129
|
+
]
|
|
130
|
+
end
|
|
131
|
+
|
|
132
|
+
# An array for nullable fields
|
|
133
|
+
def self.nullables
|
|
134
|
+
%w[
|
|
135
|
+
account_sid
|
|
136
|
+
actor_sid
|
|
137
|
+
actor_type
|
|
138
|
+
actor_url
|
|
139
|
+
description
|
|
140
|
+
event_data
|
|
141
|
+
event_date
|
|
142
|
+
event_date_ms
|
|
143
|
+
event_type
|
|
144
|
+
resource_sid
|
|
145
|
+
resource_type
|
|
146
|
+
resource_url
|
|
147
|
+
sid
|
|
148
|
+
source
|
|
149
|
+
source_ip_address
|
|
150
|
+
url
|
|
151
|
+
workspace_sid
|
|
152
|
+
]
|
|
153
|
+
end
|
|
154
|
+
|
|
155
|
+
def initialize(account_sid: SKIP, actor_sid: SKIP, actor_type: SKIP,
|
|
156
|
+
actor_url: SKIP, description: SKIP, event_data: SKIP,
|
|
157
|
+
event_date: SKIP, event_date_ms: SKIP, event_type: SKIP,
|
|
158
|
+
resource_sid: SKIP, resource_type: SKIP, resource_url: SKIP,
|
|
159
|
+
sid: SKIP, source: SKIP, source_ip_address: SKIP, url: SKIP,
|
|
160
|
+
workspace_sid: SKIP, additional_properties: nil)
|
|
161
|
+
# Add additional model properties to the instance
|
|
162
|
+
additional_properties = {} if additional_properties.nil?
|
|
163
|
+
|
|
164
|
+
@account_sid = account_sid unless account_sid == SKIP
|
|
165
|
+
@actor_sid = actor_sid unless actor_sid == SKIP
|
|
166
|
+
@actor_type = actor_type unless actor_type == SKIP
|
|
167
|
+
@actor_url = actor_url unless actor_url == SKIP
|
|
168
|
+
@description = description unless description == SKIP
|
|
169
|
+
@event_data = event_data unless event_data == SKIP
|
|
170
|
+
@event_date = event_date unless event_date == SKIP
|
|
171
|
+
@event_date_ms = event_date_ms unless event_date_ms == SKIP
|
|
172
|
+
@event_type = event_type unless event_type == SKIP
|
|
173
|
+
@resource_sid = resource_sid unless resource_sid == SKIP
|
|
174
|
+
@resource_type = resource_type unless resource_type == SKIP
|
|
175
|
+
@resource_url = resource_url unless resource_url == SKIP
|
|
176
|
+
@sid = sid unless sid == SKIP
|
|
177
|
+
@source = source unless source == SKIP
|
|
178
|
+
@source_ip_address = source_ip_address unless source_ip_address == SKIP
|
|
179
|
+
@url = url unless url == SKIP
|
|
180
|
+
@workspace_sid = workspace_sid unless workspace_sid == SKIP
|
|
181
|
+
@additional_properties = additional_properties
|
|
182
|
+
end
|
|
183
|
+
|
|
184
|
+
# Creates an instance of the object from a hash.
|
|
185
|
+
def self.from_hash(hash)
|
|
186
|
+
return nil unless hash
|
|
187
|
+
|
|
188
|
+
# Extract variables from the hash.
|
|
189
|
+
account_sid = hash.key?('account_sid') ? hash['account_sid'] : SKIP
|
|
190
|
+
actor_sid = hash.key?('actor_sid') ? hash['actor_sid'] : SKIP
|
|
191
|
+
actor_type = hash.key?('actor_type') ? hash['actor_type'] : SKIP
|
|
192
|
+
actor_url = hash.key?('actor_url') ? hash['actor_url'] : SKIP
|
|
193
|
+
description = hash.key?('description') ? hash['description'] : SKIP
|
|
194
|
+
event_data = hash.key?('event_data') ? hash['event_data'] : SKIP
|
|
195
|
+
event_date = if hash.key?('event_date')
|
|
196
|
+
(DateTimeHelper.from_rfc3339(hash['event_date']) if hash['event_date'])
|
|
197
|
+
else
|
|
198
|
+
SKIP
|
|
199
|
+
end
|
|
200
|
+
event_date_ms = hash.key?('event_date_ms') ? hash['event_date_ms'] : SKIP
|
|
201
|
+
event_type = hash.key?('event_type') ? hash['event_type'] : SKIP
|
|
202
|
+
resource_sid = hash.key?('resource_sid') ? hash['resource_sid'] : SKIP
|
|
203
|
+
resource_type = hash.key?('resource_type') ? hash['resource_type'] : SKIP
|
|
204
|
+
resource_url = hash.key?('resource_url') ? hash['resource_url'] : SKIP
|
|
205
|
+
sid = hash.key?('sid') ? hash['sid'] : SKIP
|
|
206
|
+
source = hash.key?('source') ? hash['source'] : SKIP
|
|
207
|
+
source_ip_address =
|
|
208
|
+
hash.key?('source_ip_address') ? hash['source_ip_address'] : SKIP
|
|
209
|
+
url = hash.key?('url') ? hash['url'] : SKIP
|
|
210
|
+
workspace_sid = hash.key?('workspace_sid') ? hash['workspace_sid'] : SKIP
|
|
211
|
+
|
|
212
|
+
# Create a new hash for additional properties, removing known properties.
|
|
213
|
+
new_hash = hash.reject { |k, _| names.value?(k) }
|
|
214
|
+
|
|
215
|
+
additional_properties = APIHelper.get_additional_properties(
|
|
216
|
+
new_hash, proc { |value| value }
|
|
217
|
+
)
|
|
218
|
+
|
|
219
|
+
# Create object from extracted values.
|
|
220
|
+
Event.new(account_sid: account_sid,
|
|
221
|
+
actor_sid: actor_sid,
|
|
222
|
+
actor_type: actor_type,
|
|
223
|
+
actor_url: actor_url,
|
|
224
|
+
description: description,
|
|
225
|
+
event_data: event_data,
|
|
226
|
+
event_date: event_date,
|
|
227
|
+
event_date_ms: event_date_ms,
|
|
228
|
+
event_type: event_type,
|
|
229
|
+
resource_sid: resource_sid,
|
|
230
|
+
resource_type: resource_type,
|
|
231
|
+
resource_url: resource_url,
|
|
232
|
+
sid: sid,
|
|
233
|
+
source: source,
|
|
234
|
+
source_ip_address: source_ip_address,
|
|
235
|
+
url: url,
|
|
236
|
+
workspace_sid: workspace_sid,
|
|
237
|
+
additional_properties: additional_properties)
|
|
238
|
+
end
|
|
239
|
+
|
|
240
|
+
def to_custom_event_date
|
|
241
|
+
DateTimeHelper.to_rfc3339(event_date)
|
|
242
|
+
end
|
|
243
|
+
|
|
244
|
+
# Provides a human-readable string representation of the object.
|
|
245
|
+
def to_s
|
|
246
|
+
class_name = self.class.name.split('::').last
|
|
247
|
+
"<#{class_name} account_sid: #{@account_sid}, actor_sid: #{@actor_sid}, actor_type:"\
|
|
248
|
+
" #{@actor_type}, actor_url: #{@actor_url}, description: #{@description}, event_data:"\
|
|
249
|
+
" #{@event_data}, event_date: #{@event_date}, event_date_ms: #{@event_date_ms}, event_type:"\
|
|
250
|
+
" #{@event_type}, resource_sid: #{@resource_sid}, resource_type: #{@resource_type},"\
|
|
251
|
+
" resource_url: #{@resource_url}, sid: #{@sid}, source: #{@source}, source_ip_address:"\
|
|
252
|
+
" #{@source_ip_address}, url: #{@url}, workspace_sid: #{@workspace_sid},"\
|
|
253
|
+
" additional_properties: #{@additional_properties}>"
|
|
254
|
+
end
|
|
255
|
+
|
|
256
|
+
# Provides a debugging-friendly string with detailed object information.
|
|
257
|
+
def inspect
|
|
258
|
+
class_name = self.class.name.split('::').last
|
|
259
|
+
"<#{class_name} account_sid: #{@account_sid.inspect}, actor_sid: #{@actor_sid.inspect},"\
|
|
260
|
+
" actor_type: #{@actor_type.inspect}, actor_url: #{@actor_url.inspect}, description:"\
|
|
261
|
+
" #{@description.inspect}, event_data: #{@event_data.inspect}, event_date:"\
|
|
262
|
+
" #{@event_date.inspect}, event_date_ms: #{@event_date_ms.inspect}, event_type:"\
|
|
263
|
+
" #{@event_type.inspect}, resource_sid: #{@resource_sid.inspect}, resource_type:"\
|
|
264
|
+
" #{@resource_type.inspect}, resource_url: #{@resource_url.inspect}, sid: #{@sid.inspect},"\
|
|
265
|
+
" source: #{@source.inspect}, source_ip_address: #{@source_ip_address.inspect}, url:"\
|
|
266
|
+
" #{@url.inspect}, workspace_sid: #{@workspace_sid.inspect}, additional_properties:"\
|
|
267
|
+
" #{@additional_properties}>"
|
|
268
|
+
end
|
|
269
|
+
end
|
|
270
|
+
end
|
|
@@ -0,0 +1,235 @@
|
|
|
1
|
+
# twilio_ap_is
|
|
2
|
+
#
|
|
3
|
+
# This file was automatically generated by APIMATIC v3.0 (
|
|
4
|
+
# https://www.apimatic.io ).
|
|
5
|
+
|
|
6
|
+
require 'date'
|
|
7
|
+
module TwilioApIs
|
|
8
|
+
# Factor Model.
|
|
9
|
+
class Factor < BaseModel
|
|
10
|
+
SKIP = Object.new
|
|
11
|
+
private_constant :SKIP
|
|
12
|
+
|
|
13
|
+
# A 34 character string that uniquely identifies this Factor.
|
|
14
|
+
# @return [String]
|
|
15
|
+
attr_accessor :sid
|
|
16
|
+
|
|
17
|
+
# The unique SID identifier of the Account.
|
|
18
|
+
# @return [String]
|
|
19
|
+
attr_accessor :account_sid
|
|
20
|
+
|
|
21
|
+
# The unique SID identifier of the Service.
|
|
22
|
+
# @return [String]
|
|
23
|
+
attr_accessor :service_sid
|
|
24
|
+
|
|
25
|
+
# The unique SID identifier of the Entity.
|
|
26
|
+
# @return [String]
|
|
27
|
+
attr_accessor :entity_sid
|
|
28
|
+
|
|
29
|
+
# Customer unique identity for the Entity owner of the Factor. This
|
|
30
|
+
# identifier should be immutable, not PII, length between 8 and 64
|
|
31
|
+
# characters, and generated by your external system, such as your user's
|
|
32
|
+
# UUID, GUID, or SID. It can only contain dash (-) separated alphanumeric
|
|
33
|
+
# characters.
|
|
34
|
+
# @return [String]
|
|
35
|
+
attr_accessor :identity
|
|
36
|
+
|
|
37
|
+
# The date that this Factor was created, given in [ISO
|
|
38
|
+
# 8601](https://en.wikipedia.org/wiki/ISO_8601) format.
|
|
39
|
+
# @return [DateTime]
|
|
40
|
+
attr_accessor :date_created
|
|
41
|
+
|
|
42
|
+
# The date that this Factor was updated, given in [ISO
|
|
43
|
+
# 8601](https://en.wikipedia.org/wiki/ISO_8601) format.
|
|
44
|
+
# @return [DateTime]
|
|
45
|
+
attr_accessor :date_updated
|
|
46
|
+
|
|
47
|
+
# A human readable description of this resource, up to 64 characters. For a
|
|
48
|
+
# push factor, this can be the device's name.
|
|
49
|
+
# @return [String]
|
|
50
|
+
attr_accessor :friendly_name
|
|
51
|
+
|
|
52
|
+
# The Status of this Factor. One of `unverified` or `verified`.
|
|
53
|
+
# @return [FactorEnumFactorStatuses]
|
|
54
|
+
attr_accessor :status
|
|
55
|
+
|
|
56
|
+
# The Type of this Factor. Currently `push` and `totp` are supported.
|
|
57
|
+
# @return [FactorEnumFactorType]
|
|
58
|
+
attr_accessor :factor_type
|
|
59
|
+
|
|
60
|
+
# An object that contains configurations specific to a `factor_type`.
|
|
61
|
+
# @return [Object]
|
|
62
|
+
attr_accessor :config
|
|
63
|
+
|
|
64
|
+
# Custom metadata associated with the factor. This is added by the
|
|
65
|
+
# Device/SDK directly to allow for the inclusion of device information. It
|
|
66
|
+
# must be a stringified JSON with only strings values eg. `{"os":
|
|
67
|
+
# "Android"}`. Can be up to 1024 characters in length.
|
|
68
|
+
# @return [Object]
|
|
69
|
+
attr_accessor :metadata
|
|
70
|
+
|
|
71
|
+
# The URL of this resource.
|
|
72
|
+
# @return [String]
|
|
73
|
+
attr_accessor :url
|
|
74
|
+
|
|
75
|
+
# A mapping from model property names to API property names.
|
|
76
|
+
def self.names
|
|
77
|
+
@_hash = {} if @_hash.nil?
|
|
78
|
+
@_hash['sid'] = 'sid'
|
|
79
|
+
@_hash['account_sid'] = 'account_sid'
|
|
80
|
+
@_hash['service_sid'] = 'service_sid'
|
|
81
|
+
@_hash['entity_sid'] = 'entity_sid'
|
|
82
|
+
@_hash['identity'] = 'identity'
|
|
83
|
+
@_hash['date_created'] = 'date_created'
|
|
84
|
+
@_hash['date_updated'] = 'date_updated'
|
|
85
|
+
@_hash['friendly_name'] = 'friendly_name'
|
|
86
|
+
@_hash['status'] = 'status'
|
|
87
|
+
@_hash['factor_type'] = 'factor_type'
|
|
88
|
+
@_hash['config'] = 'config'
|
|
89
|
+
@_hash['metadata'] = 'metadata'
|
|
90
|
+
@_hash['url'] = 'url'
|
|
91
|
+
@_hash
|
|
92
|
+
end
|
|
93
|
+
|
|
94
|
+
# An array for optional fields
|
|
95
|
+
def self.optionals
|
|
96
|
+
%w[
|
|
97
|
+
sid
|
|
98
|
+
account_sid
|
|
99
|
+
service_sid
|
|
100
|
+
entity_sid
|
|
101
|
+
identity
|
|
102
|
+
date_created
|
|
103
|
+
date_updated
|
|
104
|
+
friendly_name
|
|
105
|
+
status
|
|
106
|
+
factor_type
|
|
107
|
+
config
|
|
108
|
+
metadata
|
|
109
|
+
url
|
|
110
|
+
]
|
|
111
|
+
end
|
|
112
|
+
|
|
113
|
+
# An array for nullable fields
|
|
114
|
+
def self.nullables
|
|
115
|
+
%w[
|
|
116
|
+
sid
|
|
117
|
+
account_sid
|
|
118
|
+
service_sid
|
|
119
|
+
entity_sid
|
|
120
|
+
identity
|
|
121
|
+
date_created
|
|
122
|
+
date_updated
|
|
123
|
+
friendly_name
|
|
124
|
+
config
|
|
125
|
+
metadata
|
|
126
|
+
url
|
|
127
|
+
]
|
|
128
|
+
end
|
|
129
|
+
|
|
130
|
+
def initialize(sid: SKIP, account_sid: SKIP, service_sid: SKIP,
|
|
131
|
+
entity_sid: SKIP, identity: SKIP, date_created: SKIP,
|
|
132
|
+
date_updated: SKIP, friendly_name: SKIP, status: SKIP,
|
|
133
|
+
factor_type: SKIP, config: SKIP, metadata: SKIP, url: SKIP,
|
|
134
|
+
additional_properties: nil)
|
|
135
|
+
# Add additional model properties to the instance
|
|
136
|
+
additional_properties = {} if additional_properties.nil?
|
|
137
|
+
|
|
138
|
+
@sid = sid unless sid == SKIP
|
|
139
|
+
@account_sid = account_sid unless account_sid == SKIP
|
|
140
|
+
@service_sid = service_sid unless service_sid == SKIP
|
|
141
|
+
@entity_sid = entity_sid unless entity_sid == SKIP
|
|
142
|
+
@identity = identity unless identity == SKIP
|
|
143
|
+
@date_created = date_created unless date_created == SKIP
|
|
144
|
+
@date_updated = date_updated unless date_updated == SKIP
|
|
145
|
+
@friendly_name = friendly_name unless friendly_name == SKIP
|
|
146
|
+
@status = status unless status == SKIP
|
|
147
|
+
@factor_type = factor_type unless factor_type == SKIP
|
|
148
|
+
@config = config unless config == SKIP
|
|
149
|
+
@metadata = metadata unless metadata == SKIP
|
|
150
|
+
@url = url unless url == SKIP
|
|
151
|
+
@additional_properties = additional_properties
|
|
152
|
+
end
|
|
153
|
+
|
|
154
|
+
# Creates an instance of the object from a hash.
|
|
155
|
+
def self.from_hash(hash)
|
|
156
|
+
return nil unless hash
|
|
157
|
+
|
|
158
|
+
# Extract variables from the hash.
|
|
159
|
+
sid = hash.key?('sid') ? hash['sid'] : SKIP
|
|
160
|
+
account_sid = hash.key?('account_sid') ? hash['account_sid'] : SKIP
|
|
161
|
+
service_sid = hash.key?('service_sid') ? hash['service_sid'] : SKIP
|
|
162
|
+
entity_sid = hash.key?('entity_sid') ? hash['entity_sid'] : SKIP
|
|
163
|
+
identity = hash.key?('identity') ? hash['identity'] : SKIP
|
|
164
|
+
date_created = if hash.key?('date_created')
|
|
165
|
+
(DateTimeHelper.from_rfc3339(hash['date_created']) if hash['date_created'])
|
|
166
|
+
else
|
|
167
|
+
SKIP
|
|
168
|
+
end
|
|
169
|
+
date_updated = if hash.key?('date_updated')
|
|
170
|
+
(DateTimeHelper.from_rfc3339(hash['date_updated']) if hash['date_updated'])
|
|
171
|
+
else
|
|
172
|
+
SKIP
|
|
173
|
+
end
|
|
174
|
+
friendly_name = hash.key?('friendly_name') ? hash['friendly_name'] : SKIP
|
|
175
|
+
status = hash.key?('status') ? hash['status'] : SKIP
|
|
176
|
+
factor_type = hash.key?('factor_type') ? hash['factor_type'] : SKIP
|
|
177
|
+
config = hash.key?('config') ? hash['config'] : SKIP
|
|
178
|
+
metadata = hash.key?('metadata') ? hash['metadata'] : SKIP
|
|
179
|
+
url = hash.key?('url') ? hash['url'] : SKIP
|
|
180
|
+
|
|
181
|
+
# Create a new hash for additional properties, removing known properties.
|
|
182
|
+
new_hash = hash.reject { |k, _| names.value?(k) }
|
|
183
|
+
|
|
184
|
+
additional_properties = APIHelper.get_additional_properties(
|
|
185
|
+
new_hash, proc { |value| value }
|
|
186
|
+
)
|
|
187
|
+
|
|
188
|
+
# Create object from extracted values.
|
|
189
|
+
Factor.new(sid: sid,
|
|
190
|
+
account_sid: account_sid,
|
|
191
|
+
service_sid: service_sid,
|
|
192
|
+
entity_sid: entity_sid,
|
|
193
|
+
identity: identity,
|
|
194
|
+
date_created: date_created,
|
|
195
|
+
date_updated: date_updated,
|
|
196
|
+
friendly_name: friendly_name,
|
|
197
|
+
status: status,
|
|
198
|
+
factor_type: factor_type,
|
|
199
|
+
config: config,
|
|
200
|
+
metadata: metadata,
|
|
201
|
+
url: url,
|
|
202
|
+
additional_properties: additional_properties)
|
|
203
|
+
end
|
|
204
|
+
|
|
205
|
+
def to_custom_date_created
|
|
206
|
+
DateTimeHelper.to_rfc3339(date_created)
|
|
207
|
+
end
|
|
208
|
+
|
|
209
|
+
def to_custom_date_updated
|
|
210
|
+
DateTimeHelper.to_rfc3339(date_updated)
|
|
211
|
+
end
|
|
212
|
+
|
|
213
|
+
# Provides a human-readable string representation of the object.
|
|
214
|
+
def to_s
|
|
215
|
+
class_name = self.class.name.split('::').last
|
|
216
|
+
"<#{class_name} sid: #{@sid}, account_sid: #{@account_sid}, service_sid: #{@service_sid},"\
|
|
217
|
+
" entity_sid: #{@entity_sid}, identity: #{@identity}, date_created: #{@date_created},"\
|
|
218
|
+
" date_updated: #{@date_updated}, friendly_name: #{@friendly_name}, status: #{@status},"\
|
|
219
|
+
" factor_type: #{@factor_type}, config: #{@config}, metadata: #{@metadata}, url: #{@url},"\
|
|
220
|
+
" additional_properties: #{@additional_properties}>"
|
|
221
|
+
end
|
|
222
|
+
|
|
223
|
+
# Provides a debugging-friendly string with detailed object information.
|
|
224
|
+
def inspect
|
|
225
|
+
class_name = self.class.name.split('::').last
|
|
226
|
+
"<#{class_name} sid: #{@sid.inspect}, account_sid: #{@account_sid.inspect}, service_sid:"\
|
|
227
|
+
" #{@service_sid.inspect}, entity_sid: #{@entity_sid.inspect}, identity:"\
|
|
228
|
+
" #{@identity.inspect}, date_created: #{@date_created.inspect}, date_updated:"\
|
|
229
|
+
" #{@date_updated.inspect}, friendly_name: #{@friendly_name.inspect}, status:"\
|
|
230
|
+
" #{@status.inspect}, factor_type: #{@factor_type.inspect}, config: #{@config.inspect},"\
|
|
231
|
+
" metadata: #{@metadata.inspect}, url: #{@url.inspect}, additional_properties:"\
|
|
232
|
+
" #{@additional_properties}>"
|
|
233
|
+
end
|
|
234
|
+
end
|
|
235
|
+
end
|
|
@@ -0,0 +1,36 @@
|
|
|
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
|
+
# The Status of this Factor. One of `unverified` or `verified`.
|
|
8
|
+
class FactorEnumFactorStatuses
|
|
9
|
+
FACTOR_ENUM_FACTOR_STATUSES = [
|
|
10
|
+
# TODO: Write general description for UNVERIFIED
|
|
11
|
+
UNVERIFIED = 'unverified'.freeze,
|
|
12
|
+
|
|
13
|
+
# TODO: Write general description for VERIFIED
|
|
14
|
+
VERIFIED = 'verified'.freeze
|
|
15
|
+
].freeze
|
|
16
|
+
|
|
17
|
+
def self.validate(value)
|
|
18
|
+
return false if value.nil?
|
|
19
|
+
|
|
20
|
+
FACTOR_ENUM_FACTOR_STATUSES.include?(value)
|
|
21
|
+
end
|
|
22
|
+
|
|
23
|
+
def self.from_value(value, default_value = UNVERIFIED)
|
|
24
|
+
return default_value if value.nil?
|
|
25
|
+
|
|
26
|
+
str = value.to_s.strip
|
|
27
|
+
|
|
28
|
+
case str.downcase
|
|
29
|
+
when 'unverified' then UNVERIFIED
|
|
30
|
+
when 'verified' then VERIFIED
|
|
31
|
+
else
|
|
32
|
+
default_value
|
|
33
|
+
end
|
|
34
|
+
end
|
|
35
|
+
end
|
|
36
|
+
end
|
|
@@ -0,0 +1,40 @@
|
|
|
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
|
+
# The Type of this Factor. Currently `push` and `totp` are supported.
|
|
8
|
+
class FactorEnumFactorType
|
|
9
|
+
FACTOR_ENUM_FACTOR_TYPE = [
|
|
10
|
+
# TODO: Write general description for PUSH
|
|
11
|
+
PUSH = 'push'.freeze,
|
|
12
|
+
|
|
13
|
+
# TODO: Write general description for TOTP
|
|
14
|
+
TOTP = 'totp'.freeze,
|
|
15
|
+
|
|
16
|
+
# TODO: Write general description for PASSKEYS
|
|
17
|
+
PASSKEYS = 'passkeys'.freeze
|
|
18
|
+
].freeze
|
|
19
|
+
|
|
20
|
+
def self.validate(value)
|
|
21
|
+
return false if value.nil?
|
|
22
|
+
|
|
23
|
+
FACTOR_ENUM_FACTOR_TYPE.include?(value)
|
|
24
|
+
end
|
|
25
|
+
|
|
26
|
+
def self.from_value(value, default_value = PUSH)
|
|
27
|
+
return default_value if value.nil?
|
|
28
|
+
|
|
29
|
+
str = value.to_s.strip
|
|
30
|
+
|
|
31
|
+
case str.downcase
|
|
32
|
+
when 'push' then PUSH
|
|
33
|
+
when 'totp' then TOTP
|
|
34
|
+
when 'passkeys' then PASSKEYS
|
|
35
|
+
else
|
|
36
|
+
default_value
|
|
37
|
+
end
|
|
38
|
+
end
|
|
39
|
+
end
|
|
40
|
+
end
|
|
@@ -0,0 +1,40 @@
|
|
|
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
|
+
# FactorEnumNotificationPlatforms.
|
|
8
|
+
class FactorEnumNotificationPlatforms
|
|
9
|
+
FACTOR_ENUM_NOTIFICATION_PLATFORMS = [
|
|
10
|
+
# TODO: Write general description for APN
|
|
11
|
+
APN = 'apn'.freeze,
|
|
12
|
+
|
|
13
|
+
# TODO: Write general description for FCM
|
|
14
|
+
FCM = 'fcm'.freeze,
|
|
15
|
+
|
|
16
|
+
# TODO: Write general description for NONE
|
|
17
|
+
NONE = 'none'.freeze
|
|
18
|
+
].freeze
|
|
19
|
+
|
|
20
|
+
def self.validate(value)
|
|
21
|
+
return false if value.nil?
|
|
22
|
+
|
|
23
|
+
FACTOR_ENUM_NOTIFICATION_PLATFORMS.include?(value)
|
|
24
|
+
end
|
|
25
|
+
|
|
26
|
+
def self.from_value(value, default_value = APN)
|
|
27
|
+
return default_value if value.nil?
|
|
28
|
+
|
|
29
|
+
str = value.to_s.strip
|
|
30
|
+
|
|
31
|
+
case str.downcase
|
|
32
|
+
when 'apn' then APN
|
|
33
|
+
when 'fcm' then FCM
|
|
34
|
+
when 'none' then NONE
|
|
35
|
+
else
|
|
36
|
+
default_value
|
|
37
|
+
end
|
|
38
|
+
end
|
|
39
|
+
end
|
|
40
|
+
end
|
|
@@ -0,0 +1,40 @@
|
|
|
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
|
+
# FactorEnumTotpAlgorithms.
|
|
8
|
+
class FactorEnumTotpAlgorithms
|
|
9
|
+
FACTOR_ENUM_TOTP_ALGORITHMS = [
|
|
10
|
+
# TODO: Write general description for SHA1
|
|
11
|
+
SHA1 = 'sha1'.freeze,
|
|
12
|
+
|
|
13
|
+
# TODO: Write general description for SHA256
|
|
14
|
+
SHA256 = 'sha256'.freeze,
|
|
15
|
+
|
|
16
|
+
# TODO: Write general description for SHA512
|
|
17
|
+
SHA512 = 'sha512'.freeze
|
|
18
|
+
].freeze
|
|
19
|
+
|
|
20
|
+
def self.validate(value)
|
|
21
|
+
return false if value.nil?
|
|
22
|
+
|
|
23
|
+
FACTOR_ENUM_TOTP_ALGORITHMS.include?(value)
|
|
24
|
+
end
|
|
25
|
+
|
|
26
|
+
def self.from_value(value, default_value = SHA1)
|
|
27
|
+
return default_value if value.nil?
|
|
28
|
+
|
|
29
|
+
str = value.to_s.strip
|
|
30
|
+
|
|
31
|
+
case str.downcase
|
|
32
|
+
when 'sha1' then SHA1
|
|
33
|
+
when 'sha256' then SHA256
|
|
34
|
+
when 'sha512' then SHA512
|
|
35
|
+
else
|
|
36
|
+
default_value
|
|
37
|
+
end
|
|
38
|
+
end
|
|
39
|
+
end
|
|
40
|
+
end
|
|
@@ -0,0 +1,26 @@
|
|
|
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
|
+
# The Type of this Form. Currently only `form-push` is supported.
|
|
8
|
+
class FormEnumFormTypes
|
|
9
|
+
FORM_ENUM_FORM_TYPES = [
|
|
10
|
+
# TODO: Write general description for FORMPUSH
|
|
11
|
+
FORMPUSH = 'form-push'.freeze
|
|
12
|
+
].freeze
|
|
13
|
+
|
|
14
|
+
def self.validate(value)
|
|
15
|
+
return false if value.nil?
|
|
16
|
+
|
|
17
|
+
FORM_ENUM_FORM_TYPES.include?(value)
|
|
18
|
+
end
|
|
19
|
+
|
|
20
|
+
def self.from_value(value, default_value = FORMPUSH)
|
|
21
|
+
return default_value if value.nil?
|
|
22
|
+
|
|
23
|
+
default_value
|
|
24
|
+
end
|
|
25
|
+
end
|
|
26
|
+
end
|