twilio-ruby 5.19.0 → 5.20.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGES.md +13 -0
- data/README.md +2 -2
- data/lib/twilio-ruby/rest/api.rb +16 -13
- data/lib/twilio-ruby/rest/api/v2010/account/address.rb +85 -88
- data/lib/twilio-ruby/rest/api/v2010/account/address/dependent_phone_number.rb +4 -4
- data/lib/twilio-ruby/rest/api/v2010/account/application.rb +135 -146
- data/lib/twilio-ruby/rest/api/v2010/account/authorized_connect_app.rb +21 -17
- data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number.rb +14 -8
- data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number/local.rb +150 -166
- data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number/machine_to_machine.rb +174 -79
- data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number/mobile.rb +147 -160
- data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number/national.rb +174 -79
- data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number/shared_cost.rb +174 -79
- data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number/toll_free.rb +147 -160
- data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number/voip.rb +174 -79
- data/lib/twilio-ruby/rest/api/v2010/account/connect_app.rb +51 -51
- data/lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number.rb +246 -251
- data/lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/assigned_add_on.rb +31 -26
- data/lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/assigned_add_on/assigned_add_on_extension.rb +34 -26
- data/lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb +109 -112
- data/lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/mobile.rb +108 -112
- data/lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/toll_free.rb +108 -112
- data/lib/twilio-ruby/rest/api/v2010/account/message/feedback.rb +21 -11
- data/lib/twilio-ruby/rest/api/v2010/account/new_key.rb +7 -6
- data/lib/twilio-ruby/rest/api/v2010/account/new_signing_key.rb +7 -6
- data/lib/twilio-ruby/rest/api/v2010/account/notification.rb +32 -25
- data/lib/twilio-ruby/rest/api/v2010/account/outgoing_caller_id.rb +36 -36
- data/lib/twilio-ruby/rest/api/v2010/account/sip.rb +2 -1
- data/lib/twilio-ruby/rest/api/v2010/account/sip/domain.rb +70 -66
- data/lib/twilio-ruby/rest/api/v2010/account/sip/domain/auth_types.rb +10 -10
- data/lib/twilio-ruby/rest/api/v2010/account/sip/domain/auth_types/auth_calls_mapping.rb +14 -14
- data/lib/twilio-ruby/rest/api/v2010/account/sip/domain/auth_types/auth_calls_mapping/auth_calls_credential_list_mapping.rb +26 -23
- data/lib/twilio-ruby/rest/api/v2010/account/sip/domain/auth_types/auth_calls_mapping/auth_calls_ip_access_control_list_mapping.rb +26 -23
- data/lib/twilio-ruby/rest/api/v2010/account/sip/domain/auth_types/auth_registrations_mapping.rb +12 -12
- data/lib/twilio-ruby/rest/api/v2010/account/sip/domain/auth_types/auth_registrations_mapping/auth_registrations_credential_list_mapping.rb +26 -23
- data/lib/twilio-ruby/rest/api/v2010/account/sip/domain/credential_list_mapping.rb +4 -4
- data/lib/twilio-ruby/rest/api/v2010/account/sip/domain/ip_access_control_list_mapping.rb +4 -4
- data/lib/twilio-ruby/rest/api/v2010/account/token.rb +11 -9
- data/lib/twilio-ruby/rest/api/v2010/account/usage.rb +2 -1
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record.rb +56 -47
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/all_time.rb +59 -44
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/daily.rb +59 -44
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/last_month.rb +59 -47
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/monthly.rb +59 -44
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/this_month.rb +59 -44
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/today.rb +59 -44
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/yearly.rb +59 -44
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/yesterday.rb +59 -44
- data/lib/twilio-ruby/rest/api/v2010/account/usage/trigger.rb +76 -74
- data/lib/twilio-ruby/rest/authy.rb +8 -8
- data/lib/twilio-ruby/rest/authy/v1.rb +15 -15
- data/lib/twilio-ruby/rest/client.rb +16 -13
- data/lib/twilio-ruby/rest/messaging.rb +15 -0
- data/lib/twilio-ruby/rest/messaging/v1.rb +23 -0
- data/lib/twilio-ruby/rest/messaging/v1/session.rb +482 -0
- data/lib/twilio-ruby/rest/messaging/v1/session/message.rb +434 -0
- data/lib/twilio-ruby/rest/messaging/v1/session/participant.rb +458 -0
- data/lib/twilio-ruby/rest/messaging/v1/webhook.rb +285 -0
- data/lib/twilio-ruby/rest/preview.rb +8 -8
- data/lib/twilio-ruby/rest/preview/marketplace.rb +13 -13
- data/lib/twilio-ruby/rest/proxy/v1/service/session.rb +3 -2
- data/lib/twilio-ruby/rest/video.rb +9 -9
- data/lib/twilio-ruby/rest/video/v1.rb +16 -16
- data/lib/twilio-ruby/rest/video/v1/composition.rb +7 -6
- data/lib/twilio-ruby/rest/video/v1/composition_hook.rb +37 -21
- data/lib/twilio-ruby/rest/video/v1/recording.rb +12 -3
- data/lib/twilio-ruby/security/request_validator.rb +2 -2
- data/lib/twilio-ruby/version.rb +1 -1
- data/spec/integration/messaging/v1/session/message_spec.rb +238 -0
- data/spec/integration/messaging/v1/session/participant_spec.rb +256 -0
- data/spec/integration/messaging/v1/session_spec.rb +223 -0
- data/spec/integration/messaging/v1/webhook_spec.rb +92 -0
- data/spec/integration/video/v1/composition_hook_spec.rb +1 -1
- data/spec/security/request_validator_spec.rb +5 -7
- metadata +14 -2
@@ -16,8 +16,11 @@ module Twilio
|
|
16
16
|
##
|
17
17
|
# Initialize the FeedbackList
|
18
18
|
# @param [Version] version Version that contains the resource
|
19
|
-
# @param [String] account_sid The
|
20
|
-
#
|
19
|
+
# @param [String] account_sid The SID of the
|
20
|
+
# [Account](https://www.twilio.com/docs/api/rest/account) that created the
|
21
|
+
# MessageFeedback resource.
|
22
|
+
# @param [String] message_sid The SID of the Message resource for which the
|
23
|
+
# feedback was provided.
|
21
24
|
# @return [FeedbackList] FeedbackList
|
22
25
|
def initialize(version, account_sid: nil, message_sid: nil)
|
23
26
|
super(version)
|
@@ -30,7 +33,11 @@ module Twilio
|
|
30
33
|
##
|
31
34
|
# Retrieve a single page of FeedbackInstance records from the API.
|
32
35
|
# Request is executed immediately.
|
33
|
-
# @param [feedback.Outcome] outcome
|
36
|
+
# @param [feedback.Outcome] outcome Whether the feedback has arrived. Can be:
|
37
|
+
# `unconfirmed` or `confirmed`. If `provide_feedback`=`true` in [the initial HTTP
|
38
|
+
# POST](https://www.twilio.com/docs/sms/api/message#create-a-message-resource),
|
39
|
+
# the initial value of this property is `unconfirmed`. After the message arrives,
|
40
|
+
# update the value to `confirmed`.
|
34
41
|
# @return [FeedbackInstance] Newly created FeedbackInstance
|
35
42
|
def create(outcome: :unset)
|
36
43
|
data = Twilio::Values.of({'Outcome' => outcome, })
|
@@ -95,8 +102,11 @@ module Twilio
|
|
95
102
|
# Initialize the FeedbackInstance
|
96
103
|
# @param [Version] version Version that contains the resource
|
97
104
|
# @param [Hash] payload payload that contains response from Twilio
|
98
|
-
# @param [String] account_sid The
|
99
|
-
#
|
105
|
+
# @param [String] account_sid The SID of the
|
106
|
+
# [Account](https://www.twilio.com/docs/api/rest/account) that created the
|
107
|
+
# MessageFeedback resource.
|
108
|
+
# @param [String] message_sid The SID of the Message resource for which the
|
109
|
+
# feedback was provided.
|
100
110
|
# @return [FeedbackInstance] FeedbackInstance
|
101
111
|
def initialize(version, payload, account_sid: nil, message_sid: nil)
|
102
112
|
super(version)
|
@@ -113,37 +123,37 @@ module Twilio
|
|
113
123
|
end
|
114
124
|
|
115
125
|
##
|
116
|
-
# @return [String] The
|
126
|
+
# @return [String] The SID of the Account that created the resource
|
117
127
|
def account_sid
|
118
128
|
@properties['account_sid']
|
119
129
|
end
|
120
130
|
|
121
131
|
##
|
122
|
-
# @return [String] The
|
132
|
+
# @return [String] The SID of the Message resource for which the feedback was provided
|
123
133
|
def message_sid
|
124
134
|
@properties['message_sid']
|
125
135
|
end
|
126
136
|
|
127
137
|
##
|
128
|
-
# @return [feedback.Outcome]
|
138
|
+
# @return [feedback.Outcome] Whether the feedback has arrived
|
129
139
|
def outcome
|
130
140
|
@properties['outcome']
|
131
141
|
end
|
132
142
|
|
133
143
|
##
|
134
|
-
# @return [Time] The
|
144
|
+
# @return [Time] The RFC 2822 date and time in GMT that the resource was created
|
135
145
|
def date_created
|
136
146
|
@properties['date_created']
|
137
147
|
end
|
138
148
|
|
139
149
|
##
|
140
|
-
# @return [Time] The
|
150
|
+
# @return [Time] The RFC 2822 date and time in GMT that the resource was last updated
|
141
151
|
def date_updated
|
142
152
|
@properties['date_updated']
|
143
153
|
end
|
144
154
|
|
145
155
|
##
|
146
|
-
# @return [String] The
|
156
|
+
# @return [String] The URI of the resource, relative to `https://api.twilio.com`
|
147
157
|
def uri
|
148
158
|
@properties['uri']
|
149
159
|
end
|
@@ -29,7 +29,8 @@ module Twilio
|
|
29
29
|
##
|
30
30
|
# Retrieve a single page of NewKeyInstance records from the API.
|
31
31
|
# Request is executed immediately.
|
32
|
-
# @param [String] friendly_name
|
32
|
+
# @param [String] friendly_name A descriptive string that you create to describe
|
33
|
+
# the resource. It can be up to 64 characters long.
|
33
34
|
# @return [NewKeyInstance] Newly created NewKeyInstance
|
34
35
|
def create(friendly_name: :unset)
|
35
36
|
data = Twilio::Values.of({'FriendlyName' => friendly_name, })
|
@@ -101,31 +102,31 @@ module Twilio
|
|
101
102
|
end
|
102
103
|
|
103
104
|
##
|
104
|
-
# @return [String] The
|
105
|
+
# @return [String] The unique string that identifies the resource
|
105
106
|
def sid
|
106
107
|
@properties['sid']
|
107
108
|
end
|
108
109
|
|
109
110
|
##
|
110
|
-
# @return [String] The
|
111
|
+
# @return [String] The string that you assigned to describe the resource
|
111
112
|
def friendly_name
|
112
113
|
@properties['friendly_name']
|
113
114
|
end
|
114
115
|
|
115
116
|
##
|
116
|
-
# @return [Time] The
|
117
|
+
# @return [Time] The RFC 2822 date and time in GMT that the resource was created
|
117
118
|
def date_created
|
118
119
|
@properties['date_created']
|
119
120
|
end
|
120
121
|
|
121
122
|
##
|
122
|
-
# @return [Time] The
|
123
|
+
# @return [Time] The RFC 2822 date and time in GMT that the resource was last updated
|
123
124
|
def date_updated
|
124
125
|
@properties['date_updated']
|
125
126
|
end
|
126
127
|
|
127
128
|
##
|
128
|
-
# @return [String] The secret
|
129
|
+
# @return [String] The secret your application uses to sign Access Tokens and to authenticate to the REST API.
|
129
130
|
def secret
|
130
131
|
@properties['secret']
|
131
132
|
end
|
@@ -29,7 +29,8 @@ module Twilio
|
|
29
29
|
##
|
30
30
|
# Retrieve a single page of NewSigningKeyInstance records from the API.
|
31
31
|
# Request is executed immediately.
|
32
|
-
# @param [String] friendly_name
|
32
|
+
# @param [String] friendly_name A descriptive string that you create to describe
|
33
|
+
# the resource. It can be up to 64 characters long.
|
33
34
|
# @return [NewSigningKeyInstance] Newly created NewSigningKeyInstance
|
34
35
|
def create(friendly_name: :unset)
|
35
36
|
data = Twilio::Values.of({'FriendlyName' => friendly_name, })
|
@@ -101,31 +102,31 @@ module Twilio
|
|
101
102
|
end
|
102
103
|
|
103
104
|
##
|
104
|
-
# @return [String] The
|
105
|
+
# @return [String] The unique string that identifies the resource
|
105
106
|
def sid
|
106
107
|
@properties['sid']
|
107
108
|
end
|
108
109
|
|
109
110
|
##
|
110
|
-
# @return [String] The
|
111
|
+
# @return [String] The string that you assigned to describe the resource
|
111
112
|
def friendly_name
|
112
113
|
@properties['friendly_name']
|
113
114
|
end
|
114
115
|
|
115
116
|
##
|
116
|
-
# @return [Time] The
|
117
|
+
# @return [Time] The RFC 2822 date and time in GMT that the resource was created
|
117
118
|
def date_created
|
118
119
|
@properties['date_created']
|
119
120
|
end
|
120
121
|
|
121
122
|
##
|
122
|
-
# @return [Time] The
|
123
|
+
# @return [Time] The RFC 2822 date and time in GMT that the resource was last updated
|
123
124
|
def date_updated
|
124
125
|
@properties['date_updated']
|
125
126
|
end
|
126
127
|
|
127
128
|
##
|
128
|
-
# @return [String] The secret
|
129
|
+
# @return [String] The secret your application uses to sign Access Tokens and to authenticate to the REST API.
|
129
130
|
def secret
|
130
131
|
@properties['secret']
|
131
132
|
end
|
@@ -15,9 +15,9 @@ module Twilio
|
|
15
15
|
##
|
16
16
|
# Initialize the NotificationList
|
17
17
|
# @param [Version] version Version that contains the resource
|
18
|
-
# @param [String] account_sid The
|
19
|
-
# [Account](https://www.twilio.com/docs/
|
20
|
-
#
|
18
|
+
# @param [String] account_sid The SID of the
|
19
|
+
# [Account](https://www.twilio.com/docs/api/rest/account) that created the
|
20
|
+
# Notification resource.
|
21
21
|
# @return [NotificationList] NotificationList
|
22
22
|
def initialize(version, account_sid: nil)
|
23
23
|
super(version)
|
@@ -31,8 +31,9 @@ module Twilio
|
|
31
31
|
# Lists NotificationInstance records from the API as a list.
|
32
32
|
# Unlike stream(), this operation is eager and will load `limit` records into
|
33
33
|
# memory before returning.
|
34
|
-
# @param [String] log Only
|
35
|
-
#
|
34
|
+
# @param [String] log Only read notifications of the specified log level. Can be:
|
35
|
+
# `0` to read only ERROR notifications or `1` to read only WARNING notifications.
|
36
|
+
# By default, all notifications are read.
|
36
37
|
# @param [Time] message_date_before Filter by date
|
37
38
|
# @param [Time] message_date Filter by date
|
38
39
|
# @param [Time] message_date_after Filter by date
|
@@ -58,8 +59,9 @@ module Twilio
|
|
58
59
|
# Streams NotificationInstance records from the API as an Enumerable.
|
59
60
|
# This operation lazily loads records as efficiently as possible until the limit
|
60
61
|
# is reached.
|
61
|
-
# @param [String] log Only
|
62
|
-
#
|
62
|
+
# @param [String] log Only read notifications of the specified log level. Can be:
|
63
|
+
# `0` to read only ERROR notifications or `1` to read only WARNING notifications.
|
64
|
+
# By default, all notifications are read.
|
63
65
|
# @param [Time] message_date_before Filter by date
|
64
66
|
# @param [Time] message_date Filter by date
|
65
67
|
# @param [Time] message_date_after Filter by date
|
@@ -101,8 +103,9 @@ module Twilio
|
|
101
103
|
##
|
102
104
|
# Retrieve a single page of NotificationInstance records from the API.
|
103
105
|
# Request is executed immediately.
|
104
|
-
# @param [String] log Only
|
105
|
-
#
|
106
|
+
# @param [String] log Only read notifications of the specified log level. Can be:
|
107
|
+
# `0` to read only ERROR notifications or `1` to read only WARNING notifications.
|
108
|
+
# By default, all notifications are read.
|
106
109
|
# @param [Time] message_date_before Filter by date
|
107
110
|
# @param [Time] message_date Filter by date
|
108
111
|
# @param [Time] message_date_after Filter by date
|
@@ -181,8 +184,11 @@ module Twilio
|
|
181
184
|
##
|
182
185
|
# Initialize the NotificationContext
|
183
186
|
# @param [Version] version Version that contains the resource
|
184
|
-
# @param [String] account_sid The
|
185
|
-
#
|
187
|
+
# @param [String] account_sid The SID of the
|
188
|
+
# [Account](https://www.twilio.com/docs/api/rest/account) that created the
|
189
|
+
# Notification resource to fetch.
|
190
|
+
# @param [String] sid The Twilio-provided string that uniquely identifies the
|
191
|
+
# Notification resource to fetch.
|
186
192
|
# @return [NotificationContext] NotificationContext
|
187
193
|
def initialize(version, account_sid, sid)
|
188
194
|
super(version)
|
@@ -232,10 +238,11 @@ module Twilio
|
|
232
238
|
# Initialize the NotificationInstance
|
233
239
|
# @param [Version] version Version that contains the resource
|
234
240
|
# @param [Hash] payload payload that contains response from Twilio
|
235
|
-
# @param [String] account_sid The
|
236
|
-
# [Account](https://www.twilio.com/docs/
|
237
|
-
#
|
238
|
-
# @param [String] sid The
|
241
|
+
# @param [String] account_sid The SID of the
|
242
|
+
# [Account](https://www.twilio.com/docs/api/rest/account) that created the
|
243
|
+
# Notification resource.
|
244
|
+
# @param [String] sid The Twilio-provided string that uniquely identifies the
|
245
|
+
# Notification resource to fetch.
|
239
246
|
# @return [NotificationInstance] NotificationInstance
|
240
247
|
def initialize(version, payload, account_sid: nil, sid: nil)
|
241
248
|
super(version)
|
@@ -278,31 +285,31 @@ module Twilio
|
|
278
285
|
end
|
279
286
|
|
280
287
|
##
|
281
|
-
# @return [String] The
|
288
|
+
# @return [String] The SID of the Account that created the resource
|
282
289
|
def account_sid
|
283
290
|
@properties['account_sid']
|
284
291
|
end
|
285
292
|
|
286
293
|
##
|
287
|
-
# @return [String] The version
|
294
|
+
# @return [String] The API version used to generate the notification
|
288
295
|
def api_version
|
289
296
|
@properties['api_version']
|
290
297
|
end
|
291
298
|
|
292
299
|
##
|
293
|
-
# @return [String] The
|
300
|
+
# @return [String] The SID of the Call the resource is associated with
|
294
301
|
def call_sid
|
295
302
|
@properties['call_sid']
|
296
303
|
end
|
297
304
|
|
298
305
|
##
|
299
|
-
# @return [Time] The date
|
306
|
+
# @return [Time] The RFC 2822 date and time in GMT that the resource was created
|
300
307
|
def date_created
|
301
308
|
@properties['date_created']
|
302
309
|
end
|
303
310
|
|
304
311
|
##
|
305
|
-
# @return [Time] The date
|
312
|
+
# @return [Time] The RFC 2822 date and time in GMT that the resource was last updated
|
306
313
|
def date_updated
|
307
314
|
@properties['date_updated']
|
308
315
|
end
|
@@ -326,7 +333,7 @@ module Twilio
|
|
326
333
|
end
|
327
334
|
|
328
335
|
##
|
329
|
-
# @return [String] The text of the notification
|
336
|
+
# @return [String] The text of the notification
|
330
337
|
def message_text
|
331
338
|
@properties['message_text']
|
332
339
|
end
|
@@ -356,25 +363,25 @@ module Twilio
|
|
356
363
|
end
|
357
364
|
|
358
365
|
##
|
359
|
-
# @return [String] The HTTP body returned by your server
|
366
|
+
# @return [String] The HTTP body returned by your server
|
360
367
|
def response_body
|
361
368
|
@properties['response_body']
|
362
369
|
end
|
363
370
|
|
364
371
|
##
|
365
|
-
# @return [String] The HTTP headers returned by your server
|
372
|
+
# @return [String] The HTTP headers returned by your server
|
366
373
|
def response_headers
|
367
374
|
@properties['response_headers']
|
368
375
|
end
|
369
376
|
|
370
377
|
##
|
371
|
-
# @return [String]
|
378
|
+
# @return [String] The unique string that identifies the resource
|
372
379
|
def sid
|
373
380
|
@properties['sid']
|
374
381
|
end
|
375
382
|
|
376
383
|
##
|
377
|
-
# @return [String] The URI
|
384
|
+
# @return [String] The URI of the resource, relative to `https://api.twilio.com`
|
378
385
|
def uri
|
379
386
|
@properties['uri']
|
380
387
|
end
|
@@ -15,9 +15,9 @@ module Twilio
|
|
15
15
|
##
|
16
16
|
# Initialize the OutgoingCallerIdList
|
17
17
|
# @param [Version] version Version that contains the resource
|
18
|
-
# @param [String] account_sid The
|
19
|
-
# [Account](https://www.twilio.com/docs/api/rest/account)
|
20
|
-
#
|
18
|
+
# @param [String] account_sid The SID of the
|
19
|
+
# [Account](https://www.twilio.com/docs/api/rest/account) that created the
|
20
|
+
# OutgoingCallerId resource.
|
21
21
|
# @return [OutgoingCallerIdList] OutgoingCallerIdList
|
22
22
|
def initialize(version, account_sid: nil)
|
23
23
|
super(version)
|
@@ -31,10 +31,10 @@ module Twilio
|
|
31
31
|
# Lists OutgoingCallerIdInstance records from the API as a list.
|
32
32
|
# Unlike stream(), this operation is eager and will load `limit` records into
|
33
33
|
# memory before returning.
|
34
|
-
# @param [String] phone_number
|
35
|
-
#
|
36
|
-
# @param [String] friendly_name
|
37
|
-
#
|
34
|
+
# @param [String] phone_number The phone number of the OutgoingCallerId resources
|
35
|
+
# to read.
|
36
|
+
# @param [String] friendly_name The string that identifies the OutgoingCallerId
|
37
|
+
# resources to read.
|
38
38
|
# @param [Integer] limit Upper limit for the number of records to return. stream()
|
39
39
|
# guarantees to never return more than limit. Default is no limit
|
40
40
|
# @param [Integer] page_size Number of records to fetch per request, when
|
@@ -55,10 +55,10 @@ module Twilio
|
|
55
55
|
# Streams OutgoingCallerIdInstance records from the API as an Enumerable.
|
56
56
|
# This operation lazily loads records as efficiently as possible until the limit
|
57
57
|
# is reached.
|
58
|
-
# @param [String] phone_number
|
59
|
-
#
|
60
|
-
# @param [String] friendly_name
|
61
|
-
#
|
58
|
+
# @param [String] phone_number The phone number of the OutgoingCallerId resources
|
59
|
+
# to read.
|
60
|
+
# @param [String] friendly_name The string that identifies the OutgoingCallerId
|
61
|
+
# resources to read.
|
62
62
|
# @param [Integer] limit Upper limit for the number of records to return. stream()
|
63
63
|
# guarantees to never return more than limit. Default is no limit.
|
64
64
|
# @param [Integer] page_size Number of records to fetch per request, when
|
@@ -95,10 +95,10 @@ module Twilio
|
|
95
95
|
##
|
96
96
|
# Retrieve a single page of OutgoingCallerIdInstance records from the API.
|
97
97
|
# Request is executed immediately.
|
98
|
-
# @param [String] phone_number
|
99
|
-
#
|
100
|
-
# @param [String] friendly_name
|
101
|
-
#
|
98
|
+
# @param [String] phone_number The phone number of the OutgoingCallerId resources
|
99
|
+
# to read.
|
100
|
+
# @param [String] friendly_name The string that identifies the OutgoingCallerId
|
101
|
+
# resources to read.
|
102
102
|
# @param [String] page_token PageToken provided by the API
|
103
103
|
# @param [Integer] page_number Page Number, this value is simply for client state
|
104
104
|
# @param [Integer] page_size Number of records to return, defaults to 50
|
@@ -172,9 +172,11 @@ module Twilio
|
|
172
172
|
##
|
173
173
|
# Initialize the OutgoingCallerIdContext
|
174
174
|
# @param [Version] version Version that contains the resource
|
175
|
-
# @param [String] account_sid The
|
176
|
-
#
|
177
|
-
# resource
|
175
|
+
# @param [String] account_sid The SID of the
|
176
|
+
# [Account](https://www.twilio.com/docs/api/rest/account) that created the
|
177
|
+
# OutgoingCallerId resource to fetch.
|
178
|
+
# @param [String] sid The Twilio-provided string that uniquely identifies the
|
179
|
+
# OutgoingCallerId resource to fetch.
|
178
180
|
# @return [OutgoingCallerIdContext] OutgoingCallerIdContext
|
179
181
|
def initialize(version, account_sid, sid)
|
180
182
|
super(version)
|
@@ -206,9 +208,8 @@ module Twilio
|
|
206
208
|
|
207
209
|
##
|
208
210
|
# Update the OutgoingCallerIdInstance
|
209
|
-
# @param [String] friendly_name A
|
210
|
-
#
|
211
|
-
# phone number.
|
211
|
+
# @param [String] friendly_name A descriptive string that you create to describe
|
212
|
+
# the resource. It can be up to 64 characters long.
|
212
213
|
# @return [OutgoingCallerIdInstance] Updated OutgoingCallerIdInstance
|
213
214
|
def update(friendly_name: :unset)
|
214
215
|
data = Twilio::Values.of({'FriendlyName' => friendly_name, })
|
@@ -247,11 +248,11 @@ module Twilio
|
|
247
248
|
# Initialize the OutgoingCallerIdInstance
|
248
249
|
# @param [Version] version Version that contains the resource
|
249
250
|
# @param [Hash] payload payload that contains response from Twilio
|
250
|
-
# @param [String] account_sid The
|
251
|
-
# [Account](https://www.twilio.com/docs/api/rest/account)
|
252
|
-
#
|
253
|
-
# @param [String] sid The
|
254
|
-
# resource
|
251
|
+
# @param [String] account_sid The SID of the
|
252
|
+
# [Account](https://www.twilio.com/docs/api/rest/account) that created the
|
253
|
+
# OutgoingCallerId resource.
|
254
|
+
# @param [String] sid The Twilio-provided string that uniquely identifies the
|
255
|
+
# OutgoingCallerId resource to fetch.
|
255
256
|
# @return [OutgoingCallerIdInstance] OutgoingCallerIdInstance
|
256
257
|
def initialize(version, payload, account_sid: nil, sid: nil)
|
257
258
|
super(version)
|
@@ -284,43 +285,43 @@ module Twilio
|
|
284
285
|
end
|
285
286
|
|
286
287
|
##
|
287
|
-
# @return [String]
|
288
|
+
# @return [String] The unique string that identifies the resource
|
288
289
|
def sid
|
289
290
|
@properties['sid']
|
290
291
|
end
|
291
292
|
|
292
293
|
##
|
293
|
-
# @return [Time] The date
|
294
|
+
# @return [Time] The RFC 2822 date and time in GMT that the resource was created
|
294
295
|
def date_created
|
295
296
|
@properties['date_created']
|
296
297
|
end
|
297
298
|
|
298
299
|
##
|
299
|
-
# @return [Time] The date
|
300
|
+
# @return [Time] The RFC 2822 date and time in GMT that the resource was last updated
|
300
301
|
def date_updated
|
301
302
|
@properties['date_updated']
|
302
303
|
end
|
303
304
|
|
304
305
|
##
|
305
|
-
# @return [String]
|
306
|
+
# @return [String] The string that you assigned to describe the resource
|
306
307
|
def friendly_name
|
307
308
|
@properties['friendly_name']
|
308
309
|
end
|
309
310
|
|
310
311
|
##
|
311
|
-
# @return [String] The
|
312
|
+
# @return [String] The SID of the Account that created the resource
|
312
313
|
def account_sid
|
313
314
|
@properties['account_sid']
|
314
315
|
end
|
315
316
|
|
316
317
|
##
|
317
|
-
# @return [String] The
|
318
|
+
# @return [String] The phone number in E.164 format
|
318
319
|
def phone_number
|
319
320
|
@properties['phone_number']
|
320
321
|
end
|
321
322
|
|
322
323
|
##
|
323
|
-
# @return [String] The URI
|
324
|
+
# @return [String] The URI of the resource, relative to `https://api.twilio.com`
|
324
325
|
def uri
|
325
326
|
@properties['uri']
|
326
327
|
end
|
@@ -334,9 +335,8 @@ module Twilio
|
|
334
335
|
|
335
336
|
##
|
336
337
|
# Update the OutgoingCallerIdInstance
|
337
|
-
# @param [String] friendly_name A
|
338
|
-
#
|
339
|
-
# phone number.
|
338
|
+
# @param [String] friendly_name A descriptive string that you create to describe
|
339
|
+
# the resource. It can be up to 64 characters long.
|
340
340
|
# @return [OutgoingCallerIdInstance] Updated OutgoingCallerIdInstance
|
341
341
|
def update(friendly_name: :unset)
|
342
342
|
context.update(friendly_name: friendly_name, )
|