twilio-ruby 7.10.1 → 7.10.4
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 +5 -5
- data/.github/workflows/test-and-deploy.yml +2 -1
- data/CHANGES.md +89 -0
- data/Dockerfile +1 -1
- data/README.md +2 -2
- data/cluster/cluster_oauth_spec.rb +4 -4
- data/lib/twilio-ruby/rest/api/v2010/account/call/payment.rb +14 -2
- data/lib/twilio-ruby/rest/api/v2010/account/call/transcription.rb +12 -0
- data/lib/twilio-ruby/rest/api/v2010/account/call.rb +8 -8
- data/lib/twilio-ruby/rest/flex_api/v1/create_flex_instance.rb +1 -1
- data/lib/twilio-ruby/rest/flex_api_base.rb +1 -6
- 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/intelligence/v2/operator_type.rb +12 -4
- data/lib/twilio-ruby/rest/messaging/v1/service/us_app_to_person.rb +93 -19
- data/lib/twilio-ruby/rest/messaging/v1/tollfree_verification.rb +21 -21
- data/lib/twilio-ruby/rest/messaging/v2/channels_sender.rb +2 -2
- 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/numbers/v2/regulatory_compliance/bundle.rb +20 -4
- data/lib/twilio-ruby/rest/preview_iam/versionless/organization/user.rb +197 -0
- data/lib/twilio-ruby/rest/studio/v2/flow/execution.rb +14 -0
- 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/verification.rb +2 -2
- data/lib/twilio-ruby/rest/video/v1/room/transcriptions.rb +12 -3
- data/lib/twilio-ruby/version.rb +1 -1
- metadata +10 -9
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
##
|
|
2
|
+
# This code was generated by
|
|
3
|
+
# ___ _ _ _ _ _ _ ____ ____ ____ _ ____ ____ _ _ ____ ____ ____ ___ __ __
|
|
4
|
+
# | | | | | | | | | __ | | |__| | __ | __ |___ |\ | |___ |__/ |__| | | | |__/
|
|
5
|
+
# | |_|_| | |___ | |__| |__| | | | |__] |___ | \| |___ | \ | | | |__| | \
|
|
6
|
+
#
|
|
7
|
+
# Sample/reference Twilio API.
|
|
8
|
+
# This is the reference API for the rest-proxy server.
|
|
9
|
+
#
|
|
10
|
+
# NOTE: This class is auto generated by OpenAPI Generator.
|
|
11
|
+
# https://openapi-generator.tech
|
|
12
|
+
# Do not edit the class manually.
|
|
13
|
+
#
|
|
14
|
+
|
|
15
|
+
module Twilio
|
|
16
|
+
module REST
|
|
17
|
+
class Insights
|
|
18
|
+
class V2 < Version
|
|
19
|
+
##
|
|
20
|
+
# Initialize the V2 version of Insights
|
|
21
|
+
def initialize(domain)
|
|
22
|
+
super
|
|
23
|
+
@version = 'v2'
|
|
24
|
+
@inbound = nil
|
|
25
|
+
@outbound = nil
|
|
26
|
+
@reports = nil
|
|
27
|
+
end
|
|
28
|
+
|
|
29
|
+
##
|
|
30
|
+
# @param [String] report_id A unique Report Id.
|
|
31
|
+
# @return [Twilio::REST::Insights::V2::InboundContext] if reportId was passed.
|
|
32
|
+
# @return [Twilio::REST::Insights::V2::InboundList]
|
|
33
|
+
def inbound(report_id=:unset)
|
|
34
|
+
if report_id.nil?
|
|
35
|
+
raise ArgumentError, 'report_id cannot be nil'
|
|
36
|
+
end
|
|
37
|
+
if report_id == :unset
|
|
38
|
+
@inbound ||= InboundList.new self
|
|
39
|
+
else
|
|
40
|
+
InboundContext.new(self, report_id)
|
|
41
|
+
end
|
|
42
|
+
end
|
|
43
|
+
##
|
|
44
|
+
# @param [String] report_id A unique Report Id.
|
|
45
|
+
# @return [Twilio::REST::Insights::V2::OutboundContext] if reportId was passed.
|
|
46
|
+
# @return [Twilio::REST::Insights::V2::OutboundList]
|
|
47
|
+
def outbound(report_id=:unset)
|
|
48
|
+
if report_id.nil?
|
|
49
|
+
raise ArgumentError, 'report_id cannot be nil'
|
|
50
|
+
end
|
|
51
|
+
if report_id == :unset
|
|
52
|
+
@outbound ||= OutboundList.new self
|
|
53
|
+
else
|
|
54
|
+
OutboundContext.new(self, report_id)
|
|
55
|
+
end
|
|
56
|
+
end
|
|
57
|
+
##
|
|
58
|
+
# @param [String] report_id A unique request id.
|
|
59
|
+
# @return [Twilio::REST::Insights::V2::ReportContext] if reportId was passed.
|
|
60
|
+
# @return [Twilio::REST::Insights::V2::ReportList]
|
|
61
|
+
def reports(report_id=:unset)
|
|
62
|
+
if report_id.nil?
|
|
63
|
+
raise ArgumentError, 'report_id cannot be nil'
|
|
64
|
+
end
|
|
65
|
+
if report_id == :unset
|
|
66
|
+
@reports ||= ReportList.new self
|
|
67
|
+
else
|
|
68
|
+
ReportContext.new(self, report_id)
|
|
69
|
+
end
|
|
70
|
+
end
|
|
71
|
+
##
|
|
72
|
+
# Provide a user friendly representation
|
|
73
|
+
def to_s
|
|
74
|
+
'<Twilio::REST::Insights::V2>';
|
|
75
|
+
end
|
|
76
|
+
end
|
|
77
|
+
end
|
|
78
|
+
end
|
|
79
|
+
end
|
|
@@ -22,16 +22,21 @@ module Twilio
|
|
|
22
22
|
@host = "insights.twilio.com"
|
|
23
23
|
@port = 443
|
|
24
24
|
@v1 = nil
|
|
25
|
+
@v2 = nil
|
|
25
26
|
end
|
|
26
27
|
|
|
27
28
|
def v1
|
|
28
29
|
@v1 ||= Insights::V1.new self
|
|
29
30
|
end
|
|
30
31
|
|
|
32
|
+
def v2
|
|
33
|
+
@v2 ||= Insights::V2.new self
|
|
34
|
+
end
|
|
35
|
+
|
|
31
36
|
##
|
|
32
37
|
# Provide a user friendly representation
|
|
33
38
|
def to_s
|
|
34
|
-
'<Twilio::REST::Insights
|
|
39
|
+
'<Twilio::REST::Insights>';
|
|
35
40
|
end
|
|
36
41
|
end
|
|
37
42
|
end
|
|
@@ -36,6 +36,7 @@ module Twilio
|
|
|
36
36
|
# Lists OperatorTypeInstance records from the API as a list.
|
|
37
37
|
# Unlike stream(), this operation is eager and will load `limit` records into
|
|
38
38
|
# memory before returning.
|
|
39
|
+
# @param [String] language_code Returns Operator Types that support the provided language code.
|
|
39
40
|
# @param [Integer] limit Upper limit for the number of records to return. stream()
|
|
40
41
|
# guarantees to never return more than limit. Default is no limit
|
|
41
42
|
# @param [Integer] page_size Number of records to fetch per request, when
|
|
@@ -43,8 +44,9 @@ module Twilio
|
|
|
43
44
|
# but a limit is defined, stream() will attempt to read the limit with the most
|
|
44
45
|
# efficient page size, i.e. min(limit, 1000)
|
|
45
46
|
# @return [Array] Array of up to limit results
|
|
46
|
-
def list(limit: nil, page_size: nil)
|
|
47
|
+
def list(language_code: :unset, limit: nil, page_size: nil)
|
|
47
48
|
self.stream(
|
|
49
|
+
language_code: language_code,
|
|
48
50
|
limit: limit,
|
|
49
51
|
page_size: page_size
|
|
50
52
|
).entries
|
|
@@ -54,6 +56,7 @@ module Twilio
|
|
|
54
56
|
# Streams Instance records from the API as an Enumerable.
|
|
55
57
|
# This operation lazily loads records as efficiently as possible until the limit
|
|
56
58
|
# is reached.
|
|
59
|
+
# @param [String] language_code Returns Operator Types that support the provided language code.
|
|
57
60
|
# @param [Integer] limit Upper limit for the number of records to return. stream()
|
|
58
61
|
# guarantees to never return more than limit. Default is no limit
|
|
59
62
|
# @param [Integer] page_size Number of records to fetch per request, when
|
|
@@ -61,10 +64,11 @@ module Twilio
|
|
|
61
64
|
# but a limit is defined, stream() will attempt to read the limit with the most
|
|
62
65
|
# efficient page size, i.e. min(limit, 1000)
|
|
63
66
|
# @return [Enumerable] Enumerable that will yield up to limit results
|
|
64
|
-
def stream(limit: nil, page_size: nil)
|
|
67
|
+
def stream(language_code: :unset, limit: nil, page_size: nil)
|
|
65
68
|
limits = @version.read_limits(limit, page_size)
|
|
66
69
|
|
|
67
70
|
page = self.page(
|
|
71
|
+
language_code: language_code,
|
|
68
72
|
page_size: limits[:page_size], )
|
|
69
73
|
|
|
70
74
|
@version.stream(page, limit: limits[:limit], page_limit: limits[:page_limit])
|
|
@@ -72,6 +76,7 @@ module Twilio
|
|
|
72
76
|
|
|
73
77
|
##
|
|
74
78
|
# Lists OperatorTypePageMetadata records from the API as a list.
|
|
79
|
+
# @param [String] language_code Returns Operator Types that support the provided language code.
|
|
75
80
|
# @param [Integer] limit Upper limit for the number of records to return. stream()
|
|
76
81
|
# guarantees to never return more than limit. Default is no limit
|
|
77
82
|
# @param [Integer] page_size Number of records to fetch per request, when
|
|
@@ -79,9 +84,10 @@ module Twilio
|
|
|
79
84
|
# but a limit is defined, stream() will attempt to read the limit with the most
|
|
80
85
|
# efficient page size, i.e. min(limit, 1000)
|
|
81
86
|
# @return [Array] Array of up to limit results
|
|
82
|
-
def list_with_metadata(limit: nil, page_size: nil)
|
|
87
|
+
def list_with_metadata(language_code: :unset, limit: nil, page_size: nil)
|
|
83
88
|
limits = @version.read_limits(limit, page_size)
|
|
84
89
|
params = Twilio::Values.of({
|
|
90
|
+
'LanguageCode' => language_code,
|
|
85
91
|
|
|
86
92
|
'PageSize' => limits[:page_size],
|
|
87
93
|
});
|
|
@@ -109,12 +115,14 @@ module Twilio
|
|
|
109
115
|
##
|
|
110
116
|
# Retrieve a single page of OperatorTypeInstance records from the API.
|
|
111
117
|
# Request is executed immediately.
|
|
118
|
+
# @param [String] language_code Returns Operator Types that support the provided language code.
|
|
112
119
|
# @param [String] page_token PageToken provided by the API
|
|
113
120
|
# @param [Integer] page_number Page Number, this value is simply for client state
|
|
114
121
|
# @param [Integer] page_size Number of records to return, defaults to 50
|
|
115
122
|
# @return [Page] Page of OperatorTypeInstance
|
|
116
|
-
def page(page_token: :unset, page_number: :unset,page_size: :unset)
|
|
123
|
+
def page(language_code: :unset, page_token: :unset, page_number: :unset,page_size: :unset)
|
|
117
124
|
params = Twilio::Values.of({
|
|
125
|
+
'LanguageCode' => language_code,
|
|
118
126
|
'PageToken' => page_token,
|
|
119
127
|
'Page' => page_number,
|
|
120
128
|
'PageSize' => page_size,
|
|
@@ -51,6 +51,9 @@ module Twilio
|
|
|
51
51
|
# @param [Boolean] subscriber_opt_in A boolean that specifies whether campaign has Subscriber Optin or not.
|
|
52
52
|
# @param [Boolean] age_gated A boolean that specifies whether campaign is age gated or not.
|
|
53
53
|
# @param [Boolean] direct_lending A boolean that specifies whether campaign allows direct lending or not.
|
|
54
|
+
# @param [String] privacy_policy_url The URL of the privacy policy for the campaign.
|
|
55
|
+
# @param [String] terms_and_conditions_url The URL of the terms and conditions for the campaign.
|
|
56
|
+
# @param [String] x_twilio_api_version The version of the Messaging API to use for this request
|
|
54
57
|
# @return [UsAppToPersonInstance] Created UsAppToPersonInstance
|
|
55
58
|
def create(
|
|
56
59
|
brand_registration_sid: nil,
|
|
@@ -68,7 +71,10 @@ module Twilio
|
|
|
68
71
|
help_keywords: :unset,
|
|
69
72
|
subscriber_opt_in: :unset,
|
|
70
73
|
age_gated: :unset,
|
|
71
|
-
direct_lending: :unset
|
|
74
|
+
direct_lending: :unset,
|
|
75
|
+
privacy_policy_url: :unset,
|
|
76
|
+
terms_and_conditions_url: :unset,
|
|
77
|
+
x_twilio_api_version: :unset
|
|
72
78
|
)
|
|
73
79
|
|
|
74
80
|
data = Twilio::Values.of({
|
|
@@ -88,9 +94,11 @@ module Twilio
|
|
|
88
94
|
'SubscriberOptIn' => subscriber_opt_in,
|
|
89
95
|
'AgeGated' => age_gated,
|
|
90
96
|
'DirectLending' => direct_lending,
|
|
97
|
+
'PrivacyPolicyUrl' => privacy_policy_url,
|
|
98
|
+
'TermsAndConditionsUrl' => terms_and_conditions_url,
|
|
91
99
|
})
|
|
92
100
|
|
|
93
|
-
headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', })
|
|
101
|
+
headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', 'X-Twilio-Api-Version' => x_twilio_api_version, })
|
|
94
102
|
|
|
95
103
|
|
|
96
104
|
|
|
@@ -122,6 +130,9 @@ module Twilio
|
|
|
122
130
|
# @param [Boolean] subscriber_opt_in A boolean that specifies whether campaign has Subscriber Optin or not.
|
|
123
131
|
# @param [Boolean] age_gated A boolean that specifies whether campaign is age gated or not.
|
|
124
132
|
# @param [Boolean] direct_lending A boolean that specifies whether campaign allows direct lending or not.
|
|
133
|
+
# @param [String] privacy_policy_url The URL of the privacy policy for the campaign.
|
|
134
|
+
# @param [String] terms_and_conditions_url The URL of the terms and conditions for the campaign.
|
|
135
|
+
# @param [String] x_twilio_api_version The version of the Messaging API to use for this request
|
|
125
136
|
# @return [UsAppToPersonInstance] Created UsAppToPersonInstance
|
|
126
137
|
def create_with_metadata(
|
|
127
138
|
brand_registration_sid: nil,
|
|
@@ -139,7 +150,10 @@ module Twilio
|
|
|
139
150
|
help_keywords: :unset,
|
|
140
151
|
subscriber_opt_in: :unset,
|
|
141
152
|
age_gated: :unset,
|
|
142
|
-
direct_lending: :unset
|
|
153
|
+
direct_lending: :unset,
|
|
154
|
+
privacy_policy_url: :unset,
|
|
155
|
+
terms_and_conditions_url: :unset,
|
|
156
|
+
x_twilio_api_version: :unset
|
|
143
157
|
)
|
|
144
158
|
|
|
145
159
|
data = Twilio::Values.of({
|
|
@@ -159,9 +173,11 @@ module Twilio
|
|
|
159
173
|
'SubscriberOptIn' => subscriber_opt_in,
|
|
160
174
|
'AgeGated' => age_gated,
|
|
161
175
|
'DirectLending' => direct_lending,
|
|
176
|
+
'PrivacyPolicyUrl' => privacy_policy_url,
|
|
177
|
+
'TermsAndConditionsUrl' => terms_and_conditions_url,
|
|
162
178
|
})
|
|
163
179
|
|
|
164
|
-
headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', })
|
|
180
|
+
headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', 'X-Twilio-Api-Version' => x_twilio_api_version, })
|
|
165
181
|
|
|
166
182
|
|
|
167
183
|
|
|
@@ -186,6 +202,7 @@ module Twilio
|
|
|
186
202
|
# Lists UsAppToPersonInstance records from the API as a list.
|
|
187
203
|
# Unlike stream(), this operation is eager and will load `limit` records into
|
|
188
204
|
# memory before returning.
|
|
205
|
+
# @param [String] x_twilio_api_version The version of the Messaging API to use for this request
|
|
189
206
|
# @param [Integer] limit Upper limit for the number of records to return. stream()
|
|
190
207
|
# guarantees to never return more than limit. Default is no limit
|
|
191
208
|
# @param [Integer] page_size Number of records to fetch per request, when
|
|
@@ -193,8 +210,9 @@ module Twilio
|
|
|
193
210
|
# but a limit is defined, stream() will attempt to read the limit with the most
|
|
194
211
|
# efficient page size, i.e. min(limit, 1000)
|
|
195
212
|
# @return [Array] Array of up to limit results
|
|
196
|
-
def list(limit: nil, page_size: nil)
|
|
213
|
+
def list(x_twilio_api_version: :unset, limit: nil, page_size: nil)
|
|
197
214
|
self.stream(
|
|
215
|
+
x_twilio_api_version: x_twilio_api_version,
|
|
198
216
|
limit: limit,
|
|
199
217
|
page_size: page_size
|
|
200
218
|
).entries
|
|
@@ -204,6 +222,7 @@ module Twilio
|
|
|
204
222
|
# Streams Instance records from the API as an Enumerable.
|
|
205
223
|
# This operation lazily loads records as efficiently as possible until the limit
|
|
206
224
|
# is reached.
|
|
225
|
+
# @param [String] x_twilio_api_version The version of the Messaging API to use for this request
|
|
207
226
|
# @param [Integer] limit Upper limit for the number of records to return. stream()
|
|
208
227
|
# guarantees to never return more than limit. Default is no limit
|
|
209
228
|
# @param [Integer] page_size Number of records to fetch per request, when
|
|
@@ -211,10 +230,11 @@ module Twilio
|
|
|
211
230
|
# but a limit is defined, stream() will attempt to read the limit with the most
|
|
212
231
|
# efficient page size, i.e. min(limit, 1000)
|
|
213
232
|
# @return [Enumerable] Enumerable that will yield up to limit results
|
|
214
|
-
def stream(limit: nil, page_size: nil)
|
|
233
|
+
def stream(x_twilio_api_version: :unset, limit: nil, page_size: nil)
|
|
215
234
|
limits = @version.read_limits(limit, page_size)
|
|
216
235
|
|
|
217
236
|
page = self.page(
|
|
237
|
+
x_twilio_api_version: x_twilio_api_version,
|
|
218
238
|
page_size: limits[:page_size], )
|
|
219
239
|
|
|
220
240
|
@version.stream(page, limit: limits[:limit], page_limit: limits[:page_limit])
|
|
@@ -222,6 +242,7 @@ module Twilio
|
|
|
222
242
|
|
|
223
243
|
##
|
|
224
244
|
# Lists UsAppToPersonPageMetadata records from the API as a list.
|
|
245
|
+
# @param [String] x_twilio_api_version The version of the Messaging API to use for this request
|
|
225
246
|
# @param [Integer] limit Upper limit for the number of records to return. stream()
|
|
226
247
|
# guarantees to never return more than limit. Default is no limit
|
|
227
248
|
# @param [Integer] page_size Number of records to fetch per request, when
|
|
@@ -229,9 +250,10 @@ module Twilio
|
|
|
229
250
|
# but a limit is defined, stream() will attempt to read the limit with the most
|
|
230
251
|
# efficient page size, i.e. min(limit, 1000)
|
|
231
252
|
# @return [Array] Array of up to limit results
|
|
232
|
-
def list_with_metadata(limit: nil, page_size: nil)
|
|
253
|
+
def list_with_metadata(x_twilio_api_version: :unset, limit: nil, page_size: nil)
|
|
233
254
|
limits = @version.read_limits(limit, page_size)
|
|
234
255
|
params = Twilio::Values.of({
|
|
256
|
+
'X-Twilio-Api-Version' => x_twilio_api_version,
|
|
235
257
|
|
|
236
258
|
'PageSize' => limits[:page_size],
|
|
237
259
|
});
|
|
@@ -259,12 +281,14 @@ module Twilio
|
|
|
259
281
|
##
|
|
260
282
|
# Retrieve a single page of UsAppToPersonInstance records from the API.
|
|
261
283
|
# Request is executed immediately.
|
|
284
|
+
# @param [String] x_twilio_api_version The version of the Messaging API to use for this request
|
|
262
285
|
# @param [String] page_token PageToken provided by the API
|
|
263
286
|
# @param [Integer] page_number Page Number, this value is simply for client state
|
|
264
287
|
# @param [Integer] page_size Number of records to return, defaults to 50
|
|
265
288
|
# @return [Page] Page of UsAppToPersonInstance
|
|
266
|
-
def page(page_token: :unset, page_number: :unset,page_size: :unset)
|
|
289
|
+
def page(x_twilio_api_version: :unset, page_token: :unset, page_number: :unset,page_size: :unset)
|
|
267
290
|
params = Twilio::Values.of({
|
|
291
|
+
'X-Twilio-Api-Version' => x_twilio_api_version,
|
|
268
292
|
'PageToken' => page_token,
|
|
269
293
|
'Page' => page_number,
|
|
270
294
|
'PageSize' => page_size,
|
|
@@ -351,10 +375,13 @@ module Twilio
|
|
|
351
375
|
|
|
352
376
|
##
|
|
353
377
|
# Fetch the UsAppToPersonInstance
|
|
378
|
+
# @param [String] x_twilio_api_version The version of the Messaging API to use for this request
|
|
354
379
|
# @return [UsAppToPersonInstance] Fetched UsAppToPersonInstance
|
|
355
|
-
def fetch
|
|
380
|
+
def fetch(
|
|
381
|
+
x_twilio_api_version: :unset
|
|
382
|
+
)
|
|
356
383
|
|
|
357
|
-
headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', })
|
|
384
|
+
headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', 'X-Twilio-Api-Version' => x_twilio_api_version, })
|
|
358
385
|
|
|
359
386
|
|
|
360
387
|
|
|
@@ -371,10 +398,13 @@ module Twilio
|
|
|
371
398
|
|
|
372
399
|
##
|
|
373
400
|
# Fetch the UsAppToPersonInstanceMetadata
|
|
401
|
+
# @param [String] x_twilio_api_version The version of the Messaging API to use for this request
|
|
374
402
|
# @return [UsAppToPersonInstance] Fetched UsAppToPersonInstance
|
|
375
|
-
def fetch_with_metadata
|
|
403
|
+
def fetch_with_metadata(
|
|
404
|
+
x_twilio_api_version: :unset
|
|
405
|
+
)
|
|
376
406
|
|
|
377
|
-
headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', })
|
|
407
|
+
headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', 'X-Twilio-Api-Version' => x_twilio_api_version, })
|
|
378
408
|
|
|
379
409
|
|
|
380
410
|
|
|
@@ -404,6 +434,9 @@ module Twilio
|
|
|
404
434
|
# @param [String] description A short description of what this SMS campaign does. Min length: 40 characters. Max length: 4096 characters.
|
|
405
435
|
# @param [Boolean] age_gated A boolean that specifies whether campaign requires age gate for federally legal content.
|
|
406
436
|
# @param [Boolean] direct_lending A boolean that specifies whether campaign allows direct lending or not.
|
|
437
|
+
# @param [String] privacy_policy_url The URL of the privacy policy for the campaign.
|
|
438
|
+
# @param [String] terms_and_conditions_url The URL of the terms and conditions for the campaign.
|
|
439
|
+
# @param [String] x_twilio_api_version The version of the Messaging API to use for this request
|
|
407
440
|
# @return [UsAppToPersonInstance] Updated UsAppToPersonInstance
|
|
408
441
|
def update(
|
|
409
442
|
has_embedded_links: nil,
|
|
@@ -412,7 +445,10 @@ module Twilio
|
|
|
412
445
|
message_flow: nil,
|
|
413
446
|
description: nil,
|
|
414
447
|
age_gated: nil,
|
|
415
|
-
direct_lending: nil
|
|
448
|
+
direct_lending: nil,
|
|
449
|
+
privacy_policy_url: :unset,
|
|
450
|
+
terms_and_conditions_url: :unset,
|
|
451
|
+
x_twilio_api_version: :unset
|
|
416
452
|
)
|
|
417
453
|
|
|
418
454
|
data = Twilio::Values.of({
|
|
@@ -423,9 +459,11 @@ module Twilio
|
|
|
423
459
|
'Description' => description,
|
|
424
460
|
'AgeGated' => age_gated,
|
|
425
461
|
'DirectLending' => direct_lending,
|
|
462
|
+
'PrivacyPolicyUrl' => privacy_policy_url,
|
|
463
|
+
'TermsAndConditionsUrl' => terms_and_conditions_url,
|
|
426
464
|
})
|
|
427
465
|
|
|
428
|
-
headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', })
|
|
466
|
+
headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', 'X-Twilio-Api-Version' => x_twilio_api_version, })
|
|
429
467
|
|
|
430
468
|
|
|
431
469
|
|
|
@@ -449,6 +487,9 @@ module Twilio
|
|
|
449
487
|
# @param [String] description A short description of what this SMS campaign does. Min length: 40 characters. Max length: 4096 characters.
|
|
450
488
|
# @param [Boolean] age_gated A boolean that specifies whether campaign requires age gate for federally legal content.
|
|
451
489
|
# @param [Boolean] direct_lending A boolean that specifies whether campaign allows direct lending or not.
|
|
490
|
+
# @param [String] privacy_policy_url The URL of the privacy policy for the campaign.
|
|
491
|
+
# @param [String] terms_and_conditions_url The URL of the terms and conditions for the campaign.
|
|
492
|
+
# @param [String] x_twilio_api_version The version of the Messaging API to use for this request
|
|
452
493
|
# @return [UsAppToPersonInstance] Updated UsAppToPersonInstance
|
|
453
494
|
def update_with_metadata(
|
|
454
495
|
has_embedded_links: nil,
|
|
@@ -457,7 +498,10 @@ module Twilio
|
|
|
457
498
|
message_flow: nil,
|
|
458
499
|
description: nil,
|
|
459
500
|
age_gated: nil,
|
|
460
|
-
direct_lending: nil
|
|
501
|
+
direct_lending: nil,
|
|
502
|
+
privacy_policy_url: :unset,
|
|
503
|
+
terms_and_conditions_url: :unset,
|
|
504
|
+
x_twilio_api_version: :unset
|
|
461
505
|
)
|
|
462
506
|
|
|
463
507
|
data = Twilio::Values.of({
|
|
@@ -468,9 +512,11 @@ module Twilio
|
|
|
468
512
|
'Description' => description,
|
|
469
513
|
'AgeGated' => age_gated,
|
|
470
514
|
'DirectLending' => direct_lending,
|
|
515
|
+
'PrivacyPolicyUrl' => privacy_policy_url,
|
|
516
|
+
'TermsAndConditionsUrl' => terms_and_conditions_url,
|
|
471
517
|
})
|
|
472
518
|
|
|
473
|
-
headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', })
|
|
519
|
+
headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', 'X-Twilio-Api-Version' => x_twilio_api_version, })
|
|
474
520
|
|
|
475
521
|
|
|
476
522
|
|
|
@@ -687,6 +733,8 @@ module Twilio
|
|
|
687
733
|
'url' => payload['url'],
|
|
688
734
|
'mock' => payload['mock'],
|
|
689
735
|
'errors' => payload['errors'],
|
|
736
|
+
'privacy_policy_url' => payload['privacy_policy_url'],
|
|
737
|
+
'terms_and_conditions_url' => payload['terms_and_conditions_url'],
|
|
690
738
|
}
|
|
691
739
|
|
|
692
740
|
# Context
|
|
@@ -873,6 +921,18 @@ module Twilio
|
|
|
873
921
|
@properties['errors']
|
|
874
922
|
end
|
|
875
923
|
|
|
924
|
+
##
|
|
925
|
+
# @return [String] The URL of the privacy policy for the campaign.
|
|
926
|
+
def privacy_policy_url
|
|
927
|
+
@properties['privacy_policy_url']
|
|
928
|
+
end
|
|
929
|
+
|
|
930
|
+
##
|
|
931
|
+
# @return [String] The URL of the terms and conditions for the campaign.
|
|
932
|
+
def terms_and_conditions_url
|
|
933
|
+
@properties['terms_and_conditions_url']
|
|
934
|
+
end
|
|
935
|
+
|
|
876
936
|
##
|
|
877
937
|
# Delete the UsAppToPersonInstance
|
|
878
938
|
# @return [Boolean] True if delete succeeds, false otherwise
|
|
@@ -883,10 +943,15 @@ module Twilio
|
|
|
883
943
|
|
|
884
944
|
##
|
|
885
945
|
# Fetch the UsAppToPersonInstance
|
|
946
|
+
# @param [String] x_twilio_api_version The version of the Messaging API to use for this request
|
|
886
947
|
# @return [UsAppToPersonInstance] Fetched UsAppToPersonInstance
|
|
887
|
-
def fetch
|
|
948
|
+
def fetch(
|
|
949
|
+
x_twilio_api_version: :unset
|
|
950
|
+
)
|
|
888
951
|
|
|
889
|
-
context.fetch
|
|
952
|
+
context.fetch(
|
|
953
|
+
x_twilio_api_version: x_twilio_api_version,
|
|
954
|
+
)
|
|
890
955
|
end
|
|
891
956
|
|
|
892
957
|
##
|
|
@@ -898,6 +963,9 @@ module Twilio
|
|
|
898
963
|
# @param [String] description A short description of what this SMS campaign does. Min length: 40 characters. Max length: 4096 characters.
|
|
899
964
|
# @param [Boolean] age_gated A boolean that specifies whether campaign requires age gate for federally legal content.
|
|
900
965
|
# @param [Boolean] direct_lending A boolean that specifies whether campaign allows direct lending or not.
|
|
966
|
+
# @param [String] privacy_policy_url The URL of the privacy policy for the campaign.
|
|
967
|
+
# @param [String] terms_and_conditions_url The URL of the terms and conditions for the campaign.
|
|
968
|
+
# @param [String] x_twilio_api_version The version of the Messaging API to use for this request
|
|
901
969
|
# @return [UsAppToPersonInstance] Updated UsAppToPersonInstance
|
|
902
970
|
def update(
|
|
903
971
|
has_embedded_links: nil,
|
|
@@ -906,7 +974,10 @@ module Twilio
|
|
|
906
974
|
message_flow: nil,
|
|
907
975
|
description: nil,
|
|
908
976
|
age_gated: nil,
|
|
909
|
-
direct_lending: nil
|
|
977
|
+
direct_lending: nil,
|
|
978
|
+
privacy_policy_url: :unset,
|
|
979
|
+
terms_and_conditions_url: :unset,
|
|
980
|
+
x_twilio_api_version: :unset
|
|
910
981
|
)
|
|
911
982
|
|
|
912
983
|
context.update(
|
|
@@ -917,6 +988,9 @@ module Twilio
|
|
|
917
988
|
description: description,
|
|
918
989
|
age_gated: age_gated,
|
|
919
990
|
direct_lending: direct_lending,
|
|
991
|
+
privacy_policy_url: privacy_policy_url,
|
|
992
|
+
terms_and_conditions_url: terms_and_conditions_url,
|
|
993
|
+
x_twilio_api_version: x_twilio_api_version,
|
|
920
994
|
)
|
|
921
995
|
end
|
|
922
996
|
|
|
@@ -36,7 +36,7 @@ module Twilio
|
|
|
36
36
|
# @param [String] business_name The name of the business or organization using the Tollfree number.
|
|
37
37
|
# @param [String] business_website The website of the business or organization using the Tollfree number.
|
|
38
38
|
# @param [String] notification_email The email address to receive the notification about the verification result. .
|
|
39
|
-
# @param [Array[String]] use_case_categories The category of the use case for the Tollfree Number. List as many are applicable
|
|
39
|
+
# @param [Array[String]] use_case_categories The category of the use case for the Tollfree Number. List as many as are applicable.
|
|
40
40
|
# @param [String] use_case_summary Use this to further explain how messaging is used by the business or organization.
|
|
41
41
|
# @param [String] production_message_sample An example of message content, i.e. a sample message.
|
|
42
42
|
# @param [Array[String]] opt_in_image_urls Link to an image that shows the opt-in workflow. Multiple images allowed and must be a publicly hosted URL.
|
|
@@ -57,9 +57,9 @@ module Twilio
|
|
|
57
57
|
# @param [String] business_contact_phone The E.164 formatted phone number of the contact for the business or organization using the Tollfree number.
|
|
58
58
|
# @param [String] external_reference_id An optional external reference ID supplied by customer and echoed back on status retrieval.
|
|
59
59
|
# @param [String] business_registration_number A legally recognized business registration number. Required for all business types except SOLE_PROPRIETOR.
|
|
60
|
-
# @param [
|
|
60
|
+
# @param [BusinessRegistrationAuthority] business_registration_authority
|
|
61
61
|
# @param [String] business_registration_country The country where the business is registered. Required for all business types except SOLE_PROPRIETOR.
|
|
62
|
-
# @param [
|
|
62
|
+
# @param [BusinessType] business_type
|
|
63
63
|
# @param [String] business_registration_phone_number The E.164 formatted number associated with the business.
|
|
64
64
|
# @param [String] doing_business_as Trade name, sub entity, or downstream business name of business being submitted for verification
|
|
65
65
|
# @param [String] opt_in_confirmation_message The confirmation message sent to users when they opt in to receive messages.
|
|
@@ -169,7 +169,7 @@ module Twilio
|
|
|
169
169
|
# @param [String] business_name The name of the business or organization using the Tollfree number.
|
|
170
170
|
# @param [String] business_website The website of the business or organization using the Tollfree number.
|
|
171
171
|
# @param [String] notification_email The email address to receive the notification about the verification result. .
|
|
172
|
-
# @param [Array[String]] use_case_categories The category of the use case for the Tollfree Number. List as many are applicable
|
|
172
|
+
# @param [Array[String]] use_case_categories The category of the use case for the Tollfree Number. List as many as are applicable.
|
|
173
173
|
# @param [String] use_case_summary Use this to further explain how messaging is used by the business or organization.
|
|
174
174
|
# @param [String] production_message_sample An example of message content, i.e. a sample message.
|
|
175
175
|
# @param [Array[String]] opt_in_image_urls Link to an image that shows the opt-in workflow. Multiple images allowed and must be a publicly hosted URL.
|
|
@@ -190,9 +190,9 @@ module Twilio
|
|
|
190
190
|
# @param [String] business_contact_phone The E.164 formatted phone number of the contact for the business or organization using the Tollfree number.
|
|
191
191
|
# @param [String] external_reference_id An optional external reference ID supplied by customer and echoed back on status retrieval.
|
|
192
192
|
# @param [String] business_registration_number A legally recognized business registration number. Required for all business types except SOLE_PROPRIETOR.
|
|
193
|
-
# @param [
|
|
193
|
+
# @param [BusinessRegistrationAuthority] business_registration_authority
|
|
194
194
|
# @param [String] business_registration_country The country where the business is registered. Required for all business types except SOLE_PROPRIETOR.
|
|
195
|
-
# @param [
|
|
195
|
+
# @param [BusinessType] business_type
|
|
196
196
|
# @param [String] business_registration_phone_number The E.164 formatted number associated with the business.
|
|
197
197
|
# @param [String] doing_business_as Trade name, sub entity, or downstream business name of business being submitted for verification
|
|
198
198
|
# @param [String] opt_in_confirmation_message The confirmation message sent to users when they opt in to receive messages.
|
|
@@ -561,7 +561,7 @@ module Twilio
|
|
|
561
561
|
# @param [String] business_name The name of the business or organization using the Tollfree number.
|
|
562
562
|
# @param [String] business_website The website of the business or organization using the Tollfree number.
|
|
563
563
|
# @param [String] notification_email The email address to receive the notification about the verification result. .
|
|
564
|
-
# @param [Array[String]] use_case_categories The category of the use case for the Tollfree Number. List as many are applicable
|
|
564
|
+
# @param [Array[String]] use_case_categories The category of the use case for the Tollfree Number. List as many as are applicable.
|
|
565
565
|
# @param [String] use_case_summary Use this to further explain how messaging is used by the business or organization.
|
|
566
566
|
# @param [String] production_message_sample An example of message content, i.e. a sample message.
|
|
567
567
|
# @param [Array[String]] opt_in_image_urls Link to an image that shows the opt-in workflow. Multiple images allowed and must be a publicly hosted URL.
|
|
@@ -579,10 +579,10 @@ module Twilio
|
|
|
579
579
|
# @param [String] business_contact_email The email address of the contact for the business or organization using the Tollfree number.
|
|
580
580
|
# @param [String] business_contact_phone The E.164 formatted phone number of the contact for the business or organization using the Tollfree number.
|
|
581
581
|
# @param [String] edit_reason Describe why the verification is being edited. If the verification was rejected because of a technical issue, such as the website being down, and the issue has been resolved this parameter should be set to something similar to 'Website fixed'.
|
|
582
|
-
# @param [String] business_registration_number A
|
|
583
|
-
# @param [
|
|
582
|
+
# @param [String] business_registration_number A legally recognized business registration number
|
|
583
|
+
# @param [BusinessRegistrationAuthority] business_registration_authority
|
|
584
584
|
# @param [String] business_registration_country Country business is registered in
|
|
585
|
-
# @param [
|
|
585
|
+
# @param [BusinessType] business_type
|
|
586
586
|
# @param [String] business_registration_phone_number The E.164 formatted number associated with the business.
|
|
587
587
|
# @param [String] doing_business_as Trade name, sub entity, or downstream business name of business being submitted for verification
|
|
588
588
|
# @param [String] opt_in_confirmation_message The confirmation message sent to users when they opt in to receive messages.
|
|
@@ -689,7 +689,7 @@ module Twilio
|
|
|
689
689
|
# @param [String] business_name The name of the business or organization using the Tollfree number.
|
|
690
690
|
# @param [String] business_website The website of the business or organization using the Tollfree number.
|
|
691
691
|
# @param [String] notification_email The email address to receive the notification about the verification result. .
|
|
692
|
-
# @param [Array[String]] use_case_categories The category of the use case for the Tollfree Number. List as many are applicable
|
|
692
|
+
# @param [Array[String]] use_case_categories The category of the use case for the Tollfree Number. List as many as are applicable.
|
|
693
693
|
# @param [String] use_case_summary Use this to further explain how messaging is used by the business or organization.
|
|
694
694
|
# @param [String] production_message_sample An example of message content, i.e. a sample message.
|
|
695
695
|
# @param [Array[String]] opt_in_image_urls Link to an image that shows the opt-in workflow. Multiple images allowed and must be a publicly hosted URL.
|
|
@@ -707,10 +707,10 @@ module Twilio
|
|
|
707
707
|
# @param [String] business_contact_email The email address of the contact for the business or organization using the Tollfree number.
|
|
708
708
|
# @param [String] business_contact_phone The E.164 formatted phone number of the contact for the business or organization using the Tollfree number.
|
|
709
709
|
# @param [String] edit_reason Describe why the verification is being edited. If the verification was rejected because of a technical issue, such as the website being down, and the issue has been resolved this parameter should be set to something similar to 'Website fixed'.
|
|
710
|
-
# @param [String] business_registration_number A
|
|
711
|
-
# @param [
|
|
710
|
+
# @param [String] business_registration_number A legally recognized business registration number
|
|
711
|
+
# @param [BusinessRegistrationAuthority] business_registration_authority
|
|
712
712
|
# @param [String] business_registration_country Country business is registered in
|
|
713
|
-
# @param [
|
|
713
|
+
# @param [BusinessType] business_type
|
|
714
714
|
# @param [String] business_registration_phone_number The E.164 formatted number associated with the business.
|
|
715
715
|
# @param [String] doing_business_as Trade name, sub entity, or downstream business name of business being submitted for verification
|
|
716
716
|
# @param [String] opt_in_confirmation_message The confirmation message sent to users when they opt in to receive messages.
|
|
@@ -1178,7 +1178,7 @@ module Twilio
|
|
|
1178
1178
|
end
|
|
1179
1179
|
|
|
1180
1180
|
##
|
|
1181
|
-
# @return [Array<String>] The category of the use case for the Tollfree Number. List as many are applicable
|
|
1181
|
+
# @return [Array<String>] The category of the use case for the Tollfree Number. List as many as are applicable.
|
|
1182
1182
|
def use_case_categories
|
|
1183
1183
|
@properties['use_case_categories']
|
|
1184
1184
|
end
|
|
@@ -1274,7 +1274,7 @@ module Twilio
|
|
|
1274
1274
|
end
|
|
1275
1275
|
|
|
1276
1276
|
##
|
|
1277
|
-
# @return [
|
|
1277
|
+
# @return [BusinessRegistrationAuthority]
|
|
1278
1278
|
def business_registration_authority
|
|
1279
1279
|
@properties['business_registration_authority']
|
|
1280
1280
|
end
|
|
@@ -1286,7 +1286,7 @@ module Twilio
|
|
|
1286
1286
|
end
|
|
1287
1287
|
|
|
1288
1288
|
##
|
|
1289
|
-
# @return [
|
|
1289
|
+
# @return [BusinessType]
|
|
1290
1290
|
def business_type
|
|
1291
1291
|
@properties['business_type']
|
|
1292
1292
|
end
|
|
@@ -1396,7 +1396,7 @@ module Twilio
|
|
|
1396
1396
|
# @param [String] business_name The name of the business or organization using the Tollfree number.
|
|
1397
1397
|
# @param [String] business_website The website of the business or organization using the Tollfree number.
|
|
1398
1398
|
# @param [String] notification_email The email address to receive the notification about the verification result. .
|
|
1399
|
-
# @param [Array[String]] use_case_categories The category of the use case for the Tollfree Number. List as many are applicable
|
|
1399
|
+
# @param [Array[String]] use_case_categories The category of the use case for the Tollfree Number. List as many as are applicable.
|
|
1400
1400
|
# @param [String] use_case_summary Use this to further explain how messaging is used by the business or organization.
|
|
1401
1401
|
# @param [String] production_message_sample An example of message content, i.e. a sample message.
|
|
1402
1402
|
# @param [Array[String]] opt_in_image_urls Link to an image that shows the opt-in workflow. Multiple images allowed and must be a publicly hosted URL.
|
|
@@ -1414,10 +1414,10 @@ module Twilio
|
|
|
1414
1414
|
# @param [String] business_contact_email The email address of the contact for the business or organization using the Tollfree number.
|
|
1415
1415
|
# @param [String] business_contact_phone The E.164 formatted phone number of the contact for the business or organization using the Tollfree number.
|
|
1416
1416
|
# @param [String] edit_reason Describe why the verification is being edited. If the verification was rejected because of a technical issue, such as the website being down, and the issue has been resolved this parameter should be set to something similar to 'Website fixed'.
|
|
1417
|
-
# @param [String] business_registration_number A
|
|
1418
|
-
# @param [
|
|
1417
|
+
# @param [String] business_registration_number A legally recognized business registration number
|
|
1418
|
+
# @param [BusinessRegistrationAuthority] business_registration_authority
|
|
1419
1419
|
# @param [String] business_registration_country Country business is registered in
|
|
1420
|
-
# @param [
|
|
1420
|
+
# @param [BusinessType] business_type
|
|
1421
1421
|
# @param [String] business_registration_phone_number The E.164 formatted number associated with the business.
|
|
1422
1422
|
# @param [String] doing_business_as Trade name, sub entity, or downstream business name of business being submitted for verification
|
|
1423
1423
|
# @param [String] opt_in_confirmation_message The confirmation message sent to users when they opt in to receive messages.
|