twilio-ruby 5.41.0 → 5.45.1

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 (150) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGES.md +99 -0
  3. data/{LICENSE.md → LICENSE} +0 -0
  4. data/PULL_REQUEST_TEMPLATE.md +3 -3
  5. data/README.md +18 -2
  6. data/lib/twilio-ruby.rb +1 -1
  7. data/lib/twilio-ruby/jwt/access_token.rb +7 -2
  8. data/lib/twilio-ruby/rest/api/v2010/account/call.rb +26 -1
  9. data/lib/twilio-ruby/rest/api/v2010/account/call/event.rb +201 -0
  10. data/lib/twilio-ruby/rest/api/v2010/account/call/recording.rb +13 -1
  11. data/lib/twilio-ruby/rest/api/v2010/account/conference/participant.rb +6 -1
  12. data/lib/twilio-ruby/rest/bulkexports/v1/export/day.rb +5 -22
  13. data/lib/twilio-ruby/rest/bulkexports/v1/export/export_custom_job.rb +25 -40
  14. data/lib/twilio-ruby/rest/client.rb +29 -3
  15. data/lib/twilio-ruby/rest/conversations/v1/conversation/participant.rb +32 -2
  16. data/lib/twilio-ruby/rest/conversations/v1/service/configuration.rb +17 -2
  17. data/lib/twilio-ruby/rest/conversations/v1/service/conversation/participant.rb +32 -2
  18. data/lib/twilio-ruby/rest/conversations/v1/service/user.rb +8 -1
  19. data/lib/twilio-ruby/rest/conversations/v1/user.rb +8 -1
  20. data/lib/twilio-ruby/rest/events/v1/subscription.rb +12 -5
  21. data/lib/twilio-ruby/rest/flex_api.rb +1 -1
  22. data/lib/twilio-ruby/rest/flex_api/v1.rb +1 -1
  23. data/lib/twilio-ruby/rest/flex_api/v1/channel.rb +5 -5
  24. data/lib/twilio-ruby/rest/flex_api/v1/flex_flow.rb +88 -76
  25. data/lib/twilio-ruby/rest/flex_api/v1/web_channel.rb +2 -2
  26. data/lib/twilio-ruby/rest/insights.rb +8 -0
  27. data/lib/twilio-ruby/rest/insights/v1.rb +15 -0
  28. data/lib/twilio-ruby/rest/insights/v1/room.rb +487 -0
  29. data/lib/twilio-ruby/rest/insights/v1/room/participant.rb +378 -0
  30. data/lib/twilio-ruby/rest/ip_messaging.rb +8 -10
  31. data/lib/twilio-ruby/rest/ip_messaging/v1.rb +6 -8
  32. data/lib/twilio-ruby/rest/ip_messaging/v1/credential.rb +29 -68
  33. data/lib/twilio-ruby/rest/ip_messaging/v1/service.rb +198 -313
  34. data/lib/twilio-ruby/rest/ip_messaging/v1/service/channel.rb +32 -59
  35. data/lib/twilio-ruby/rest/ip_messaging/v1/service/channel/invite.rb +23 -55
  36. data/lib/twilio-ruby/rest/ip_messaging/v1/service/channel/member.rb +28 -71
  37. data/lib/twilio-ruby/rest/ip_messaging/v1/service/channel/message.rb +31 -59
  38. data/lib/twilio-ruby/rest/ip_messaging/v1/service/role.rb +19 -39
  39. data/lib/twilio-ruby/rest/ip_messaging/v1/service/user.rb +29 -51
  40. data/lib/twilio-ruby/rest/ip_messaging/v1/service/user/user_channel.rb +12 -18
  41. data/lib/twilio-ruby/rest/ip_messaging/v2.rb +6 -6
  42. data/lib/twilio-ruby/rest/ip_messaging/v2/credential.rb +29 -66
  43. data/lib/twilio-ruby/rest/ip_messaging/v2/service.rb +116 -205
  44. data/lib/twilio-ruby/rest/ip_messaging/v2/service/binding.rb +23 -50
  45. data/lib/twilio-ruby/rest/ip_messaging/v2/service/channel.rb +41 -91
  46. data/lib/twilio-ruby/rest/ip_messaging/v2/service/channel/invite.rb +23 -50
  47. data/lib/twilio-ruby/rest/ip_messaging/v2/service/channel/member.rb +42 -118
  48. data/lib/twilio-ruby/rest/ip_messaging/v2/service/channel/message.rb +46 -100
  49. data/lib/twilio-ruby/rest/ip_messaging/v2/service/channel/webhook.rb +36 -89
  50. data/lib/twilio-ruby/rest/ip_messaging/v2/service/role.rb +19 -41
  51. data/lib/twilio-ruby/rest/ip_messaging/v2/service/user.rb +29 -53
  52. data/lib/twilio-ruby/rest/ip_messaging/v2/service/user/user_binding.rb +23 -53
  53. data/lib/twilio-ruby/rest/ip_messaging/v2/service/user/user_channel.rb +27 -56
  54. data/lib/twilio-ruby/rest/preview.rb +0 -21
  55. data/lib/twilio-ruby/rest/preview/bulk_exports/export/day.rb +5 -22
  56. data/lib/twilio-ruby/rest/preview/bulk_exports/export/export_custom_job.rb +21 -39
  57. data/lib/twilio-ruby/rest/preview/trusted_comms.rb +0 -30
  58. data/lib/twilio-ruby/rest/serverless/v1/service.rb +5 -5
  59. data/lib/twilio-ruby/rest/serverless/v1/service/asset.rb +4 -4
  60. data/lib/twilio-ruby/rest/serverless/v1/service/asset/asset_version.rb +4 -4
  61. data/lib/twilio-ruby/rest/serverless/v1/service/build.rb +4 -4
  62. data/lib/twilio-ruby/rest/serverless/v1/service/build/build_status.rb +4 -4
  63. data/lib/twilio-ruby/rest/serverless/v1/service/environment.rb +4 -4
  64. data/lib/twilio-ruby/rest/serverless/v1/service/environment/deployment.rb +4 -4
  65. data/lib/twilio-ruby/rest/serverless/v1/service/environment/log.rb +4 -4
  66. data/lib/twilio-ruby/rest/serverless/v1/service/environment/variable.rb +4 -4
  67. data/lib/twilio-ruby/rest/serverless/v1/service/function.rb +4 -4
  68. data/lib/twilio-ruby/rest/serverless/v1/service/function/function_version.rb +4 -4
  69. data/lib/twilio-ruby/rest/serverless/v1/service/function/function_version/function_version_content.rb +4 -4
  70. data/lib/twilio-ruby/rest/sync/v1/service/document.rb +15 -5
  71. data/lib/twilio-ruby/rest/sync/v1/service/sync_list.rb +15 -5
  72. data/lib/twilio-ruby/rest/sync/v1/service/sync_list/sync_list_item.rb +28 -5
  73. data/lib/twilio-ruby/rest/sync/v1/service/sync_map.rb +15 -5
  74. data/lib/twilio-ruby/rest/sync/v1/service/sync_map/sync_map_item.rb +28 -5
  75. data/lib/twilio-ruby/rest/sync/v1/service/sync_stream.rb +15 -5
  76. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task.rb +12 -9
  77. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_channel.rb +16 -16
  78. data/lib/twilio-ruby/rest/trunking/v1/trunk/recording.rb +21 -24
  79. data/lib/twilio-ruby/rest/verify/v2/form.rb +4 -4
  80. data/lib/twilio-ruby/rest/verify/v2/service.rb +3 -3
  81. data/lib/twilio-ruby/rest/verify/v2/service/access_token.rb +3 -3
  82. data/lib/twilio-ruby/rest/verify/v2/service/entity.rb +23 -35
  83. data/lib/twilio-ruby/rest/verify/v2/service/entity/challenge.rb +27 -49
  84. data/lib/twilio-ruby/rest/verify/v2/service/entity/factor.rb +24 -42
  85. data/lib/twilio-ruby/rest/verify/v2/service/webhook.rb +4 -4
  86. data/lib/twilio-ruby/rest/video/v1/composition_settings.rb +6 -6
  87. data/lib/twilio-ruby/rest/video/v1/recording_settings.rb +6 -6
  88. data/lib/twilio-ruby/rest/video/v1/room.rb +20 -0
  89. data/lib/twilio-ruby/rest/video/v1/room/room_recording_rule.rb +150 -0
  90. data/lib/twilio-ruby/twiml/voice_response.rb +8 -4
  91. data/lib/twilio-ruby/util/configuration.rb +5 -1
  92. data/lib/twilio-ruby/version.rb +1 -1
  93. data/spec/integration/api/v2010/account/call/event_spec.rb +102 -0
  94. data/spec/integration/api/v2010/account/call/recording_spec.rb +4 -0
  95. data/spec/integration/api/v2010/account/call_spec.rb +20 -10
  96. data/spec/integration/api/v2010/account/conference/participant_spec.rb +30 -0
  97. data/spec/integration/bulkexports/v1/export/export_custom_job_spec.rb +4 -2
  98. data/spec/integration/conversations/v1/conversation/participant_spec.rb +30 -10
  99. data/spec/integration/conversations/v1/service/configuration_spec.rb +2 -0
  100. data/spec/integration/conversations/v1/service/conversation/participant_spec.rb +30 -10
  101. data/spec/integration/conversations/v1/service/user_spec.rb +9 -4
  102. data/spec/integration/conversations/v1/user_spec.rb +9 -4
  103. data/spec/integration/events/v1/sink/sink_test_spec.rb +1 -1
  104. data/spec/integration/events/v1/subscription_spec.rb +49 -0
  105. data/spec/integration/insights/v1/room/participant_spec.rb +147 -0
  106. data/spec/integration/insights/v1/room_spec.rb +164 -0
  107. data/spec/integration/ip_messaging/v1/credential_spec.rb +13 -13
  108. data/spec/integration/ip_messaging/v1/service/channel/invite_spec.rb +11 -11
  109. data/spec/integration/ip_messaging/v1/service/channel/member_spec.rb +14 -14
  110. data/spec/integration/ip_messaging/v1/service/channel/message_spec.rb +14 -14
  111. data/spec/integration/ip_messaging/v1/service/channel_spec.rb +25 -25
  112. data/spec/integration/ip_messaging/v1/service/role_spec.rb +13 -13
  113. data/spec/integration/ip_messaging/v1/service/user/user_channel_spec.rb +7 -7
  114. data/spec/integration/ip_messaging/v1/service/user_spec.rb +17 -17
  115. data/spec/integration/ip_messaging/v1/service_spec.rb +9 -9
  116. data/spec/integration/ip_messaging/v2/credential_spec.rb +13 -13
  117. data/spec/integration/ip_messaging/v2/service/binding_spec.rb +11 -11
  118. data/spec/integration/ip_messaging/v2/service/channel/invite_spec.rb +11 -11
  119. data/spec/integration/ip_messaging/v2/service/channel/member_spec.rb +13 -13
  120. data/spec/integration/ip_messaging/v2/service/channel/message_spec.rb +17 -17
  121. data/spec/integration/ip_messaging/v2/service/channel/webhook_spec.rb +15 -15
  122. data/spec/integration/ip_messaging/v2/service/channel_spec.rb +29 -29
  123. data/spec/integration/ip_messaging/v2/service/role_spec.rb +13 -13
  124. data/spec/integration/ip_messaging/v2/service/user/user_binding_spec.rb +9 -9
  125. data/spec/integration/ip_messaging/v2/service/user/user_channel_spec.rb +20 -20
  126. data/spec/integration/ip_messaging/v2/service/user_spec.rb +21 -21
  127. data/spec/integration/ip_messaging/v2/service_spec.rb +29 -29
  128. data/spec/integration/lookups/v1/phone_number_spec.rb +7 -7
  129. data/spec/integration/preview/bulk_exports/export/export_custom_job_spec.rb +4 -2
  130. data/spec/integration/taskrouter/v1/workspace/worker/worker_channel_spec.rb +1 -1
  131. data/spec/integration/trunking/v1/trunk/recording_spec.rb +2 -6
  132. data/spec/integration/verify/v2/service/entity/challenge_spec.rb +4 -12
  133. data/spec/integration/verify/v2/service/entity/factor_spec.rb +5 -15
  134. data/spec/integration/verify/v2/service/entity_spec.rb +4 -12
  135. data/spec/integration/video/v1/room/room_recording_rule_spec.rb +89 -0
  136. data/spec/integration/video/v1/room_spec.rb +10 -5
  137. data/spec/jwt/access_token_spec.rb +9 -1
  138. data/spec/rest/client_spec.rb +24 -2
  139. data/twilio-ruby.gemspec +2 -1
  140. metadata +30 -19
  141. data/lib/twilio-ruby/rest/preview/trusted_comms/branded_call.rb +0 -243
  142. data/lib/twilio-ruby/rest/preview/trusted_comms/business.rb +0 -213
  143. data/lib/twilio-ruby/rest/preview/trusted_comms/business/insights.rb +0 -108
  144. data/lib/twilio-ruby/rest/preview/trusted_comms/business/insights/impressions_rate.rb +0 -260
  145. data/lib/twilio-ruby/rest/preview/trusted_comms/phone_call.rb +0 -342
  146. data/spec/integration/preview/trusted_comms/branded_call_spec.rb +0 -59
  147. data/spec/integration/preview/trusted_comms/business/insights/impressions_rate_spec.rb +0 -56
  148. data/spec/integration/preview/trusted_comms/business/insights_spec.rb +0 -12
  149. data/spec/integration/preview/trusted_comms/business_spec.rb +0 -45
  150. data/spec/integration/preview/trusted_comms/phone_call_spec.rb +0 -59
@@ -14,10 +14,18 @@ describe Twilio::JWT::AccessToken do
14
14
  expect(payload['grants'].count).to eq(0)
15
15
  end
16
16
 
17
- it 'should add the proper headers' do
17
+ it 'should add the proper headers without region' do
18
18
  scat = Twilio::JWT::AccessToken.new 'AC123', 'SK123', 'secret'
19
19
  _, headers = JWT.decode scat.to_s, 'secret'
20
20
  expect(headers['cty']).to eq('twilio-fpa;v=1')
21
+ expect(headers['twr']).to be_nil
22
+ end
23
+
24
+ it 'should add the proper headers with region' do
25
+ scat = Twilio::JWT::AccessToken.new 'AC123', 'SK123', 'secret', region: 'foo'
26
+ _, headers = JWT.decode scat.to_s, 'secret'
27
+ expect(headers['cty']).to eq('twilio-fpa;v=1')
28
+ expect(headers['twr']).to eq('foo')
21
29
  end
22
30
 
23
31
  it 'identity should exist in the grants' do
@@ -1,4 +1,5 @@
1
1
  require 'spec_helper'
2
+ require 'logger'
2
3
 
3
4
  describe Twilio::REST::ObsoleteClient do
4
5
  it 'raise an exception' do
@@ -57,6 +58,7 @@ describe Twilio::REST::Client do
57
58
  config.http_client = 'someClient'
58
59
  config.region = 'someRegion'
59
60
  config.edge = 'someEdge'
61
+ config.logger = 'someLogger'
60
62
  end
61
63
  end
62
64
 
@@ -67,16 +69,18 @@ describe Twilio::REST::Client do
67
69
  expect(@client.http_client).to eq('someClient')
68
70
  expect(@client.region).to eq('someRegion')
69
71
  expect(@client.edge).to eq('someEdge')
72
+ expect(@client.logger).to eq('someLogger')
70
73
  end
71
74
 
72
75
  it 'uses the arguments over global configuration' do
73
- @client = Twilio::REST::Client.new('myUser', 'myPassword', nil, 'myRegion', 'myClient')
76
+ @client = Twilio::REST::Client.new('myUser', 'myPassword', nil, 'myRegion', 'myClient', 'myLogger')
74
77
  @client.edge = 'myEdge'
75
78
  expect(@client.account_sid).to eq('myUser')
76
79
  expect(@client.auth_token).to eq('myPassword')
77
80
  expect(@client.http_client).to eq('myClient')
78
81
  expect(@client.region).to eq('myRegion')
79
82
  expect(@client.edge).to eq('myEdge')
83
+ expect(@client.logger).to eq('myLogger')
80
84
  end
81
85
 
82
86
  class MyVersion < Twilio::REST::Version
@@ -97,13 +101,14 @@ describe Twilio::REST::Client do
97
101
  end
98
102
 
99
103
  context 'validation' do
100
- before do
104
+ before :all do
101
105
  Twilio.configure do |config|
102
106
  config.account_sid = 'someSid'
103
107
  config.auth_token = 'someToken'
104
108
  config.http_client = 'someClient'
105
109
  config.region = nil
106
110
  config.edge = nil
111
+ config.logger = nil
107
112
  end
108
113
  end
109
114
 
@@ -142,6 +147,23 @@ describe Twilio::REST::Client do
142
147
  end
143
148
  end
144
149
 
150
+ context 'logging' do
151
+ it 'logs the call details' do
152
+ @client.logger = Logger.new(STDOUT)
153
+ @holodeck.mock Twilio::Response.new(200, {})
154
+ expect {
155
+ @client.request('host', 'port', 'GET', 'http://foobar.com')
156
+ }.to output(/Host:foobar.com/).to_stdout_from_any_process
157
+ end
158
+
159
+ it 'does not log when the logger instance is not passed' do
160
+ @holodeck.mock Twilio::Response.new(200, {})
161
+ expect {
162
+ @client.request('host', 'port', 'GET', 'http://foobar.com')
163
+ }.to_not output(/Host:foobar.com/).to_stdout_from_any_process
164
+ end
165
+ end
166
+
145
167
  describe '#build_uri' do
146
168
  before(:all) do
147
169
  Twilio.configure do |config|
@@ -21,7 +21,7 @@ Gem::Specification.new do |spec|
21
21
  spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
22
22
  spec.require_paths = ['lib']
23
23
  spec.required_ruby_version = '>= 2.0.0'
24
- spec.extra_rdoc_files = ['README.md', 'LICENSE.md']
24
+ spec.extra_rdoc_files = ['README.md', 'LICENSE']
25
25
  spec.rdoc_options = ['--line-numbers', '--inline-source', '--title', 'twilio-ruby', '--main', 'README.md']
26
26
 
27
27
  spec.add_dependency('jwt', '>= 1.5', '<= 2.5')
@@ -38,4 +38,5 @@ Gem::Specification.new do |spec|
38
38
  spec.add_development_dependency 'rspec', '~> 3.0'
39
39
  spec.add_development_dependency 'rubocop', '~> 0.82.0'
40
40
  spec.add_development_dependency 'yard', '~> 0.9.9'
41
+ spec.add_development_dependency 'logger', '~> 1.4.2'
41
42
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: twilio-ruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 5.41.0
4
+ version: 5.45.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Twilio API Team
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-10-14 00:00:00.000000000 Z
11
+ date: 2020-12-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jwt
@@ -188,6 +188,20 @@ dependencies:
188
188
  - - "~>"
189
189
  - !ruby/object:Gem::Version
190
190
  version: 0.9.9
191
+ - !ruby/object:Gem::Dependency
192
+ name: logger
193
+ requirement: !ruby/object:Gem::Requirement
194
+ requirements:
195
+ - - "~>"
196
+ - !ruby/object:Gem::Version
197
+ version: 1.4.2
198
+ type: :development
199
+ prerelease: false
200
+ version_requirements: !ruby/object:Gem::Requirement
201
+ requirements:
202
+ - - "~>"
203
+ - !ruby/object:Gem::Version
204
+ version: 1.4.2
191
205
  description: The official library for communicating with the Twilio REST API, building
192
206
  TwiML, and generating Twilio JWT Capability Tokens
193
207
  email:
@@ -195,7 +209,7 @@ executables: []
195
209
  extensions: []
196
210
  extra_rdoc_files:
197
211
  - README.md
198
- - LICENSE.md
212
+ - LICENSE
199
213
  files:
200
214
  - ".dockerignore"
201
215
  - ".gitignore"
@@ -209,7 +223,7 @@ files:
209
223
  - Dockerfile
210
224
  - Gemfile
211
225
  - ISSUE_TEMPLATE.md
212
- - LICENSE.md
226
+ - LICENSE
213
227
  - Makefile
214
228
  - PULL_REQUEST_TEMPLATE.md
215
229
  - README.md
@@ -263,6 +277,7 @@ files:
263
277
  - lib/twilio-ruby/rest/api/v2010/account/available_phone_number/voip.rb
264
278
  - lib/twilio-ruby/rest/api/v2010/account/balance.rb
265
279
  - lib/twilio-ruby/rest/api/v2010/account/call.rb
280
+ - lib/twilio-ruby/rest/api/v2010/account/call/event.rb
266
281
  - lib/twilio-ruby/rest/api/v2010/account/call/feedback.rb
267
282
  - lib/twilio-ruby/rest/api/v2010/account/call/feedback_summary.rb
268
283
  - lib/twilio-ruby/rest/api/v2010/account/call/notification.rb
@@ -420,6 +435,8 @@ files:
420
435
  - lib/twilio-ruby/rest/insights/v1/call/event.rb
421
436
  - lib/twilio-ruby/rest/insights/v1/call/metric.rb
422
437
  - lib/twilio-ruby/rest/insights/v1/call/summary.rb
438
+ - lib/twilio-ruby/rest/insights/v1/room.rb
439
+ - lib/twilio-ruby/rest/insights/v1/room/participant.rb
423
440
  - lib/twilio-ruby/rest/ip_messaging.rb
424
441
  - lib/twilio-ruby/rest/ip_messaging/v1.rb
425
442
  - lib/twilio-ruby/rest/ip_messaging/v1/credential.rb
@@ -508,16 +525,11 @@ files:
508
525
  - lib/twilio-ruby/rest/preview/sync/service/sync_map/sync_map_item.rb
509
526
  - lib/twilio-ruby/rest/preview/sync/service/sync_map/sync_map_permission.rb
510
527
  - lib/twilio-ruby/rest/preview/trusted_comms.rb
511
- - lib/twilio-ruby/rest/preview/trusted_comms/branded_call.rb
512
528
  - lib/twilio-ruby/rest/preview/trusted_comms/branded_channel.rb
513
529
  - lib/twilio-ruby/rest/preview/trusted_comms/branded_channel/channel.rb
514
530
  - lib/twilio-ruby/rest/preview/trusted_comms/brands_information.rb
515
- - lib/twilio-ruby/rest/preview/trusted_comms/business.rb
516
- - lib/twilio-ruby/rest/preview/trusted_comms/business/insights.rb
517
- - lib/twilio-ruby/rest/preview/trusted_comms/business/insights/impressions_rate.rb
518
531
  - lib/twilio-ruby/rest/preview/trusted_comms/cps.rb
519
532
  - lib/twilio-ruby/rest/preview/trusted_comms/current_call.rb
520
- - lib/twilio-ruby/rest/preview/trusted_comms/phone_call.rb
521
533
  - lib/twilio-ruby/rest/preview/understand.rb
522
534
  - lib/twilio-ruby/rest/preview/understand/assistant.rb
523
535
  - lib/twilio-ruby/rest/preview/understand/assistant/assistant_fallback_actions.rb
@@ -678,6 +690,7 @@ files:
678
690
  - lib/twilio-ruby/rest/video/v1/room/room_participant/room_participant_published_track.rb
679
691
  - lib/twilio-ruby/rest/video/v1/room/room_participant/room_participant_subscribe_rule.rb
680
692
  - lib/twilio-ruby/rest/video/v1/room/room_participant/room_participant_subscribed_track.rb
693
+ - lib/twilio-ruby/rest/video/v1/room/room_recording_rule.rb
681
694
  - lib/twilio-ruby/rest/voice.rb
682
695
  - lib/twilio-ruby/rest/voice/v1.rb
683
696
  - lib/twilio-ruby/rest/voice/v1/byoc_trunk.rb
@@ -730,6 +743,7 @@ files:
730
743
  - spec/integration/api/v2010/account/available_phone_number/voip_spec.rb
731
744
  - spec/integration/api/v2010/account/available_phone_number_spec.rb
732
745
  - spec/integration/api/v2010/account/balance_spec.rb
746
+ - spec/integration/api/v2010/account/call/event_spec.rb
733
747
  - spec/integration/api/v2010/account/call/feedback_spec.rb
734
748
  - spec/integration/api/v2010/account/call/feedback_summary_spec.rb
735
749
  - spec/integration/api/v2010/account/call/notification_spec.rb
@@ -871,6 +885,8 @@ files:
871
885
  - spec/integration/insights/v1/call/metric_spec.rb
872
886
  - spec/integration/insights/v1/call/summary_spec.rb
873
887
  - spec/integration/insights/v1/call_spec.rb
888
+ - spec/integration/insights/v1/room/participant_spec.rb
889
+ - spec/integration/insights/v1/room_spec.rb
874
890
  - spec/integration/ip_messaging/v1/credential_spec.rb
875
891
  - spec/integration/ip_messaging/v1/service/channel/invite_spec.rb
876
892
  - spec/integration/ip_messaging/v1/service/channel/member_spec.rb
@@ -939,16 +955,11 @@ files:
939
955
  - spec/integration/preview/sync/service/sync_map/sync_map_permission_spec.rb
940
956
  - spec/integration/preview/sync/service/sync_map_spec.rb
941
957
  - spec/integration/preview/sync/service_spec.rb
942
- - spec/integration/preview/trusted_comms/branded_call_spec.rb
943
958
  - spec/integration/preview/trusted_comms/branded_channel/channel_spec.rb
944
959
  - spec/integration/preview/trusted_comms/branded_channel_spec.rb
945
960
  - spec/integration/preview/trusted_comms/brands_information_spec.rb
946
- - spec/integration/preview/trusted_comms/business/insights/impressions_rate_spec.rb
947
- - spec/integration/preview/trusted_comms/business/insights_spec.rb
948
- - spec/integration/preview/trusted_comms/business_spec.rb
949
961
  - spec/integration/preview/trusted_comms/cps_spec.rb
950
962
  - spec/integration/preview/trusted_comms/current_call_spec.rb
951
- - spec/integration/preview/trusted_comms/phone_call_spec.rb
952
963
  - spec/integration/preview/understand/assistant/assistant_fallback_actions_spec.rb
953
964
  - spec/integration/preview/understand/assistant/assistant_initiation_actions_spec.rb
954
965
  - spec/integration/preview/understand/assistant/dialogue_spec.rb
@@ -1084,6 +1095,7 @@ files:
1084
1095
  - spec/integration/video/v1/room/room_participant/room_participant_subscribe_rule_spec.rb
1085
1096
  - spec/integration/video/v1/room/room_participant/room_participant_subscribed_track_spec.rb
1086
1097
  - spec/integration/video/v1/room/room_participant_spec.rb
1098
+ - spec/integration/video/v1/room/room_recording_rule_spec.rb
1087
1099
  - spec/integration/video/v1/room_spec.rb
1088
1100
  - spec/integration/voice/v1/byoc_trunk_spec.rb
1089
1101
  - spec/integration/voice/v1/connection_policy/connection_policy_target_spec.rb
@@ -1171,6 +1183,7 @@ test_files:
1171
1183
  - spec/integration/api/v2010/account/available_phone_number/voip_spec.rb
1172
1184
  - spec/integration/api/v2010/account/available_phone_number_spec.rb
1173
1185
  - spec/integration/api/v2010/account/balance_spec.rb
1186
+ - spec/integration/api/v2010/account/call/event_spec.rb
1174
1187
  - spec/integration/api/v2010/account/call/feedback_spec.rb
1175
1188
  - spec/integration/api/v2010/account/call/feedback_summary_spec.rb
1176
1189
  - spec/integration/api/v2010/account/call/notification_spec.rb
@@ -1312,6 +1325,8 @@ test_files:
1312
1325
  - spec/integration/insights/v1/call/metric_spec.rb
1313
1326
  - spec/integration/insights/v1/call/summary_spec.rb
1314
1327
  - spec/integration/insights/v1/call_spec.rb
1328
+ - spec/integration/insights/v1/room/participant_spec.rb
1329
+ - spec/integration/insights/v1/room_spec.rb
1315
1330
  - spec/integration/ip_messaging/v1/credential_spec.rb
1316
1331
  - spec/integration/ip_messaging/v1/service/channel/invite_spec.rb
1317
1332
  - spec/integration/ip_messaging/v1/service/channel/member_spec.rb
@@ -1380,16 +1395,11 @@ test_files:
1380
1395
  - spec/integration/preview/sync/service/sync_map/sync_map_permission_spec.rb
1381
1396
  - spec/integration/preview/sync/service/sync_map_spec.rb
1382
1397
  - spec/integration/preview/sync/service_spec.rb
1383
- - spec/integration/preview/trusted_comms/branded_call_spec.rb
1384
1398
  - spec/integration/preview/trusted_comms/branded_channel/channel_spec.rb
1385
1399
  - spec/integration/preview/trusted_comms/branded_channel_spec.rb
1386
1400
  - spec/integration/preview/trusted_comms/brands_information_spec.rb
1387
- - spec/integration/preview/trusted_comms/business/insights/impressions_rate_spec.rb
1388
- - spec/integration/preview/trusted_comms/business/insights_spec.rb
1389
- - spec/integration/preview/trusted_comms/business_spec.rb
1390
1401
  - spec/integration/preview/trusted_comms/cps_spec.rb
1391
1402
  - spec/integration/preview/trusted_comms/current_call_spec.rb
1392
- - spec/integration/preview/trusted_comms/phone_call_spec.rb
1393
1403
  - spec/integration/preview/understand/assistant/assistant_fallback_actions_spec.rb
1394
1404
  - spec/integration/preview/understand/assistant/assistant_initiation_actions_spec.rb
1395
1405
  - spec/integration/preview/understand/assistant/dialogue_spec.rb
@@ -1525,6 +1535,7 @@ test_files:
1525
1535
  - spec/integration/video/v1/room/room_participant/room_participant_subscribe_rule_spec.rb
1526
1536
  - spec/integration/video/v1/room/room_participant/room_participant_subscribed_track_spec.rb
1527
1537
  - spec/integration/video/v1/room/room_participant_spec.rb
1538
+ - spec/integration/video/v1/room/room_recording_rule_spec.rb
1528
1539
  - spec/integration/video/v1/room_spec.rb
1529
1540
  - spec/integration/voice/v1/byoc_trunk_spec.rb
1530
1541
  - spec/integration/voice/v1/connection_policy/connection_policy_target_spec.rb
@@ -1,243 +0,0 @@
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 Preview < Domain
12
- class TrustedComms < 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 BrandedCallList < ListResource
16
- ##
17
- # Initialize the BrandedCallList
18
- # @param [Version] version Version that contains the resource
19
- # @return [BrandedCallList] BrandedCallList
20
- def initialize(version)
21
- super(version)
22
-
23
- # Path Solution
24
- @solution = {}
25
- @uri = "/Business/BrandedCalls"
26
- end
27
-
28
- ##
29
- # Create the BrandedCallInstance
30
- # @param [String] from The phone number to use as the caller id, given in {E.164
31
- # format}[https://www.twilio.com/docs/glossary/what-e164]. It must be a Twilio
32
- # number that has been set up as a Branded Number in the Business Profile section
33
- # for your account.
34
- # @param [String] to The terminating Phone Number, given in {E.164
35
- # format}[https://www.twilio.com/docs/glossary/what-e164].
36
- # @param [String] reason The business reason for this phone call that will appear
37
- # in the terminating device's screen. Max 50 characters.
38
- # @param [String] call_sid The Call sid this Branded Call should link to.
39
- # @return [BrandedCallInstance] Created BrandedCallInstance
40
- def create(from: nil, to: nil, reason: nil, call_sid: :unset)
41
- data = Twilio::Values.of({'From' => from, 'To' => to, 'Reason' => reason, 'CallSid' => call_sid, })
42
-
43
- payload = @version.create('POST', @uri, data: data)
44
-
45
- BrandedCallInstance.new(@version, payload, )
46
- end
47
-
48
- ##
49
- # Provide a user friendly representation
50
- def to_s
51
- '#<Twilio.Preview.TrustedComms.BrandedCallList>'
52
- end
53
- end
54
-
55
- ##
56
- # 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.
57
- class BrandedCallPage < Page
58
- ##
59
- # Initialize the BrandedCallPage
60
- # @param [Version] version Version that contains the resource
61
- # @param [Response] response Response from the API
62
- # @param [Hash] solution Path solution for the resource
63
- # @return [BrandedCallPage] BrandedCallPage
64
- def initialize(version, response, solution)
65
- super(version, response)
66
-
67
- # Path Solution
68
- @solution = solution
69
- end
70
-
71
- ##
72
- # Build an instance of BrandedCallInstance
73
- # @param [Hash] payload Payload response from the API
74
- # @return [BrandedCallInstance] BrandedCallInstance
75
- def get_instance(payload)
76
- BrandedCallInstance.new(@version, payload, )
77
- end
78
-
79
- ##
80
- # Provide a user friendly representation
81
- def to_s
82
- '<Twilio.Preview.TrustedComms.BrandedCallPage>'
83
- end
84
- end
85
-
86
- ##
87
- # 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.
88
- class BrandedCallInstance < InstanceResource
89
- ##
90
- # Initialize the BrandedCallInstance
91
- # @param [Version] version Version that contains the resource
92
- # @param [Hash] payload payload that contains response from Twilio
93
- # @return [BrandedCallInstance] BrandedCallInstance
94
- def initialize(version, payload)
95
- super(version)
96
-
97
- # Marshaled Properties
98
- @properties = {
99
- 'account_sid' => payload['account_sid'],
100
- 'bg_color' => payload['bg_color'],
101
- 'brand_sid' => payload['brand_sid'],
102
- 'branded_channel_sid' => payload['branded_channel_sid'],
103
- 'business_sid' => payload['business_sid'],
104
- 'call_sid' => payload['call_sid'],
105
- 'caller' => payload['caller'],
106
- 'created_at' => Twilio.deserialize_iso8601_datetime(payload['created_at']),
107
- 'font_color' => payload['font_color'],
108
- 'from' => payload['from'],
109
- 'logo' => payload['logo'],
110
- 'phone_number_sid' => payload['phone_number_sid'],
111
- 'reason' => payload['reason'],
112
- 'sid' => payload['sid'],
113
- 'status' => payload['status'],
114
- 'to' => payload['to'],
115
- 'url' => payload['url'],
116
- 'use_case' => payload['use_case'],
117
- }
118
- end
119
-
120
- ##
121
- # @return [String] Account Sid.
122
- def account_sid
123
- @properties['account_sid']
124
- end
125
-
126
- ##
127
- # @return [String] Background color of the current phone call
128
- def bg_color
129
- @properties['bg_color']
130
- end
131
-
132
- ##
133
- # @return [String] Brand Sid.
134
- def brand_sid
135
- @properties['brand_sid']
136
- end
137
-
138
- ##
139
- # @return [String] Branded Channel Sid.
140
- def branded_channel_sid
141
- @properties['branded_channel_sid']
142
- end
143
-
144
- ##
145
- # @return [String] Business Sid.
146
- def business_sid
147
- @properties['business_sid']
148
- end
149
-
150
- ##
151
- # @return [String] A string that uniquely identifies this phone call.
152
- def call_sid
153
- @properties['call_sid']
154
- end
155
-
156
- ##
157
- # @return [String] Caller name of the current phone call
158
- def caller
159
- @properties['caller']
160
- end
161
-
162
- ##
163
- # @return [Time] The date this current phone call was created
164
- def created_at
165
- @properties['created_at']
166
- end
167
-
168
- ##
169
- # @return [String] Font color of the current phone call
170
- def font_color
171
- @properties['font_color']
172
- end
173
-
174
- ##
175
- # @return [String] The originating phone number
176
- def from
177
- @properties['from']
178
- end
179
-
180
- ##
181
- # @return [String] Logo URL of the caller
182
- def logo
183
- @properties['logo']
184
- end
185
-
186
- ##
187
- # @return [String] Phone Number Sid.
188
- def phone_number_sid
189
- @properties['phone_number_sid']
190
- end
191
-
192
- ##
193
- # @return [String] The business reason for this current phone call
194
- def reason
195
- @properties['reason']
196
- end
197
-
198
- ##
199
- # @return [String] A string that uniquely identifies this current branded phone call.
200
- def sid
201
- @properties['sid']
202
- end
203
-
204
- ##
205
- # @return [String] The status of the current phone call
206
- def status
207
- @properties['status']
208
- end
209
-
210
- ##
211
- # @return [String] The terminating phone number
212
- def to
213
- @properties['to']
214
- end
215
-
216
- ##
217
- # @return [String] The URL of this resource.
218
- def url
219
- @properties['url']
220
- end
221
-
222
- ##
223
- # @return [String] The use case for the current phone call
224
- def use_case
225
- @properties['use_case']
226
- end
227
-
228
- ##
229
- # Provide a user friendly representation
230
- def to_s
231
- "<Twilio.Preview.TrustedComms.BrandedCallInstance>"
232
- end
233
-
234
- ##
235
- # Provide a detailed, user friendly representation
236
- def inspect
237
- "<Twilio.Preview.TrustedComms.BrandedCallInstance>"
238
- end
239
- end
240
- end
241
- end
242
- end
243
- end