twilio-ruby 5.52.0 → 5.53.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.travis.yml +22 -28
- data/CHANGES.md +23 -0
- data/README.md +2 -2
- data/lib/twilio-ruby/http/http_client.rb +3 -1
- data/lib/twilio-ruby/rest/api/v2010/account/call/feedback.rb +23 -23
- data/lib/twilio-ruby/rest/api/v2010/account/call/feedback_summary.rb +5 -5
- data/lib/twilio-ruby/rest/bulkexports/v1/export.rb +0 -8
- data/lib/twilio-ruby/rest/bulkexports/v1/export/day.rb +0 -8
- data/lib/twilio-ruby/rest/bulkexports/v1/export/export_custom_job.rb +0 -6
- data/lib/twilio-ruby/rest/bulkexports/v1/export/job.rb +0 -8
- data/lib/twilio-ruby/rest/bulkexports/v1/export_configuration.rb +0 -8
- data/lib/twilio-ruby/rest/events/v1/sink.rb +22 -0
- data/lib/twilio-ruby/rest/messaging/v1/service/us_app_to_person.rb +3 -3
- data/lib/twilio-ruby/rest/studio/v1/flow/execution.rb +1 -1
- data/lib/twilio-ruby/rest/studio/v2/flow/execution.rb +1 -1
- data/lib/twilio-ruby/rest/verify/v2/service/entity/challenge.rb +2 -2
- data/lib/twilio-ruby/rest/verify/v2/service/entity/new_factor.rb +42 -17
- data/lib/twilio-ruby/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d2f1293c8cedd9eb9e7c9a5078d1e0ac4bb2e34116056233c1112d31911d7de1
|
4
|
+
data.tar.gz: d4d4a2935c742a0f70a5899963b2b114fd83abc5570e0de72f594f2a9ce34b36
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 398824d908de11ffd6449648f01eabc8d8ce97156080c55e4a785fa66caa1a05f38fad0c4fe77521310ebb917bd7482b84c91860c2612a91cb6d322698e5cf84
|
7
|
+
data.tar.gz: 3755621b7a3d180ac82c5b07c88e0bf349099c7d661231247c96b91d3fb726b25d0d01968a653cddc270a816305681a5c941130dedc19a07f9f6253f64afd77a
|
data/.travis.yml
CHANGED
@@ -1,40 +1,34 @@
|
|
1
1
|
language: ruby
|
2
2
|
cache: bundler
|
3
|
-
bundler_args: --without development
|
4
|
-
|
3
|
+
bundler_args: "--without development"
|
5
4
|
rvm:
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
5
|
+
- ruby-head
|
6
|
+
- 3.0
|
7
|
+
- 2.7
|
8
|
+
- 2.6
|
9
|
+
- 2.5
|
10
|
+
- 2.4
|
11
|
+
- jruby-9.2
|
14
12
|
services:
|
15
|
-
|
16
|
-
|
13
|
+
- docker
|
17
14
|
install: make install
|
18
15
|
script: make test
|
19
|
-
|
20
16
|
matrix:
|
21
17
|
allow_failures:
|
22
|
-
|
18
|
+
- rvm: ruby-head
|
23
19
|
fast_finish: true
|
24
|
-
|
25
20
|
deploy:
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
21
|
+
- provider: script
|
22
|
+
script: make docker-build && make docker-push
|
23
|
+
skip_cleanup: true
|
24
|
+
on:
|
25
|
+
tags: true
|
26
|
+
rvm: '2.4'
|
27
|
+
- provider: rubygems
|
28
|
+
api_key: "$RUBYGEMS_APIKEY"
|
29
|
+
on:
|
30
|
+
tags: true
|
31
|
+
rvm: '2.4'
|
38
32
|
notifications:
|
39
33
|
slack:
|
40
34
|
if: branch = main
|
@@ -42,4 +36,4 @@ notifications:
|
|
42
36
|
on_success: never
|
43
37
|
on_failure: change
|
44
38
|
rooms:
|
45
|
-
|
39
|
+
secure: OkXuxf75AYfH919/hhfY3IZOb6IzN3p74ouG2U860Vdwku1WzXjIutq0PnTeL7frqd+jbQgJmKcc3lbVXFZM0r96t8EsAuvXXx9ZWl7GuxpNUKAxwOqAY80m1b6Os7175MKeRyGnfvW8HTX14O7UmyYIJp5HrfN9dU1D1ZMUTDw=
|
data/CHANGES.md
CHANGED
@@ -1,6 +1,29 @@
|
|
1
1
|
twilio-ruby changelog
|
2
2
|
=====================
|
3
3
|
|
4
|
+
[2021-05-05] Version 5.53.0
|
5
|
+
---------------------------
|
6
|
+
**Library - Fix**
|
7
|
+
- [PR #554](https://github.com/twilio/twilio-ruby/pull/554): JSON parser error on timeout response. Thanks to [@Maychell](https://github.com/Maychell)!
|
8
|
+
|
9
|
+
**Api**
|
10
|
+
- Corrected the data types for feedback summary fields **(breaking change)**
|
11
|
+
- Update the conference participant create `from` and `to` param to be endpoint type for supporting client identifier and sip address
|
12
|
+
|
13
|
+
**Bulkexports**
|
14
|
+
- promoting API maturity to GA
|
15
|
+
|
16
|
+
**Events**
|
17
|
+
- Add endpoint to update description in sink
|
18
|
+
- Remove beta-feature account flag
|
19
|
+
|
20
|
+
**Messaging**
|
21
|
+
- Update `status` field in us_app_to_person api to `campaign_status` **(breaking change)**
|
22
|
+
|
23
|
+
**Verify**
|
24
|
+
- Improve documentation regarding `push` factor and include extra information about `totp` factor.
|
25
|
+
|
26
|
+
|
4
27
|
[2021-04-21] Version 5.52.0
|
5
28
|
---------------------------
|
6
29
|
**Api**
|
data/README.md
CHANGED
@@ -35,13 +35,13 @@ This library supports the following Ruby implementations:
|
|
35
35
|
To install using [Bundler][bundler] grab the latest stable version:
|
36
36
|
|
37
37
|
```ruby
|
38
|
-
gem 'twilio-ruby', '~> 5.
|
38
|
+
gem 'twilio-ruby', '~> 5.53.0'
|
39
39
|
```
|
40
40
|
|
41
41
|
To manually install `twilio-ruby` via [Rubygems][rubygems] simply gem install:
|
42
42
|
|
43
43
|
```bash
|
44
|
-
gem install twilio-ruby -v 5.
|
44
|
+
gem install twilio-ruby -v 5.53.0
|
45
45
|
```
|
46
46
|
|
47
47
|
To build and install the development branch yourself from the latest source:
|
@@ -34,7 +34,9 @@ module Twilio
|
|
34
34
|
@last_response = nil
|
35
35
|
|
36
36
|
response = send(request)
|
37
|
-
if response.
|
37
|
+
if response.status == 504
|
38
|
+
object = { message: 'Request timeout', code: 504 }.to_json
|
39
|
+
elsif response.body && !response.body.empty?
|
38
40
|
object = response.body
|
39
41
|
elsif response.status == 400
|
40
42
|
object = { message: 'Bad request', code: 400 }.to_json
|
@@ -87,6 +87,20 @@ module Twilio
|
|
87
87
|
@uri = "/Accounts/#{@solution[:account_sid]}/Calls/#{@solution[:call_sid]}/Feedback.json"
|
88
88
|
end
|
89
89
|
|
90
|
+
##
|
91
|
+
# Fetch the FeedbackInstance
|
92
|
+
# @return [FeedbackInstance] Fetched FeedbackInstance
|
93
|
+
def fetch
|
94
|
+
payload = @version.fetch('GET', @uri)
|
95
|
+
|
96
|
+
FeedbackInstance.new(
|
97
|
+
@version,
|
98
|
+
payload,
|
99
|
+
account_sid: @solution[:account_sid],
|
100
|
+
call_sid: @solution[:call_sid],
|
101
|
+
)
|
102
|
+
end
|
103
|
+
|
90
104
|
##
|
91
105
|
# Create the FeedbackInstance
|
92
106
|
# @param [String] quality_score The call quality expressed as an integer from `1`
|
@@ -113,20 +127,6 @@ module Twilio
|
|
113
127
|
)
|
114
128
|
end
|
115
129
|
|
116
|
-
##
|
117
|
-
# Fetch the FeedbackInstance
|
118
|
-
# @return [FeedbackInstance] Fetched FeedbackInstance
|
119
|
-
def fetch
|
120
|
-
payload = @version.fetch('GET', @uri)
|
121
|
-
|
122
|
-
FeedbackInstance.new(
|
123
|
-
@version,
|
124
|
-
payload,
|
125
|
-
account_sid: @solution[:account_sid],
|
126
|
-
call_sid: @solution[:call_sid],
|
127
|
-
)
|
128
|
-
end
|
129
|
-
|
130
130
|
##
|
131
131
|
# Update the FeedbackInstance
|
132
132
|
# @param [String] quality_score The call quality expressed as an integer from `1`
|
@@ -137,7 +137,7 @@ module Twilio
|
|
137
137
|
# `incorrect-caller-id`, `post-dial-delay`, `digits-not-captured`,
|
138
138
|
# `audio-latency`, `unsolicited-call`, or `one-way-audio`.
|
139
139
|
# @return [FeedbackInstance] Updated FeedbackInstance
|
140
|
-
def update(quality_score:
|
140
|
+
def update(quality_score: :unset, issue: :unset)
|
141
141
|
data = Twilio::Values.of({
|
142
142
|
'QualityScore' => quality_score,
|
143
143
|
'Issue' => Twilio.serialize_list(issue) { |e| e },
|
@@ -244,6 +244,13 @@ module Twilio
|
|
244
244
|
@properties['sid']
|
245
245
|
end
|
246
246
|
|
247
|
+
##
|
248
|
+
# Fetch the FeedbackInstance
|
249
|
+
# @return [FeedbackInstance] Fetched FeedbackInstance
|
250
|
+
def fetch
|
251
|
+
context.fetch
|
252
|
+
end
|
253
|
+
|
247
254
|
##
|
248
255
|
# Create the FeedbackInstance
|
249
256
|
# @param [String] quality_score The call quality expressed as an integer from `1`
|
@@ -258,13 +265,6 @@ module Twilio
|
|
258
265
|
context.create(quality_score: quality_score, issue: issue, )
|
259
266
|
end
|
260
267
|
|
261
|
-
##
|
262
|
-
# Fetch the FeedbackInstance
|
263
|
-
# @return [FeedbackInstance] Fetched FeedbackInstance
|
264
|
-
def fetch
|
265
|
-
context.fetch
|
266
|
-
end
|
267
|
-
|
268
268
|
##
|
269
269
|
# Update the FeedbackInstance
|
270
270
|
# @param [String] quality_score The call quality expressed as an integer from `1`
|
@@ -275,7 +275,7 @@ module Twilio
|
|
275
275
|
# `incorrect-caller-id`, `post-dial-delay`, `digits-not-captured`,
|
276
276
|
# `audio-latency`, `unsolicited-call`, or `one-way-audio`.
|
277
277
|
# @return [FeedbackInstance] Updated FeedbackInstance
|
278
|
-
def update(quality_score:
|
278
|
+
def update(quality_score: :unset, issue: :unset)
|
279
279
|
context.update(quality_score: quality_score, issue: issue, )
|
280
280
|
end
|
281
281
|
|
@@ -167,14 +167,14 @@ module Twilio
|
|
167
167
|
'call_feedback_count' => payload['call_feedback_count'].to_i,
|
168
168
|
'date_created' => Twilio.deserialize_rfc2822(payload['date_created']),
|
169
169
|
'date_updated' => Twilio.deserialize_rfc2822(payload['date_updated']),
|
170
|
-
'end_date' => Twilio.
|
170
|
+
'end_date' => Twilio.deserialize_iso8601_date(payload['end_date']),
|
171
171
|
'include_subaccounts' => payload['include_subaccounts'],
|
172
172
|
'issues' => payload['issues'],
|
173
173
|
'quality_score_average' => payload['quality_score_average'].to_f,
|
174
174
|
'quality_score_median' => payload['quality_score_median'].to_f,
|
175
175
|
'quality_score_standard_deviation' => payload['quality_score_standard_deviation'].to_f,
|
176
176
|
'sid' => payload['sid'],
|
177
|
-
'start_date' => Twilio.
|
177
|
+
'start_date' => Twilio.deserialize_iso8601_date(payload['start_date']),
|
178
178
|
'status' => payload['status'],
|
179
179
|
}
|
180
180
|
|
@@ -225,7 +225,7 @@ module Twilio
|
|
225
225
|
end
|
226
226
|
|
227
227
|
##
|
228
|
-
# @return [
|
228
|
+
# @return [Date] The latest feedback entry date in the summary
|
229
229
|
def end_date
|
230
230
|
@properties['end_date']
|
231
231
|
end
|
@@ -237,7 +237,7 @@ module Twilio
|
|
237
237
|
end
|
238
238
|
|
239
239
|
##
|
240
|
-
# @return [Array[
|
240
|
+
# @return [Array[Hash]] Issues experienced during the call
|
241
241
|
def issues
|
242
242
|
@properties['issues']
|
243
243
|
end
|
@@ -267,7 +267,7 @@ module Twilio
|
|
267
267
|
end
|
268
268
|
|
269
269
|
##
|
270
|
-
# @return [
|
270
|
+
# @return [Date] The earliest feedback entry date in the summary
|
271
271
|
def start_date
|
272
272
|
@properties['start_date']
|
273
273
|
end
|
@@ -10,8 +10,6 @@ module Twilio
|
|
10
10
|
module REST
|
11
11
|
class Bulkexports < Domain
|
12
12
|
class V1 < Version
|
13
|
-
##
|
14
|
-
# PLEASE NOTE that this class contains beta products that are subject to change. Use them with caution.
|
15
13
|
class ExportList < ListResource
|
16
14
|
##
|
17
15
|
# Initialize the ExportList
|
@@ -50,8 +48,6 @@ module Twilio
|
|
50
48
|
end
|
51
49
|
end
|
52
50
|
|
53
|
-
##
|
54
|
-
# PLEASE NOTE that this class contains beta products that are subject to change. Use them with caution.
|
55
51
|
class ExportPage < Page
|
56
52
|
##
|
57
53
|
# Initialize the ExportPage
|
@@ -81,8 +77,6 @@ module Twilio
|
|
81
77
|
end
|
82
78
|
end
|
83
79
|
|
84
|
-
##
|
85
|
-
# PLEASE NOTE that this class contains beta products that are subject to change. Use them with caution.
|
86
80
|
class ExportContext < InstanceContext
|
87
81
|
##
|
88
82
|
# Initialize the ExportContext
|
@@ -156,8 +150,6 @@ module Twilio
|
|
156
150
|
end
|
157
151
|
end
|
158
152
|
|
159
|
-
##
|
160
|
-
# PLEASE NOTE that this class contains beta products that are subject to change. Use them with caution.
|
161
153
|
class ExportInstance < InstanceResource
|
162
154
|
##
|
163
155
|
# Initialize the ExportInstance
|
@@ -11,8 +11,6 @@ module Twilio
|
|
11
11
|
class Bulkexports < Domain
|
12
12
|
class V1 < Version
|
13
13
|
class ExportContext < InstanceContext
|
14
|
-
##
|
15
|
-
# PLEASE NOTE that this class contains beta products that are subject to change. Use them with caution.
|
16
14
|
class DayList < ListResource
|
17
15
|
##
|
18
16
|
# Initialize the DayList
|
@@ -115,8 +113,6 @@ module Twilio
|
|
115
113
|
end
|
116
114
|
end
|
117
115
|
|
118
|
-
##
|
119
|
-
# PLEASE NOTE that this class contains beta products that are subject to change. Use them with caution.
|
120
116
|
class DayPage < Page
|
121
117
|
##
|
122
118
|
# Initialize the DayPage
|
@@ -146,8 +142,6 @@ module Twilio
|
|
146
142
|
end
|
147
143
|
end
|
148
144
|
|
149
|
-
##
|
150
|
-
# PLEASE NOTE that this class contains beta products that are subject to change. Use them with caution.
|
151
145
|
class DayContext < InstanceContext
|
152
146
|
##
|
153
147
|
# Initialize the DayContext
|
@@ -189,8 +183,6 @@ module Twilio
|
|
189
183
|
end
|
190
184
|
end
|
191
185
|
|
192
|
-
##
|
193
|
-
# PLEASE NOTE that this class contains beta products that are subject to change. Use them with caution.
|
194
186
|
class DayInstance < InstanceResource
|
195
187
|
##
|
196
188
|
# Initialize the DayInstance
|
@@ -11,8 +11,6 @@ module Twilio
|
|
11
11
|
class Bulkexports < Domain
|
12
12
|
class V1 < Version
|
13
13
|
class ExportContext < InstanceContext
|
14
|
-
##
|
15
|
-
# PLEASE NOTE that this class contains beta products that are subject to change. Use them with caution.
|
16
14
|
class ExportCustomJobList < ListResource
|
17
15
|
##
|
18
16
|
# Initialize the ExportCustomJobList
|
@@ -147,8 +145,6 @@ module Twilio
|
|
147
145
|
end
|
148
146
|
end
|
149
147
|
|
150
|
-
##
|
151
|
-
# PLEASE NOTE that this class contains beta products that are subject to change. Use them with caution.
|
152
148
|
class ExportCustomJobPage < Page
|
153
149
|
##
|
154
150
|
# Initialize the ExportCustomJobPage
|
@@ -178,8 +174,6 @@ module Twilio
|
|
178
174
|
end
|
179
175
|
end
|
180
176
|
|
181
|
-
##
|
182
|
-
# PLEASE NOTE that this class contains beta products that are subject to change. Use them with caution.
|
183
177
|
class ExportCustomJobInstance < InstanceResource
|
184
178
|
##
|
185
179
|
# Initialize the ExportCustomJobInstance
|
@@ -11,8 +11,6 @@ module Twilio
|
|
11
11
|
class Bulkexports < Domain
|
12
12
|
class V1 < Version
|
13
13
|
class ExportList < ListResource
|
14
|
-
##
|
15
|
-
# PLEASE NOTE that this class contains beta products that are subject to change. Use them with caution.
|
16
14
|
class JobList < ListResource
|
17
15
|
##
|
18
16
|
# Initialize the JobList
|
@@ -32,8 +30,6 @@ module Twilio
|
|
32
30
|
end
|
33
31
|
end
|
34
32
|
|
35
|
-
##
|
36
|
-
# PLEASE NOTE that this class contains beta products that are subject to change. Use them with caution.
|
37
33
|
class JobPage < Page
|
38
34
|
##
|
39
35
|
# Initialize the JobPage
|
@@ -63,8 +59,6 @@ module Twilio
|
|
63
59
|
end
|
64
60
|
end
|
65
61
|
|
66
|
-
##
|
67
|
-
# PLEASE NOTE that this class contains beta products that are subject to change. Use them with caution.
|
68
62
|
class JobContext < InstanceContext
|
69
63
|
##
|
70
64
|
# Initialize the JobContext
|
@@ -111,8 +105,6 @@ module Twilio
|
|
111
105
|
end
|
112
106
|
end
|
113
107
|
|
114
|
-
##
|
115
|
-
# PLEASE NOTE that this class contains beta products that are subject to change. Use them with caution.
|
116
108
|
class JobInstance < InstanceResource
|
117
109
|
##
|
118
110
|
# Initialize the JobInstance
|
@@ -10,8 +10,6 @@ module Twilio
|
|
10
10
|
module REST
|
11
11
|
class Bulkexports < Domain
|
12
12
|
class V1 < Version
|
13
|
-
##
|
14
|
-
# PLEASE NOTE that this class contains beta products that are subject to change. Use them with caution.
|
15
13
|
class ExportConfigurationList < ListResource
|
16
14
|
##
|
17
15
|
# Initialize the ExportConfigurationList
|
@@ -31,8 +29,6 @@ module Twilio
|
|
31
29
|
end
|
32
30
|
end
|
33
31
|
|
34
|
-
##
|
35
|
-
# PLEASE NOTE that this class contains beta products that are subject to change. Use them with caution.
|
36
32
|
class ExportConfigurationPage < Page
|
37
33
|
##
|
38
34
|
# Initialize the ExportConfigurationPage
|
@@ -62,8 +58,6 @@ module Twilio
|
|
62
58
|
end
|
63
59
|
end
|
64
60
|
|
65
|
-
##
|
66
|
-
# PLEASE NOTE that this class contains beta products that are subject to change. Use them with caution.
|
67
61
|
class ExportConfigurationContext < InstanceContext
|
68
62
|
##
|
69
63
|
# Initialize the ExportConfigurationContext
|
@@ -125,8 +119,6 @@ module Twilio
|
|
125
119
|
end
|
126
120
|
end
|
127
121
|
|
128
|
-
##
|
129
|
-
# PLEASE NOTE that this class contains beta products that are subject to change. Use them with caution.
|
130
122
|
class ExportConfigurationInstance < InstanceResource
|
131
123
|
##
|
132
124
|
# Initialize the ExportConfigurationInstance
|
@@ -200,6 +200,19 @@ module Twilio
|
|
200
200
|
@version.delete('DELETE', @uri)
|
201
201
|
end
|
202
202
|
|
203
|
+
##
|
204
|
+
# Update the SinkInstance
|
205
|
+
# @param [String] description A human readable description for the Sink **This
|
206
|
+
# value should not contain PII.**
|
207
|
+
# @return [SinkInstance] Updated SinkInstance
|
208
|
+
def update(description: nil)
|
209
|
+
data = Twilio::Values.of({'Description' => description, })
|
210
|
+
|
211
|
+
payload = @version.update('POST', @uri, data: data)
|
212
|
+
|
213
|
+
SinkInstance.new(@version, payload, sid: @solution[:sid], )
|
214
|
+
end
|
215
|
+
|
203
216
|
##
|
204
217
|
# Access the sink_test
|
205
218
|
# @return [SinkTestList]
|
@@ -348,6 +361,15 @@ module Twilio
|
|
348
361
|
context.delete
|
349
362
|
end
|
350
363
|
|
364
|
+
##
|
365
|
+
# Update the SinkInstance
|
366
|
+
# @param [String] description A human readable description for the Sink **This
|
367
|
+
# value should not contain PII.**
|
368
|
+
# @return [SinkInstance] Updated SinkInstance
|
369
|
+
def update(description: nil)
|
370
|
+
context.update(description: description, )
|
371
|
+
end
|
372
|
+
|
351
373
|
##
|
352
374
|
# Access the sink_test
|
353
375
|
# @return [sink_test] sink_test
|
@@ -147,7 +147,7 @@ module Twilio
|
|
147
147
|
'us_app_to_person_usecase' => payload['us_app_to_person_usecase'],
|
148
148
|
'has_embedded_links' => payload['has_embedded_links'],
|
149
149
|
'has_embedded_phone' => payload['has_embedded_phone'],
|
150
|
-
'
|
150
|
+
'campaign_status' => payload['campaign_status'],
|
151
151
|
'campaign_id' => payload['campaign_id'],
|
152
152
|
'is_externally_registered' => payload['is_externally_registered'],
|
153
153
|
'rate_limits' => payload['rate_limits'],
|
@@ -207,8 +207,8 @@ module Twilio
|
|
207
207
|
|
208
208
|
##
|
209
209
|
# @return [String] Campaign status
|
210
|
-
def
|
211
|
-
@properties['
|
210
|
+
def campaign_status
|
211
|
+
@properties['campaign_status']
|
212
212
|
end
|
213
213
|
|
214
214
|
##
|
@@ -140,7 +140,7 @@ module Twilio
|
|
140
140
|
# available as variable `{{contact.channel.address}}`.
|
141
141
|
# @param [String] from The Twilio phone number to send messages or initiate calls
|
142
142
|
# from during the Flow's Execution. Available as variable
|
143
|
-
# `{{flow.channel.address}}`.
|
143
|
+
# `{{flow.channel.address}}`. For SMS, this can also be a Messaging Service SID.
|
144
144
|
# @param [Hash] parameters JSON data that will be added to the Flow's context and
|
145
145
|
# that can be accessed as variables inside your Flow. For example, if you pass in
|
146
146
|
# `Parameters={"name":"Zeke"}`, a widget in your Flow can reference the variable
|
@@ -140,7 +140,7 @@ module Twilio
|
|
140
140
|
# available as variable `{{contact.channel.address}}`.
|
141
141
|
# @param [String] from The Twilio phone number to send messages or initiate calls
|
142
142
|
# from during the Flow's Execution. Available as variable
|
143
|
-
# `{{flow.channel.address}}`.
|
143
|
+
# `{{flow.channel.address}}`. For SMS, this can also be a Messaging Service SID.
|
144
144
|
# @param [Hash] parameters JSON data that will be added to the Flow's context and
|
145
145
|
# that can be accessed as variables inside your Flow. For example, if you pass in
|
146
146
|
# `Parameters={"name":"Zeke"}`, a widget in your Flow can reference the variable
|
@@ -46,8 +46,8 @@ module Twilio
|
|
46
46
|
# Challenge. Not shown to the end user. It must be a stringified JSON with only
|
47
47
|
# strings values eg. `{"ip": "172.168.1.234"}`
|
48
48
|
# @param [String] auth_payload Optional payload used to verify the Challenge upon
|
49
|
-
# creation. Only used with a Factor of type `totp` to carry
|
50
|
-
#
|
49
|
+
# creation. Only used with a Factor of type `totp` to carry the TOTP code that
|
50
|
+
# needs to be verified.
|
51
51
|
# @return [ChallengeInstance] Created ChallengeInstance
|
52
52
|
def create(factor_sid: nil, expiration_date: :unset, details_message: :unset, details_fields: :unset, hidden_details: :unset, auth_payload: :unset)
|
53
53
|
data = Twilio::Values.of({
|
@@ -34,43 +34,68 @@ module Twilio
|
|
34
34
|
|
35
35
|
##
|
36
36
|
# Create the NewFactorInstance
|
37
|
-
# @param [String] friendly_name The friendly name of this Factor.
|
38
|
-
# 64 characters.
|
37
|
+
# @param [String] friendly_name The friendly name of this Factor. This can be any
|
38
|
+
# string up to 64 characters, meant for humans to distinguish between Factors.
|
39
|
+
# For `factor_type` `push`, this could be a device name.
|
40
|
+
# For `factor_type` `totp`, this value is used as the “account name” in
|
41
|
+
# constructing the `binding.uri` property.
|
42
|
+
# At the same time, we recommend avoiding providing PII.
|
39
43
|
# @param [new_factor.FactorTypes] factor_type The Type of this Factor. Currently
|
40
|
-
# `push` and `totp` are supported. For `totp` to work, you need to contact Twilio
|
41
|
-
# sales first to have the Verify TOTP feature
|
44
|
+
# `push` and `totp` are supported. For `totp` to work, you need to contact {Twilio
|
45
|
+
# sales}[https://www.twilio.com/help/sales] first to have the Verify TOTP feature
|
46
|
+
# enabled for your Twilio account.
|
42
47
|
# @param [String] binding_alg The algorithm used when `factor_type` is `push`.
|
43
48
|
# Algorithm supported: `ES256`
|
44
49
|
# @param [String] binding_public_key The Ecdsa public key in PKIX, ASN.1 DER
|
45
|
-
# format encoded in Base64
|
50
|
+
# format encoded in Base64.
|
51
|
+
#
|
52
|
+
# Required when `factor_type` is `push`
|
46
53
|
# @param [String] config_app_id The ID that uniquely identifies your app in the
|
47
|
-
# Google or Apple store, such as `com.example.myapp`.
|
48
|
-
#
|
54
|
+
# Google or Apple store, such as `com.example.myapp`.
|
55
|
+
#
|
56
|
+
# Required when `factor_type` is `push`. If specified, it can be up to 100
|
57
|
+
# characters long.
|
49
58
|
# @param [new_factor.NotificationPlatforms] config_notification_platform The
|
50
59
|
# transport technology used to generate the Notification Token. Can be `apn` or
|
51
|
-
# `fcm`.
|
60
|
+
# `fcm`.
|
61
|
+
#
|
62
|
+
# Required when `factor_type` is `push`
|
52
63
|
# @param [String] config_notification_token For APN, the device token. For FCM the
|
53
|
-
# registration token. It used to send the push notifications.
|
54
|
-
#
|
64
|
+
# registration token. It used to send the push notifications.
|
65
|
+
#
|
66
|
+
# Used when `factor_type` is `push`. If specified, must be between 32 and 255
|
55
67
|
# characters long.
|
56
68
|
# @param [String] config_sdk_version The Verify Push SDK version used to configure
|
57
69
|
# the factor
|
70
|
+
#
|
71
|
+
# Used when `factor_type` is `push`
|
58
72
|
# @param [String] binding_secret The shared secret for TOTP factors encoded in
|
59
|
-
# Base32
|
73
|
+
# Base32. This can be provided when creating the Factor, otherwise it will be
|
74
|
+
# generated.
|
75
|
+
#
|
76
|
+
# Used when `factor_type` is `totp`
|
60
77
|
# @param [String] config_time_step Defines how often, in seconds, are TOTP codes
|
61
78
|
# generated. i.e, a new TOTP code is generated every time_step seconds. Must be
|
62
79
|
# between 20 and 60 seconds, inclusive. The default value is defined at the
|
63
|
-
# service level in the property totp.time_step
|
64
|
-
#
|
80
|
+
# service level in the property `totp.time_step`. Defaults to 30 seconds if not
|
81
|
+
# configured.
|
82
|
+
#
|
83
|
+
# Used when `factor_type` is `totp`
|
65
84
|
# @param [String] config_skew The number of time-steps, past and future, that are
|
66
85
|
# valid for validation of TOTP codes. Must be between 0 and 2, inclusive. The
|
67
|
-
# default value is defined at the service level in the property totp.skew
|
68
|
-
# configured defaults to 1
|
86
|
+
# default value is defined at the service level in the property `totp.skew`. If
|
87
|
+
# not configured defaults to 1.
|
88
|
+
#
|
89
|
+
# Used when `factor_type` is `totp`
|
69
90
|
# @param [String] config_code_length Number of digits for generated TOTP codes.
|
70
91
|
# Must be between 3 and 8, inclusive. The default value is defined at the service
|
71
|
-
# level in the property totp.code_length
|
92
|
+
# level in the property `totp.code_length`. If not configured defaults to 6.
|
93
|
+
#
|
94
|
+
# Used when `factor_type` is `totp`
|
72
95
|
# @param [new_factor.TotpAlgorithms] config_alg The algorithm used to derive the
|
73
|
-
# TOTP codes. Can be `sha1`, `sha256` or `sha512`. Defaults to `sha1
|
96
|
+
# TOTP codes. Can be `sha1`, `sha256` or `sha512`. Defaults to `sha1`.
|
97
|
+
#
|
98
|
+
# Used when `factor_type` is `totp`
|
74
99
|
# @return [NewFactorInstance] Created NewFactorInstance
|
75
100
|
def create(friendly_name: nil, factor_type: nil, binding_alg: :unset, binding_public_key: :unset, config_app_id: :unset, config_notification_platform: :unset, config_notification_token: :unset, config_sdk_version: :unset, binding_secret: :unset, config_time_step: :unset, config_skew: :unset, config_code_length: :unset, config_alg: :unset)
|
76
101
|
data = Twilio::Values.of({
|
data/lib/twilio-ruby/version.rb
CHANGED
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.
|
4
|
+
version: 5.53.0
|
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: 2021-
|
11
|
+
date: 2021-05-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: jwt
|