twilio-ruby 7.10.3 → 7.10.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.
- checksums.yaml +4 -4
- data/CHANGES.md +147 -0
- data/README.md +2 -2
- data/lib/twilio-ruby/rest/api/v2010/account/call/transcription.rb +6 -0
- data/lib/twilio-ruby/rest/api/v2010/account/message.rb +6 -0
- data/lib/twilio-ruby/rest/flex_api/v1.rb +0 -6
- data/lib/twilio-ruby/rest/iam/v1/role_permission.rb +319 -0
- data/lib/twilio-ruby/rest/iam/v1.rb +6 -0
- data/lib/twilio-ruby/rest/insights/v2/inbound.rb +570 -0
- data/lib/twilio-ruby/rest/insights/v2/outbound.rb +641 -0
- data/lib/twilio-ruby/rest/insights/v2/report.rb +940 -0
- data/lib/twilio-ruby/rest/insights/v2.rb +79 -0
- data/lib/twilio-ruby/rest/insights_base.rb +6 -1
- data/lib/twilio-ruby/rest/messaging/v3/typing_indicator.rb +247 -0
- data/lib/twilio-ruby/rest/messaging/v3.rb +40 -0
- data/lib/twilio-ruby/rest/messaging_base.rb +5 -0
- data/lib/twilio-ruby/rest/numbers/v1/embedded_session.rb +251 -0
- data/lib/twilio-ruby/rest/numbers/v1/sender_id_registration.rb +333 -0
- data/lib/twilio-ruby/rest/numbers/v1.rb +12 -0
- data/lib/twilio-ruby/rest/numbers/v2/application.rb +153 -8
- data/lib/twilio-ruby/rest/preview_iam/versionless/organization/user.rb +197 -0
- data/lib/twilio-ruby/rest/studio/v2/flow/execution.rb +33 -4
- data/lib/twilio-ruby/rest/studio/v2/flow/flow_revision.rb +7 -0
- data/lib/twilio-ruby/rest/studio/v2/flow.rb +7 -0
- data/lib/twilio-ruby/rest/verify/v2/service/approve_challenge.rb +7 -7
- data/lib/twilio-ruby/rest/verify/v2/service/new_challenge.rb +7 -7
- data/lib/twilio-ruby/rest/verify/v2/service/verification.rb +4 -4
- data/lib/twilio-ruby/twiml/voice_response.rb +8 -3
- data/lib/twilio-ruby/version.rb +1 -1
- metadata +11 -3
- data/lib/twilio-ruby/rest/flex_api/v1/create_flex_instance.rb +0 -382
|
@@ -21,6 +21,135 @@ module Twilio
|
|
|
21
21
|
|
|
22
22
|
class UserList < ListResource
|
|
23
23
|
|
|
24
|
+
class ScimPatchOperation
|
|
25
|
+
# @param [op]: [String] The operation to perform
|
|
26
|
+
# @param [path]: [String]
|
|
27
|
+
# @param [value]: [Hash]
|
|
28
|
+
attr_accessor :op, :path, :value
|
|
29
|
+
def initialize(payload)
|
|
30
|
+
@op = payload["op"]
|
|
31
|
+
@path = payload["path"]
|
|
32
|
+
@value = payload["value"]
|
|
33
|
+
end
|
|
34
|
+
def to_json(options = {})
|
|
35
|
+
{
|
|
36
|
+
"op": @op,
|
|
37
|
+
"path": @path,
|
|
38
|
+
"value": @value,
|
|
39
|
+
}.to_json(options)
|
|
40
|
+
end
|
|
41
|
+
end
|
|
42
|
+
|
|
43
|
+
class ScimPatchRequest
|
|
44
|
+
# @param [schemas]: [Array<String>]
|
|
45
|
+
# @param [operations]: [Array<UserList.ScimPatchOperation>]
|
|
46
|
+
attr_accessor :schemas, :operations
|
|
47
|
+
def initialize(payload)
|
|
48
|
+
@schemas = payload["schemas"]
|
|
49
|
+
@operations = payload["operations"]
|
|
50
|
+
end
|
|
51
|
+
def to_json(options = {})
|
|
52
|
+
{
|
|
53
|
+
"schemas": @schemas,
|
|
54
|
+
"Operations": @operations,
|
|
55
|
+
}.to_json(options)
|
|
56
|
+
end
|
|
57
|
+
end
|
|
58
|
+
|
|
59
|
+
class ScimUser
|
|
60
|
+
# @param [id]: [String] Unique Twilio user sid
|
|
61
|
+
# @param [external_id]: [String] External unique resource id defined by provisioning client
|
|
62
|
+
# @param [user_name]: [String] Unique username, MUST be same as primary email address
|
|
63
|
+
# @param [display_name]: [String] User friendly display name
|
|
64
|
+
# @param [name]: [UserList.ScimName]
|
|
65
|
+
# @param [emails]: [Array<UserList.ScimEmailAddress>] Email address list of the user. Primary email must be defined if there are more than 1 email. Primary email must match the username.
|
|
66
|
+
# @param [active]: [Boolean] Indicates whether the user is active
|
|
67
|
+
# @param [locale]: [String] User's locale
|
|
68
|
+
# @param [timezone]: [String] User's time zone
|
|
69
|
+
# @param [schemas]: [Array<String>] An array of URIs that indicate the schemas supported for this user resource
|
|
70
|
+
# @param [meta]: [UserList.ScimMeta]
|
|
71
|
+
# @param [detail]: [String] A human-readable description of the error
|
|
72
|
+
# @param [scim_type]: [String] A scimType error code as defined in RFC7644
|
|
73
|
+
# @param [status]: [String] Http status code
|
|
74
|
+
# @param [code]: [String] Twilio-specific error code
|
|
75
|
+
# @param [more_info]: [String] Link to Error Code References
|
|
76
|
+
attr_accessor :id, :external_id, :user_name, :display_name, :name, :emails, :active, :locale, :timezone, :schemas, :meta, :detail, :scim_type, :status, :code, :more_info
|
|
77
|
+
def initialize(payload)
|
|
78
|
+
@id = payload["id"]
|
|
79
|
+
@external_id = payload["external_id"]
|
|
80
|
+
@user_name = payload["user_name"]
|
|
81
|
+
@display_name = payload["display_name"]
|
|
82
|
+
@name = payload["name"]
|
|
83
|
+
@emails = payload["emails"]
|
|
84
|
+
@active = payload["active"]
|
|
85
|
+
@locale = payload["locale"]
|
|
86
|
+
@timezone = payload["timezone"]
|
|
87
|
+
@schemas = payload["schemas"]
|
|
88
|
+
@meta = payload["meta"]
|
|
89
|
+
@detail = payload["detail"]
|
|
90
|
+
@scim_type = payload["scim_type"]
|
|
91
|
+
@status = payload["status"]
|
|
92
|
+
@code = payload["code"]
|
|
93
|
+
@more_info = payload["more_info"]
|
|
94
|
+
end
|
|
95
|
+
def to_json(options = {})
|
|
96
|
+
{
|
|
97
|
+
"id": @id,
|
|
98
|
+
"externalId": @external_id,
|
|
99
|
+
"userName": @user_name,
|
|
100
|
+
"displayName": @display_name,
|
|
101
|
+
"name": @name,
|
|
102
|
+
"emails": @emails,
|
|
103
|
+
"active": @active,
|
|
104
|
+
"locale": @locale,
|
|
105
|
+
"timezone": @timezone,
|
|
106
|
+
"schemas": @schemas,
|
|
107
|
+
"meta": @meta,
|
|
108
|
+
"detail": @detail,
|
|
109
|
+
"scimType": @scim_type,
|
|
110
|
+
"status": @status,
|
|
111
|
+
"code": @code,
|
|
112
|
+
"moreInfo": @more_info,
|
|
113
|
+
}.to_json(options)
|
|
114
|
+
end
|
|
115
|
+
end
|
|
116
|
+
|
|
117
|
+
|
|
118
|
+
class ScimPatchOperation
|
|
119
|
+
# @param [op]: [String] The operation to perform
|
|
120
|
+
# @param [path]: [String]
|
|
121
|
+
# @param [value]: [Hash]
|
|
122
|
+
attr_accessor :op, :path, :value
|
|
123
|
+
def initialize(payload)
|
|
124
|
+
@op = payload["op"]
|
|
125
|
+
@path = payload["path"]
|
|
126
|
+
@value = payload["value"]
|
|
127
|
+
end
|
|
128
|
+
def to_json(options = {})
|
|
129
|
+
{
|
|
130
|
+
"op": @op,
|
|
131
|
+
"path": @path,
|
|
132
|
+
"value": @value,
|
|
133
|
+
}.to_json(options)
|
|
134
|
+
end
|
|
135
|
+
end
|
|
136
|
+
|
|
137
|
+
class ScimPatchRequest
|
|
138
|
+
# @param [schemas]: [Array<String>]
|
|
139
|
+
# @param [operations]: [Array<UserList.ScimPatchOperation>]
|
|
140
|
+
attr_accessor :schemas, :operations
|
|
141
|
+
def initialize(payload)
|
|
142
|
+
@schemas = payload["schemas"]
|
|
143
|
+
@operations = payload["operations"]
|
|
144
|
+
end
|
|
145
|
+
def to_json(options = {})
|
|
146
|
+
{
|
|
147
|
+
"schemas": @schemas,
|
|
148
|
+
"Operations": @operations,
|
|
149
|
+
}.to_json(options)
|
|
150
|
+
end
|
|
151
|
+
end
|
|
152
|
+
|
|
24
153
|
class ScimUser
|
|
25
154
|
# @param [id]: [String] Unique Twilio user sid
|
|
26
155
|
# @param [external_id]: [String] External unique resource id defined by provisioning client
|
|
@@ -362,6 +491,60 @@ module Twilio
|
|
|
362
491
|
)
|
|
363
492
|
end
|
|
364
493
|
|
|
494
|
+
##
|
|
495
|
+
# Patch the UserInstance
|
|
496
|
+
# @param [String] if_match
|
|
497
|
+
# @param [ScimPatchRequest] scim_patch_request
|
|
498
|
+
# @return [UserInstance] Patched UserInstance
|
|
499
|
+
def patch(
|
|
500
|
+
if_match: :unset,scim_patch_request: nil
|
|
501
|
+
)
|
|
502
|
+
|
|
503
|
+
headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', 'If-Match' => if_match, })
|
|
504
|
+
|
|
505
|
+
headers['Content-Type'] = 'application/scim+json'
|
|
506
|
+
|
|
507
|
+
headers['Accept'] = 'application/scim+json'
|
|
508
|
+
|
|
509
|
+
payload = @version.patch('PATCH', @uri, headers: headers, data: scim_patch_request.to_json)
|
|
510
|
+
UserInstance.new(
|
|
511
|
+
@version,
|
|
512
|
+
payload,
|
|
513
|
+
organization_sid: @solution[:organization_sid],
|
|
514
|
+
id: @solution[:id],
|
|
515
|
+
)
|
|
516
|
+
end
|
|
517
|
+
|
|
518
|
+
##
|
|
519
|
+
# Patch the UserInstanceMetadata
|
|
520
|
+
# @param [String] if_match
|
|
521
|
+
# @param [ScimPatchRequest] scim_patch_request
|
|
522
|
+
# @return [UserInstance] Patchd UserInstance
|
|
523
|
+
def patch_with_metadata(
|
|
524
|
+
if_match: :unset,scim_patch_request: nil
|
|
525
|
+
)
|
|
526
|
+
|
|
527
|
+
headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', 'If-Match' => if_match, })
|
|
528
|
+
|
|
529
|
+
headers['Content-Type'] = 'application/scim+json'
|
|
530
|
+
|
|
531
|
+
headers['Accept'] = 'application/scim+json'
|
|
532
|
+
|
|
533
|
+
response = @version.patch_with_metadata('PATCH', @uri, headers: headers, data: scim_patch_request.to_json)
|
|
534
|
+
user_instance = UserInstance.new(
|
|
535
|
+
@version,
|
|
536
|
+
response.body,
|
|
537
|
+
organization_sid: @solution[:organization_sid],
|
|
538
|
+
id: @solution[:id],
|
|
539
|
+
)
|
|
540
|
+
UserInstanceMetadata.new(
|
|
541
|
+
@version,
|
|
542
|
+
user_instance,
|
|
543
|
+
response.headers,
|
|
544
|
+
response.status_code
|
|
545
|
+
)
|
|
546
|
+
end
|
|
547
|
+
|
|
365
548
|
##
|
|
366
549
|
# Update the UserInstance
|
|
367
550
|
# @param [String] if_match
|
|
@@ -730,6 +913,20 @@ module Twilio
|
|
|
730
913
|
context.fetch
|
|
731
914
|
end
|
|
732
915
|
|
|
916
|
+
##
|
|
917
|
+
# Patch the UserInstance
|
|
918
|
+
# @param [String] if_match
|
|
919
|
+
# @param [ScimPatchRequest] scim_patch_request
|
|
920
|
+
# @return [UserInstance] Patched UserInstance
|
|
921
|
+
def patch(
|
|
922
|
+
if_match: :unset,scim_patch_request: nil
|
|
923
|
+
)
|
|
924
|
+
|
|
925
|
+
context.patch(
|
|
926
|
+
if_match: if_match,
|
|
927
|
+
)
|
|
928
|
+
end
|
|
929
|
+
|
|
733
930
|
##
|
|
734
931
|
# Update the UserInstance
|
|
735
932
|
# @param [String] if_match
|
|
@@ -108,6 +108,7 @@ module Twilio
|
|
|
108
108
|
# Lists ExecutionInstance records from the API as a list.
|
|
109
109
|
# Unlike stream(), this operation is eager and will load `limit` records into
|
|
110
110
|
# memory before returning.
|
|
111
|
+
# @param [Status] status Only show Execution resources with the given status. Can be: `active` or `ended`.
|
|
111
112
|
# @param [Time] date_created_from Only show Execution resources starting on or after this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date-time, given as `YYYY-MM-DDThh:mm:ss-hh:mm`.
|
|
112
113
|
# @param [Time] date_created_to Only show Execution resources starting before this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date-time, given as `YYYY-MM-DDThh:mm:ss-hh:mm`.
|
|
113
114
|
# @param [Integer] limit Upper limit for the number of records to return. stream()
|
|
@@ -117,8 +118,9 @@ module Twilio
|
|
|
117
118
|
# but a limit is defined, stream() will attempt to read the limit with the most
|
|
118
119
|
# efficient page size, i.e. min(limit, 1000)
|
|
119
120
|
# @return [Array] Array of up to limit results
|
|
120
|
-
def list(date_created_from: :unset, date_created_to: :unset, limit: nil, page_size: nil)
|
|
121
|
+
def list(status: :unset, date_created_from: :unset, date_created_to: :unset, limit: nil, page_size: nil)
|
|
121
122
|
self.stream(
|
|
123
|
+
status: status,
|
|
122
124
|
date_created_from: date_created_from,
|
|
123
125
|
date_created_to: date_created_to,
|
|
124
126
|
limit: limit,
|
|
@@ -130,6 +132,7 @@ module Twilio
|
|
|
130
132
|
# Streams Instance records from the API as an Enumerable.
|
|
131
133
|
# This operation lazily loads records as efficiently as possible until the limit
|
|
132
134
|
# is reached.
|
|
135
|
+
# @param [Status] status Only show Execution resources with the given status. Can be: `active` or `ended`.
|
|
133
136
|
# @param [Time] date_created_from Only show Execution resources starting on or after this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date-time, given as `YYYY-MM-DDThh:mm:ss-hh:mm`.
|
|
134
137
|
# @param [Time] date_created_to Only show Execution resources starting before this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date-time, given as `YYYY-MM-DDThh:mm:ss-hh:mm`.
|
|
135
138
|
# @param [Integer] limit Upper limit for the number of records to return. stream()
|
|
@@ -139,10 +142,11 @@ module Twilio
|
|
|
139
142
|
# but a limit is defined, stream() will attempt to read the limit with the most
|
|
140
143
|
# efficient page size, i.e. min(limit, 1000)
|
|
141
144
|
# @return [Enumerable] Enumerable that will yield up to limit results
|
|
142
|
-
def stream(date_created_from: :unset, date_created_to: :unset, limit: nil, page_size: nil)
|
|
145
|
+
def stream(status: :unset, date_created_from: :unset, date_created_to: :unset, limit: nil, page_size: nil)
|
|
143
146
|
limits = @version.read_limits(limit, page_size)
|
|
144
147
|
|
|
145
148
|
page = self.page(
|
|
149
|
+
status: status,
|
|
146
150
|
date_created_from: date_created_from,
|
|
147
151
|
date_created_to: date_created_to,
|
|
148
152
|
page_size: limits[:page_size], )
|
|
@@ -152,6 +156,7 @@ module Twilio
|
|
|
152
156
|
|
|
153
157
|
##
|
|
154
158
|
# Lists ExecutionPageMetadata records from the API as a list.
|
|
159
|
+
# @param [Status] status Only show Execution resources with the given status. Can be: `active` or `ended`.
|
|
155
160
|
# @param [Time] date_created_from Only show Execution resources starting on or after this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date-time, given as `YYYY-MM-DDThh:mm:ss-hh:mm`.
|
|
156
161
|
# @param [Time] date_created_to Only show Execution resources starting before this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date-time, given as `YYYY-MM-DDThh:mm:ss-hh:mm`.
|
|
157
162
|
# @param [Integer] limit Upper limit for the number of records to return. stream()
|
|
@@ -161,9 +166,10 @@ module Twilio
|
|
|
161
166
|
# but a limit is defined, stream() will attempt to read the limit with the most
|
|
162
167
|
# efficient page size, i.e. min(limit, 1000)
|
|
163
168
|
# @return [Array] Array of up to limit results
|
|
164
|
-
def list_with_metadata(date_created_from: :unset, date_created_to: :unset, limit: nil, page_size: nil)
|
|
169
|
+
def list_with_metadata(status: :unset, date_created_from: :unset, date_created_to: :unset, limit: nil, page_size: nil)
|
|
165
170
|
limits = @version.read_limits(limit, page_size)
|
|
166
171
|
params = Twilio::Values.of({
|
|
172
|
+
'status' => status,
|
|
167
173
|
'DateCreatedFrom' => Twilio.serialize_iso8601_datetime(date_created_from),
|
|
168
174
|
'DateCreatedTo' => Twilio.serialize_iso8601_datetime(date_created_to),
|
|
169
175
|
|
|
@@ -193,14 +199,16 @@ module Twilio
|
|
|
193
199
|
##
|
|
194
200
|
# Retrieve a single page of ExecutionInstance records from the API.
|
|
195
201
|
# Request is executed immediately.
|
|
202
|
+
# @param [Status] status Only show Execution resources with the given status. Can be: `active` or `ended`.
|
|
196
203
|
# @param [Time] date_created_from Only show Execution resources starting on or after this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date-time, given as `YYYY-MM-DDThh:mm:ss-hh:mm`.
|
|
197
204
|
# @param [Time] date_created_to Only show Execution resources starting before this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date-time, given as `YYYY-MM-DDThh:mm:ss-hh:mm`.
|
|
198
205
|
# @param [String] page_token PageToken provided by the API
|
|
199
206
|
# @param [Integer] page_number Page Number, this value is simply for client state
|
|
200
207
|
# @param [Integer] page_size Number of records to return, defaults to 50
|
|
201
208
|
# @return [Page] Page of ExecutionInstance
|
|
202
|
-
def page(date_created_from: :unset, date_created_to: :unset, page_token: :unset, page_number: :unset,page_size: :unset)
|
|
209
|
+
def page(status: :unset, date_created_from: :unset, date_created_to: :unset, page_token: :unset, page_number: :unset,page_size: :unset)
|
|
203
210
|
params = Twilio::Values.of({
|
|
211
|
+
'status' => status,
|
|
204
212
|
'DateCreatedFrom' => Twilio.serialize_iso8601_datetime(date_created_from),
|
|
205
213
|
'DateCreatedTo' => Twilio.serialize_iso8601_datetime(date_created_to),
|
|
206
214
|
'PageToken' => page_token,
|
|
@@ -597,10 +605,13 @@ module Twilio
|
|
|
597
605
|
'account_sid' => payload['account_sid'],
|
|
598
606
|
'flow_sid' => payload['flow_sid'],
|
|
599
607
|
'contact_channel_address' => payload['contact_channel_address'],
|
|
608
|
+
'contact_sid' => payload['contact_sid'],
|
|
609
|
+
'flow_version' => payload['flow_version'] == nil ? payload['flow_version'] : payload['flow_version'].to_i,
|
|
600
610
|
'context' => payload['context'],
|
|
601
611
|
'status' => payload['status'],
|
|
602
612
|
'date_created' => Twilio.deserialize_iso8601_datetime(payload['date_created']),
|
|
603
613
|
'date_updated' => Twilio.deserialize_iso8601_datetime(payload['date_updated']),
|
|
614
|
+
'initiated_by' => payload['initiated_by'],
|
|
604
615
|
'url' => payload['url'],
|
|
605
616
|
'links' => payload['links'],
|
|
606
617
|
}
|
|
@@ -645,6 +656,18 @@ module Twilio
|
|
|
645
656
|
@properties['contact_channel_address']
|
|
646
657
|
end
|
|
647
658
|
|
|
659
|
+
##
|
|
660
|
+
# @return [String] The SID of the Contact.
|
|
661
|
+
def contact_sid
|
|
662
|
+
@properties['contact_sid']
|
|
663
|
+
end
|
|
664
|
+
|
|
665
|
+
##
|
|
666
|
+
# @return [String] The Flow version number at the time of Execution creation.
|
|
667
|
+
def flow_version
|
|
668
|
+
@properties['flow_version']
|
|
669
|
+
end
|
|
670
|
+
|
|
648
671
|
##
|
|
649
672
|
# @return [Hash] The current state of the Flow's Execution. As a flow executes, we save its state in this context. We save data that your widgets can access as variables in configuration fields or in text areas as variable substitution.
|
|
650
673
|
def context
|
|
@@ -669,6 +692,12 @@ module Twilio
|
|
|
669
692
|
@properties['date_updated']
|
|
670
693
|
end
|
|
671
694
|
|
|
695
|
+
##
|
|
696
|
+
# @return [String] The SID or identifier that triggered this Execution. For example, a Call SID if triggered by an incoming call, a Message SID if triggered by an incoming message, a Request SID if triggered by a REST API request, and so on.
|
|
697
|
+
def initiated_by
|
|
698
|
+
@properties['initiated_by']
|
|
699
|
+
end
|
|
700
|
+
|
|
672
701
|
##
|
|
673
702
|
# @return [String] The absolute URL of the resource.
|
|
674
703
|
def url
|
|
@@ -385,6 +385,7 @@ module Twilio
|
|
|
385
385
|
@properties = {
|
|
386
386
|
'sid' => payload['sid'],
|
|
387
387
|
'account_sid' => payload['account_sid'],
|
|
388
|
+
'author_sid' => payload['author_sid'],
|
|
388
389
|
'friendly_name' => payload['friendly_name'],
|
|
389
390
|
'definition' => payload['definition'],
|
|
390
391
|
'status' => payload['status'],
|
|
@@ -425,6 +426,12 @@ module Twilio
|
|
|
425
426
|
@properties['account_sid']
|
|
426
427
|
end
|
|
427
428
|
|
|
429
|
+
##
|
|
430
|
+
# @return [String] The SID of the User that created or last updated the Flow.
|
|
431
|
+
def author_sid
|
|
432
|
+
@properties['author_sid']
|
|
433
|
+
end
|
|
434
|
+
|
|
428
435
|
##
|
|
429
436
|
# @return [String] The string that you assigned to describe the Flow.
|
|
430
437
|
def friendly_name
|
|
@@ -613,6 +613,7 @@ module Twilio
|
|
|
613
613
|
@properties = {
|
|
614
614
|
'sid' => payload['sid'],
|
|
615
615
|
'account_sid' => payload['account_sid'],
|
|
616
|
+
'author_sid' => payload['author_sid'],
|
|
616
617
|
'friendly_name' => payload['friendly_name'],
|
|
617
618
|
'definition' => payload['definition'],
|
|
618
619
|
'status' => payload['status'],
|
|
@@ -656,6 +657,12 @@ module Twilio
|
|
|
656
657
|
@properties['account_sid']
|
|
657
658
|
end
|
|
658
659
|
|
|
660
|
+
##
|
|
661
|
+
# @return [String] The SID of the User that created or last updated the Flow.
|
|
662
|
+
def author_sid
|
|
663
|
+
@properties['author_sid']
|
|
664
|
+
end
|
|
665
|
+
|
|
659
666
|
##
|
|
660
667
|
# @return [String] The string that you assigned to describe the Flow.
|
|
661
668
|
def friendly_name
|
|
@@ -243,7 +243,6 @@ module Twilio
|
|
|
243
243
|
|
|
244
244
|
# Marshaled Properties
|
|
245
245
|
@properties = {
|
|
246
|
-
'options' => payload['options'],
|
|
247
246
|
'sid' => payload['sid'],
|
|
248
247
|
'account_sid' => payload['account_sid'],
|
|
249
248
|
'service_sid' => payload['service_sid'],
|
|
@@ -262,16 +261,11 @@ module Twilio
|
|
|
262
261
|
'factor_type' => payload['factor_type'],
|
|
263
262
|
'url' => payload['url'],
|
|
264
263
|
'links' => payload['links'],
|
|
264
|
+
'options' => payload['options'],
|
|
265
265
|
}
|
|
266
266
|
end
|
|
267
267
|
|
|
268
268
|
|
|
269
|
-
##
|
|
270
|
-
# @return [Hash] An object that contains challenge options. Currently only used for `passkeys`.
|
|
271
|
-
def options
|
|
272
|
-
@properties['options']
|
|
273
|
-
end
|
|
274
|
-
|
|
275
269
|
##
|
|
276
270
|
# @return [String] A 34 character string that uniquely identifies this Challenge.
|
|
277
271
|
def sid
|
|
@@ -380,6 +374,12 @@ module Twilio
|
|
|
380
374
|
@properties['links']
|
|
381
375
|
end
|
|
382
376
|
|
|
377
|
+
##
|
|
378
|
+
# @return [Hash] An object that contains challenge options. Currently only used for `passkeys`.
|
|
379
|
+
def options
|
|
380
|
+
@properties['options']
|
|
381
|
+
end
|
|
382
|
+
|
|
383
383
|
##
|
|
384
384
|
# Provide a user friendly representation
|
|
385
385
|
def to_s
|
|
@@ -292,7 +292,6 @@ module Twilio
|
|
|
292
292
|
|
|
293
293
|
# Marshaled Properties
|
|
294
294
|
@properties = {
|
|
295
|
-
'options' => payload['options'],
|
|
296
295
|
'sid' => payload['sid'],
|
|
297
296
|
'account_sid' => payload['account_sid'],
|
|
298
297
|
'service_sid' => payload['service_sid'],
|
|
@@ -311,6 +310,7 @@ module Twilio
|
|
|
311
310
|
'factor_type' => payload['factor_type'],
|
|
312
311
|
'url' => payload['url'],
|
|
313
312
|
'links' => payload['links'],
|
|
313
|
+
'options' => payload['options'],
|
|
314
314
|
}
|
|
315
315
|
|
|
316
316
|
# Context
|
|
@@ -329,12 +329,6 @@ module Twilio
|
|
|
329
329
|
@instance_context
|
|
330
330
|
end
|
|
331
331
|
|
|
332
|
-
##
|
|
333
|
-
# @return [Hash] An object that contains challenge options. Currently only used for `passkeys`.
|
|
334
|
-
def options
|
|
335
|
-
@properties['options']
|
|
336
|
-
end
|
|
337
|
-
|
|
338
332
|
##
|
|
339
333
|
# @return [String] A 34 character string that uniquely identifies this Challenge.
|
|
340
334
|
def sid
|
|
@@ -443,6 +437,12 @@ module Twilio
|
|
|
443
437
|
@properties['links']
|
|
444
438
|
end
|
|
445
439
|
|
|
440
|
+
##
|
|
441
|
+
# @return [Hash] An object that contains challenge options. Currently only used for `passkeys`.
|
|
442
|
+
def options
|
|
443
|
+
@properties['options']
|
|
444
|
+
end
|
|
445
|
+
|
|
446
446
|
##
|
|
447
447
|
# Create the NewChallengeInstance
|
|
448
448
|
# @param [CreatePasskeysChallengeRequest] create_passkeys_challenge_request
|
|
@@ -38,7 +38,7 @@ module Twilio
|
|
|
38
38
|
# @param [String] to The phone number or [email](https://www.twilio.com/docs/verify/email) to verify. Phone numbers must be in [E.164 format](https://www.twilio.com/docs/glossary/what-e164).
|
|
39
39
|
# @param [String] channel The verification method to use. One of: [`email`](https://www.twilio.com/docs/verify/email), `sms`, `whatsapp`, `call`, `sna` or `auto`.
|
|
40
40
|
# @param [String] custom_friendly_name A custom user defined friendly name that overwrites the existing one in the verification message
|
|
41
|
-
# @param [String] custom_message The text of a custom message to use for the verification.
|
|
41
|
+
# @param [String] custom_message The text of a custom message to use for the verification [DEPRECATED].
|
|
42
42
|
# @param [String] send_digits The digits to send after a phone call is answered, for example, to dial an extension. For more information, see the Programmable Voice documentation of [sendDigits](https://www.twilio.com/docs/voice/twiml/number#attributes-sendDigits).
|
|
43
43
|
# @param [String] locale Locale will automatically resolve based on phone number country code for SMS, WhatsApp, and call channel verifications. It will fallback to English or the template’s default translation if the selected translation is not available. This parameter will override the automatic locale resolution. [See supported languages and more information here](https://www.twilio.com/docs/verify/supported-languages).
|
|
44
44
|
# @param [String] custom_code A pre-generated code to use for verification. The code can be between 4 and 10 characters, inclusive.
|
|
@@ -52,7 +52,7 @@ module Twilio
|
|
|
52
52
|
# @param [String] device_ip Strongly encouraged if using the auto channel. The IP address of the client's device. If provided, it has to be a valid IPv4 or IPv6 address.
|
|
53
53
|
# @param [Boolean] enable_sna_client_token An optional Boolean value to indicate the requirement of sna client token in the SNA URL invocation response for added security. This token must match in the Verification Check request to confirm phone number verification.
|
|
54
54
|
# @param [RiskCheck] risk_check
|
|
55
|
-
# @param [String] tags A string containing a JSON map of key value pairs of tags to be recorded as metadata for the message. The object may contain up to 10 tags. Keys and values can each be up to 128 characters in length.
|
|
55
|
+
# @param [String] tags A string containing a JSON map of key value pairs of tags to be recorded as metadata for the message. The tags will also be included as part of the verification and message status event type payloads. The object may contain up to 10 tags. Keys and values can each be up to 128 characters in length. **This value should not contain PII.**
|
|
56
56
|
# @return [VerificationInstance] Created VerificationInstance
|
|
57
57
|
def create(
|
|
58
58
|
to: nil,
|
|
@@ -115,7 +115,7 @@ module Twilio
|
|
|
115
115
|
# @param [String] to The phone number or [email](https://www.twilio.com/docs/verify/email) to verify. Phone numbers must be in [E.164 format](https://www.twilio.com/docs/glossary/what-e164).
|
|
116
116
|
# @param [String] channel The verification method to use. One of: [`email`](https://www.twilio.com/docs/verify/email), `sms`, `whatsapp`, `call`, `sna` or `auto`.
|
|
117
117
|
# @param [String] custom_friendly_name A custom user defined friendly name that overwrites the existing one in the verification message
|
|
118
|
-
# @param [String] custom_message The text of a custom message to use for the verification.
|
|
118
|
+
# @param [String] custom_message The text of a custom message to use for the verification [DEPRECATED].
|
|
119
119
|
# @param [String] send_digits The digits to send after a phone call is answered, for example, to dial an extension. For more information, see the Programmable Voice documentation of [sendDigits](https://www.twilio.com/docs/voice/twiml/number#attributes-sendDigits).
|
|
120
120
|
# @param [String] locale Locale will automatically resolve based on phone number country code for SMS, WhatsApp, and call channel verifications. It will fallback to English or the template’s default translation if the selected translation is not available. This parameter will override the automatic locale resolution. [See supported languages and more information here](https://www.twilio.com/docs/verify/supported-languages).
|
|
121
121
|
# @param [String] custom_code A pre-generated code to use for verification. The code can be between 4 and 10 characters, inclusive.
|
|
@@ -129,7 +129,7 @@ module Twilio
|
|
|
129
129
|
# @param [String] device_ip Strongly encouraged if using the auto channel. The IP address of the client's device. If provided, it has to be a valid IPv4 or IPv6 address.
|
|
130
130
|
# @param [Boolean] enable_sna_client_token An optional Boolean value to indicate the requirement of sna client token in the SNA URL invocation response for added security. This token must match in the Verification Check request to confirm phone number verification.
|
|
131
131
|
# @param [RiskCheck] risk_check
|
|
132
|
-
# @param [String] tags A string containing a JSON map of key value pairs of tags to be recorded as metadata for the message. The object may contain up to 10 tags. Keys and values can each be up to 128 characters in length.
|
|
132
|
+
# @param [String] tags A string containing a JSON map of key value pairs of tags to be recorded as metadata for the message. The tags will also be included as part of the verification and message status event type payloads. The object may contain up to 10 tags. Keys and values can each be up to 128 characters in length. **This value should not contain PII.**
|
|
133
133
|
# @return [VerificationInstance] Created VerificationInstance
|
|
134
134
|
def create_with_metadata(
|
|
135
135
|
to: nil,
|
|
@@ -2102,9 +2102,14 @@ module Twilio
|
|
|
2102
2102
|
# elevenlabs_text_normalization:: When using ElevenLabs as TTS provider, this parameter allows you to enable or disable its text normalization feature
|
|
2103
2103
|
# interrupt_sensitivity:: Set the sensitivity of the interrupt feature for speech. The value can be low, medium, or high
|
|
2104
2104
|
# debug:: Multiple debug options to be used for troubleshooting
|
|
2105
|
-
#
|
|
2106
|
-
|
|
2107
|
-
|
|
2105
|
+
# backgroundNoiseReduction:: This parameters enables background noise filtering on the audio stream before it reaches the STT engine, improving transcription accuracy in noisy environments
|
|
2106
|
+
# speechTimeout:: Set the duration of silence that indicates the end of speech
|
|
2107
|
+
# deepgramSmartFormat:: This parameter enables Deepgram's smart formatting feature, which automatically applies punctuation, capitalization, and formatting (e.g. numbers, dates, currency) to transcripts
|
|
2108
|
+
# ignoreBackchannel:: This parameter brief caller acknowledgments (e.g. "yeah", "uh-huh") are ignored and will not interrupt the agent while it is speaking.
|
|
2109
|
+
# events:: This parameter allows you to enable event subscriptions
|
|
2110
|
+
# keyword_args:: additional attributes
|
|
2111
|
+
def conversation_relay(url: nil, language: nil, tts_language: nil, transcription_language: nil, tts_provider: nil, voice: nil, transcription_provider: nil, speech_model: nil, profanity_filter: nil, dtmf_detection: nil, welcome_greeting: nil, partial_prompts: nil, welcome_greeting_interruptible: nil, interruptible: nil, preemptible: nil, hints: nil, intelligence_service: nil, report_input_during_agent_speech: nil, elevenlabs_text_normalization: nil, interrupt_sensitivity: nil, debug: nil, backgroundNoiseReduction: nil, speechTimeout: nil, deepgramSmartFormat: nil, ignoreBackchannel: nil, events: nil, **keyword_args)
|
|
2112
|
+
conversation_relay = ConversationRelay.new(url: url, language: language, tts_language: tts_language, transcription_language: transcription_language, tts_provider: tts_provider, voice: voice, transcription_provider: transcription_provider, speech_model: speech_model, profanity_filter: profanity_filter, dtmf_detection: dtmf_detection, welcome_greeting: welcome_greeting, partial_prompts: partial_prompts, welcome_greeting_interruptible: welcome_greeting_interruptible, interruptible: interruptible, preemptible: preemptible, hints: hints, intelligence_service: intelligence_service, report_input_during_agent_speech: report_input_during_agent_speech, elevenlabs_text_normalization: elevenlabs_text_normalization, interrupt_sensitivity: interrupt_sensitivity, debug: debug, backgroundNoiseReduction: backgroundNoiseReduction, speechTimeout: speechTimeout, deepgramSmartFormat: deepgramSmartFormat, ignoreBackchannel: ignoreBackchannel, events: events, **keyword_args)
|
|
2108
2113
|
|
|
2109
2114
|
yield(conversation_relay) if block_given?
|
|
2110
2115
|
append(conversation_relay)
|
data/lib/twilio-ruby/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: twilio-ruby
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 7.10.
|
|
4
|
+
version: 7.10.5
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Twilio API Team
|
|
@@ -461,7 +461,6 @@ files:
|
|
|
461
461
|
- lib/twilio-ruby/rest/flex_api/v1/assessments.rb
|
|
462
462
|
- lib/twilio-ruby/rest/flex_api/v1/channel.rb
|
|
463
463
|
- lib/twilio-ruby/rest/flex_api/v1/configuration.rb
|
|
464
|
-
- lib/twilio-ruby/rest/flex_api/v1/create_flex_instance.rb
|
|
465
464
|
- lib/twilio-ruby/rest/flex_api/v1/flex_flow.rb
|
|
466
465
|
- lib/twilio-ruby/rest/flex_api/v1/insights_assessments_comment.rb
|
|
467
466
|
- lib/twilio-ruby/rest/flex_api/v1/insights_conversations.rb
|
|
@@ -502,6 +501,7 @@ files:
|
|
|
502
501
|
- lib/twilio-ruby/rest/iam/v1/get_api_keys.rb
|
|
503
502
|
- lib/twilio-ruby/rest/iam/v1/new_api_key.rb
|
|
504
503
|
- lib/twilio-ruby/rest/iam/v1/o_auth_app.rb
|
|
504
|
+
- lib/twilio-ruby/rest/iam/v1/role_permission.rb
|
|
505
505
|
- lib/twilio-ruby/rest/iam/v1/token.rb
|
|
506
506
|
- lib/twilio-ruby/rest/iam_base.rb
|
|
507
507
|
- lib/twilio-ruby/rest/insights.rb
|
|
@@ -517,6 +517,10 @@ files:
|
|
|
517
517
|
- lib/twilio-ruby/rest/insights/v1/room.rb
|
|
518
518
|
- lib/twilio-ruby/rest/insights/v1/room/participant.rb
|
|
519
519
|
- lib/twilio-ruby/rest/insights/v1/setting.rb
|
|
520
|
+
- lib/twilio-ruby/rest/insights/v2.rb
|
|
521
|
+
- lib/twilio-ruby/rest/insights/v2/inbound.rb
|
|
522
|
+
- lib/twilio-ruby/rest/insights/v2/outbound.rb
|
|
523
|
+
- lib/twilio-ruby/rest/insights/v2/report.rb
|
|
520
524
|
- lib/twilio-ruby/rest/insights_base.rb
|
|
521
525
|
- lib/twilio-ruby/rest/intelligence.rb
|
|
522
526
|
- lib/twilio-ruby/rest/intelligence/v2.rb
|
|
@@ -614,6 +618,8 @@ files:
|
|
|
614
618
|
- lib/twilio-ruby/rest/messaging/v2/channels_sender.rb
|
|
615
619
|
- lib/twilio-ruby/rest/messaging/v2/domain_certs.rb
|
|
616
620
|
- lib/twilio-ruby/rest/messaging/v2/typing_indicator.rb
|
|
621
|
+
- lib/twilio-ruby/rest/messaging/v3.rb
|
|
622
|
+
- lib/twilio-ruby/rest/messaging/v3/typing_indicator.rb
|
|
617
623
|
- lib/twilio-ruby/rest/messaging_base.rb
|
|
618
624
|
- lib/twilio-ruby/rest/monitor.rb
|
|
619
625
|
- lib/twilio-ruby/rest/monitor/v1.rb
|
|
@@ -631,12 +637,14 @@ files:
|
|
|
631
637
|
- lib/twilio-ruby/rest/numbers/v1.rb
|
|
632
638
|
- lib/twilio-ruby/rest/numbers/v1/bulk_eligibility.rb
|
|
633
639
|
- lib/twilio-ruby/rest/numbers/v1/eligibility.rb
|
|
640
|
+
- lib/twilio-ruby/rest/numbers/v1/embedded_session.rb
|
|
634
641
|
- lib/twilio-ruby/rest/numbers/v1/porting_all_port_in.rb
|
|
635
642
|
- lib/twilio-ruby/rest/numbers/v1/porting_port_in.rb
|
|
636
643
|
- lib/twilio-ruby/rest/numbers/v1/porting_port_in_phone_number.rb
|
|
637
644
|
- lib/twilio-ruby/rest/numbers/v1/porting_portability.rb
|
|
638
645
|
- lib/twilio-ruby/rest/numbers/v1/porting_webhook_configuration.rb
|
|
639
646
|
- lib/twilio-ruby/rest/numbers/v1/porting_webhook_configuration_delete.rb
|
|
647
|
+
- lib/twilio-ruby/rest/numbers/v1/sender_id_registration.rb
|
|
640
648
|
- lib/twilio-ruby/rest/numbers/v1/signing_request_configuration.rb
|
|
641
649
|
- lib/twilio-ruby/rest/numbers/v1/webhook.rb
|
|
642
650
|
- lib/twilio-ruby/rest/numbers/v2.rb
|
|
@@ -948,7 +956,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
948
956
|
- !ruby/object:Gem::Version
|
|
949
957
|
version: '0'
|
|
950
958
|
requirements: []
|
|
951
|
-
rubygems_version: 4.0.
|
|
959
|
+
rubygems_version: 4.0.10
|
|
952
960
|
specification_version: 4
|
|
953
961
|
summary: The official library for communicating with the Twilio REST API, building
|
|
954
962
|
TwiML, and generating Twilio JWT Capability Tokens
|