twilio-ruby 5.27.0 → 5.27.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (115) hide show
  1. checksums.yaml +5 -5
  2. data/.dockerignore +1 -0
  3. data/CHANGES.md +13 -0
  4. data/CONTRIBUTING.md +2 -0
  5. data/Dockerfile +2 -2
  6. data/README.md +2 -2
  7. data/lib/twilio-ruby/http/http_client.rb +1 -1
  8. data/lib/twilio-ruby/rest/api/v2010/account/call.rb +18 -18
  9. data/lib/twilio-ruby/rest/api/v2010/account/message/media.rb +9 -9
  10. data/lib/twilio-ruby/rest/api/v2010/account/recording.rb +9 -9
  11. data/lib/twilio-ruby/rest/autopilot/v1/assistant/query.rb +5 -5
  12. data/lib/twilio-ruby/rest/conversations/v1/conversation/message.rb +10 -1
  13. data/lib/twilio-ruby/rest/conversations/v1/conversation/participant.rb +1 -1
  14. data/lib/twilio-ruby/rest/fax/v1/fax.rb +12 -12
  15. data/lib/twilio-ruby/rest/flex_api.rb +6 -3
  16. data/lib/twilio-ruby/rest/flex_api/v1.rb +3 -3
  17. data/lib/twilio-ruby/rest/flex_api/v1/channel.rb +23 -23
  18. data/lib/twilio-ruby/rest/flex_api/v1/configuration.rb +39 -37
  19. data/lib/twilio-ruby/rest/flex_api/v1/flex_flow.rb +102 -96
  20. data/lib/twilio-ruby/rest/flex_api/v1/web_channel.rb +20 -20
  21. data/lib/twilio-ruby/rest/messaging.rb +3 -2
  22. data/lib/twilio-ruby/rest/messaging/v1.rb +2 -3
  23. data/lib/twilio-ruby/rest/messaging/v1/service.rb +124 -91
  24. data/lib/twilio-ruby/rest/messaging/v1/service/alpha_sender.rb +22 -18
  25. data/lib/twilio-ruby/rest/messaging/v1/service/phone_number.rb +22 -16
  26. data/lib/twilio-ruby/rest/messaging/v1/service/short_code.rb +18 -20
  27. data/lib/twilio-ruby/rest/messaging/v1/session.rb +48 -44
  28. data/lib/twilio-ruby/rest/messaging/v1/session/message.rb +46 -48
  29. data/lib/twilio-ruby/rest/messaging/v1/session/participant.rb +55 -62
  30. data/lib/twilio-ruby/rest/messaging/v1/session/webhook.rb +61 -65
  31. data/lib/twilio-ruby/rest/messaging/v1/webhook.rb +30 -36
  32. data/lib/twilio-ruby/rest/monitor.rb +4 -2
  33. data/lib/twilio-ruby/rest/monitor/v1.rb +2 -2
  34. data/lib/twilio-ruby/rest/monitor/v1/alert.rb +45 -57
  35. data/lib/twilio-ruby/rest/monitor/v1/event.rb +47 -50
  36. data/lib/twilio-ruby/rest/notify/v1/service/binding.rb +8 -8
  37. data/lib/twilio-ruby/rest/notify/v1/service/notification.rb +3 -3
  38. data/lib/twilio-ruby/rest/preview/trusted_comms/branded_call.rb +6 -6
  39. data/lib/twilio-ruby/rest/preview/trusted_comms/device.rb +1 -1
  40. data/lib/twilio-ruby/rest/preview/trusted_comms/phone_call.rb +55 -55
  41. data/lib/twilio-ruby/rest/pricing/v2/voice.rb +2 -2
  42. data/lib/twilio-ruby/rest/pricing/v2/voice/country.rb +4 -4
  43. data/lib/twilio-ruby/rest/proxy/v1/service/phone_number.rb +1 -1
  44. data/lib/twilio-ruby/rest/serverless.rb +2 -1
  45. data/lib/twilio-ruby/rest/serverless/v1.rb +1 -2
  46. data/lib/twilio-ruby/rest/serverless/v1/service.rb +27 -28
  47. data/lib/twilio-ruby/rest/serverless/v1/service/asset.rb +22 -22
  48. data/lib/twilio-ruby/rest/serverless/v1/service/asset/asset_version.rb +22 -22
  49. data/lib/twilio-ruby/rest/serverless/v1/service/build.rb +25 -24
  50. data/lib/twilio-ruby/rest/serverless/v1/service/environment.rb +26 -24
  51. data/lib/twilio-ruby/rest/serverless/v1/service/environment/deployment.rb +21 -24
  52. data/lib/twilio-ruby/rest/serverless/v1/service/environment/log.rb +31 -31
  53. data/lib/twilio-ruby/rest/serverless/v1/service/environment/variable.rb +35 -35
  54. data/lib/twilio-ruby/rest/serverless/v1/service/function.rb +22 -22
  55. data/lib/twilio-ruby/rest/serverless/v1/service/function/function_version.rb +22 -22
  56. data/lib/twilio-ruby/rest/studio/v1/flow/execution.rb +12 -12
  57. data/lib/twilio-ruby/rest/sync/v1/service/document.rb +7 -4
  58. data/lib/twilio-ruby/rest/sync/v1/service/sync_list.rb +6 -3
  59. data/lib/twilio-ruby/rest/sync/v1/service/sync_list/sync_list_item.rb +15 -9
  60. data/lib/twilio-ruby/rest/sync/v1/service/sync_map.rb +6 -3
  61. data/lib/twilio-ruby/rest/sync/v1/service/sync_map/sync_map_item.rb +15 -9
  62. data/lib/twilio-ruby/rest/sync/v1/service/sync_stream.rb +9 -6
  63. data/lib/twilio-ruby/rest/taskrouter.rb +2 -1
  64. data/lib/twilio-ruby/rest/taskrouter/v1.rb +1 -1
  65. data/lib/twilio-ruby/rest/taskrouter/v1/workspace.rb +102 -95
  66. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/activity.rb +52 -44
  67. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/event.rb +90 -81
  68. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task.rb +152 -136
  69. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_channel.rb +35 -29
  70. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue.rb +96 -89
  71. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue/task_queue_cumulative_statistics.rb +61 -61
  72. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue/task_queue_real_time_statistics.rb +27 -21
  73. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue/task_queue_statistics.rb +46 -46
  74. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue/task_queues_statistics.rb +57 -64
  75. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker.rb +98 -79
  76. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker/worker_channel.rb +41 -39
  77. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker/worker_statistics.rb +39 -33
  78. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker/workers_cumulative_statistics.rb +32 -31
  79. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker/workers_real_time_statistics.rb +16 -11
  80. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker/workers_statistics.rb +42 -42
  81. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workflow.rb +75 -72
  82. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workflow/workflow_cumulative_statistics.rb +59 -51
  83. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workflow/workflow_real_time_statistics.rb +24 -18
  84. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workflow/workflow_statistics.rb +54 -46
  85. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workspace_cumulative_statistics.rb +48 -46
  86. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workspace_real_time_statistics.rb +17 -17
  87. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workspace_statistics.rb +44 -42
  88. data/lib/twilio-ruby/rest/trunking/v1/trunk.rb +24 -18
  89. data/lib/twilio-ruby/rest/trunking/v1/trunk/credential_list.rb +3 -3
  90. data/lib/twilio-ruby/rest/trunking/v1/trunk/ip_access_control_list.rb +1 -2
  91. data/lib/twilio-ruby/rest/trunking/v1/trunk/phone_number.rb +1 -2
  92. data/lib/twilio-ruby/rest/verify/v2/service/messaging_configuration.rb +12 -12
  93. data/lib/twilio-ruby/rest/verify/v2/service/rate_limit.rb +6 -6
  94. data/lib/twilio-ruby/rest/verify/v2/service/rate_limit/bucket.rb +6 -6
  95. data/lib/twilio-ruby/rest/verify/v2/service/verification.rb +2 -1
  96. data/lib/twilio-ruby/rest/verify/v2/service/verification_check.rb +2 -1
  97. data/lib/twilio-ruby/rest/video.rb +8 -8
  98. data/lib/twilio-ruby/rest/video/v1.rb +4 -7
  99. data/lib/twilio-ruby/rest/video/v1/composition.rb +89 -98
  100. data/lib/twilio-ruby/rest/video/v1/composition_hook.rb +224 -195
  101. data/lib/twilio-ruby/rest/video/v1/composition_settings.rb +34 -34
  102. data/lib/twilio-ruby/rest/video/v1/recording.rb +53 -55
  103. data/lib/twilio-ruby/rest/video/v1/recording_settings.rb +32 -32
  104. data/lib/twilio-ruby/rest/video/v1/room.rb +71 -61
  105. data/lib/twilio-ruby/rest/video/v1/room/recording.rb +45 -33
  106. data/lib/twilio-ruby/rest/video/v1/room/room_participant.rb +56 -57
  107. data/lib/twilio-ruby/rest/video/v1/room/room_participant/room_participant_published_track.rb +25 -22
  108. data/lib/twilio-ruby/rest/video/v1/room/room_participant/room_participant_subscribe_rule.rb +10 -10
  109. data/lib/twilio-ruby/rest/video/v1/room/room_participant/room_participant_subscribed_track.rb +24 -23
  110. data/lib/twilio-ruby/rest/voice/v1/dialing_permissions.rb +1 -1
  111. data/lib/twilio-ruby/rest/voice/v1/dialing_permissions/country.rb +5 -5
  112. data/lib/twilio-ruby/rest/voice/v1/dialing_permissions/country/highrisk_special_prefix.rb +2 -2
  113. data/lib/twilio-ruby/version.rb +1 -1
  114. data/spec/integration/conversations/v1/conversation/message_spec.rb +58 -0
  115. metadata +4 -4
@@ -32,7 +32,7 @@ module Twilio
32
32
  ##
33
33
  # Access the countries
34
34
  # @param [String] iso_code The [ISO country
35
- # code](http://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)
35
+ # code](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)
36
36
  # @return [CountryList]
37
37
  # @return [CountryContext] if iso_code was passed.
38
38
  def countries(iso_code=:unset)
@@ -32,7 +32,7 @@ module Twilio
32
32
  # memory before returning.
33
33
  # @param [String] iso_code Filter to retrieve the country permissions by
34
34
  # specifying the [ISO country
35
- # code](http://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)
35
+ # code](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)
36
36
  # @param [String] continent Filter to retrieve the country permissions by
37
37
  # specifying the continent
38
38
  # @param [String] country_code Filter the results by specified [country
@@ -72,7 +72,7 @@ module Twilio
72
72
  # is reached.
73
73
  # @param [String] iso_code Filter to retrieve the country permissions by
74
74
  # specifying the [ISO country
75
- # code](http://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)
75
+ # code](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)
76
76
  # @param [String] continent Filter to retrieve the country permissions by
77
77
  # specifying the continent
78
78
  # @param [String] country_code Filter the results by specified [country
@@ -128,7 +128,7 @@ module Twilio
128
128
  # Request is executed immediately.
129
129
  # @param [String] iso_code Filter to retrieve the country permissions by
130
130
  # specifying the [ISO country
131
- # code](http://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)
131
+ # code](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)
132
132
  # @param [String] continent Filter to retrieve the country permissions by
133
133
  # specifying the continent
134
134
  # @param [String] country_code Filter the results by specified [country
@@ -224,7 +224,7 @@ module Twilio
224
224
  # Initialize the CountryContext
225
225
  # @param [Version] version Version that contains the resource
226
226
  # @param [String] iso_code The [ISO country
227
- # code](http://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)
227
+ # code](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)
228
228
  # @return [CountryContext] CountryContext
229
229
  def initialize(version, iso_code)
230
230
  super(version)
@@ -287,7 +287,7 @@ module Twilio
287
287
  # @param [Version] version Version that contains the resource
288
288
  # @param [Hash] payload payload that contains response from Twilio
289
289
  # @param [String] iso_code The [ISO country
290
- # code](http://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)
290
+ # code](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)
291
291
  # @return [CountryInstance] CountryInstance
292
292
  def initialize(version, payload, iso_code: nil)
293
293
  super(version)
@@ -19,7 +19,7 @@ module Twilio
19
19
  # Initialize the HighriskSpecialPrefixList
20
20
  # @param [Version] version Version that contains the resource
21
21
  # @param [String] iso_code The [ISO country
22
- # code](http://en.wikipedia.org/wiki/ISO_3166-1_alpha-2).
22
+ # code](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2).
23
23
  # @return [HighriskSpecialPrefixList] HighriskSpecialPrefixList
24
24
  def initialize(version, iso_code: nil)
25
25
  super(version)
@@ -157,7 +157,7 @@ module Twilio
157
157
  # @param [Version] version Version that contains the resource
158
158
  # @param [Hash] payload payload that contains response from Twilio
159
159
  # @param [String] iso_code The [ISO country
160
- # code](http://en.wikipedia.org/wiki/ISO_3166-1_alpha-2).
160
+ # code](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2).
161
161
  # @return [HighriskSpecialPrefixInstance] HighriskSpecialPrefixInstance
162
162
  def initialize(version, payload, iso_code: nil)
163
163
  super(version)
@@ -1,3 +1,3 @@
1
1
  module Twilio
2
- VERSION = '5.27.0'
2
+ VERSION = '5.27.1'
3
3
  end
@@ -34,6 +34,40 @@ describe 'Message' do
34
34
  "account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
35
35
  "conversation_sid": "CHaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
36
36
  "body": "Hello",
37
+ "media": null,
38
+ "author": "message author",
39
+ "attributes": "{ \\"importance\\": \\"high\\" }",
40
+ "date_created": "2015-12-16T22:18:37Z",
41
+ "date_updated": "2015-12-16T22:18:38Z",
42
+ "index": 0,
43
+ "url": "https://conversations.twilio.com/v1/Conversations/CHaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Messages/IMaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
44
+ }
45
+ ]
46
+ ))
47
+
48
+ actual = @client.conversations.v1.conversations('CHXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
49
+ .messages.create()
50
+
51
+ expect(actual).to_not eq(nil)
52
+ end
53
+
54
+ it "receives create_with_media responses" do
55
+ @holodeck.mock(Twilio::Response.new(
56
+ 201,
57
+ %q[
58
+ {
59
+ "sid": "IMaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
60
+ "account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
61
+ "conversation_sid": "CHaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
62
+ "body": null,
63
+ "media": [
64
+ {
65
+ "sid": "MEaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
66
+ "size": 42056,
67
+ "content_type": "image/jpeg",
68
+ "filename": "car.jpg"
69
+ }
70
+ ],
37
71
  "author": "message author",
38
72
  "attributes": "{ \\"importance\\": \\"high\\" }",
39
73
  "date_created": "2015-12-16T22:18:37Z",
@@ -75,6 +109,7 @@ describe 'Message' do
75
109
  "account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
76
110
  "conversation_sid": "CHaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
77
111
  "body": "Hello",
112
+ "media": null,
78
113
  "author": "message author",
79
114
  "attributes": "{ \\"importance\\": \\"high\\" }",
80
115
  "date_created": "2015-12-16T22:18:37Z",
@@ -144,6 +179,7 @@ describe 'Message' do
144
179
  "account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
145
180
  "conversation_sid": "CHaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
146
181
  "body": "Welcome!",
182
+ "media": null,
147
183
  "author": "system",
148
184
  "attributes": "{ \\"importance\\": \\"high\\" }",
149
185
  "date_created": "2016-03-24T20:37:57Z",
@@ -196,6 +232,7 @@ describe 'Message' do
196
232
  "account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
197
233
  "conversation_sid": "CHaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
198
234
  "body": "I like pie.",
235
+ "media": null,
199
236
  "author": "pie_preferrer",
200
237
  "attributes": "{ \\"importance\\": \\"high\\" }",
201
238
  "date_created": "2016-03-24T20:37:57Z",
@@ -208,6 +245,27 @@ describe 'Message' do
208
245
  "account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
209
246
  "conversation_sid": "CHaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
210
247
  "body": "Cake is my favorite!",
248
+ "media": null,
249
+ "author": "cake_lover",
250
+ "attributes": "{ \\"importance\\": \\"high\\" }",
251
+ "date_created": "2016-03-24T20:38:21Z",
252
+ "date_updated": "2016-03-24T20:38:21Z",
253
+ "index": 0,
254
+ "url": "https://conversations.twilio.com/v1/Conversations/CHaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Messages/IMaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
255
+ },
256
+ {
257
+ "sid": "IMaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
258
+ "account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
259
+ "conversation_sid": "CHaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
260
+ "body": null,
261
+ "media": [
262
+ {
263
+ "sid": "MEaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
264
+ "size": 42056,
265
+ "content_type": "image/jpeg",
266
+ "filename": "car.jpg"
267
+ }
268
+ ],
211
269
  "author": "cake_lover",
212
270
  "attributes": "{ \\"importance\\": \\"high\\" }",
213
271
  "date_created": "2016-03-24T20:38:21Z",
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.27.0
4
+ version: 5.27.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: 2019-09-18 00:00:00.000000000 Z
11
+ date: 2019-10-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jwt
@@ -121,6 +121,7 @@ extra_rdoc_files:
121
121
  - README.md
122
122
  - LICENSE.md
123
123
  files:
124
+ - ".dockerignore"
124
125
  - ".gitignore"
125
126
  - ".rubocop.yml"
126
127
  - ".rubocop_todo.yml"
@@ -920,8 +921,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
920
921
  - !ruby/object:Gem::Version
921
922
  version: '0'
922
923
  requirements: []
923
- rubyforge_project:
924
- rubygems_version: 2.5.2.3
924
+ rubygems_version: 3.0.6
925
925
  signing_key:
926
926
  specification_version: 4
927
927
  summary: The official library for communicating with the Twilio REST API, building