twilio-ruby 5.0.0.rc9 → 5.0.0.rc10
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/twilio-ruby/rest/api/v2010/account/address/dependent_phone_number.rb +2 -9
- data/lib/twilio-ruby/rest/api/v2010/account/address.rb +13 -24
- data/lib/twilio-ruby/rest/api/v2010/account/application.rb +12 -23
- data/lib/twilio-ruby/rest/api/v2010/account/authorized_connect_app.rb +6 -15
- data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number/local.rb +2 -9
- data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number/mobile.rb +2 -9
- data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number/toll_free.rb +2 -9
- data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number.rb +9 -18
- data/lib/twilio-ruby/rest/api/v2010/account/call/feedback.rb +15 -23
- data/lib/twilio-ruby/rest/api/v2010/account/call/feedback_summary.rb +8 -15
- data/lib/twilio-ruby/rest/api/v2010/account/call/notification.rb +9 -18
- data/lib/twilio-ruby/rest/api/v2010/account/call/recording.rb +9 -18
- data/lib/twilio-ruby/rest/api/v2010/account/call.rb +20 -28
- data/lib/twilio-ruby/rest/api/v2010/account/conference/participant.rb +15 -24
- data/lib/twilio-ruby/rest/api/v2010/account/conference.rb +7 -16
- data/lib/twilio-ruby/rest/api/v2010/account/connect_app.rb +10 -20
- data/lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb +2 -10
- data/lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/mobile.rb +2 -10
- data/lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/toll_free.rb +2 -10
- data/lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number.rb +12 -23
- data/lib/twilio-ruby/rest/api/v2010/account/key.rb +324 -0
- data/lib/twilio-ruby/rest/api/v2010/account/message/feedback.rb +4 -9
- data/lib/twilio-ruby/rest/api/v2010/account/message/media.rb +9 -18
- data/lib/twilio-ruby/rest/api/v2010/account/message.rb +23 -29
- data/lib/twilio-ruby/rest/api/v2010/account/new_key.rb +145 -0
- data/lib/twilio-ruby/rest/api/v2010/account/new_signing_key.rb +145 -0
- data/lib/twilio-ruby/rest/api/v2010/account/notification.rb +7 -16
- data/lib/twilio-ruby/rest/api/v2010/account/outgoing_caller_id.rb +12 -21
- data/lib/twilio-ruby/rest/api/v2010/account/queue/member.rb +13 -23
- data/lib/twilio-ruby/rest/api/v2010/account/queue.rb +13 -24
- data/lib/twilio-ruby/rest/api/v2010/account/recording/transcription.rb +9 -18
- data/lib/twilio-ruby/rest/api/v2010/account/recording.rb +8 -17
- data/lib/twilio-ruby/rest/api/v2010/account/sandbox.rb +8 -15
- data/lib/twilio-ruby/rest/api/v2010/account/signing_key.rb +324 -0
- data/lib/twilio-ruby/rest/api/v2010/account/sip/credential_list/credential.rb +16 -27
- data/lib/twilio-ruby/rest/api/v2010/account/sip/credential_list.rb +14 -24
- data/lib/twilio-ruby/rest/api/v2010/account/sip/domain/credential_list_mapping.rb +11 -21
- data/lib/twilio-ruby/rest/api/v2010/account/sip/domain/ip_access_control_list_mapping.rb +11 -21
- data/lib/twilio-ruby/rest/api/v2010/account/sip/domain.rb +23 -31
- data/lib/twilio-ruby/rest/api/v2010/account/sip/ip_access_control_list/ip_address.rb +16 -27
- data/lib/twilio-ruby/rest/api/v2010/account/sip/ip_access_control_list.rb +14 -24
- data/lib/twilio-ruby/rest/api/v2010/account/sip.rb +1 -8
- data/lib/twilio-ruby/rest/api/v2010/account/sms/short_code.rb +10 -20
- data/lib/twilio-ruby/rest/api/v2010/account/sms/sms_message.rb +13 -23
- data/lib/twilio-ruby/rest/api/v2010/account/sms.rb +1 -7
- data/lib/twilio-ruby/rest/api/v2010/account/token.rb +2 -7
- data/lib/twilio-ruby/rest/api/v2010/account/transcription.rb +7 -16
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/all_time.rb +1 -8
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/daily.rb +1 -8
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/last_month.rb +1 -8
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/monthly.rb +1 -8
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/this_month.rb +1 -8
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/today.rb +1 -8
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/yearly.rb +1 -8
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/yesterday.rb +1 -8
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record.rb +1 -8
- data/lib/twilio-ruby/rest/api/v2010/account/usage/trigger.rb +12 -23
- data/lib/twilio-ruby/rest/api/v2010/account/usage.rb +1 -6
- data/lib/twilio-ruby/rest/api/v2010/account/validation_request.rb +2 -7
- data/lib/twilio-ruby/rest/api/v2010/account.rb +131 -38
- data/lib/twilio-ruby/rest/api/v2010.rb +17 -1
- data/lib/twilio-ruby/rest/api.rb +16 -0
- data/lib/twilio-ruby/rest/client.rb +16 -0
- data/lib/twilio-ruby/rest/ip_messaging/v1/credential.rb +13 -28
- data/lib/twilio-ruby/rest/ip_messaging/v1/service/channel/member.rb +11 -21
- data/lib/twilio-ruby/rest/ip_messaging/v1/service/channel/message.rb +62 -20
- data/lib/twilio-ruby/rest/ip_messaging/v1/service/channel.rb +17 -28
- data/lib/twilio-ruby/rest/ip_messaging/v1/service/role.rb +12 -23
- data/lib/twilio-ruby/rest/ip_messaging/v1/service/user.rb +23 -25
- data/lib/twilio-ruby/rest/ip_messaging/v1/service.rb +13 -24
- data/lib/twilio-ruby/rest/ip_messaging/v1.rb +1 -1
- data/lib/twilio-ruby/rest/lookups/v1/phone_number.rb +5 -12
- data/lib/twilio-ruby/rest/lookups/v1.rb +1 -1
- data/lib/twilio-ruby/rest/monitor/v1/alert.rb +5 -14
- data/lib/twilio-ruby/rest/monitor/v1/event.rb +4 -13
- data/lib/twilio-ruby/rest/monitor/v1.rb +1 -1
- data/lib/twilio-ruby/rest/notifications/v1/credential.rb +13 -28
- data/lib/twilio-ruby/rest/notifications/v1/service/binding.rb +8 -18
- data/lib/twilio-ruby/rest/notifications/v1/service/notification.rb +8 -8
- data/lib/twilio-ruby/rest/notifications/v1/service.rb +10 -21
- data/lib/twilio-ruby/rest/notifications/v1.rb +1 -1
- data/lib/twilio-ruby/rest/preview/wireless/command.rb +4 -14
- data/lib/twilio-ruby/rest/preview/wireless/device/usage.rb +6 -13
- data/lib/twilio-ruby/rest/preview/wireless/device.rb +8 -19
- data/lib/twilio-ruby/rest/preview/wireless/rate_plan.rb +4 -13
- data/lib/twilio-ruby/rest/preview/wireless.rb +1 -1
- data/lib/twilio-ruby/rest/pricing/v1/messaging/country.rb +4 -13
- data/lib/twilio-ruby/rest/pricing/v1/messaging.rb +0 -5
- data/lib/twilio-ruby/rest/pricing/v1/phone_number/country.rb +4 -13
- data/lib/twilio-ruby/rest/pricing/v1/phone_number.rb +0 -5
- data/lib/twilio-ruby/rest/pricing/v1/voice/country.rb +4 -13
- data/lib/twilio-ruby/rest/pricing/v1/voice/number.rb +4 -10
- data/lib/twilio-ruby/rest/pricing/v1/voice.rb +0 -6
- data/lib/twilio-ruby/rest/pricing/v1.rb +1 -1
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/activity.rb +13 -23
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/event.rb +6 -15
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task/reservation.rb +13 -23
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task.rb +13 -24
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue/task_queue_statistics.rb +8 -15
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue/task_queues_statistics.rb +1 -8
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue.rb +13 -24
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker/worker_statistics.rb +8 -15
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker/workers_statistics.rb +6 -13
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker.rb +13 -24
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workflow/workflow_statistics.rb +8 -15
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workflow.rb +13 -24
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workspace_statistics.rb +6 -13
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace.rb +15 -26
- data/lib/twilio-ruby/rest/taskrouter/v1.rb +1 -1
- data/lib/twilio-ruby/rest/trunking/v1/trunk/credential_list.rb +8 -18
- data/lib/twilio-ruby/rest/trunking/v1/trunk/ip_access_control_list.rb +8 -18
- data/lib/twilio-ruby/rest/trunking/v1/trunk/origination_url.rb +12 -23
- data/lib/twilio-ruby/rest/trunking/v1/trunk/phone_number.rb +8 -18
- data/lib/twilio-ruby/rest/trunking/v1/trunk.rb +12 -23
- data/lib/twilio-ruby/rest/trunking/v1.rb +1 -1
- data/lib/twilio-ruby/version.rb +1 -1
- data/spec/integration/api/v2010/account/key_spec.rb +178 -0
- data/spec/integration/api/v2010/account/message_spec.rb +2 -3
- data/spec/integration/api/v2010/account/new_key_spec.rb +45 -0
- data/spec/integration/api/v2010/account/new_signing_key_spec.rb +45 -0
- data/spec/integration/api/v2010/account/signing_key_spec.rb +178 -0
- data/spec/integration/api/v2010/account/sip/ip_access_control_list/ip_address_spec.rb +3 -7
- data/spec/integration/ip_messaging/v1/credential_spec.rb +5 -10
- data/spec/integration/ip_messaging/v1/service/channel/message_spec.rb +37 -0
- data/spec/integration/ip_messaging/v1/service/channel_spec.rb +3 -7
- data/spec/integration/ip_messaging/v1/service/user_spec.rb +3 -6
- data/spec/integration/notifications/v1/credential_spec.rb +5 -10
- data/spec/integration/notifications/v1/service/notification_spec.rb +1 -0
- data/spec/integration/preview/wireless/device_spec.rb +4 -4
- data/spec/integration/taskrouter/v1/workspace/task/reservation_spec.rb +3 -6
- metadata +15 -3
@@ -16,7 +16,6 @@ module Twilio
|
|
16
16
|
# @param [Version] version Version that contains the resource
|
17
17
|
# @param [String] account_sid A 34 character string that uniquely identifies this
|
18
18
|
# resource.
|
19
|
-
|
20
19
|
# @return [CredentialListList] CredentialListList
|
21
20
|
def initialize(version, account_sid: nil)
|
22
21
|
super(version)
|
@@ -38,7 +37,6 @@ module Twilio
|
|
38
37
|
# the default value of 50 records. If no page_size is defined
|
39
38
|
# but a limit is defined, stream() will attempt to read the
|
40
39
|
# limit with the most efficient page size, i.e. min(limit, 1000)
|
41
|
-
|
42
40
|
# @return [Array] Array of up to limit results
|
43
41
|
def list(limit: nil, page_size: nil)
|
44
42
|
self.stream(
|
@@ -57,7 +55,6 @@ module Twilio
|
|
57
55
|
# the default value of 50 records. If no page_size is defined
|
58
56
|
# but a limit is defined, stream() will attempt to read the
|
59
57
|
# limit with the most efficient page size, i.e. min(limit, 1000)
|
60
|
-
|
61
58
|
# @return [Enumerable] Enumerable that will yield up to limit results
|
62
59
|
def stream(limit: nil, page_size: nil)
|
63
60
|
limits = @version.read_limits(limit, page_size)
|
@@ -97,7 +94,6 @@ module Twilio
|
|
97
94
|
# @param [String] page_token PageToken provided by the API
|
98
95
|
# @param [Integer] page_number Page Number, this value is simply for client state
|
99
96
|
# @param [Integer] page_size Number of records to return, defaults to 50
|
100
|
-
|
101
97
|
# @return [Page] Page of CredentialListInstance
|
102
98
|
def page(page_token: nil, page_number: nil, page_size: nil)
|
103
99
|
params = {
|
@@ -117,7 +113,6 @@ module Twilio
|
|
117
113
|
# Retrieve a single page of CredentialListInstance records from the API.
|
118
114
|
# Request is executed immediately.
|
119
115
|
# @param [String] friendly_name The friendly_name
|
120
|
-
|
121
116
|
# @return [CredentialListInstance] Newly created CredentialListInstance
|
122
117
|
def create(friendly_name: nil)
|
123
118
|
data = {
|
@@ -133,7 +128,7 @@ module Twilio
|
|
133
128
|
return CredentialListInstance.new(
|
134
129
|
@version,
|
135
130
|
payload,
|
136
|
-
account_sid: @solution[
|
131
|
+
account_sid: @solution[:account_sid],
|
137
132
|
)
|
138
133
|
end
|
139
134
|
|
@@ -152,7 +147,6 @@ module Twilio
|
|
152
147
|
# @param [Hash] solution Path solution for the resource
|
153
148
|
# @param [String] account_sid A 34 character string that uniquely identifies this
|
154
149
|
# resource.
|
155
|
-
|
156
150
|
# @return [CredentialListPage] CredentialListPage
|
157
151
|
def initialize(version, response, solution)
|
158
152
|
super(version, response)
|
@@ -164,13 +158,12 @@ module Twilio
|
|
164
158
|
##
|
165
159
|
# Build an instance of CredentialListInstance
|
166
160
|
# @param [Hash] payload Payload response from the API
|
167
|
-
|
168
161
|
# @return [CredentialListInstance] CredentialListInstance
|
169
162
|
def get_instance(payload)
|
170
163
|
return CredentialListInstance.new(
|
171
164
|
@version,
|
172
165
|
payload,
|
173
|
-
account_sid: @solution[
|
166
|
+
account_sid: @solution[:account_sid],
|
174
167
|
)
|
175
168
|
end
|
176
169
|
|
@@ -187,7 +180,6 @@ module Twilio
|
|
187
180
|
# @param [Version] version Version that contains the resource
|
188
181
|
# @param [String] account_sid The account_sid
|
189
182
|
# @param [String] sid The credential Sid that uniquely identifies this resource
|
190
|
-
|
191
183
|
# @return [CredentialListContext] CredentialListContext
|
192
184
|
def initialize(version, account_sid, sid)
|
193
185
|
super(version)
|
@@ -218,15 +210,14 @@ module Twilio
|
|
218
210
|
return CredentialListInstance.new(
|
219
211
|
@version,
|
220
212
|
payload,
|
221
|
-
account_sid: @solution[
|
222
|
-
sid: @solution[
|
213
|
+
account_sid: @solution[:account_sid],
|
214
|
+
sid: @solution[:sid],
|
223
215
|
)
|
224
216
|
end
|
225
217
|
|
226
218
|
##
|
227
219
|
# Update the CredentialListInstance
|
228
220
|
# @param [String] friendly_name The friendly_name
|
229
|
-
|
230
221
|
# @return [CredentialListInstance] Updated CredentialListInstance
|
231
222
|
def update(friendly_name: nil)
|
232
223
|
data = {
|
@@ -242,8 +233,8 @@ module Twilio
|
|
242
233
|
return CredentialListInstance.new(
|
243
234
|
@version,
|
244
235
|
payload,
|
245
|
-
account_sid: @solution[
|
246
|
-
sid: @solution[
|
236
|
+
account_sid: @solution[:account_sid],
|
237
|
+
sid: @solution[:sid],
|
247
238
|
)
|
248
239
|
end
|
249
240
|
|
@@ -294,7 +285,6 @@ module Twilio
|
|
294
285
|
# @param [String] account_sid A 34 character string that uniquely identifies this
|
295
286
|
# resource.
|
296
287
|
# @param [String] sid The credential Sid that uniquely identifies this resource
|
297
|
-
|
298
288
|
# @return [CredentialListInstance] CredentialListInstance
|
299
289
|
def initialize(version, payload, account_sid: nil, sid: nil)
|
300
290
|
super(version)
|
@@ -322,7 +312,6 @@ module Twilio
|
|
322
312
|
# Generate an instance context for the instance, the context is capable of
|
323
313
|
# performing various actions. All instance actions are proxied to the context
|
324
314
|
# @param [Version] version Version that contains the resource
|
325
|
-
|
326
315
|
# @return [CredentialListContext] CredentialListContext for this CredentialListInstance
|
327
316
|
def context
|
328
317
|
unless @instance_context
|
@@ -367,37 +356,38 @@ module Twilio
|
|
367
356
|
# Fetch a CredentialListInstance
|
368
357
|
# @return [CredentialListInstance] Fetched CredentialListInstance
|
369
358
|
def fetch
|
370
|
-
|
359
|
+
context.fetch
|
371
360
|
end
|
372
361
|
|
373
362
|
##
|
374
363
|
# Update the CredentialListInstance
|
375
364
|
# @param [String] friendly_name The friendly_name
|
376
|
-
|
377
365
|
# @return [CredentialListInstance] Updated CredentialListInstance
|
378
366
|
def update(friendly_name: nil)
|
379
|
-
|
367
|
+
context.update(
|
368
|
+
friendly_name: friendly_name,
|
369
|
+
)
|
380
370
|
end
|
381
371
|
|
382
372
|
##
|
383
373
|
# Deletes the CredentialListInstance
|
384
374
|
# @return [Boolean] true if delete succeeds, true otherwise
|
385
375
|
def delete
|
386
|
-
|
376
|
+
context.delete
|
387
377
|
end
|
388
378
|
|
389
379
|
##
|
390
380
|
# Access the credentials
|
391
381
|
# @return [credentials] credentials
|
392
382
|
def credentials
|
393
|
-
|
383
|
+
context.credentials
|
394
384
|
end
|
395
385
|
|
396
386
|
##
|
397
387
|
# Provide a user friendly representation
|
398
388
|
def to_s
|
399
|
-
|
400
|
-
"<Twilio.Api.V2010.CredentialListInstance #{
|
389
|
+
values = @params.map{|k, v| "#{k}: #{v}"}.join(" ")
|
390
|
+
"<Twilio.Api.V2010.CredentialListInstance #{values}>"
|
401
391
|
end
|
402
392
|
end
|
403
393
|
end
|
@@ -18,7 +18,6 @@ module Twilio
|
|
18
18
|
# @param [String] account_sid The account_sid
|
19
19
|
# @param [String] domain_sid A 34 character string that uniquely identifies the
|
20
20
|
# SIP domain in Twilio
|
21
|
-
|
22
21
|
# @return [CredentialListMappingList] CredentialListMappingList
|
23
22
|
def initialize(version, account_sid: nil, domain_sid: nil)
|
24
23
|
super(version)
|
@@ -35,7 +34,6 @@ module Twilio
|
|
35
34
|
# Retrieve a single page of CredentialListMappingInstance records from the API.
|
36
35
|
# Request is executed immediately.
|
37
36
|
# @param [String] credential_list_sid The credential_list_sid
|
38
|
-
|
39
37
|
# @return [CredentialListMappingInstance] Newly created CredentialListMappingInstance
|
40
38
|
def create(credential_list_sid: nil)
|
41
39
|
data = {
|
@@ -51,8 +49,8 @@ module Twilio
|
|
51
49
|
return CredentialListMappingInstance.new(
|
52
50
|
@version,
|
53
51
|
payload,
|
54
|
-
account_sid: @solution[
|
55
|
-
domain_sid: @solution[
|
52
|
+
account_sid: @solution[:account_sid],
|
53
|
+
domain_sid: @solution[:domain_sid],
|
56
54
|
)
|
57
55
|
end
|
58
56
|
|
@@ -66,7 +64,6 @@ module Twilio
|
|
66
64
|
# the default value of 50 records. If no page_size is defined
|
67
65
|
# but a limit is defined, stream() will attempt to read the
|
68
66
|
# limit with the most efficient page size, i.e. min(limit, 1000)
|
69
|
-
|
70
67
|
# @return [Array] Array of up to limit results
|
71
68
|
def list(limit: nil, page_size: nil)
|
72
69
|
self.stream(
|
@@ -85,7 +82,6 @@ module Twilio
|
|
85
82
|
# the default value of 50 records. If no page_size is defined
|
86
83
|
# but a limit is defined, stream() will attempt to read the
|
87
84
|
# limit with the most efficient page size, i.e. min(limit, 1000)
|
88
|
-
|
89
85
|
# @return [Enumerable] Enumerable that will yield up to limit results
|
90
86
|
def stream(limit: nil, page_size: nil)
|
91
87
|
limits = @version.read_limits(limit, page_size)
|
@@ -125,7 +121,6 @@ module Twilio
|
|
125
121
|
# @param [String] page_token PageToken provided by the API
|
126
122
|
# @param [Integer] page_number Page Number, this value is simply for client state
|
127
123
|
# @param [Integer] page_size Number of records to return, defaults to 50
|
128
|
-
|
129
124
|
# @return [Page] Page of CredentialListMappingInstance
|
130
125
|
def page(page_token: nil, page_number: nil, page_size: nil)
|
131
126
|
params = {
|
@@ -157,7 +152,6 @@ module Twilio
|
|
157
152
|
# @param [String] account_sid The account_sid
|
158
153
|
# @param [String] domain_sid A 34 character string that uniquely identifies the
|
159
154
|
# SIP domain in Twilio
|
160
|
-
|
161
155
|
# @return [CredentialListMappingPage] CredentialListMappingPage
|
162
156
|
def initialize(version, response, solution)
|
163
157
|
super(version, response)
|
@@ -169,14 +163,13 @@ module Twilio
|
|
169
163
|
##
|
170
164
|
# Build an instance of CredentialListMappingInstance
|
171
165
|
# @param [Hash] payload Payload response from the API
|
172
|
-
|
173
166
|
# @return [CredentialListMappingInstance] CredentialListMappingInstance
|
174
167
|
def get_instance(payload)
|
175
168
|
return CredentialListMappingInstance.new(
|
176
169
|
@version,
|
177
170
|
payload,
|
178
|
-
account_sid: @solution[
|
179
|
-
domain_sid: @solution[
|
171
|
+
account_sid: @solution[:account_sid],
|
172
|
+
domain_sid: @solution[:domain_sid],
|
180
173
|
)
|
181
174
|
end
|
182
175
|
|
@@ -194,7 +187,6 @@ module Twilio
|
|
194
187
|
# @param [String] account_sid The account_sid
|
195
188
|
# @param [String] domain_sid The domain_sid
|
196
189
|
# @param [String] sid The sid
|
197
|
-
|
198
190
|
# @return [CredentialListMappingContext] CredentialListMappingContext
|
199
191
|
def initialize(version, account_sid, domain_sid, sid)
|
200
192
|
super(version)
|
@@ -223,9 +215,9 @@ module Twilio
|
|
223
215
|
return CredentialListMappingInstance.new(
|
224
216
|
@version,
|
225
217
|
payload,
|
226
|
-
account_sid: @solution[
|
227
|
-
domain_sid: @solution[
|
228
|
-
sid: @solution[
|
218
|
+
account_sid: @solution[:account_sid],
|
219
|
+
domain_sid: @solution[:domain_sid],
|
220
|
+
sid: @solution[:sid],
|
229
221
|
)
|
230
222
|
end
|
231
223
|
|
@@ -253,7 +245,6 @@ module Twilio
|
|
253
245
|
# @param [String] domain_sid A 34 character string that uniquely identifies the
|
254
246
|
# SIP domain in Twilio
|
255
247
|
# @param [String] sid The sid
|
256
|
-
|
257
248
|
# @return [CredentialListMappingInstance] CredentialListMappingInstance
|
258
249
|
def initialize(version, payload, account_sid: nil, domain_sid: nil, sid: nil)
|
259
250
|
super(version)
|
@@ -281,7 +272,6 @@ module Twilio
|
|
281
272
|
# Generate an instance context for the instance, the context is capable of
|
282
273
|
# performing various actions. All instance actions are proxied to the context
|
283
274
|
# @param [Version] version Version that contains the resource
|
284
|
-
|
285
275
|
# @return [CredentialListMappingContext] CredentialListMappingContext for this CredentialListMappingInstance
|
286
276
|
def context
|
287
277
|
unless @instance_context
|
@@ -323,21 +313,21 @@ module Twilio
|
|
323
313
|
# Fetch a CredentialListMappingInstance
|
324
314
|
# @return [CredentialListMappingInstance] Fetched CredentialListMappingInstance
|
325
315
|
def fetch
|
326
|
-
|
316
|
+
context.fetch
|
327
317
|
end
|
328
318
|
|
329
319
|
##
|
330
320
|
# Deletes the CredentialListMappingInstance
|
331
321
|
# @return [Boolean] true if delete succeeds, true otherwise
|
332
322
|
def delete
|
333
|
-
|
323
|
+
context.delete
|
334
324
|
end
|
335
325
|
|
336
326
|
##
|
337
327
|
# Provide a user friendly representation
|
338
328
|
def to_s
|
339
|
-
|
340
|
-
"<Twilio.Api.V2010.CredentialListMappingInstance #{
|
329
|
+
values = @params.map{|k, v| "#{k}: #{v}"}.join(" ")
|
330
|
+
"<Twilio.Api.V2010.CredentialListMappingInstance #{values}>"
|
341
331
|
end
|
342
332
|
end
|
343
333
|
end
|
@@ -18,7 +18,6 @@ module Twilio
|
|
18
18
|
# @param [String] account_sid The account_sid
|
19
19
|
# @param [String] domain_sid A 34 character string that uniquely identifies the
|
20
20
|
# SIP domain in Twilio
|
21
|
-
|
22
21
|
# @return [IpAccessControlListMappingList] IpAccessControlListMappingList
|
23
22
|
def initialize(version, account_sid: nil, domain_sid: nil)
|
24
23
|
super(version)
|
@@ -35,7 +34,6 @@ module Twilio
|
|
35
34
|
# Retrieve a single page of IpAccessControlListMappingInstance records from the API.
|
36
35
|
# Request is executed immediately.
|
37
36
|
# @param [String] ip_access_control_list_sid The ip_access_control_list_sid
|
38
|
-
|
39
37
|
# @return [IpAccessControlListMappingInstance] Newly created IpAccessControlListMappingInstance
|
40
38
|
def create(ip_access_control_list_sid: nil)
|
41
39
|
data = {
|
@@ -51,8 +49,8 @@ module Twilio
|
|
51
49
|
return IpAccessControlListMappingInstance.new(
|
52
50
|
@version,
|
53
51
|
payload,
|
54
|
-
account_sid: @solution[
|
55
|
-
domain_sid: @solution[
|
52
|
+
account_sid: @solution[:account_sid],
|
53
|
+
domain_sid: @solution[:domain_sid],
|
56
54
|
)
|
57
55
|
end
|
58
56
|
|
@@ -66,7 +64,6 @@ module Twilio
|
|
66
64
|
# the default value of 50 records. If no page_size is defined
|
67
65
|
# but a limit is defined, stream() will attempt to read the
|
68
66
|
# limit with the most efficient page size, i.e. min(limit, 1000)
|
69
|
-
|
70
67
|
# @return [Array] Array of up to limit results
|
71
68
|
def list(limit: nil, page_size: nil)
|
72
69
|
self.stream(
|
@@ -85,7 +82,6 @@ module Twilio
|
|
85
82
|
# the default value of 50 records. If no page_size is defined
|
86
83
|
# but a limit is defined, stream() will attempt to read the
|
87
84
|
# limit with the most efficient page size, i.e. min(limit, 1000)
|
88
|
-
|
89
85
|
# @return [Enumerable] Enumerable that will yield up to limit results
|
90
86
|
def stream(limit: nil, page_size: nil)
|
91
87
|
limits = @version.read_limits(limit, page_size)
|
@@ -125,7 +121,6 @@ module Twilio
|
|
125
121
|
# @param [String] page_token PageToken provided by the API
|
126
122
|
# @param [Integer] page_number Page Number, this value is simply for client state
|
127
123
|
# @param [Integer] page_size Number of records to return, defaults to 50
|
128
|
-
|
129
124
|
# @return [Page] Page of IpAccessControlListMappingInstance
|
130
125
|
def page(page_token: nil, page_number: nil, page_size: nil)
|
131
126
|
params = {
|
@@ -157,7 +152,6 @@ module Twilio
|
|
157
152
|
# @param [String] account_sid The account_sid
|
158
153
|
# @param [String] domain_sid A 34 character string that uniquely identifies the
|
159
154
|
# SIP domain in Twilio
|
160
|
-
|
161
155
|
# @return [IpAccessControlListMappingPage] IpAccessControlListMappingPage
|
162
156
|
def initialize(version, response, solution)
|
163
157
|
super(version, response)
|
@@ -169,14 +163,13 @@ module Twilio
|
|
169
163
|
##
|
170
164
|
# Build an instance of IpAccessControlListMappingInstance
|
171
165
|
# @param [Hash] payload Payload response from the API
|
172
|
-
|
173
166
|
# @return [IpAccessControlListMappingInstance] IpAccessControlListMappingInstance
|
174
167
|
def get_instance(payload)
|
175
168
|
return IpAccessControlListMappingInstance.new(
|
176
169
|
@version,
|
177
170
|
payload,
|
178
|
-
account_sid: @solution[
|
179
|
-
domain_sid: @solution[
|
171
|
+
account_sid: @solution[:account_sid],
|
172
|
+
domain_sid: @solution[:domain_sid],
|
180
173
|
)
|
181
174
|
end
|
182
175
|
|
@@ -194,7 +187,6 @@ module Twilio
|
|
194
187
|
# @param [String] account_sid The account_sid
|
195
188
|
# @param [String] domain_sid The domain_sid
|
196
189
|
# @param [String] sid The sid
|
197
|
-
|
198
190
|
# @return [IpAccessControlListMappingContext] IpAccessControlListMappingContext
|
199
191
|
def initialize(version, account_sid, domain_sid, sid)
|
200
192
|
super(version)
|
@@ -223,9 +215,9 @@ module Twilio
|
|
223
215
|
return IpAccessControlListMappingInstance.new(
|
224
216
|
@version,
|
225
217
|
payload,
|
226
|
-
account_sid: @solution[
|
227
|
-
domain_sid: @solution[
|
228
|
-
sid: @solution[
|
218
|
+
account_sid: @solution[:account_sid],
|
219
|
+
domain_sid: @solution[:domain_sid],
|
220
|
+
sid: @solution[:sid],
|
229
221
|
)
|
230
222
|
end
|
231
223
|
|
@@ -253,7 +245,6 @@ module Twilio
|
|
253
245
|
# @param [String] domain_sid A 34 character string that uniquely identifies the
|
254
246
|
# SIP domain in Twilio
|
255
247
|
# @param [String] sid The sid
|
256
|
-
|
257
248
|
# @return [IpAccessControlListMappingInstance] IpAccessControlListMappingInstance
|
258
249
|
def initialize(version, payload, account_sid: nil, domain_sid: nil, sid: nil)
|
259
250
|
super(version)
|
@@ -281,7 +272,6 @@ module Twilio
|
|
281
272
|
# Generate an instance context for the instance, the context is capable of
|
282
273
|
# performing various actions. All instance actions are proxied to the context
|
283
274
|
# @param [Version] version Version that contains the resource
|
284
|
-
|
285
275
|
# @return [IpAccessControlListMappingContext] IpAccessControlListMappingContext for this IpAccessControlListMappingInstance
|
286
276
|
def context
|
287
277
|
unless @instance_context
|
@@ -323,21 +313,21 @@ module Twilio
|
|
323
313
|
# Fetch a IpAccessControlListMappingInstance
|
324
314
|
# @return [IpAccessControlListMappingInstance] Fetched IpAccessControlListMappingInstance
|
325
315
|
def fetch
|
326
|
-
|
316
|
+
context.fetch
|
327
317
|
end
|
328
318
|
|
329
319
|
##
|
330
320
|
# Deletes the IpAccessControlListMappingInstance
|
331
321
|
# @return [Boolean] true if delete succeeds, true otherwise
|
332
322
|
def delete
|
333
|
-
|
323
|
+
context.delete
|
334
324
|
end
|
335
325
|
|
336
326
|
##
|
337
327
|
# Provide a user friendly representation
|
338
328
|
def to_s
|
339
|
-
|
340
|
-
"<Twilio.Api.V2010.IpAccessControlListMappingInstance #{
|
329
|
+
values = @params.map{|k, v| "#{k}: #{v}"}.join(" ")
|
330
|
+
"<Twilio.Api.V2010.IpAccessControlListMappingInstance #{values}>"
|
341
331
|
end
|
342
332
|
end
|
343
333
|
end
|
@@ -16,7 +16,6 @@ module Twilio
|
|
16
16
|
# @param [Version] version Version that contains the resource
|
17
17
|
# @param [String] account_sid A 34 character string that uniquely identifies this
|
18
18
|
# resource.
|
19
|
-
|
20
19
|
# @return [DomainList] DomainList
|
21
20
|
def initialize(version, account_sid: nil)
|
22
21
|
super(version)
|
@@ -38,7 +37,6 @@ module Twilio
|
|
38
37
|
# the default value of 50 records. If no page_size is defined
|
39
38
|
# but a limit is defined, stream() will attempt to read the
|
40
39
|
# limit with the most efficient page size, i.e. min(limit, 1000)
|
41
|
-
|
42
40
|
# @return [Array] Array of up to limit results
|
43
41
|
def list(limit: nil, page_size: nil)
|
44
42
|
self.stream(
|
@@ -57,7 +55,6 @@ module Twilio
|
|
57
55
|
# the default value of 50 records. If no page_size is defined
|
58
56
|
# but a limit is defined, stream() will attempt to read the
|
59
57
|
# limit with the most efficient page size, i.e. min(limit, 1000)
|
60
|
-
|
61
58
|
# @return [Enumerable] Enumerable that will yield up to limit results
|
62
59
|
def stream(limit: nil, page_size: nil)
|
63
60
|
limits = @version.read_limits(limit, page_size)
|
@@ -97,7 +94,6 @@ module Twilio
|
|
97
94
|
# @param [String] page_token PageToken provided by the API
|
98
95
|
# @param [Integer] page_number Page Number, this value is simply for client state
|
99
96
|
# @param [Integer] page_size Number of records to return, defaults to 50
|
100
|
-
|
101
97
|
# @return [Page] Page of DomainInstance
|
102
98
|
def page(page_token: nil, page_number: nil, page_size: nil)
|
103
99
|
params = {
|
@@ -120,6 +116,8 @@ module Twilio
|
|
120
116
|
# you route your SIP traffic
|
121
117
|
# @param [String] friendly_name A user-specified, human-readable name for the
|
122
118
|
# trigger.
|
119
|
+
# @param [String] auth_type The types of authentication you have mapped to your
|
120
|
+
# domain
|
123
121
|
# @param [String] voice_url The URL Twilio will request when this domain receives
|
124
122
|
# a call
|
125
123
|
# @param [String] voice_method The HTTP method to use with the voice_url
|
@@ -130,12 +128,12 @@ module Twilio
|
|
130
128
|
# @param [String] voice_status_callback_url The URL that Twilio will request to
|
131
129
|
# pass status parameters
|
132
130
|
# @param [String] voice_status_callback_method The voice_status_callback_method
|
133
|
-
|
134
131
|
# @return [DomainInstance] Newly created DomainInstance
|
135
|
-
def create(domain_name: nil, friendly_name: nil, voice_url: nil, voice_method: nil, voice_fallback_url: nil, voice_fallback_method: nil, voice_status_callback_url: nil, voice_status_callback_method: nil)
|
132
|
+
def create(domain_name: nil, friendly_name: nil, auth_type: nil, voice_url: nil, voice_method: nil, voice_fallback_url: nil, voice_fallback_method: nil, voice_status_callback_url: nil, voice_status_callback_method: nil)
|
136
133
|
data = {
|
137
134
|
'DomainName' => domain_name,
|
138
135
|
'FriendlyName' => friendly_name,
|
136
|
+
'AuthType' => auth_type,
|
139
137
|
'VoiceUrl' => voice_url,
|
140
138
|
'VoiceMethod' => voice_method,
|
141
139
|
'VoiceFallbackUrl' => voice_fallback_url,
|
@@ -153,7 +151,7 @@ module Twilio
|
|
153
151
|
return DomainInstance.new(
|
154
152
|
@version,
|
155
153
|
payload,
|
156
|
-
account_sid: @solution[
|
154
|
+
account_sid: @solution[:account_sid],
|
157
155
|
)
|
158
156
|
end
|
159
157
|
|
@@ -172,7 +170,6 @@ module Twilio
|
|
172
170
|
# @param [Hash] solution Path solution for the resource
|
173
171
|
# @param [String] account_sid A 34 character string that uniquely identifies this
|
174
172
|
# resource.
|
175
|
-
|
176
173
|
# @return [DomainPage] DomainPage
|
177
174
|
def initialize(version, response, solution)
|
178
175
|
super(version, response)
|
@@ -184,13 +181,12 @@ module Twilio
|
|
184
181
|
##
|
185
182
|
# Build an instance of DomainInstance
|
186
183
|
# @param [Hash] payload Payload response from the API
|
187
|
-
|
188
184
|
# @return [DomainInstance] DomainInstance
|
189
185
|
def get_instance(payload)
|
190
186
|
return DomainInstance.new(
|
191
187
|
@version,
|
192
188
|
payload,
|
193
|
-
account_sid: @solution[
|
189
|
+
account_sid: @solution[:account_sid],
|
194
190
|
)
|
195
191
|
end
|
196
192
|
|
@@ -207,7 +203,6 @@ module Twilio
|
|
207
203
|
# @param [Version] version Version that contains the resource
|
208
204
|
# @param [String] account_sid The account_sid
|
209
205
|
# @param [String] sid The domain sid that uniquely identifies the resource
|
210
|
-
|
211
206
|
# @return [DomainContext] DomainContext
|
212
207
|
def initialize(version, account_sid, sid)
|
213
208
|
super(version)
|
@@ -239,14 +234,14 @@ module Twilio
|
|
239
234
|
return DomainInstance.new(
|
240
235
|
@version,
|
241
236
|
payload,
|
242
|
-
account_sid: @solution[
|
243
|
-
sid: @solution[
|
237
|
+
account_sid: @solution[:account_sid],
|
238
|
+
sid: @solution[:sid],
|
244
239
|
)
|
245
240
|
end
|
246
241
|
|
247
242
|
##
|
248
243
|
# Update the DomainInstance
|
249
|
-
# @param [String]
|
244
|
+
# @param [String] auth_type The auth_type
|
250
245
|
# @param [String] friendly_name A user-specified, human-readable name for the
|
251
246
|
# trigger.
|
252
247
|
# @param [String] voice_fallback_method The voice_fallback_method
|
@@ -255,11 +250,10 @@ module Twilio
|
|
255
250
|
# @param [String] voice_status_callback_method The voice_status_callback_method
|
256
251
|
# @param [String] voice_status_callback_url The voice_status_callback_url
|
257
252
|
# @param [String] voice_url The voice_url
|
258
|
-
|
259
253
|
# @return [DomainInstance] Updated DomainInstance
|
260
|
-
def update(
|
254
|
+
def update(auth_type: nil, friendly_name: nil, voice_fallback_method: nil, voice_fallback_url: nil, voice_method: nil, voice_status_callback_method: nil, voice_status_callback_url: nil, voice_url: nil)
|
261
255
|
data = {
|
262
|
-
'
|
256
|
+
'AuthType' => auth_type,
|
263
257
|
'FriendlyName' => friendly_name,
|
264
258
|
'VoiceFallbackMethod' => voice_fallback_method,
|
265
259
|
'VoiceFallbackUrl' => voice_fallback_url,
|
@@ -278,8 +272,8 @@ module Twilio
|
|
278
272
|
return DomainInstance.new(
|
279
273
|
@version,
|
280
274
|
payload,
|
281
|
-
account_sid: @solution[
|
282
|
-
sid: @solution[
|
275
|
+
account_sid: @solution[:account_sid],
|
276
|
+
sid: @solution[:sid],
|
283
277
|
)
|
284
278
|
end
|
285
279
|
|
@@ -354,7 +348,6 @@ module Twilio
|
|
354
348
|
# @param [String] account_sid A 34 character string that uniquely identifies this
|
355
349
|
# resource.
|
356
350
|
# @param [String] sid The domain sid that uniquely identifies the resource
|
357
|
-
|
358
351
|
# @return [DomainInstance] DomainInstance
|
359
352
|
def initialize(version, payload, account_sid: nil, sid: nil)
|
360
353
|
super(version)
|
@@ -390,7 +383,6 @@ module Twilio
|
|
390
383
|
# Generate an instance context for the instance, the context is capable of
|
391
384
|
# performing various actions. All instance actions are proxied to the context
|
392
385
|
# @param [Version] version Version that contains the resource
|
393
|
-
|
394
386
|
# @return [DomainContext] DomainContext for this DomainInstance
|
395
387
|
def context
|
396
388
|
unless @instance_context
|
@@ -467,12 +459,12 @@ module Twilio
|
|
467
459
|
# Fetch a DomainInstance
|
468
460
|
# @return [DomainInstance] Fetched DomainInstance
|
469
461
|
def fetch
|
470
|
-
|
462
|
+
context.fetch
|
471
463
|
end
|
472
464
|
|
473
465
|
##
|
474
466
|
# Update the DomainInstance
|
475
|
-
# @param [String]
|
467
|
+
# @param [String] auth_type The auth_type
|
476
468
|
# @param [String] friendly_name A user-specified, human-readable name for the
|
477
469
|
# trigger.
|
478
470
|
# @param [String] voice_fallback_method The voice_fallback_method
|
@@ -481,10 +473,10 @@ module Twilio
|
|
481
473
|
# @param [String] voice_status_callback_method The voice_status_callback_method
|
482
474
|
# @param [String] voice_status_callback_url The voice_status_callback_url
|
483
475
|
# @param [String] voice_url The voice_url
|
484
|
-
|
485
476
|
# @return [DomainInstance] Updated DomainInstance
|
486
|
-
def update(
|
487
|
-
|
477
|
+
def update(auth_type: nil, friendly_name: nil, voice_fallback_method: nil, voice_fallback_url: nil, voice_method: nil, voice_status_callback_method: nil, voice_status_callback_url: nil, voice_url: nil)
|
478
|
+
context.update(
|
479
|
+
auth_type: auth_type,
|
488
480
|
friendly_name: friendly_name,
|
489
481
|
voice_fallback_method: voice_fallback_method,
|
490
482
|
voice_fallback_url: voice_fallback_url,
|
@@ -499,28 +491,28 @@ module Twilio
|
|
499
491
|
# Deletes the DomainInstance
|
500
492
|
# @return [Boolean] true if delete succeeds, true otherwise
|
501
493
|
def delete
|
502
|
-
|
494
|
+
context.delete
|
503
495
|
end
|
504
496
|
|
505
497
|
##
|
506
498
|
# Access the ip_access_control_list_mappings
|
507
499
|
# @return [ip_access_control_list_mappings] ip_access_control_list_mappings
|
508
500
|
def ip_access_control_list_mappings
|
509
|
-
|
501
|
+
context.ip_access_control_list_mappings
|
510
502
|
end
|
511
503
|
|
512
504
|
##
|
513
505
|
# Access the credential_list_mappings
|
514
506
|
# @return [credential_list_mappings] credential_list_mappings
|
515
507
|
def credential_list_mappings
|
516
|
-
|
508
|
+
context.credential_list_mappings
|
517
509
|
end
|
518
510
|
|
519
511
|
##
|
520
512
|
# Provide a user friendly representation
|
521
513
|
def to_s
|
522
|
-
|
523
|
-
"<Twilio.Api.V2010.DomainInstance #{
|
514
|
+
values = @params.map{|k, v| "#{k}: #{v}"}.join(" ")
|
515
|
+
"<Twilio.Api.V2010.DomainInstance #{values}>"
|
524
516
|
end
|
525
517
|
end
|
526
518
|
end
|