twilio-ruby 5.10.3 → 5.10.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGES.md +14 -0
- data/README.md +2 -2
- data/lib/twilio-ruby/rest/api.rb +1 -1
- data/lib/twilio-ruby/rest/api/v2010/account/call.rb +109 -107
- data/lib/twilio-ruby/rest/api/v2010/account/call/feedback.rb +2 -2
- data/lib/twilio-ruby/rest/api/v2010/account/call/feedback_summary.rb +2 -2
- data/lib/twilio-ruby/rest/api/v2010/account/conference.rb +8 -4
- data/lib/twilio-ruby/rest/api/v2010/account/conference/participant.rb +8 -4
- data/lib/twilio-ruby/rest/client.rb +10 -1
- data/lib/twilio-ruby/rest/notify/v1/service/notification.rb +2 -2
- data/lib/twilio-ruby/rest/proxy/v1/service.rb +40 -31
- data/lib/twilio-ruby/rest/proxy/v1/service/phone_number.rb +6 -3
- data/lib/twilio-ruby/rest/proxy/v1/service/session.rb +28 -28
- data/lib/twilio-ruby/rest/proxy/v1/service/session/interaction.rb +13 -7
- data/lib/twilio-ruby/rest/proxy/v1/service/session/participant.rb +13 -7
- data/lib/twilio-ruby/rest/proxy/v1/service/session/participant/message_interaction.rb +18 -12
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace.rb +4 -4
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/event.rb +3 -3
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue/task_queue_cumulative_statistics.rb +2 -2
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue/task_queue_statistics.rb +2 -2
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue/task_queues_statistics.rb +6 -6
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker.rb +7 -7
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker/reservation.rb +4 -4
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker/worker_statistics.rb +6 -6
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker/workers_cumulative_statistics.rb +6 -6
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker/workers_statistics.rb +6 -6
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workflow/workflow_cumulative_statistics.rb +2 -2
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workflow/workflow_statistics.rb +2 -2
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workspace_cumulative_statistics.rb +2 -2
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workspace_statistics.rb +2 -2
- data/lib/twilio-ruby/rest/trunking/v1/trunk.rb +19 -4
- data/lib/twilio-ruby/twiml/twiml.rb +32 -13
- data/lib/twilio-ruby/version.rb +1 -1
- data/spec/integration/api/v2010/account/application_spec.rb +5 -11
- data/spec/rest/client_spec.rb +12 -0
- data/spec/twiml/messaging_response_spec.rb +26 -0
- data/spec/twiml/voice_response_spec.rb +25 -0
- metadata +3 -3
@@ -17,7 +17,7 @@ module Twilio
|
|
17
17
|
# Initialize the FeedbackList
|
18
18
|
# @param [Version] version Version that contains the resource
|
19
19
|
# @param [String] account_sid The account_sid
|
20
|
-
# @param [String] call_sid A 34
|
20
|
+
# @param [String] call_sid A 34-character string that uniquely identifies the Call
|
21
21
|
# resource.
|
22
22
|
# @return [FeedbackList] FeedbackList
|
23
23
|
def initialize(version, account_sid: nil, call_sid: nil)
|
@@ -174,7 +174,7 @@ module Twilio
|
|
174
174
|
# @param [Version] version Version that contains the resource
|
175
175
|
# @param [Hash] payload payload that contains response from Twilio
|
176
176
|
# @param [String] account_sid The account_sid
|
177
|
-
# @param [String] call_sid A 34
|
177
|
+
# @param [String] call_sid A 34-character string that uniquely identifies the Call
|
178
178
|
# resource.
|
179
179
|
# @return [FeedbackInstance] FeedbackInstance
|
180
180
|
def initialize(version, payload, account_sid: nil, call_sid: nil)
|
@@ -18,7 +18,7 @@ module Twilio
|
|
18
18
|
# @param [Version] version Version that contains the resource
|
19
19
|
# @param [String] account_sid The unique id of the
|
20
20
|
# [Account](https://www.twilio.com/docs/api/rest/account) responsible for creating
|
21
|
-
# this
|
21
|
+
# this Call.
|
22
22
|
# @return [FeedbackSummaryList] FeedbackSummaryList
|
23
23
|
def initialize(version, account_sid: nil)
|
24
24
|
super(version)
|
@@ -154,7 +154,7 @@ module Twilio
|
|
154
154
|
# @param [Hash] payload payload that contains response from Twilio
|
155
155
|
# @param [String] account_sid The unique id of the
|
156
156
|
# [Account](https://www.twilio.com/docs/api/rest/account) responsible for creating
|
157
|
-
# this
|
157
|
+
# this Call.
|
158
158
|
# @param [String] sid The sid
|
159
159
|
# @return [FeedbackSummaryInstance] FeedbackSummaryInstance
|
160
160
|
def initialize(version, payload, account_sid: nil, sid: nil)
|
@@ -246,8 +246,10 @@ module Twilio
|
|
246
246
|
# Update the ConferenceInstance
|
247
247
|
# @param [conference.UpdateStatus] status Specifying `completed` will end the
|
248
248
|
# conference and kick all participants
|
249
|
-
# @param [String] announce_url The
|
250
|
-
#
|
249
|
+
# @param [String] announce_url The 'AnnounceUrl' attribute lets you specify a URL
|
250
|
+
# for announcing something into a conference. The URL may return an MP3, a WAV or
|
251
|
+
# a TwiML document with `<Play>` or `<Say>`.
|
252
|
+
# @param [String] announce_method Specify GET or POST, defaults to POST
|
251
253
|
# @return [ConferenceInstance] Updated ConferenceInstance
|
252
254
|
def update(status: :unset, announce_url: :unset, announce_method: :unset)
|
253
255
|
data = Twilio::Values.of({
|
@@ -414,8 +416,10 @@ module Twilio
|
|
414
416
|
# Update the ConferenceInstance
|
415
417
|
# @param [conference.UpdateStatus] status Specifying `completed` will end the
|
416
418
|
# conference and kick all participants
|
417
|
-
# @param [String] announce_url The
|
418
|
-
#
|
419
|
+
# @param [String] announce_url The 'AnnounceUrl' attribute lets you specify a URL
|
420
|
+
# for announcing something into a conference. The URL may return an MP3, a WAV or
|
421
|
+
# a TwiML document with `<Play>` or `<Say>`.
|
422
|
+
# @param [String] announce_method Specify GET or POST, defaults to POST
|
419
423
|
# @return [ConferenceInstance] Updated ConferenceInstance
|
420
424
|
def update(status: :unset, announce_url: :unset, announce_method: :unset)
|
421
425
|
context.update(status: status, announce_url: announce_url, announce_method: announce_method, )
|
@@ -301,8 +301,10 @@ module Twilio
|
|
301
301
|
# music that plays when a participant is held. The URL may be an MP3, a WAV or a
|
302
302
|
# TwiML document that uses `<Play>`, `<Say>` or `<Redirect>`.
|
303
303
|
# @param [String] hold_method Specify GET or POST, defaults to GET
|
304
|
-
# @param [String] announce_url The
|
305
|
-
#
|
304
|
+
# @param [String] announce_url The 'AnnounceUrl' attribute lets you specify a URL
|
305
|
+
# for announcing something to the participant. The URL may return an MP3, a WAV or
|
306
|
+
# a TwiML document with `<Play>` or `<Say>`.
|
307
|
+
# @param [String] announce_method Specify GET or POST, defaults to POST
|
306
308
|
# @return [ParticipantInstance] Updated ParticipantInstance
|
307
309
|
def update(muted: :unset, hold: :unset, hold_url: :unset, hold_method: :unset, announce_url: :unset, announce_method: :unset)
|
308
310
|
data = Twilio::Values.of({
|
@@ -483,8 +485,10 @@ module Twilio
|
|
483
485
|
# music that plays when a participant is held. The URL may be an MP3, a WAV or a
|
484
486
|
# TwiML document that uses `<Play>`, `<Say>` or `<Redirect>`.
|
485
487
|
# @param [String] hold_method Specify GET or POST, defaults to GET
|
486
|
-
# @param [String] announce_url The
|
487
|
-
#
|
488
|
+
# @param [String] announce_url The 'AnnounceUrl' attribute lets you specify a URL
|
489
|
+
# for announcing something to the participant. The URL may return an MP3, a WAV or
|
490
|
+
# a TwiML document with `<Play>` or `<Say>`.
|
491
|
+
# @param [String] announce_method Specify GET or POST, defaults to POST
|
488
492
|
# @return [ParticipantInstance] Updated ParticipantInstance
|
489
493
|
def update(muted: :unset, hold: :unset, hold_url: :unset, hold_method: :unset, announce_url: :unset, announce_method: :unset)
|
490
494
|
context.update(
|
@@ -84,6 +84,15 @@ module Twilio
|
|
84
84
|
)
|
85
85
|
end
|
86
86
|
|
87
|
+
##
|
88
|
+
# Validate the new SSL certificate for the Twilio API
|
89
|
+
def validate_ssl_certificate
|
90
|
+
response = request('api.twilio.com', '8443', 'GET', 'https://api.twilio.com:8443/.json')
|
91
|
+
if response.status_code < 200 || response.status_code >= 300
|
92
|
+
raise RestError.new 'Unexpected response from certificate endpoint', response
|
93
|
+
end
|
94
|
+
end
|
95
|
+
|
87
96
|
##
|
88
97
|
# Access the Accounts Twilio Domain
|
89
98
|
def accounts
|
@@ -227,7 +236,7 @@ module Twilio
|
|
227
236
|
end
|
228
237
|
|
229
238
|
##
|
230
|
-
# @param [String] sid A 34
|
239
|
+
# @param [String] sid A 34-character string that uniquely identifies the Call
|
231
240
|
# resource.
|
232
241
|
# @return [Twilio::REST::Api::V2010::AccountContext::CallInstance] if sid was passed.
|
233
242
|
# @return [Twilio::REST::Api::V2010::AccountContext::CallList]
|
@@ -66,7 +66,7 @@ module Twilio
|
|
66
66
|
# APNS. This parameter is not supported by SMS and Facebook Messenger and is
|
67
67
|
# omitted from deliveries via those channels.
|
68
68
|
# @param [Hash] data This parameter specifies the custom key-value pairs of the
|
69
|
-
# notification
|
69
|
+
# notification's payload. Translates to `data` dictionary in FCM and GCM payload.
|
70
70
|
# FCM and GCM [reserves certain
|
71
71
|
# keys](https://firebase.google.com/docs/cloud-messaging/http-server-ref) that
|
72
72
|
# cannot be used for those channels. For APNS, attributes of `Data` will be
|
@@ -307,7 +307,7 @@ module Twilio
|
|
307
307
|
end
|
308
308
|
|
309
309
|
##
|
310
|
-
# @return [Hash] This parameter specifies the custom key-value pairs of the notification
|
310
|
+
# @return [Hash] This parameter specifies the custom key-value pairs of the notification's payload.
|
311
311
|
def data
|
312
312
|
@properties['data']
|
313
313
|
end
|
@@ -112,19 +112,22 @@ module Twilio
|
|
112
112
|
# Request is executed immediately.
|
113
113
|
# @param [String] unique_name The human-readable string that uniquely identifies
|
114
114
|
# this Service, up to 64 characters.
|
115
|
-
# @param [String] default_ttl The default time delay
|
116
|
-
#
|
115
|
+
# @param [String] default_ttl The default time delay in seconds after the latest
|
116
|
+
# of Session create time or the Session's last Interaction time, after which a
|
117
|
+
# session will expire. Used for sessions where ttl is not specified.
|
117
118
|
# @param [String] callback_url The URL to which Twilio will make callbacks on
|
118
119
|
# interaction status changes.
|
119
|
-
# @param [service.GeoMatchLevel] geo_match_level
|
120
|
-
#
|
121
|
-
#
|
122
|
-
#
|
123
|
-
#
|
120
|
+
# @param [service.GeoMatchLevel] geo_match_level Whether proxy number selected
|
121
|
+
# must be in the same area code as the participant identifier. Options: `country`,
|
122
|
+
# `area-code`, `extended-area-code`. Default: `country`. Levels lower than country
|
123
|
+
# are only available in North America.
|
124
|
+
# @param [service.NumberSelectionBehavior] number_selection_behavior Options:
|
125
|
+
# `prefer-sticky`, `avoid-sticky`. Default: `prefer-sticky`.
|
124
126
|
# @param [String] intercept_callback_url A URL for Twilio call before each
|
125
|
-
# Interaction.
|
127
|
+
# Interaction. Returning a 403 status code will prevent the interaction from
|
128
|
+
# continuing.
|
126
129
|
# @param [String] out_of_session_callback_url A URL for Twilio call when a new
|
127
|
-
# Interaction has no Session.
|
130
|
+
# Interaction has no [Session](https://www.twilio.com/docs/proxy/api/session).
|
128
131
|
# @return [ServiceInstance] Newly created ServiceInstance
|
129
132
|
def create(unique_name: nil, default_ttl: :unset, callback_url: :unset, geo_match_level: :unset, number_selection_behavior: :unset, intercept_callback_url: :unset, out_of_session_callback_url: :unset)
|
130
133
|
data = Twilio::Values.of({
|
@@ -231,19 +234,22 @@ module Twilio
|
|
231
234
|
# Update the ServiceInstance
|
232
235
|
# @param [String] unique_name A human readable description of this resource, up to
|
233
236
|
# 64 characters.
|
234
|
-
# @param [String] default_ttl The default time delay
|
235
|
-
#
|
237
|
+
# @param [String] default_ttl The default time delay in seconds after the latest
|
238
|
+
# of Session create time or the Session's last Interaction time, after which a
|
239
|
+
# session will expire. Used for sessions where ttl is not specified.
|
236
240
|
# @param [String] callback_url The URL to which Twilio will make callbacks on
|
237
241
|
# interaction status changes.
|
238
|
-
# @param [service.GeoMatchLevel] geo_match_level
|
239
|
-
#
|
240
|
-
#
|
241
|
-
#
|
242
|
-
# @param [
|
243
|
-
#
|
244
|
-
#
|
242
|
+
# @param [service.GeoMatchLevel] geo_match_level Whether proxy number selected
|
243
|
+
# must be in the same area code as the participant identifier. Options: `country`,
|
244
|
+
# `area-code`, `extended-area-code`. Default: `country`. Levels lower than country
|
245
|
+
# are only available in North America.
|
246
|
+
# @param [service.NumberSelectionBehavior] number_selection_behavior Options:
|
247
|
+
# `prefer-sticky`, `avoid-sticky`. Default: `prefer-sticky`.
|
248
|
+
# @param [String] intercept_callback_url A URL for Twilio call before each
|
249
|
+
# Interaction. Returning a 403 status code will prevent the interaction from
|
250
|
+
# continuing.
|
245
251
|
# @param [String] out_of_session_callback_url A URL for Twilio call when a new
|
246
|
-
# Interaction has no Session.
|
252
|
+
# Interaction has no [Session](https://www.twilio.com/docs/proxy/api/session).
|
247
253
|
# @return [ServiceInstance] Updated ServiceInstance
|
248
254
|
def update(unique_name: :unset, default_ttl: :unset, callback_url: :unset, geo_match_level: :unset, number_selection_behavior: :unset, intercept_callback_url: :unset, out_of_session_callback_url: :unset)
|
249
255
|
data = Twilio::Values.of({
|
@@ -409,7 +415,7 @@ module Twilio
|
|
409
415
|
end
|
410
416
|
|
411
417
|
##
|
412
|
-
# @return [service.GeoMatchLevel] Whether
|
418
|
+
# @return [service.GeoMatchLevel] Whether proxy number selected must be in the same area code as the participant identifier.
|
413
419
|
def geo_match_level
|
414
420
|
@properties['geo_match_level']
|
415
421
|
end
|
@@ -433,7 +439,7 @@ module Twilio
|
|
433
439
|
end
|
434
440
|
|
435
441
|
##
|
436
|
-
# @return [Time] The date this Service was updated
|
442
|
+
# @return [Time] The date this Service was last updated
|
437
443
|
def date_updated
|
438
444
|
@properties['date_updated']
|
439
445
|
end
|
@@ -468,19 +474,22 @@ module Twilio
|
|
468
474
|
# Update the ServiceInstance
|
469
475
|
# @param [String] unique_name A human readable description of this resource, up to
|
470
476
|
# 64 characters.
|
471
|
-
# @param [String] default_ttl The default time delay
|
472
|
-
#
|
477
|
+
# @param [String] default_ttl The default time delay in seconds after the latest
|
478
|
+
# of Session create time or the Session's last Interaction time, after which a
|
479
|
+
# session will expire. Used for sessions where ttl is not specified.
|
473
480
|
# @param [String] callback_url The URL to which Twilio will make callbacks on
|
474
481
|
# interaction status changes.
|
475
|
-
# @param [service.GeoMatchLevel] geo_match_level
|
476
|
-
#
|
477
|
-
#
|
478
|
-
#
|
479
|
-
# @param [
|
480
|
-
#
|
481
|
-
#
|
482
|
+
# @param [service.GeoMatchLevel] geo_match_level Whether proxy number selected
|
483
|
+
# must be in the same area code as the participant identifier. Options: `country`,
|
484
|
+
# `area-code`, `extended-area-code`. Default: `country`. Levels lower than country
|
485
|
+
# are only available in North America.
|
486
|
+
# @param [service.NumberSelectionBehavior] number_selection_behavior Options:
|
487
|
+
# `prefer-sticky`, `avoid-sticky`. Default: `prefer-sticky`.
|
488
|
+
# @param [String] intercept_callback_url A URL for Twilio call before each
|
489
|
+
# Interaction. Returning a 403 status code will prevent the interaction from
|
490
|
+
# continuing.
|
482
491
|
# @param [String] out_of_session_callback_url A URL for Twilio call when a new
|
483
|
-
# Interaction has no Session.
|
492
|
+
# Interaction has no [Session](https://www.twilio.com/docs/proxy/api/session).
|
484
493
|
# @return [ServiceInstance] Updated ServiceInstance
|
485
494
|
def update(unique_name: :unset, default_ttl: :unset, callback_url: :unset, geo_match_level: :unset, number_selection_behavior: :unset, intercept_callback_url: :unset, out_of_session_callback_url: :unset)
|
486
495
|
context.update(
|
@@ -17,7 +17,8 @@ module Twilio
|
|
17
17
|
##
|
18
18
|
# Initialize the PhoneNumberList
|
19
19
|
# @param [Version] version Version that contains the resource
|
20
|
-
# @param [String] service_sid The unique SID identifier of the
|
20
|
+
# @param [String] service_sid The unique SID identifier of the parent
|
21
|
+
# [Service](https://www.twilio.com/docs/proxy/api/service).
|
21
22
|
# @return [PhoneNumberList] PhoneNumberList
|
22
23
|
def initialize(version, service_sid: nil)
|
23
24
|
super(version)
|
@@ -172,7 +173,8 @@ module Twilio
|
|
172
173
|
##
|
173
174
|
# Initialize the PhoneNumberContext
|
174
175
|
# @param [Version] version Version that contains the resource
|
175
|
-
# @param [String] service_sid The unique SID identifier of the
|
176
|
+
# @param [String] service_sid The unique SID identifier of the parent
|
177
|
+
# [Service](https://www.twilio.com/docs/proxy/api/service).
|
176
178
|
# @param [String] sid A 34 character string that uniquely identifies this Phone
|
177
179
|
# Number.
|
178
180
|
# @return [PhoneNumberContext] PhoneNumberContext
|
@@ -226,7 +228,8 @@ module Twilio
|
|
226
228
|
# Initialize the PhoneNumberInstance
|
227
229
|
# @param [Version] version Version that contains the resource
|
228
230
|
# @param [Hash] payload payload that contains response from Twilio
|
229
|
-
# @param [String] service_sid The unique SID identifier of the
|
231
|
+
# @param [String] service_sid The unique SID identifier of the parent
|
232
|
+
# [Service](https://www.twilio.com/docs/proxy/api/service).
|
230
233
|
# @param [String] sid A 34 character string that uniquely identifies this Phone
|
231
234
|
# Number.
|
232
235
|
# @return [PhoneNumberInstance] PhoneNumberInstance
|
@@ -123,19 +123,18 @@ module Twilio
|
|
123
123
|
##
|
124
124
|
# Retrieve a single page of SessionInstance records from the API.
|
125
125
|
# Request is executed immediately.
|
126
|
-
# @param [String] unique_name Your identifier for this Session such as a
|
127
|
-
# conversation ID.
|
128
|
-
# @param [Time] date_expiry An absolute time at which this Session
|
129
|
-
# If this is populated, it takes precedence over TTL values.
|
130
|
-
# @param [String] ttl The
|
131
|
-
#
|
132
|
-
# the last interaction or session creation time.
|
126
|
+
# @param [String] unique_name Your unique identifier for this Session such as a
|
127
|
+
# Job ID or conversation ID. Should not contain PII.
|
128
|
+
# @param [Time] date_expiry An absolute time (ISO 8601) at which this Session
|
129
|
+
# should close. If this is populated, it takes precedence over TTL values.
|
130
|
+
# @param [String] ttl The time, in seconds, after the latest of Session create
|
131
|
+
# time or the Session's last Interaction time at which the session will expire.
|
133
132
|
# @param [session.Mode] mode The type of communications mediums allowed on a
|
134
|
-
# Session. Defaults to voice-and-message
|
135
|
-
# message-only
|
136
|
-
# @param [session.Status] status Set this value to
|
133
|
+
# Session. Defaults to `voice-and-message`. Other options are `voice-only` or
|
134
|
+
# `message-only`.
|
135
|
+
# @param [session.Status] status Set this value to `closed` to close the session.
|
137
136
|
# A Session can be re-opened by posting to a closed session with the value
|
138
|
-
#
|
137
|
+
# `in-progress`. This will be `open` by default on create.
|
139
138
|
# @param [Hash] participants The participants
|
140
139
|
# @return [SessionInstance] Newly created SessionInstance
|
141
140
|
def create(unique_name: :unset, date_expiry: :unset, ttl: :unset, mode: :unset, status: :unset, participants: :unset)
|
@@ -201,7 +200,8 @@ module Twilio
|
|
201
200
|
##
|
202
201
|
# Initialize the SessionContext
|
203
202
|
# @param [Version] version Version that contains the resource
|
204
|
-
# @param [String] service_sid The unique SID identifier of the
|
203
|
+
# @param [String] service_sid The unique SID identifier of the parent
|
204
|
+
# [Service](https://www.twilio.com/docs/proxy/api/service).
|
205
205
|
# @param [String] sid A 34 character string that uniquely identifies this Session.
|
206
206
|
# @return [SessionContext] SessionContext
|
207
207
|
def initialize(version, service_sid, sid)
|
@@ -241,13 +241,13 @@ module Twilio
|
|
241
241
|
##
|
242
242
|
# Update the SessionInstance
|
243
243
|
# @param [String] unique_name The unique_name
|
244
|
-
# @param [Time] date_expiry The date that this Session should
|
245
|
-
#
|
246
|
-
# @param [String] ttl The time
|
247
|
-
#
|
244
|
+
# @param [Time] date_expiry The date that this Session should expire, given in ISO
|
245
|
+
# 8601 format.
|
246
|
+
# @param [String] ttl The time, in seconds, after the latest of Session create
|
247
|
+
# time or the Session's last Interaction time at which the session will expire.
|
248
248
|
# @param [session.Mode] mode The mode
|
249
|
-
# @param [session.Status] status The Status of this Session. Set `in-progress`
|
250
|
-
# re-open a session
|
249
|
+
# @param [session.Status] status The Status of this Session. Set to `in-progress`
|
250
|
+
# to re-open a session or `closed` to close a session.
|
251
251
|
# @param [Hash] participants The participants
|
252
252
|
# @return [SessionInstance] Updated SessionInstance
|
253
253
|
def update(unique_name: :unset, date_expiry: :unset, ttl: :unset, mode: :unset, status: :unset, participants: :unset)
|
@@ -401,19 +401,19 @@ module Twilio
|
|
401
401
|
end
|
402
402
|
|
403
403
|
##
|
404
|
-
# @return [Time] The date this Session
|
404
|
+
# @return [Time] The date this Session last had an interaction
|
405
405
|
def date_last_interaction
|
406
406
|
@properties['date_last_interaction']
|
407
407
|
end
|
408
408
|
|
409
409
|
##
|
410
|
-
# @return [Time] The date this Session
|
410
|
+
# @return [Time] The date this Session should expire
|
411
411
|
def date_expiry
|
412
412
|
@properties['date_expiry']
|
413
413
|
end
|
414
414
|
|
415
415
|
##
|
416
|
-
# @return [String] A unique, developer assigned
|
416
|
+
# @return [String] A unique, developer assigned identifier for this Session.
|
417
417
|
def unique_name
|
418
418
|
@properties['unique_name']
|
419
419
|
end
|
@@ -449,7 +449,7 @@ module Twilio
|
|
449
449
|
end
|
450
450
|
|
451
451
|
##
|
452
|
-
# @return [Time] The date this Session was updated
|
452
|
+
# @return [Time] The date this Session was last updated
|
453
453
|
def date_updated
|
454
454
|
@properties['date_updated']
|
455
455
|
end
|
@@ -483,13 +483,13 @@ module Twilio
|
|
483
483
|
##
|
484
484
|
# Update the SessionInstance
|
485
485
|
# @param [String] unique_name The unique_name
|
486
|
-
# @param [Time] date_expiry The date that this Session should
|
487
|
-
#
|
488
|
-
# @param [String] ttl The time
|
489
|
-
#
|
486
|
+
# @param [Time] date_expiry The date that this Session should expire, given in ISO
|
487
|
+
# 8601 format.
|
488
|
+
# @param [String] ttl The time, in seconds, after the latest of Session create
|
489
|
+
# time or the Session's last Interaction time at which the session will expire.
|
490
490
|
# @param [session.Mode] mode The mode
|
491
|
-
# @param [session.Status] status The Status of this Session. Set `in-progress`
|
492
|
-
# re-open a session
|
491
|
+
# @param [session.Status] status The Status of this Session. Set to `in-progress`
|
492
|
+
# to re-open a session or `closed` to close a session.
|
493
493
|
# @param [Hash] participants The participants
|
494
494
|
# @return [SessionInstance] Updated SessionInstance
|
495
495
|
def update(unique_name: :unset, date_expiry: :unset, ttl: :unset, mode: :unset, status: :unset, participants: :unset)
|
@@ -18,8 +18,10 @@ module Twilio
|
|
18
18
|
##
|
19
19
|
# Initialize the InteractionList
|
20
20
|
# @param [Version] version Version that contains the resource
|
21
|
-
# @param [String] service_sid The unique SID identifier of the
|
22
|
-
#
|
21
|
+
# @param [String] service_sid The unique SID identifier of the parent
|
22
|
+
# [Service](https://www.twilio.com/docs/proxy/api/service).
|
23
|
+
# @param [String] session_sid The unique SID identifier of the parent
|
24
|
+
# [Session](https://www.twilio.com/docs/proxy/api/session).
|
23
25
|
# @return [InteractionList] InteractionList
|
24
26
|
def initialize(version, service_sid: nil, session_sid: nil)
|
25
27
|
super(version)
|
@@ -183,8 +185,10 @@ module Twilio
|
|
183
185
|
##
|
184
186
|
# Initialize the InteractionContext
|
185
187
|
# @param [Version] version Version that contains the resource
|
186
|
-
# @param [String] service_sid The unique SID identifier of the
|
187
|
-
#
|
188
|
+
# @param [String] service_sid The unique SID identifier of the parent
|
189
|
+
# [Service](https://www.twilio.com/docs/proxy/api/service).
|
190
|
+
# @param [String] session_sid The unique SID identifier of the parent
|
191
|
+
# [Session](https://www.twilio.com/docs/proxy/api/session).
|
188
192
|
# @param [String] sid A 34 character string that uniquely identifies this
|
189
193
|
# Interaction.
|
190
194
|
# @return [InteractionContext] InteractionContext
|
@@ -239,8 +243,10 @@ module Twilio
|
|
239
243
|
# Initialize the InteractionInstance
|
240
244
|
# @param [Version] version Version that contains the resource
|
241
245
|
# @param [Hash] payload payload that contains response from Twilio
|
242
|
-
# @param [String] service_sid The unique SID identifier of the
|
243
|
-
#
|
246
|
+
# @param [String] service_sid The unique SID identifier of the parent
|
247
|
+
# [Service](https://www.twilio.com/docs/proxy/api/service).
|
248
|
+
# @param [String] session_sid The unique SID identifier of the parent
|
249
|
+
# [Session](https://www.twilio.com/docs/proxy/api/session).
|
244
250
|
# @param [String] sid A 34 character string that uniquely identifies this
|
245
251
|
# Interaction.
|
246
252
|
# @return [InteractionInstance] InteractionInstance
|
@@ -398,7 +404,7 @@ module Twilio
|
|
398
404
|
end
|
399
405
|
|
400
406
|
##
|
401
|
-
# @return [Time] The date this Interaction was updated
|
407
|
+
# @return [Time] The date this Interaction was last updated
|
402
408
|
def date_updated
|
403
409
|
@properties['date_updated']
|
404
410
|
end
|
@@ -18,8 +18,10 @@ module Twilio
|
|
18
18
|
##
|
19
19
|
# Initialize the ParticipantList
|
20
20
|
# @param [Version] version Version that contains the resource
|
21
|
-
# @param [String] service_sid The unique SID identifier of the
|
22
|
-
#
|
21
|
+
# @param [String] service_sid The unique SID identifier of the parent
|
22
|
+
# [Service](https://www.twilio.com/docs/proxy/api/service).
|
23
|
+
# @param [String] session_sid The unique SID identifier of the parent
|
24
|
+
# [Session](https://www.twilio.com/docs/proxy/api/session).
|
23
25
|
# @return [ParticipantList] ParticipantList
|
24
26
|
def initialize(version, service_sid: nil, session_sid: nil)
|
25
27
|
super(version)
|
@@ -196,8 +198,10 @@ module Twilio
|
|
196
198
|
##
|
197
199
|
# Initialize the ParticipantContext
|
198
200
|
# @param [Version] version Version that contains the resource
|
199
|
-
# @param [String] service_sid The unique SID identifier of the
|
200
|
-
#
|
201
|
+
# @param [String] service_sid The unique SID identifier of the parent
|
202
|
+
# [Service](https://www.twilio.com/docs/proxy/api/service).
|
203
|
+
# @param [String] session_sid The unique SID identifier of the parent
|
204
|
+
# [Session](https://www.twilio.com/docs/proxy/api/session).
|
201
205
|
# @param [String] sid A 34 character string that uniquely identifies this
|
202
206
|
# Participant.
|
203
207
|
# @return [ParticipantContext] ParticipantContext
|
@@ -314,8 +318,10 @@ module Twilio
|
|
314
318
|
# Initialize the ParticipantInstance
|
315
319
|
# @param [Version] version Version that contains the resource
|
316
320
|
# @param [Hash] payload payload that contains response from Twilio
|
317
|
-
# @param [String] service_sid The unique SID identifier of the
|
318
|
-
#
|
321
|
+
# @param [String] service_sid The unique SID identifier of the parent
|
322
|
+
# [Service](https://www.twilio.com/docs/proxy/api/service).
|
323
|
+
# @param [String] session_sid The unique SID identifier of the parent
|
324
|
+
# [Session](https://www.twilio.com/docs/proxy/api/session).
|
319
325
|
# @param [String] sid A 34 character string that uniquely identifies this
|
320
326
|
# Participant.
|
321
327
|
# @return [ParticipantInstance] ParticipantInstance
|
@@ -425,7 +431,7 @@ module Twilio
|
|
425
431
|
end
|
426
432
|
|
427
433
|
##
|
428
|
-
# @return [Time] The date this Participant was updated
|
434
|
+
# @return [Time] The date this Participant was last updated
|
429
435
|
def date_updated
|
430
436
|
@properties['date_updated']
|
431
437
|
end
|