twilio-ruby 5.67.3 → 5.74.5

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.
Files changed (216) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/pr-lint.yml +8 -2
  3. data/.github/workflows/test-and-deploy.yml +3 -3
  4. data/CHANGES.md +288 -0
  5. data/LICENSE +1 -1
  6. data/Makefile +6 -2
  7. data/PULL_REQUEST_TEMPLATE.md +1 -1
  8. data/README.md +2 -2
  9. data/lib/twilio-ruby/rest/api/v2010/account/address.rb +19 -3
  10. data/lib/twilio-ruby/rest/api/v2010/account/application.rb +22 -3
  11. data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number/local.rb +2 -2
  12. data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number/machine_to_machine.rb +2 -2
  13. data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number/mobile.rb +2 -2
  14. data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number/national.rb +2 -2
  15. data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number/shared_cost.rb +2 -2
  16. data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number/toll_free.rb +2 -2
  17. data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number/voip.rb +2 -2
  18. data/lib/twilio-ruby/rest/api/v2010/account/call/feedback.rb +1 -1
  19. data/lib/twilio-ruby/rest/api/v2010/account/call/feedback_summary.rb +5 -5
  20. data/lib/twilio-ruby/rest/api/v2010/account/call/recording.rb +2 -2
  21. data/lib/twilio-ruby/rest/api/v2010/account/call/user_defined_message.rb +160 -0
  22. data/lib/twilio-ruby/rest/api/v2010/account/call/user_defined_message_subscription.rb +251 -0
  23. data/lib/twilio-ruby/rest/api/v2010/account/call.rb +59 -0
  24. data/lib/twilio-ruby/rest/api/v2010/account/conference/participant.rb +56 -17
  25. data/lib/twilio-ruby/rest/api/v2010/account/conference/recording.rb +1 -1
  26. data/lib/twilio-ruby/rest/api/v2010/account/conference.rb +5 -5
  27. data/lib/twilio-ruby/rest/api/v2010/account/message.rb +17 -1
  28. data/lib/twilio-ruby/rest/api/v2010/account/queue/member.rb +2 -2
  29. data/lib/twilio-ruby/rest/api/v2010/account/queue.rb +3 -3
  30. data/lib/twilio-ruby/rest/api/v2010/account/recording/transcription.rb +1 -1
  31. data/lib/twilio-ruby/rest/api/v2010/account/recording.rb +1 -1
  32. data/lib/twilio-ruby/rest/api/v2010/account/sip/ip_access_control_list/ip_address.rb +5 -5
  33. data/lib/twilio-ruby/rest/api/v2010/account/sip/ip_access_control_list.rb +3 -3
  34. data/lib/twilio-ruby/rest/api/v2010/account/transcription.rb +1 -1
  35. data/lib/twilio-ruby/rest/api/v2010/account/usage/record/all_time.rb +1 -1
  36. data/lib/twilio-ruby/rest/api/v2010/account/usage/record/daily.rb +1 -1
  37. data/lib/twilio-ruby/rest/api/v2010/account/usage/record/last_month.rb +1 -1
  38. data/lib/twilio-ruby/rest/api/v2010/account/usage/record/monthly.rb +1 -1
  39. data/lib/twilio-ruby/rest/api/v2010/account/usage/record/this_month.rb +1 -1
  40. data/lib/twilio-ruby/rest/api/v2010/account/usage/record/today.rb +1 -1
  41. data/lib/twilio-ruby/rest/api/v2010/account/usage/record/yearly.rb +1 -1
  42. data/lib/twilio-ruby/rest/api/v2010/account/usage/record/yesterday.rb +1 -1
  43. data/lib/twilio-ruby/rest/api/v2010/account/usage/record.rb +1 -1
  44. data/lib/twilio-ruby/rest/autopilot/v1/assistant/task/task_statistics.rb +2 -2
  45. data/lib/twilio-ruby/rest/bulkexports/v1/export/day.rb +1 -1
  46. data/lib/twilio-ruby/rest/chat/v1/service/channel/message.rb +1 -1
  47. data/lib/twilio-ruby/rest/chat/v1/service/channel.rb +2 -2
  48. data/lib/twilio-ruby/rest/chat/v1/service/user.rb +1 -1
  49. data/lib/twilio-ruby/rest/chat/v1/service.rb +2 -2
  50. data/lib/twilio-ruby/rest/chat/v2/service/channel/message.rb +1 -1
  51. data/lib/twilio-ruby/rest/chat/v2/service/channel.rb +2 -2
  52. data/lib/twilio-ruby/rest/chat/v2/service/user.rb +1 -1
  53. data/lib/twilio-ruby/rest/chat/v2/service.rb +4 -4
  54. data/lib/twilio-ruby/rest/chat/v3/channel.rb +2 -2
  55. data/lib/twilio-ruby/rest/client.rb +28 -0
  56. data/lib/twilio-ruby/rest/content/v1/content/approval_fetch.rb +195 -0
  57. data/lib/twilio-ruby/rest/content/v1/content.rb +346 -0
  58. data/lib/twilio-ruby/rest/content/v1/legacy_content.rb +254 -0
  59. data/lib/twilio-ruby/rest/content/v1.rb +52 -0
  60. data/lib/twilio-ruby/rest/content.rb +53 -0
  61. data/lib/twilio-ruby/rest/conversations/v1/conversation/message/delivery_receipt.rb +1 -1
  62. data/lib/twilio-ruby/rest/conversations/v1/conversation/message.rb +17 -2
  63. data/lib/twilio-ruby/rest/conversations/v1/service/conversation/message/delivery_receipt.rb +1 -1
  64. data/lib/twilio-ruby/rest/conversations/v1/service/conversation/message.rb +17 -2
  65. data/lib/twilio-ruby/rest/events/v1/schema/version.rb +1 -1
  66. data/lib/twilio-ruby/rest/events/v1/schema.rb +1 -1
  67. data/lib/twilio-ruby/rest/events/v1/subscription/subscribed_event.rb +1 -1
  68. data/lib/twilio-ruby/rest/flex_api/v1/assessments.rb +397 -0
  69. data/lib/twilio-ruby/rest/flex_api/v1/configuration.rb +14 -0
  70. data/lib/twilio-ruby/rest/flex_api/v1/insights_assessments_comment.rb +314 -0
  71. data/lib/twilio-ruby/rest/flex_api/v1/insights_questionnaires.rb +394 -0
  72. data/lib/twilio-ruby/rest/flex_api/v1/insights_questionnaires_category.rb +313 -0
  73. data/lib/twilio-ruby/rest/flex_api/v1/insights_questionnaires_question.rb +390 -0
  74. data/lib/twilio-ruby/rest/flex_api/v1/insights_segments.rb +413 -0
  75. data/lib/twilio-ruby/rest/{preview/trusted_comms/brands_information.rb → flex_api/v1/insights_session.rb} +58 -55
  76. data/lib/twilio-ruby/rest/flex_api/v1/insights_settings_answersets.rb +144 -0
  77. data/lib/twilio-ruby/rest/flex_api/v1/insights_settings_comment.rb +130 -0
  78. data/lib/twilio-ruby/rest/{preview/trusted_comms/cps.rb → flex_api/v1/insights_user_roles.rb} +42 -54
  79. data/lib/twilio-ruby/rest/flex_api/v1/interaction/interaction_channel.rb +22 -1
  80. data/lib/twilio-ruby/rest/flex_api/v1.rb +115 -0
  81. data/lib/twilio-ruby/rest/flex_api/v2/web_channels.rb +133 -0
  82. data/lib/twilio-ruby/rest/flex_api/v2.rb +35 -0
  83. data/lib/twilio-ruby/rest/flex_api.rb +83 -0
  84. data/lib/twilio-ruby/rest/insights/v1/call/annotation.rb +322 -0
  85. data/lib/twilio-ruby/rest/insights/v1/call/summary.rb +14 -0
  86. data/lib/twilio-ruby/rest/insights/v1/call.rb +16 -8
  87. data/lib/twilio-ruby/rest/insights/v1/call_summaries.rb +7 -0
  88. data/lib/twilio-ruby/rest/insights/v1/room/participant.rb +1 -1
  89. data/lib/twilio-ruby/rest/insights/v1/room.rb +3 -3
  90. data/lib/twilio-ruby/rest/insights/v1.rb +0 -16
  91. data/lib/twilio-ruby/rest/insights.rb +0 -8
  92. data/lib/twilio-ruby/rest/ip_messaging/v1/service/channel/message.rb +1 -1
  93. data/lib/twilio-ruby/rest/ip_messaging/v1/service/channel.rb +2 -2
  94. data/lib/twilio-ruby/rest/ip_messaging/v1/service/user.rb +1 -1
  95. data/lib/twilio-ruby/rest/ip_messaging/v1/service.rb +2 -2
  96. data/lib/twilio-ruby/rest/ip_messaging/v2/service/channel/message.rb +1 -1
  97. data/lib/twilio-ruby/rest/ip_messaging/v2/service/channel.rb +2 -2
  98. data/lib/twilio-ruby/rest/ip_messaging/v2/service/user.rb +1 -1
  99. data/lib/twilio-ruby/rest/ip_messaging/v2/service.rb +4 -4
  100. data/lib/twilio-ruby/rest/lookups/v2/phone_number.rb +94 -12
  101. data/lib/twilio-ruby/rest/media/v1/media_processor.rb +1 -1
  102. data/lib/twilio-ruby/rest/media/v1/media_recording.rb +2 -9
  103. data/lib/twilio-ruby/rest/media/v1/player_streamer.rb +5 -5
  104. data/lib/twilio-ruby/rest/messaging/v1/domain_cert.rb +257 -0
  105. data/lib/twilio-ruby/rest/messaging/v1/domain_config.rb +267 -0
  106. data/lib/twilio-ruby/rest/messaging/v1/service/alpha_sender.rb +2 -2
  107. data/lib/twilio-ruby/rest/messaging/v1/service/us_app_to_person.rb +98 -3
  108. data/lib/twilio-ruby/rest/messaging/v1/service.rb +1 -1
  109. data/lib/twilio-ruby/rest/messaging/v1/tollfree_verification.rb +709 -0
  110. data/lib/twilio-ruby/rest/messaging/v1.rb +50 -0
  111. data/lib/twilio-ruby/rest/messaging.rb +26 -0
  112. data/lib/twilio-ruby/rest/microvisor/v1/account_config.rb +317 -0
  113. data/lib/twilio-ruby/rest/microvisor/v1/account_secret.rb +310 -0
  114. data/lib/twilio-ruby/rest/microvisor/v1/app/app_manifest.rb +192 -0
  115. data/lib/twilio-ruby/rest/microvisor/v1/app.rb +330 -0
  116. data/lib/twilio-ruby/rest/microvisor/v1/device/device_config.rb +342 -0
  117. data/lib/twilio-ruby/rest/{preview/bulk_exports/export/day.rb → microvisor/v1/device/device_secret.rb} +125 -84
  118. data/lib/twilio-ruby/rest/microvisor/v1/device.rb +393 -0
  119. data/lib/twilio-ruby/rest/microvisor/v1.rb +92 -0
  120. data/lib/twilio-ruby/rest/microvisor.rb +70 -0
  121. data/lib/twilio-ruby/rest/notify/v1/service/notification.rb +1 -1
  122. data/lib/twilio-ruby/rest/oauth/v1/device_code.rb +153 -0
  123. data/lib/twilio-ruby/rest/oauth/v1/oauth.rb +162 -0
  124. data/lib/twilio-ruby/rest/oauth/v1/openid_discovery.rb +242 -0
  125. data/lib/twilio-ruby/rest/oauth/v1/token.rb +157 -0
  126. data/lib/twilio-ruby/rest/oauth/v1/user_info.rb +193 -0
  127. data/lib/twilio-ruby/rest/oauth/v1.rb +63 -0
  128. data/lib/twilio-ruby/rest/oauth.rb +68 -0
  129. data/lib/twilio-ruby/rest/preview/hosted_numbers/authorization_document/dependent_hosted_number_order.rb +2 -2
  130. data/lib/twilio-ruby/rest/preview/hosted_numbers/hosted_number_order.rb +2 -2
  131. data/lib/twilio-ruby/rest/preview/sync/service/sync_list/sync_list_item.rb +1 -1
  132. data/lib/twilio-ruby/rest/preview/understand/assistant/task/task_statistics.rb +2 -2
  133. data/lib/twilio-ruby/rest/preview/wireless/rate_plan.rb +1 -1
  134. data/lib/twilio-ruby/rest/preview.rb +0 -58
  135. data/lib/twilio-ruby/rest/proxy/v1/service/phone_number.rb +1 -1
  136. data/lib/twilio-ruby/rest/proxy/v1/service/session/participant.rb +1 -14
  137. data/lib/twilio-ruby/rest/proxy/v1/service/session.rb +5 -46
  138. data/lib/twilio-ruby/rest/proxy/v1/service.rb +1 -1
  139. data/lib/twilio-ruby/rest/routes/v2/phone_number.rb +235 -0
  140. data/lib/twilio-ruby/rest/routes/v2/sip_domain.rb +231 -0
  141. data/lib/twilio-ruby/rest/routes/v2/trunk.rb +235 -0
  142. data/lib/twilio-ruby/rest/routes/v2.rb +76 -0
  143. data/lib/twilio-ruby/rest/routes.rb +62 -0
  144. data/lib/twilio-ruby/rest/studio/v1/flow.rb +1 -1
  145. data/lib/twilio-ruby/rest/studio/v2/flow/flow_revision.rb +1 -1
  146. data/lib/twilio-ruby/rest/studio/v2/flow.rb +1 -1
  147. data/lib/twilio-ruby/rest/supersim/v1/esim_profile.rb +21 -1
  148. data/lib/twilio-ruby/rest/supersim/v1/fleet.rb +17 -7
  149. data/lib/twilio-ruby/rest/supersim/v1/ip_command.rb +5 -2
  150. data/lib/twilio-ruby/rest/supersim/v1/settings_update.rb +247 -0
  151. data/lib/twilio-ruby/rest/supersim/v1/sim/sim_ip_address.rb +195 -0
  152. data/lib/twilio-ruby/rest/supersim/v1/sim.rb +20 -0
  153. data/lib/twilio-ruby/rest/supersim/v1/sms_command.rb +3 -3
  154. data/lib/twilio-ruby/rest/supersim/v1/usage_record.rb +4 -4
  155. data/lib/twilio-ruby/rest/supersim/v1.rb +7 -0
  156. data/lib/twilio-ruby/rest/supersim.rb +6 -0
  157. data/lib/twilio-ruby/rest/sync/v1/service/sync_list/sync_list_item.rb +1 -1
  158. data/lib/twilio-ruby/rest/sync/v1/service.rb +1 -1
  159. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/event.rb +1 -1
  160. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task/reservation.rb +18 -5
  161. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task.rb +3 -3
  162. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue/task_queue_cumulative_statistics.rb +12 -12
  163. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue/task_queue_real_time_statistics.rb +5 -5
  164. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue.rb +10 -4
  165. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker/worker_channel.rb +3 -3
  166. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker/workers_cumulative_statistics.rb +6 -6
  167. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker/workers_real_time_statistics.rb +1 -1
  168. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker.rb +9 -3
  169. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workflow/workflow_cumulative_statistics.rb +13 -13
  170. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workflow/workflow_real_time_statistics.rb +2 -2
  171. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workflow.rb +1 -1
  172. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workspace_cumulative_statistics.rb +13 -13
  173. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workspace_real_time_statistics.rb +3 -3
  174. data/lib/twilio-ruby/rest/trunking/v1/trunk/origination_url.rb +2 -2
  175. data/lib/twilio-ruby/rest/verify/v2/safelist.rb +215 -0
  176. data/lib/twilio-ruby/rest/verify/v2/service/access_token.rb +1 -9
  177. data/lib/twilio-ruby/rest/verify/v2/service/entity/challenge/notification.rb +1 -7
  178. data/lib/twilio-ruby/rest/verify/v2/service/entity/challenge.rb +0 -8
  179. data/lib/twilio-ruby/rest/verify/v2/service/entity/factor.rb +0 -8
  180. data/lib/twilio-ruby/rest/verify/v2/service/entity/new_factor.rb +0 -6
  181. data/lib/twilio-ruby/rest/verify/v2/service/entity.rb +0 -8
  182. data/lib/twilio-ruby/rest/verify/v2/service/rate_limit/bucket.rb +2 -2
  183. data/lib/twilio-ruby/rest/verify/v2/service/verification.rb +14 -10
  184. data/lib/twilio-ruby/rest/verify/v2/service/verification_check.rb +8 -1
  185. data/lib/twilio-ruby/rest/verify/v2/service/webhook.rb +0 -8
  186. data/lib/twilio-ruby/rest/verify/v2/service.rb +1 -1
  187. data/lib/twilio-ruby/rest/verify/v2/template.rb +7 -0
  188. data/lib/twilio-ruby/rest/verify/v2/verification_attempts_summary.rb +4 -4
  189. data/lib/twilio-ruby/rest/verify/v2.rb +18 -0
  190. data/lib/twilio-ruby/rest/verify.rb +8 -0
  191. data/lib/twilio-ruby/rest/video/v1/composition.rb +3 -3
  192. data/lib/twilio-ruby/rest/video/v1/recording.rb +2 -2
  193. data/lib/twilio-ruby/rest/video/v1/room/recording.rb +2 -2
  194. data/lib/twilio-ruby/rest/video/v1/room/room_participant/room_participant_anonymize.rb +240 -0
  195. data/lib/twilio-ruby/rest/video/v1/room/room_participant.rb +16 -0
  196. data/lib/twilio-ruby/rest/video/v1/room.rb +4 -4
  197. data/lib/twilio-ruby/rest/voice/v1/connection_policy/connection_policy_target.rb +2 -2
  198. data/lib/twilio-ruby/rest/voice/v1/dialing_permissions/bulk_country_update.rb +1 -1
  199. data/lib/twilio-ruby/rest/voice/v1/ip_record.rb +1 -1
  200. data/lib/twilio-ruby/rest/wireless/v1/rate_plan.rb +3 -3
  201. data/lib/twilio-ruby/rest/wireless/v1/sim/data_session.rb +2 -2
  202. data/lib/twilio-ruby/security/request_validator.rb +1 -1
  203. data/lib/twilio-ruby/twiml/voice_response.rb +135 -35
  204. data/lib/twilio-ruby/version.rb +1 -1
  205. data/twilio-ruby.gemspec +1 -1
  206. metadata +52 -17
  207. data/lib/twilio-ruby/rest/insights/v1/annotation.rb +0 -271
  208. data/lib/twilio-ruby/rest/preview/bulk_exports/export/export_custom_job.rb +0 -275
  209. data/lib/twilio-ruby/rest/preview/bulk_exports/export/job.rb +0 -249
  210. data/lib/twilio-ruby/rest/preview/bulk_exports/export.rb +0 -251
  211. data/lib/twilio-ruby/rest/preview/bulk_exports/export_configuration.rb +0 -234
  212. data/lib/twilio-ruby/rest/preview/bulk_exports.rb +0 -62
  213. data/lib/twilio-ruby/rest/preview/trusted_comms/branded_channel/channel.rb +0 -165
  214. data/lib/twilio-ruby/rest/preview/trusted_comms/branded_channel.rb +0 -225
  215. data/lib/twilio-ruby/rest/preview/trusted_comms/current_call.rb +0 -277
  216. data/lib/twilio-ruby/rest/preview/trusted_comms.rb +0 -65
@@ -0,0 +1,144 @@
1
+ ##
2
+ # This code was generated by
3
+ # \ / _ _ _| _ _
4
+ # | (_)\/(_)(_|\/| |(/_ v1.0.0
5
+ # / /
6
+ #
7
+ # frozen_string_literal: true
8
+
9
+ module Twilio
10
+ module REST
11
+ class FlexApi < Domain
12
+ class V1 < Version
13
+ ##
14
+ # PLEASE NOTE that this class contains preview products that are subject to change. Use them with caution. If you currently do not have developer preview access, please contact help@twilio.com.
15
+ class InsightsSettingsAnswerSetsList < ListResource
16
+ ##
17
+ # Initialize the InsightsSettingsAnswerSetsList
18
+ # @param [Version] version Version that contains the resource
19
+ # @return [InsightsSettingsAnswerSetsList] InsightsSettingsAnswerSetsList
20
+ def initialize(version)
21
+ super(version)
22
+
23
+ # Path Solution
24
+ @solution = {}
25
+ @uri = "/Insights/QM/Settings/AnswerSets"
26
+ end
27
+
28
+ ##
29
+ # Fetch the InsightsSettingsAnswerSetsInstance
30
+ # @param [String] token The Token HTTP request header
31
+ # @return [InsightsSettingsAnswerSetsInstance] Fetched InsightsSettingsAnswerSetsInstance
32
+ def fetch(token: :unset)
33
+ headers = Twilio::Values.of({'Token' => token, })
34
+
35
+ payload = @version.fetch('GET', @uri, headers: headers)
36
+
37
+ InsightsSettingsAnswerSetsInstance.new(@version, payload, )
38
+ end
39
+
40
+ ##
41
+ # Provide a user friendly representation
42
+ def to_s
43
+ '#<Twilio.FlexApi.V1.InsightsSettingsAnswerSetsList>'
44
+ end
45
+ end
46
+
47
+ ##
48
+ # PLEASE NOTE that this class contains preview products that are subject to change. Use them with caution. If you currently do not have developer preview access, please contact help@twilio.com.
49
+ class InsightsSettingsAnswerSetsPage < Page
50
+ ##
51
+ # Initialize the InsightsSettingsAnswerSetsPage
52
+ # @param [Version] version Version that contains the resource
53
+ # @param [Response] response Response from the API
54
+ # @param [Hash] solution Path solution for the resource
55
+ # @return [InsightsSettingsAnswerSetsPage] InsightsSettingsAnswerSetsPage
56
+ def initialize(version, response, solution)
57
+ super(version, response)
58
+
59
+ # Path Solution
60
+ @solution = solution
61
+ end
62
+
63
+ ##
64
+ # Build an instance of InsightsSettingsAnswerSetsInstance
65
+ # @param [Hash] payload Payload response from the API
66
+ # @return [InsightsSettingsAnswerSetsInstance] InsightsSettingsAnswerSetsInstance
67
+ def get_instance(payload)
68
+ InsightsSettingsAnswerSetsInstance.new(@version, payload, )
69
+ end
70
+
71
+ ##
72
+ # Provide a user friendly representation
73
+ def to_s
74
+ '<Twilio.FlexApi.V1.InsightsSettingsAnswerSetsPage>'
75
+ end
76
+ end
77
+
78
+ ##
79
+ # PLEASE NOTE that this class contains preview products that are subject to change. Use them with caution. If you currently do not have developer preview access, please contact help@twilio.com.
80
+ class InsightsSettingsAnswerSetsInstance < InstanceResource
81
+ ##
82
+ # Initialize the InsightsSettingsAnswerSetsInstance
83
+ # @param [Version] version Version that contains the resource
84
+ # @param [Hash] payload payload that contains response from Twilio
85
+ # @return [InsightsSettingsAnswerSetsInstance] InsightsSettingsAnswerSetsInstance
86
+ def initialize(version, payload)
87
+ super(version)
88
+
89
+ # Marshaled Properties
90
+ @properties = {
91
+ 'account_sid' => payload['account_sid'],
92
+ 'answer_sets' => payload['answer_sets'],
93
+ 'answer_set_categories' => payload['answer_set_categories'],
94
+ 'not_applicable' => payload['not_applicable'],
95
+ 'url' => payload['url'],
96
+ }
97
+ end
98
+
99
+ ##
100
+ # @return [String] The SID of the Account that created the resource and owns this Flex Insights
101
+ def account_sid
102
+ @properties['account_sid']
103
+ end
104
+
105
+ ##
106
+ # @return [Hash] Answer Set list
107
+ def answer_sets
108
+ @properties['answer_sets']
109
+ end
110
+
111
+ ##
112
+ # @return [Hash] Categories of Answer Set
113
+ def answer_set_categories
114
+ @properties['answer_set_categories']
115
+ end
116
+
117
+ ##
118
+ # @return [Hash] NA answer set
119
+ def not_applicable
120
+ @properties['not_applicable']
121
+ end
122
+
123
+ ##
124
+ # @return [String] The url
125
+ def url
126
+ @properties['url']
127
+ end
128
+
129
+ ##
130
+ # Provide a user friendly representation
131
+ def to_s
132
+ "<Twilio.FlexApi.V1.InsightsSettingsAnswerSetsInstance>"
133
+ end
134
+
135
+ ##
136
+ # Provide a detailed, user friendly representation
137
+ def inspect
138
+ "<Twilio.FlexApi.V1.InsightsSettingsAnswerSetsInstance>"
139
+ end
140
+ end
141
+ end
142
+ end
143
+ end
144
+ end
@@ -0,0 +1,130 @@
1
+ ##
2
+ # This code was generated by
3
+ # \ / _ _ _| _ _
4
+ # | (_)\/(_)(_|\/| |(/_ v1.0.0
5
+ # / /
6
+ #
7
+ # frozen_string_literal: true
8
+
9
+ module Twilio
10
+ module REST
11
+ class FlexApi < Domain
12
+ class V1 < Version
13
+ ##
14
+ # PLEASE NOTE that this class contains preview products that are subject to change. Use them with caution. If you currently do not have developer preview access, please contact help@twilio.com.
15
+ class InsightsSettingsCommentList < ListResource
16
+ ##
17
+ # Initialize the InsightsSettingsCommentList
18
+ # @param [Version] version Version that contains the resource
19
+ # @return [InsightsSettingsCommentList] InsightsSettingsCommentList
20
+ def initialize(version)
21
+ super(version)
22
+
23
+ # Path Solution
24
+ @solution = {}
25
+ @uri = "/Insights/QM/Settings/CommentTags"
26
+ end
27
+
28
+ ##
29
+ # Fetch the InsightsSettingsCommentInstance
30
+ # @param [String] token The Token HTTP request header
31
+ # @return [InsightsSettingsCommentInstance] Fetched InsightsSettingsCommentInstance
32
+ def fetch(token: :unset)
33
+ headers = Twilio::Values.of({'Token' => token, })
34
+
35
+ payload = @version.fetch('GET', @uri, headers: headers)
36
+
37
+ InsightsSettingsCommentInstance.new(@version, payload, )
38
+ end
39
+
40
+ ##
41
+ # Provide a user friendly representation
42
+ def to_s
43
+ '#<Twilio.FlexApi.V1.InsightsSettingsCommentList>'
44
+ end
45
+ end
46
+
47
+ ##
48
+ # PLEASE NOTE that this class contains preview products that are subject to change. Use them with caution. If you currently do not have developer preview access, please contact help@twilio.com.
49
+ class InsightsSettingsCommentPage < Page
50
+ ##
51
+ # Initialize the InsightsSettingsCommentPage
52
+ # @param [Version] version Version that contains the resource
53
+ # @param [Response] response Response from the API
54
+ # @param [Hash] solution Path solution for the resource
55
+ # @return [InsightsSettingsCommentPage] InsightsSettingsCommentPage
56
+ def initialize(version, response, solution)
57
+ super(version, response)
58
+
59
+ # Path Solution
60
+ @solution = solution
61
+ end
62
+
63
+ ##
64
+ # Build an instance of InsightsSettingsCommentInstance
65
+ # @param [Hash] payload Payload response from the API
66
+ # @return [InsightsSettingsCommentInstance] InsightsSettingsCommentInstance
67
+ def get_instance(payload)
68
+ InsightsSettingsCommentInstance.new(@version, payload, )
69
+ end
70
+
71
+ ##
72
+ # Provide a user friendly representation
73
+ def to_s
74
+ '<Twilio.FlexApi.V1.InsightsSettingsCommentPage>'
75
+ end
76
+ end
77
+
78
+ ##
79
+ # PLEASE NOTE that this class contains preview products that are subject to change. Use them with caution. If you currently do not have developer preview access, please contact help@twilio.com.
80
+ class InsightsSettingsCommentInstance < InstanceResource
81
+ ##
82
+ # Initialize the InsightsSettingsCommentInstance
83
+ # @param [Version] version Version that contains the resource
84
+ # @param [Hash] payload payload that contains response from Twilio
85
+ # @return [InsightsSettingsCommentInstance] InsightsSettingsCommentInstance
86
+ def initialize(version, payload)
87
+ super(version)
88
+
89
+ # Marshaled Properties
90
+ @properties = {
91
+ 'account_sid' => payload['account_sid'],
92
+ 'comments' => payload['comments'],
93
+ 'url' => payload['url'],
94
+ }
95
+ end
96
+
97
+ ##
98
+ # @return [String] The SID of the Account that created the resource and owns this Flex Insights
99
+ def account_sid
100
+ @properties['account_sid']
101
+ end
102
+
103
+ ##
104
+ # @return [Hash] The comments
105
+ def comments
106
+ @properties['comments']
107
+ end
108
+
109
+ ##
110
+ # @return [String] The url
111
+ def url
112
+ @properties['url']
113
+ end
114
+
115
+ ##
116
+ # Provide a user friendly representation
117
+ def to_s
118
+ "<Twilio.FlexApi.V1.InsightsSettingsCommentInstance>"
119
+ end
120
+
121
+ ##
122
+ # Provide a detailed, user friendly representation
123
+ def inspect
124
+ "<Twilio.FlexApi.V1.InsightsSettingsCommentInstance>"
125
+ end
126
+ end
127
+ end
128
+ end
129
+ end
130
+ end
@@ -8,15 +8,15 @@
8
8
 
9
9
  module Twilio
10
10
  module REST
11
- class Preview < Domain
12
- class TrustedComms < Version
11
+ class FlexApi < Domain
12
+ class V1 < Version
13
13
  ##
14
14
  # PLEASE NOTE that this class contains preview products that are subject to change. Use them with caution. If you currently do not have developer preview access, please contact help@twilio.com.
15
- class CpsList < ListResource
15
+ class InsightsUserRolesList < ListResource
16
16
  ##
17
- # Initialize the CpsList
17
+ # Initialize the InsightsUserRolesList
18
18
  # @param [Version] version Version that contains the resource
19
- # @return [CpsList] CpsList
19
+ # @return [InsightsUserRolesList] InsightsUserRolesList
20
20
  def initialize(version)
21
21
  super(version)
22
22
 
@@ -27,19 +27,19 @@ module Twilio
27
27
  ##
28
28
  # Provide a user friendly representation
29
29
  def to_s
30
- '#<Twilio.Preview.TrustedComms.CpsList>'
30
+ '#<Twilio.FlexApi.V1.InsightsUserRolesList>'
31
31
  end
32
32
  end
33
33
 
34
34
  ##
35
35
  # PLEASE NOTE that this class contains preview products that are subject to change. Use them with caution. If you currently do not have developer preview access, please contact help@twilio.com.
36
- class CpsPage < Page
36
+ class InsightsUserRolesPage < Page
37
37
  ##
38
- # Initialize the CpsPage
38
+ # Initialize the InsightsUserRolesPage
39
39
  # @param [Version] version Version that contains the resource
40
40
  # @param [Response] response Response from the API
41
41
  # @param [Hash] solution Path solution for the resource
42
- # @return [CpsPage] CpsPage
42
+ # @return [InsightsUserRolesPage] InsightsUserRolesPage
43
43
  def initialize(version, response, solution)
44
44
  super(version, response)
45
45
 
@@ -48,80 +48,75 @@ module Twilio
48
48
  end
49
49
 
50
50
  ##
51
- # Build an instance of CpsInstance
51
+ # Build an instance of InsightsUserRolesInstance
52
52
  # @param [Hash] payload Payload response from the API
53
- # @return [CpsInstance] CpsInstance
53
+ # @return [InsightsUserRolesInstance] InsightsUserRolesInstance
54
54
  def get_instance(payload)
55
- CpsInstance.new(@version, payload, )
55
+ InsightsUserRolesInstance.new(@version, payload, )
56
56
  end
57
57
 
58
58
  ##
59
59
  # Provide a user friendly representation
60
60
  def to_s
61
- '<Twilio.Preview.TrustedComms.CpsPage>'
61
+ '<Twilio.FlexApi.V1.InsightsUserRolesPage>'
62
62
  end
63
63
  end
64
64
 
65
65
  ##
66
66
  # PLEASE NOTE that this class contains preview products that are subject to change. Use them with caution. If you currently do not have developer preview access, please contact help@twilio.com.
67
- class CpsContext < InstanceContext
67
+ class InsightsUserRolesContext < InstanceContext
68
68
  ##
69
- # Initialize the CpsContext
69
+ # Initialize the InsightsUserRolesContext
70
70
  # @param [Version] version Version that contains the resource
71
- # @return [CpsContext] CpsContext
71
+ # @return [InsightsUserRolesContext] InsightsUserRolesContext
72
72
  def initialize(version)
73
73
  super(version)
74
74
 
75
75
  # Path Solution
76
76
  @solution = {}
77
- @uri = "/CPS"
77
+ @uri = "/Insights/UserRoles"
78
78
  end
79
79
 
80
80
  ##
81
- # Fetch the CpsInstance
82
- # @param [String] x_xcnam_sensitive_phone_number Phone number used to retrieve its
83
- # corresponding CPS.
84
- # @return [CpsInstance] Fetched CpsInstance
85
- def fetch(x_xcnam_sensitive_phone_number: :unset)
86
- headers = Twilio::Values.of({'X-Xcnam-Sensitive-Phone-Number' => x_xcnam_sensitive_phone_number, })
81
+ # Fetch the InsightsUserRolesInstance
82
+ # @param [String] authorization The Authorization HTTP request header
83
+ # @return [InsightsUserRolesInstance] Fetched InsightsUserRolesInstance
84
+ def fetch(authorization: :unset)
85
+ headers = Twilio::Values.of({'Authorization' => authorization, })
87
86
 
88
87
  payload = @version.fetch('GET', @uri, headers: headers)
89
88
 
90
- CpsInstance.new(@version, payload, )
89
+ InsightsUserRolesInstance.new(@version, payload, )
91
90
  end
92
91
 
93
92
  ##
94
93
  # Provide a user friendly representation
95
94
  def to_s
96
95
  context = @solution.map {|k, v| "#{k}: #{v}"}.join(',')
97
- "#<Twilio.Preview.TrustedComms.CpsContext #{context}>"
96
+ "#<Twilio.FlexApi.V1.InsightsUserRolesContext #{context}>"
98
97
  end
99
98
 
100
99
  ##
101
100
  # Provide a detailed, user friendly representation
102
101
  def inspect
103
102
  context = @solution.map {|k, v| "#{k}: #{v}"}.join(',')
104
- "#<Twilio.Preview.TrustedComms.CpsContext #{context}>"
103
+ "#<Twilio.FlexApi.V1.InsightsUserRolesContext #{context}>"
105
104
  end
106
105
  end
107
106
 
108
107
  ##
109
108
  # PLEASE NOTE that this class contains preview products that are subject to change. Use them with caution. If you currently do not have developer preview access, please contact help@twilio.com.
110
- class CpsInstance < InstanceResource
109
+ class InsightsUserRolesInstance < InstanceResource
111
110
  ##
112
- # Initialize the CpsInstance
111
+ # Initialize the InsightsUserRolesInstance
113
112
  # @param [Version] version Version that contains the resource
114
113
  # @param [Hash] payload payload that contains response from Twilio
115
- # @return [CpsInstance] CpsInstance
114
+ # @return [InsightsUserRolesInstance] InsightsUserRolesInstance
116
115
  def initialize(version, payload)
117
116
  super(version)
118
117
 
119
118
  # Marshaled Properties
120
- @properties = {
121
- 'cps_url' => payload['cps_url'],
122
- 'phone_number' => payload['phone_number'],
123
- 'url' => payload['url'],
124
- }
119
+ @properties = {'roles' => payload['roles'], 'url' => payload['url'], }
125
120
 
126
121
  # Context
127
122
  @instance_context = nil
@@ -131,53 +126,46 @@ module Twilio
131
126
  ##
132
127
  # Generate an instance context for the instance, the context is capable of
133
128
  # performing various actions. All instance actions are proxied to the context
134
- # @return [CpsContext] CpsContext for this CpsInstance
129
+ # @return [InsightsUserRolesContext] InsightsUserRolesContext for this InsightsUserRolesInstance
135
130
  def context
136
131
  unless @instance_context
137
- @instance_context = CpsContext.new(@version, )
132
+ @instance_context = InsightsUserRolesContext.new(@version, )
138
133
  end
139
134
  @instance_context
140
135
  end
141
136
 
142
137
  ##
143
- # @return [String] CPS URL of the phone number.
144
- def cps_url
145
- @properties['cps_url']
138
+ # @return [Array[String]] Flex Insights roles for the user
139
+ def roles
140
+ @properties['roles']
146
141
  end
147
142
 
148
143
  ##
149
- # @return [String] Phone number passed.
150
- def phone_number
151
- @properties['phone_number']
152
- end
153
-
154
- ##
155
- # @return [String] The URL of this resource.
144
+ # @return [String] The url
156
145
  def url
157
146
  @properties['url']
158
147
  end
159
148
 
160
149
  ##
161
- # Fetch the CpsInstance
162
- # @param [String] x_xcnam_sensitive_phone_number Phone number used to retrieve its
163
- # corresponding CPS.
164
- # @return [CpsInstance] Fetched CpsInstance
165
- def fetch(x_xcnam_sensitive_phone_number: :unset)
166
- context.fetch(x_xcnam_sensitive_phone_number: x_xcnam_sensitive_phone_number, )
150
+ # Fetch the InsightsUserRolesInstance
151
+ # @param [String] authorization The Authorization HTTP request header
152
+ # @return [InsightsUserRolesInstance] Fetched InsightsUserRolesInstance
153
+ def fetch(authorization: :unset)
154
+ context.fetch(authorization: authorization, )
167
155
  end
168
156
 
169
157
  ##
170
158
  # Provide a user friendly representation
171
159
  def to_s
172
160
  values = @params.map{|k, v| "#{k}: #{v}"}.join(" ")
173
- "<Twilio.Preview.TrustedComms.CpsInstance #{values}>"
161
+ "<Twilio.FlexApi.V1.InsightsUserRolesInstance #{values}>"
174
162
  end
175
163
 
176
164
  ##
177
165
  # Provide a detailed, user friendly representation
178
166
  def inspect
179
167
  values = @properties.map{|k, v| "#{k}: #{v}"}.join(" ")
180
- "<Twilio.Preview.TrustedComms.CpsInstance #{values}>"
168
+ "<Twilio.FlexApi.V1.InsightsUserRolesInstance #{values}>"
181
169
  end
182
170
  end
183
171
  end
@@ -275,6 +275,9 @@ module Twilio
275
275
  'sid' => payload['sid'],
276
276
  'interaction_sid' => payload['interaction_sid'],
277
277
  'type' => payload['type'],
278
+ 'status' => payload['status'],
279
+ 'error_code' => payload['error_code'] == nil ? payload['error_code'] : payload['error_code'].to_i,
280
+ 'error_message' => payload['error_message'],
278
281
  'url' => payload['url'],
279
282
  'links' => payload['links'],
280
283
  }
@@ -306,7 +309,7 @@ module Twilio
306
309
  end
307
310
 
308
311
  ##
309
- # @return [String] The unique string that identifies the resource
312
+ # @return [String] The unique string that identifies the resource.
310
313
  def interaction_sid
311
314
  @properties['interaction_sid']
312
315
  end
@@ -317,6 +320,24 @@ module Twilio
317
320
  @properties['type']
318
321
  end
319
322
 
323
+ ##
324
+ # @return [interaction_channel.ChannelStatus] The status of this channel.
325
+ def status
326
+ @properties['status']
327
+ end
328
+
329
+ ##
330
+ # @return [String] The Twilio error code for a failed channel.
331
+ def error_code
332
+ @properties['error_code']
333
+ end
334
+
335
+ ##
336
+ # @return [String] The error message for a failed channel.
337
+ def error_message
338
+ @properties['error_message']
339
+ end
340
+
320
341
  ##
321
342
  # @return [String] The url
322
343
  def url
@@ -18,6 +18,16 @@ module Twilio
18
18
  @channel = nil
19
19
  @configuration = nil
20
20
  @flex_flow = nil
21
+ @assessments = nil
22
+ @insights_assessments_comment = nil
23
+ @insights_questionnaires = nil
24
+ @insights_questionnaires_category = nil
25
+ @insights_questionnaires_question = nil
26
+ @insights_segments = nil
27
+ @insights_session = nil
28
+ @insights_settings_answer_sets = nil
29
+ @insights_settings_comment = nil
30
+ @insights_user_roles = nil
21
31
  @interaction = nil
22
32
  @web_channel = nil
23
33
  end
@@ -58,6 +68,111 @@ module Twilio
58
68
  end
59
69
  end
60
70
 
71
+ ##
72
+ # @param [String] assessment_id The id of the assessment to be modified
73
+ # @return [Twilio::REST::Flex_api::V1::AssessmentsContext] if assessment_id was passed.
74
+ # @return [Twilio::REST::Flex_api::V1::AssessmentsList]
75
+ def assessments(assessment_id=:unset)
76
+ if assessment_id.nil?
77
+ raise ArgumentError, 'assessment_id cannot be nil'
78
+ end
79
+ if assessment_id == :unset
80
+ @assessments ||= AssessmentsList.new self
81
+ else
82
+ AssessmentsContext.new(self, assessment_id)
83
+ end
84
+ end
85
+
86
+ ##
87
+ # @return [Twilio::REST::Flex_api::V1::InsightsAssessmentsCommentContext]
88
+ def insights_assessments_comment
89
+ @insights_assessments_comment ||= InsightsAssessmentsCommentList.new self
90
+ end
91
+
92
+ ##
93
+ # @param [String] id The unique ID of the questionnaire
94
+ # @return [Twilio::REST::Flex_api::V1::InsightsQuestionnairesContext] if id was passed.
95
+ # @return [Twilio::REST::Flex_api::V1::InsightsQuestionnairesList]
96
+ def insights_questionnaires(id=:unset)
97
+ if id.nil?
98
+ raise ArgumentError, 'id cannot be nil'
99
+ end
100
+ if id == :unset
101
+ @insights_questionnaires ||= InsightsQuestionnairesList.new self
102
+ else
103
+ InsightsQuestionnairesContext.new(self, id)
104
+ end
105
+ end
106
+
107
+ ##
108
+ # @param [String] category_id The ID of the category to be update
109
+ # @return [Twilio::REST::Flex_api::V1::InsightsQuestionnairesCategoryContext] if category_id was passed.
110
+ # @return [Twilio::REST::Flex_api::V1::InsightsQuestionnairesCategoryList]
111
+ def insights_questionnaires_category(category_id=:unset)
112
+ if category_id.nil?
113
+ raise ArgumentError, 'category_id cannot be nil'
114
+ end
115
+ if category_id == :unset
116
+ @insights_questionnaires_category ||= InsightsQuestionnairesCategoryList.new self
117
+ else
118
+ InsightsQuestionnairesCategoryContext.new(self, category_id)
119
+ end
120
+ end
121
+
122
+ ##
123
+ # @param [String] question_id The unique ID of the question
124
+ # @return [Twilio::REST::Flex_api::V1::InsightsQuestionnairesQuestionContext] if question_id was passed.
125
+ # @return [Twilio::REST::Flex_api::V1::InsightsQuestionnairesQuestionList]
126
+ def insights_questionnaires_question(question_id=:unset)
127
+ if question_id.nil?
128
+ raise ArgumentError, 'question_id cannot be nil'
129
+ end
130
+ if question_id == :unset
131
+ @insights_questionnaires_question ||= InsightsQuestionnairesQuestionList.new self
132
+ else
133
+ InsightsQuestionnairesQuestionContext.new(self, question_id)
134
+ end
135
+ end
136
+
137
+ ##
138
+ # @param [String] segment_id To unique id of the segment
139
+ # @return [Twilio::REST::Flex_api::V1::InsightsSegmentsContext] if segment_id was passed.
140
+ # @return [Twilio::REST::Flex_api::V1::InsightsSegmentsList]
141
+ def insights_segments(segment_id=:unset)
142
+ if segment_id.nil?
143
+ raise ArgumentError, 'segment_id cannot be nil'
144
+ end
145
+ if segment_id == :unset
146
+ @insights_segments ||= InsightsSegmentsList.new self
147
+ else
148
+ InsightsSegmentsContext.new(self, segment_id)
149
+ end
150
+ end
151
+
152
+ ##
153
+ # @return [Twilio::REST::Flex_api::V1::InsightsSessionContext]
154
+ def insights_session
155
+ @insights_session ||= InsightsSessionContext.new self
156
+ end
157
+
158
+ ##
159
+ # @return [Twilio::REST::Flex_api::V1::InsightsSettingsAnswerSetsContext]
160
+ def insights_settings_answer_sets
161
+ @insights_settings_answer_sets ||= InsightsSettingsAnswerSetsList.new self
162
+ end
163
+
164
+ ##
165
+ # @return [Twilio::REST::Flex_api::V1::InsightsSettingsCommentContext]
166
+ def insights_settings_comment
167
+ @insights_settings_comment ||= InsightsSettingsCommentList.new self
168
+ end
169
+
170
+ ##
171
+ # @return [Twilio::REST::Flex_api::V1::InsightsUserRolesContext]
172
+ def insights_user_roles
173
+ @insights_user_roles ||= InsightsUserRolesContext.new self
174
+ end
175
+
61
176
  ##
62
177
  # @param [String] sid The SID of the Interaction resource to fetch.
63
178
  # @return [Twilio::REST::Flex_api::V1::InteractionContext] if sid was passed.