twilio-ruby 5.72.1 → 5.73.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGES.md +45 -0
- data/README.md +2 -2
- data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number/local.rb +2 -2
- data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number/machine_to_machine.rb +2 -2
- data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number/mobile.rb +2 -2
- data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number/national.rb +2 -2
- data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number/shared_cost.rb +2 -2
- data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number/toll_free.rb +2 -2
- data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number/voip.rb +2 -2
- data/lib/twilio-ruby/rest/api/v2010/account/call/feedback.rb +1 -1
- data/lib/twilio-ruby/rest/api/v2010/account/call/feedback_summary.rb +5 -5
- data/lib/twilio-ruby/rest/api/v2010/account/call/recording.rb +2 -2
- data/lib/twilio-ruby/rest/api/v2010/account/call/user_defined_message.rb +160 -0
- data/lib/twilio-ruby/rest/api/v2010/account/call/user_defined_message_subscription.rb +251 -0
- data/lib/twilio-ruby/rest/api/v2010/account/call.rb +59 -0
- data/lib/twilio-ruby/rest/api/v2010/account/conference/participant.rb +22 -16
- data/lib/twilio-ruby/rest/api/v2010/account/conference/recording.rb +1 -1
- data/lib/twilio-ruby/rest/api/v2010/account/conference.rb +4 -4
- data/lib/twilio-ruby/rest/api/v2010/account/message.rb +17 -1
- data/lib/twilio-ruby/rest/api/v2010/account/queue/member.rb +2 -2
- data/lib/twilio-ruby/rest/api/v2010/account/queue.rb +3 -3
- data/lib/twilio-ruby/rest/api/v2010/account/recording/transcription.rb +1 -1
- data/lib/twilio-ruby/rest/api/v2010/account/recording.rb +1 -1
- data/lib/twilio-ruby/rest/api/v2010/account/sip/ip_access_control_list/ip_address.rb +1 -1
- data/lib/twilio-ruby/rest/api/v2010/account/transcription.rb +1 -1
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/all_time.rb +1 -1
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/daily.rb +1 -1
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/last_month.rb +1 -1
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/monthly.rb +1 -1
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/this_month.rb +1 -1
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/today.rb +1 -1
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/yearly.rb +1 -1
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record/yesterday.rb +1 -1
- data/lib/twilio-ruby/rest/api/v2010/account/usage/record.rb +1 -1
- data/lib/twilio-ruby/rest/autopilot/v1/assistant/task/task_statistics.rb +2 -2
- data/lib/twilio-ruby/rest/bulkexports/v1/export/day.rb +1 -1
- data/lib/twilio-ruby/rest/chat/v1/service/channel/message.rb +1 -1
- data/lib/twilio-ruby/rest/chat/v1/service/channel.rb +2 -2
- data/lib/twilio-ruby/rest/chat/v1/service/user.rb +1 -1
- data/lib/twilio-ruby/rest/chat/v1/service.rb +2 -2
- data/lib/twilio-ruby/rest/chat/v2/service/channel/message.rb +1 -1
- data/lib/twilio-ruby/rest/chat/v2/service/channel.rb +2 -2
- data/lib/twilio-ruby/rest/chat/v2/service/user.rb +1 -1
- data/lib/twilio-ruby/rest/chat/v2/service.rb +4 -4
- data/lib/twilio-ruby/rest/chat/v3/channel.rb +2 -2
- data/lib/twilio-ruby/rest/client.rb +7 -0
- data/lib/twilio-ruby/rest/conversations/v1/conversation/message/delivery_receipt.rb +1 -1
- data/lib/twilio-ruby/rest/conversations/v1/conversation/message.rb +1 -1
- data/lib/twilio-ruby/rest/conversations/v1/service/conversation/message/delivery_receipt.rb +1 -1
- data/lib/twilio-ruby/rest/conversations/v1/service/conversation/message.rb +1 -1
- data/lib/twilio-ruby/rest/events/v1/schema/version.rb +1 -1
- data/lib/twilio-ruby/rest/events/v1/schema.rb +1 -1
- data/lib/twilio-ruby/rest/events/v1/subscription/subscribed_event.rb +1 -1
- data/lib/twilio-ruby/rest/insights/v1/room/participant.rb +1 -1
- data/lib/twilio-ruby/rest/insights/v1/room.rb +3 -3
- data/lib/twilio-ruby/rest/ip_messaging/v1/service/channel/message.rb +1 -1
- data/lib/twilio-ruby/rest/ip_messaging/v1/service/channel.rb +2 -2
- data/lib/twilio-ruby/rest/ip_messaging/v1/service/user.rb +1 -1
- data/lib/twilio-ruby/rest/ip_messaging/v1/service.rb +2 -2
- data/lib/twilio-ruby/rest/ip_messaging/v2/service/channel/message.rb +1 -1
- data/lib/twilio-ruby/rest/ip_messaging/v2/service/channel.rb +2 -2
- data/lib/twilio-ruby/rest/ip_messaging/v2/service/user.rb +1 -1
- data/lib/twilio-ruby/rest/ip_messaging/v2/service.rb +4 -4
- data/lib/twilio-ruby/rest/media/v1/media_processor.rb +1 -1
- data/lib/twilio-ruby/rest/media/v1/media_recording.rb +2 -2
- data/lib/twilio-ruby/rest/media/v1/player_streamer.rb +1 -1
- data/lib/twilio-ruby/rest/messaging/v1/service.rb +1 -1
- data/lib/twilio-ruby/rest/notify/v1/service/notification.rb +1 -1
- data/lib/twilio-ruby/rest/oauth/v1/oauth.rb +162 -0
- data/lib/twilio-ruby/rest/oauth/v1/openid_discovery.rb +242 -0
- data/lib/twilio-ruby/rest/oauth/v1/token.rb +157 -0
- data/lib/twilio-ruby/rest/oauth/v1/user_info.rb +193 -0
- data/lib/twilio-ruby/rest/oauth/v1.rb +56 -0
- data/lib/twilio-ruby/rest/oauth.rb +62 -0
- data/lib/twilio-ruby/rest/preview/hosted_numbers/authorization_document/dependent_hosted_number_order.rb +2 -2
- data/lib/twilio-ruby/rest/preview/hosted_numbers/hosted_number_order.rb +2 -2
- data/lib/twilio-ruby/rest/preview/sync/service/sync_list/sync_list_item.rb +1 -1
- data/lib/twilio-ruby/rest/preview/understand/assistant/task/task_statistics.rb +2 -2
- data/lib/twilio-ruby/rest/preview/wireless/rate_plan.rb +1 -1
- data/lib/twilio-ruby/rest/proxy/v1/service/phone_number.rb +1 -1
- data/lib/twilio-ruby/rest/proxy/v1/service/session/participant.rb +1 -14
- data/lib/twilio-ruby/rest/proxy/v1/service/session.rb +5 -46
- data/lib/twilio-ruby/rest/proxy/v1/service.rb +1 -1
- data/lib/twilio-ruby/rest/studio/v1/flow.rb +1 -1
- data/lib/twilio-ruby/rest/studio/v2/flow/flow_revision.rb +1 -1
- data/lib/twilio-ruby/rest/studio/v2/flow.rb +1 -1
- data/lib/twilio-ruby/rest/supersim/v1/fleet.rb +1 -1
- data/lib/twilio-ruby/rest/supersim/v1/ip_command.rb +1 -1
- data/lib/twilio-ruby/rest/supersim/v1/settings_update.rb +240 -0
- data/lib/twilio-ruby/rest/supersim/v1/usage_record.rb +4 -4
- data/lib/twilio-ruby/rest/supersim/v1.rb +7 -0
- data/lib/twilio-ruby/rest/supersim.rb +6 -0
- data/lib/twilio-ruby/rest/sync/v1/service/sync_list/sync_list_item.rb +1 -1
- data/lib/twilio-ruby/rest/sync/v1/service.rb +1 -1
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/event.rb +1 -1
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task/reservation.rb +18 -5
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task.rb +3 -3
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue/task_queue_cumulative_statistics.rb +12 -12
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue/task_queue_real_time_statistics.rb +5 -5
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue.rb +10 -4
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker/worker_channel.rb +3 -3
- 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_real_time_statistics.rb +1 -1
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker.rb +9 -3
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workflow/workflow_cumulative_statistics.rb +13 -13
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workflow/workflow_real_time_statistics.rb +2 -2
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workflow.rb +1 -1
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workspace_cumulative_statistics.rb +13 -13
- data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workspace_real_time_statistics.rb +3 -3
- data/lib/twilio-ruby/rest/trunking/v1/trunk/origination_url.rb +2 -2
- data/lib/twilio-ruby/rest/verify/v2/service/access_token.rb +1 -9
- data/lib/twilio-ruby/rest/verify/v2/service/entity/challenge/notification.rb +1 -7
- data/lib/twilio-ruby/rest/verify/v2/service/entity/challenge.rb +0 -8
- data/lib/twilio-ruby/rest/verify/v2/service/entity/factor.rb +0 -8
- data/lib/twilio-ruby/rest/verify/v2/service/entity/new_factor.rb +0 -6
- data/lib/twilio-ruby/rest/verify/v2/service/entity.rb +0 -8
- data/lib/twilio-ruby/rest/verify/v2/service/rate_limit/bucket.rb +2 -2
- data/lib/twilio-ruby/rest/verify/v2/service/verification.rb +2 -2
- data/lib/twilio-ruby/rest/verify/v2/service/webhook.rb +0 -8
- data/lib/twilio-ruby/rest/verify/v2/service.rb +1 -1
- data/lib/twilio-ruby/rest/verify/v2/template.rb +7 -0
- data/lib/twilio-ruby/rest/verify/v2/verification_attempts_summary.rb +4 -4
- data/lib/twilio-ruby/rest/video/v1/composition.rb +3 -3
- data/lib/twilio-ruby/rest/video/v1/recording.rb +2 -2
- data/lib/twilio-ruby/rest/video/v1/room/recording.rb +2 -2
- data/lib/twilio-ruby/rest/video/v1/room.rb +4 -4
- data/lib/twilio-ruby/rest/voice/v1/connection_policy/connection_policy_target.rb +2 -2
- data/lib/twilio-ruby/rest/voice/v1/dialing_permissions/bulk_country_update.rb +1 -1
- data/lib/twilio-ruby/rest/voice/v1/ip_record.rb +1 -1
- data/lib/twilio-ruby/rest/wireless/v1/rate_plan.rb +3 -3
- data/lib/twilio-ruby/rest/wireless/v1/sim/data_session.rb +2 -2
- data/lib/twilio-ruby/twiml/voice_response.rb +10 -6
- data/lib/twilio-ruby/version.rb +1 -1
- metadata +11 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: fdb1f38ca1c9845c134c63e773b2b4ca0c0a92ca
|
|
4
|
+
data.tar.gz: '06295d094a8aaf33db0854c726930fcc02f869ec'
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: e54d51bd992ece7215d43ea5cab42e618166c87173283d8b300ca0c161ded07028720ec5e5492d2b30e3664b304c620569704d15749891e364acd8f5b800df7c
|
|
7
|
+
data.tar.gz: 80faf14855805d87f599a222284d3be8782b0620d3c3fe55377ee66c98cc486e17074a0e74daaa5db025b13a8b9da50ebb6e6546c5bf50fa898bfbcc3287e6ff
|
data/CHANGES.md
CHANGED
|
@@ -1,6 +1,51 @@
|
|
|
1
1
|
twilio-ruby changelog
|
|
2
2
|
=====================
|
|
3
3
|
|
|
4
|
+
[2022-10-31] Version 5.73.1
|
|
5
|
+
---------------------------
|
|
6
|
+
**Api**
|
|
7
|
+
- Added `contentSid` and `contentVariables` to Message resource with public visibility as Beta
|
|
8
|
+
- Add `UserDefinedMessageSubscription` and `UserDefinedMessage` resource
|
|
9
|
+
|
|
10
|
+
**Proxy**
|
|
11
|
+
- Remove FailOnParticipantConflict param from Proxy Session create and update and Proxy Participant create
|
|
12
|
+
|
|
13
|
+
**Supersim**
|
|
14
|
+
- Update SettingsUpdates resource to remove PackageSid
|
|
15
|
+
|
|
16
|
+
**Taskrouter**
|
|
17
|
+
- Add `Ordering` query parameter to Workers and TaskQueues for sorting by
|
|
18
|
+
- Add `worker_sid` query param for list reservations endpoint
|
|
19
|
+
|
|
20
|
+
**Twiml**
|
|
21
|
+
- Add `url` and `method` attributes to `<Conversation>`
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
[2022-10-19] Version 5.73.0
|
|
25
|
+
---------------------------
|
|
26
|
+
**Library - Feature**
|
|
27
|
+
- [PR #619](https://github.com/twilio/twilio-ruby/pull/619): check numeric properties for nil before converting. Thanks to [@childish-sambino](https://github.com/childish-sambino)!
|
|
28
|
+
|
|
29
|
+
**Api**
|
|
30
|
+
- Make link shortening parameters public **(breaking change)**
|
|
31
|
+
|
|
32
|
+
**Oauth**
|
|
33
|
+
- added oauth JWKS endpoint
|
|
34
|
+
- Get userinfo resource
|
|
35
|
+
- OpenID discovery resource
|
|
36
|
+
- Add new API for token endpoint
|
|
37
|
+
|
|
38
|
+
**Supersim**
|
|
39
|
+
- Add SettingsUpdates resource
|
|
40
|
+
|
|
41
|
+
**Verify**
|
|
42
|
+
- Update Verify Push endpoints to `ga` maturity
|
|
43
|
+
- Verify BYOT add Channels property to the Get Templates response
|
|
44
|
+
|
|
45
|
+
**Twiml**
|
|
46
|
+
- Add `requireMatchingInputs` attribute and `input-matching-failed` errorType to `<Prompt>`
|
|
47
|
+
|
|
48
|
+
|
|
4
49
|
[2022-10-05] Version 5.72.1
|
|
5
50
|
---------------------------
|
|
6
51
|
**Api**
|
data/README.md
CHANGED
|
@@ -34,13 +34,13 @@ This library supports the following Ruby implementations:
|
|
|
34
34
|
To install using [Bundler][bundler] grab the latest stable version:
|
|
35
35
|
|
|
36
36
|
```ruby
|
|
37
|
-
gem 'twilio-ruby', '~> 5.
|
|
37
|
+
gem 'twilio-ruby', '~> 5.73.1'
|
|
38
38
|
```
|
|
39
39
|
|
|
40
40
|
To manually install `twilio-ruby` via [Rubygems][rubygems] simply gem install:
|
|
41
41
|
|
|
42
42
|
```bash
|
|
43
|
-
gem install twilio-ruby -v 5.
|
|
43
|
+
gem install twilio-ruby -v 5.73.1
|
|
44
44
|
```
|
|
45
45
|
|
|
46
46
|
To build and install the development branch yourself from the latest source:
|
|
@@ -391,8 +391,8 @@ module Twilio
|
|
|
391
391
|
'lata' => payload['lata'],
|
|
392
392
|
'locality' => payload['locality'],
|
|
393
393
|
'rate_center' => payload['rate_center'],
|
|
394
|
-
'latitude' => payload['latitude'].to_f,
|
|
395
|
-
'longitude' => payload['longitude'].to_f,
|
|
394
|
+
'latitude' => payload['latitude'] == nil ? payload['latitude'] : payload['latitude'].to_f,
|
|
395
|
+
'longitude' => payload['longitude'] == nil ? payload['longitude'] : payload['longitude'].to_f,
|
|
396
396
|
'region' => payload['region'],
|
|
397
397
|
'postal_code' => payload['postal_code'],
|
|
398
398
|
'iso_country' => payload['iso_country'],
|
|
@@ -391,8 +391,8 @@ module Twilio
|
|
|
391
391
|
'lata' => payload['lata'],
|
|
392
392
|
'locality' => payload['locality'],
|
|
393
393
|
'rate_center' => payload['rate_center'],
|
|
394
|
-
'latitude' => payload['latitude'].to_f,
|
|
395
|
-
'longitude' => payload['longitude'].to_f,
|
|
394
|
+
'latitude' => payload['latitude'] == nil ? payload['latitude'] : payload['latitude'].to_f,
|
|
395
|
+
'longitude' => payload['longitude'] == nil ? payload['longitude'] : payload['longitude'].to_f,
|
|
396
396
|
'region' => payload['region'],
|
|
397
397
|
'postal_code' => payload['postal_code'],
|
|
398
398
|
'iso_country' => payload['iso_country'],
|
|
@@ -391,8 +391,8 @@ module Twilio
|
|
|
391
391
|
'lata' => payload['lata'],
|
|
392
392
|
'locality' => payload['locality'],
|
|
393
393
|
'rate_center' => payload['rate_center'],
|
|
394
|
-
'latitude' => payload['latitude'].to_f,
|
|
395
|
-
'longitude' => payload['longitude'].to_f,
|
|
394
|
+
'latitude' => payload['latitude'] == nil ? payload['latitude'] : payload['latitude'].to_f,
|
|
395
|
+
'longitude' => payload['longitude'] == nil ? payload['longitude'] : payload['longitude'].to_f,
|
|
396
396
|
'region' => payload['region'],
|
|
397
397
|
'postal_code' => payload['postal_code'],
|
|
398
398
|
'iso_country' => payload['iso_country'],
|
|
@@ -391,8 +391,8 @@ module Twilio
|
|
|
391
391
|
'lata' => payload['lata'],
|
|
392
392
|
'locality' => payload['locality'],
|
|
393
393
|
'rate_center' => payload['rate_center'],
|
|
394
|
-
'latitude' => payload['latitude'].to_f,
|
|
395
|
-
'longitude' => payload['longitude'].to_f,
|
|
394
|
+
'latitude' => payload['latitude'] == nil ? payload['latitude'] : payload['latitude'].to_f,
|
|
395
|
+
'longitude' => payload['longitude'] == nil ? payload['longitude'] : payload['longitude'].to_f,
|
|
396
396
|
'region' => payload['region'],
|
|
397
397
|
'postal_code' => payload['postal_code'],
|
|
398
398
|
'iso_country' => payload['iso_country'],
|
|
@@ -391,8 +391,8 @@ module Twilio
|
|
|
391
391
|
'lata' => payload['lata'],
|
|
392
392
|
'locality' => payload['locality'],
|
|
393
393
|
'rate_center' => payload['rate_center'],
|
|
394
|
-
'latitude' => payload['latitude'].to_f,
|
|
395
|
-
'longitude' => payload['longitude'].to_f,
|
|
394
|
+
'latitude' => payload['latitude'] == nil ? payload['latitude'] : payload['latitude'].to_f,
|
|
395
|
+
'longitude' => payload['longitude'] == nil ? payload['longitude'] : payload['longitude'].to_f,
|
|
396
396
|
'region' => payload['region'],
|
|
397
397
|
'postal_code' => payload['postal_code'],
|
|
398
398
|
'iso_country' => payload['iso_country'],
|
|
@@ -391,8 +391,8 @@ module Twilio
|
|
|
391
391
|
'lata' => payload['lata'],
|
|
392
392
|
'locality' => payload['locality'],
|
|
393
393
|
'rate_center' => payload['rate_center'],
|
|
394
|
-
'latitude' => payload['latitude'].to_f,
|
|
395
|
-
'longitude' => payload['longitude'].to_f,
|
|
394
|
+
'latitude' => payload['latitude'] == nil ? payload['latitude'] : payload['latitude'].to_f,
|
|
395
|
+
'longitude' => payload['longitude'] == nil ? payload['longitude'] : payload['longitude'].to_f,
|
|
396
396
|
'region' => payload['region'],
|
|
397
397
|
'postal_code' => payload['postal_code'],
|
|
398
398
|
'iso_country' => payload['iso_country'],
|
|
@@ -391,8 +391,8 @@ module Twilio
|
|
|
391
391
|
'lata' => payload['lata'],
|
|
392
392
|
'locality' => payload['locality'],
|
|
393
393
|
'rate_center' => payload['rate_center'],
|
|
394
|
-
'latitude' => payload['latitude'].to_f,
|
|
395
|
-
'longitude' => payload['longitude'].to_f,
|
|
394
|
+
'latitude' => payload['latitude'] == nil ? payload['latitude'] : payload['latitude'].to_f,
|
|
395
|
+
'longitude' => payload['longitude'] == nil ? payload['longitude'] : payload['longitude'].to_f,
|
|
396
396
|
'region' => payload['region'],
|
|
397
397
|
'postal_code' => payload['postal_code'],
|
|
398
398
|
'iso_country' => payload['iso_country'],
|
|
@@ -188,7 +188,7 @@ module Twilio
|
|
|
188
188
|
'date_created' => Twilio.deserialize_rfc2822(payload['date_created']),
|
|
189
189
|
'date_updated' => Twilio.deserialize_rfc2822(payload['date_updated']),
|
|
190
190
|
'issues' => payload['issues'],
|
|
191
|
-
'quality_score' => payload['quality_score'].to_i,
|
|
191
|
+
'quality_score' => payload['quality_score'] == nil ? payload['quality_score'] : payload['quality_score'].to_i,
|
|
192
192
|
'sid' => payload['sid'],
|
|
193
193
|
}
|
|
194
194
|
|
|
@@ -163,16 +163,16 @@ module Twilio
|
|
|
163
163
|
# Marshaled Properties
|
|
164
164
|
@properties = {
|
|
165
165
|
'account_sid' => payload['account_sid'],
|
|
166
|
-
'call_count' => payload['call_count'].to_i,
|
|
167
|
-
'call_feedback_count' => payload['call_feedback_count'].to_i,
|
|
166
|
+
'call_count' => payload['call_count'] == nil ? payload['call_count'] : payload['call_count'].to_i,
|
|
167
|
+
'call_feedback_count' => payload['call_feedback_count'] == nil ? payload['call_feedback_count'] : payload['call_feedback_count'].to_i,
|
|
168
168
|
'date_created' => Twilio.deserialize_rfc2822(payload['date_created']),
|
|
169
169
|
'date_updated' => Twilio.deserialize_rfc2822(payload['date_updated']),
|
|
170
170
|
'end_date' => Twilio.deserialize_iso8601_date(payload['end_date']),
|
|
171
171
|
'include_subaccounts' => payload['include_subaccounts'],
|
|
172
172
|
'issues' => payload['issues'],
|
|
173
|
-
'quality_score_average' => payload['quality_score_average'].to_f,
|
|
174
|
-
'quality_score_median' => payload['quality_score_median'].to_f,
|
|
175
|
-
'quality_score_standard_deviation' => payload['quality_score_standard_deviation'].to_f,
|
|
173
|
+
'quality_score_average' => payload['quality_score_average'] == nil ? payload['quality_score_average'] : payload['quality_score_average'].to_f,
|
|
174
|
+
'quality_score_median' => payload['quality_score_median'] == nil ? payload['quality_score_median'] : payload['quality_score_median'].to_f,
|
|
175
|
+
'quality_score_standard_deviation' => payload['quality_score_standard_deviation'] == nil ? payload['quality_score_standard_deviation'] : payload['quality_score_standard_deviation'].to_f,
|
|
176
176
|
'sid' => payload['sid'],
|
|
177
177
|
'start_date' => Twilio.deserialize_iso8601_date(payload['start_date']),
|
|
178
178
|
'status' => payload['status'],
|
|
@@ -332,12 +332,12 @@ module Twilio
|
|
|
332
332
|
'start_time' => Twilio.deserialize_rfc2822(payload['start_time']),
|
|
333
333
|
'duration' => payload['duration'],
|
|
334
334
|
'sid' => payload['sid'],
|
|
335
|
-
'price' => payload['price'].to_f,
|
|
335
|
+
'price' => payload['price'] == nil ? payload['price'] : payload['price'].to_f,
|
|
336
336
|
'uri' => payload['uri'],
|
|
337
337
|
'encryption_details' => payload['encryption_details'],
|
|
338
338
|
'price_unit' => payload['price_unit'],
|
|
339
339
|
'status' => payload['status'],
|
|
340
|
-
'channels' => payload['channels'].to_i,
|
|
340
|
+
'channels' => payload['channels'] == nil ? payload['channels'] : payload['channels'].to_i,
|
|
341
341
|
'source' => payload['source'],
|
|
342
342
|
'error_code' => payload['error_code'] == nil ? payload['error_code'] : payload['error_code'].to_i,
|
|
343
343
|
'track' => payload['track'],
|
|
@@ -0,0 +1,160 @@
|
|
|
1
|
+
##
|
|
2
|
+
# This code was generated by
|
|
3
|
+
# \ / _ _ _| _ _
|
|
4
|
+
# | (_)\/(_)(_|\/| |(/_ v1.0.0
|
|
5
|
+
# / /
|
|
6
|
+
#
|
|
7
|
+
# frozen_string_literal: true
|
|
8
|
+
|
|
9
|
+
module Twilio
|
|
10
|
+
module REST
|
|
11
|
+
class Api < Domain
|
|
12
|
+
class V2010 < Version
|
|
13
|
+
class AccountContext < InstanceContext
|
|
14
|
+
class CallContext < InstanceContext
|
|
15
|
+
class UserDefinedMessageList < ListResource
|
|
16
|
+
##
|
|
17
|
+
# Initialize the UserDefinedMessageList
|
|
18
|
+
# @param [Version] version Version that contains the resource
|
|
19
|
+
# @param [String] account_sid The SID of the
|
|
20
|
+
# {Account}[https://www.twilio.com/docs/iam/api/account] that created User Defined
|
|
21
|
+
# Message.
|
|
22
|
+
# @param [String] call_sid The SID of the
|
|
23
|
+
# {Call}[https://www.twilio.com/docs/voice/api/call-resource] the User Defined
|
|
24
|
+
# Message is associated with.
|
|
25
|
+
# @return [UserDefinedMessageList] UserDefinedMessageList
|
|
26
|
+
def initialize(version, account_sid: nil, call_sid: nil)
|
|
27
|
+
super(version)
|
|
28
|
+
|
|
29
|
+
# Path Solution
|
|
30
|
+
@solution = {account_sid: account_sid, call_sid: call_sid}
|
|
31
|
+
@uri = "/Accounts/#{@solution[:account_sid]}/Calls/#{@solution[:call_sid]}/UserDefinedMessages.json"
|
|
32
|
+
end
|
|
33
|
+
|
|
34
|
+
##
|
|
35
|
+
# Create the UserDefinedMessageInstance
|
|
36
|
+
# @param [String] content A unique string value to identify API call. This should
|
|
37
|
+
# be a unique string value per API call and can be a randomly generated.
|
|
38
|
+
# @param [String] idempotency_key A unique string value to identify API call. This
|
|
39
|
+
# should be a unique string value per API call and can be a randomly generated.
|
|
40
|
+
# @return [UserDefinedMessageInstance] Created UserDefinedMessageInstance
|
|
41
|
+
def create(content: nil, idempotency_key: :unset)
|
|
42
|
+
data = Twilio::Values.of({'Content' => content, 'IdempotencyKey' => idempotency_key, })
|
|
43
|
+
|
|
44
|
+
payload = @version.create('POST', @uri, data: data)
|
|
45
|
+
|
|
46
|
+
UserDefinedMessageInstance.new(
|
|
47
|
+
@version,
|
|
48
|
+
payload,
|
|
49
|
+
account_sid: @solution[:account_sid],
|
|
50
|
+
call_sid: @solution[:call_sid],
|
|
51
|
+
)
|
|
52
|
+
end
|
|
53
|
+
|
|
54
|
+
##
|
|
55
|
+
# Provide a user friendly representation
|
|
56
|
+
def to_s
|
|
57
|
+
'#<Twilio.Api.V2010.UserDefinedMessageList>'
|
|
58
|
+
end
|
|
59
|
+
end
|
|
60
|
+
|
|
61
|
+
class UserDefinedMessagePage < Page
|
|
62
|
+
##
|
|
63
|
+
# Initialize the UserDefinedMessagePage
|
|
64
|
+
# @param [Version] version Version that contains the resource
|
|
65
|
+
# @param [Response] response Response from the API
|
|
66
|
+
# @param [Hash] solution Path solution for the resource
|
|
67
|
+
# @return [UserDefinedMessagePage] UserDefinedMessagePage
|
|
68
|
+
def initialize(version, response, solution)
|
|
69
|
+
super(version, response)
|
|
70
|
+
|
|
71
|
+
# Path Solution
|
|
72
|
+
@solution = solution
|
|
73
|
+
end
|
|
74
|
+
|
|
75
|
+
##
|
|
76
|
+
# Build an instance of UserDefinedMessageInstance
|
|
77
|
+
# @param [Hash] payload Payload response from the API
|
|
78
|
+
# @return [UserDefinedMessageInstance] UserDefinedMessageInstance
|
|
79
|
+
def get_instance(payload)
|
|
80
|
+
UserDefinedMessageInstance.new(
|
|
81
|
+
@version,
|
|
82
|
+
payload,
|
|
83
|
+
account_sid: @solution[:account_sid],
|
|
84
|
+
call_sid: @solution[:call_sid],
|
|
85
|
+
)
|
|
86
|
+
end
|
|
87
|
+
|
|
88
|
+
##
|
|
89
|
+
# Provide a user friendly representation
|
|
90
|
+
def to_s
|
|
91
|
+
'<Twilio.Api.V2010.UserDefinedMessagePage>'
|
|
92
|
+
end
|
|
93
|
+
end
|
|
94
|
+
|
|
95
|
+
class UserDefinedMessageInstance < InstanceResource
|
|
96
|
+
##
|
|
97
|
+
# Initialize the UserDefinedMessageInstance
|
|
98
|
+
# @param [Version] version Version that contains the resource
|
|
99
|
+
# @param [Hash] payload payload that contains response from Twilio
|
|
100
|
+
# @param [String] account_sid The SID of the
|
|
101
|
+
# {Account}[https://www.twilio.com/docs/iam/api/account] that created User Defined
|
|
102
|
+
# Message.
|
|
103
|
+
# @param [String] call_sid The SID of the
|
|
104
|
+
# {Call}[https://www.twilio.com/docs/voice/api/call-resource] the User Defined
|
|
105
|
+
# Message is associated with.
|
|
106
|
+
# @return [UserDefinedMessageInstance] UserDefinedMessageInstance
|
|
107
|
+
def initialize(version, payload, account_sid: nil, call_sid: nil)
|
|
108
|
+
super(version)
|
|
109
|
+
|
|
110
|
+
# Marshaled Properties
|
|
111
|
+
@properties = {
|
|
112
|
+
'account_sid' => payload['account_sid'],
|
|
113
|
+
'call_sid' => payload['call_sid'],
|
|
114
|
+
'sid' => payload['sid'],
|
|
115
|
+
'date_created' => Twilio.deserialize_rfc2822(payload['date_created']),
|
|
116
|
+
}
|
|
117
|
+
end
|
|
118
|
+
|
|
119
|
+
##
|
|
120
|
+
# @return [String] Account Sid.
|
|
121
|
+
def account_sid
|
|
122
|
+
@properties['account_sid']
|
|
123
|
+
end
|
|
124
|
+
|
|
125
|
+
##
|
|
126
|
+
# @return [String] Call Sid.
|
|
127
|
+
def call_sid
|
|
128
|
+
@properties['call_sid']
|
|
129
|
+
end
|
|
130
|
+
|
|
131
|
+
##
|
|
132
|
+
# @return [String] A string that uniquely identifies this User Defined Message.
|
|
133
|
+
def sid
|
|
134
|
+
@properties['sid']
|
|
135
|
+
end
|
|
136
|
+
|
|
137
|
+
##
|
|
138
|
+
# @return [Time] The date this User Defined Message was created
|
|
139
|
+
def date_created
|
|
140
|
+
@properties['date_created']
|
|
141
|
+
end
|
|
142
|
+
|
|
143
|
+
##
|
|
144
|
+
# Provide a user friendly representation
|
|
145
|
+
def to_s
|
|
146
|
+
"<Twilio.Api.V2010.UserDefinedMessageInstance>"
|
|
147
|
+
end
|
|
148
|
+
|
|
149
|
+
##
|
|
150
|
+
# Provide a detailed, user friendly representation
|
|
151
|
+
def inspect
|
|
152
|
+
"<Twilio.Api.V2010.UserDefinedMessageInstance>"
|
|
153
|
+
end
|
|
154
|
+
end
|
|
155
|
+
end
|
|
156
|
+
end
|
|
157
|
+
end
|
|
158
|
+
end
|
|
159
|
+
end
|
|
160
|
+
end
|
|
@@ -0,0 +1,251 @@
|
|
|
1
|
+
##
|
|
2
|
+
# This code was generated by
|
|
3
|
+
# \ / _ _ _| _ _
|
|
4
|
+
# | (_)\/(_)(_|\/| |(/_ v1.0.0
|
|
5
|
+
# / /
|
|
6
|
+
#
|
|
7
|
+
# frozen_string_literal: true
|
|
8
|
+
|
|
9
|
+
module Twilio
|
|
10
|
+
module REST
|
|
11
|
+
class Api < Domain
|
|
12
|
+
class V2010 < Version
|
|
13
|
+
class AccountContext < InstanceContext
|
|
14
|
+
class CallContext < InstanceContext
|
|
15
|
+
class UserDefinedMessageSubscriptionList < ListResource
|
|
16
|
+
##
|
|
17
|
+
# Initialize the UserDefinedMessageSubscriptionList
|
|
18
|
+
# @param [Version] version Version that contains the resource
|
|
19
|
+
# @param [String] account_sid The SID of the
|
|
20
|
+
# {Account}[https://www.twilio.com/docs/iam/api/account] that subscribed to the
|
|
21
|
+
# User Defined Messages.
|
|
22
|
+
# @param [String] call_sid The SID of the
|
|
23
|
+
# {Call}[https://www.twilio.com/docs/voice/api/call-resource] the User Defined
|
|
24
|
+
# Messages subscription is associated with. This refers to the call sid that is
|
|
25
|
+
# producing the user defined messages.
|
|
26
|
+
# @return [UserDefinedMessageSubscriptionList] UserDefinedMessageSubscriptionList
|
|
27
|
+
def initialize(version, account_sid: nil, call_sid: nil)
|
|
28
|
+
super(version)
|
|
29
|
+
|
|
30
|
+
# Path Solution
|
|
31
|
+
@solution = {account_sid: account_sid, call_sid: call_sid}
|
|
32
|
+
@uri = "/Accounts/#{@solution[:account_sid]}/Calls/#{@solution[:call_sid]}/UserDefinedMessageSubscriptions.json"
|
|
33
|
+
end
|
|
34
|
+
|
|
35
|
+
##
|
|
36
|
+
# Create the UserDefinedMessageSubscriptionInstance
|
|
37
|
+
# @param [String] callback The URL we should call using the `method` to send user
|
|
38
|
+
# defined events to your application. URLs must contain a valid hostname
|
|
39
|
+
# (underscores are not permitted).
|
|
40
|
+
# @param [String] method The HTTP method Twilio will use when requesting the above
|
|
41
|
+
# `Url`. Either `GET` or `POST`.
|
|
42
|
+
# @param [String] idempotency_key A unique string value to identify API call. This
|
|
43
|
+
# should be a unique string value per API call and can be a randomly generated.
|
|
44
|
+
# @return [UserDefinedMessageSubscriptionInstance] Created UserDefinedMessageSubscriptionInstance
|
|
45
|
+
def create(callback: nil, method: nil, idempotency_key: :unset)
|
|
46
|
+
data = Twilio::Values.of({
|
|
47
|
+
'Callback' => callback,
|
|
48
|
+
'Method' => method,
|
|
49
|
+
'IdempotencyKey' => idempotency_key,
|
|
50
|
+
})
|
|
51
|
+
|
|
52
|
+
payload = @version.create('POST', @uri, data: data)
|
|
53
|
+
|
|
54
|
+
UserDefinedMessageSubscriptionInstance.new(
|
|
55
|
+
@version,
|
|
56
|
+
payload,
|
|
57
|
+
account_sid: @solution[:account_sid],
|
|
58
|
+
call_sid: @solution[:call_sid],
|
|
59
|
+
)
|
|
60
|
+
end
|
|
61
|
+
|
|
62
|
+
##
|
|
63
|
+
# Provide a user friendly representation
|
|
64
|
+
def to_s
|
|
65
|
+
'#<Twilio.Api.V2010.UserDefinedMessageSubscriptionList>'
|
|
66
|
+
end
|
|
67
|
+
end
|
|
68
|
+
|
|
69
|
+
class UserDefinedMessageSubscriptionPage < Page
|
|
70
|
+
##
|
|
71
|
+
# Initialize the UserDefinedMessageSubscriptionPage
|
|
72
|
+
# @param [Version] version Version that contains the resource
|
|
73
|
+
# @param [Response] response Response from the API
|
|
74
|
+
# @param [Hash] solution Path solution for the resource
|
|
75
|
+
# @return [UserDefinedMessageSubscriptionPage] UserDefinedMessageSubscriptionPage
|
|
76
|
+
def initialize(version, response, solution)
|
|
77
|
+
super(version, response)
|
|
78
|
+
|
|
79
|
+
# Path Solution
|
|
80
|
+
@solution = solution
|
|
81
|
+
end
|
|
82
|
+
|
|
83
|
+
##
|
|
84
|
+
# Build an instance of UserDefinedMessageSubscriptionInstance
|
|
85
|
+
# @param [Hash] payload Payload response from the API
|
|
86
|
+
# @return [UserDefinedMessageSubscriptionInstance] UserDefinedMessageSubscriptionInstance
|
|
87
|
+
def get_instance(payload)
|
|
88
|
+
UserDefinedMessageSubscriptionInstance.new(
|
|
89
|
+
@version,
|
|
90
|
+
payload,
|
|
91
|
+
account_sid: @solution[:account_sid],
|
|
92
|
+
call_sid: @solution[:call_sid],
|
|
93
|
+
)
|
|
94
|
+
end
|
|
95
|
+
|
|
96
|
+
##
|
|
97
|
+
# Provide a user friendly representation
|
|
98
|
+
def to_s
|
|
99
|
+
'<Twilio.Api.V2010.UserDefinedMessageSubscriptionPage>'
|
|
100
|
+
end
|
|
101
|
+
end
|
|
102
|
+
|
|
103
|
+
class UserDefinedMessageSubscriptionContext < InstanceContext
|
|
104
|
+
##
|
|
105
|
+
# Initialize the UserDefinedMessageSubscriptionContext
|
|
106
|
+
# @param [Version] version Version that contains the resource
|
|
107
|
+
# @param [String] account_sid The SID of the
|
|
108
|
+
# {Account}[https://www.twilio.com/docs/iam/api/account] that subscribed to the
|
|
109
|
+
# User Defined Messages.
|
|
110
|
+
# @param [String] call_sid The SID of the
|
|
111
|
+
# {Call}[https://www.twilio.com/docs/voice/api/call-resource] the User Defined
|
|
112
|
+
# Messages subscription is associated with. This refers to the call sid that is
|
|
113
|
+
# producing the user defined messages.
|
|
114
|
+
# @param [String] sid The SID that uniquely identifies this User Defined Message
|
|
115
|
+
# Subscription.
|
|
116
|
+
# @return [UserDefinedMessageSubscriptionContext] UserDefinedMessageSubscriptionContext
|
|
117
|
+
def initialize(version, account_sid, call_sid, sid)
|
|
118
|
+
super(version)
|
|
119
|
+
|
|
120
|
+
# Path Solution
|
|
121
|
+
@solution = {account_sid: account_sid, call_sid: call_sid, sid: sid, }
|
|
122
|
+
@uri = "/Accounts/#{@solution[:account_sid]}/Calls/#{@solution[:call_sid]}/UserDefinedMessageSubscriptions/#{@solution[:sid]}.json"
|
|
123
|
+
end
|
|
124
|
+
|
|
125
|
+
##
|
|
126
|
+
# Delete the UserDefinedMessageSubscriptionInstance
|
|
127
|
+
# @return [Boolean] true if delete succeeds, false otherwise
|
|
128
|
+
def delete
|
|
129
|
+
@version.delete('DELETE', @uri)
|
|
130
|
+
end
|
|
131
|
+
|
|
132
|
+
##
|
|
133
|
+
# Provide a user friendly representation
|
|
134
|
+
def to_s
|
|
135
|
+
context = @solution.map {|k, v| "#{k}: #{v}"}.join(',')
|
|
136
|
+
"#<Twilio.Api.V2010.UserDefinedMessageSubscriptionContext #{context}>"
|
|
137
|
+
end
|
|
138
|
+
|
|
139
|
+
##
|
|
140
|
+
# Provide a detailed, user friendly representation
|
|
141
|
+
def inspect
|
|
142
|
+
context = @solution.map {|k, v| "#{k}: #{v}"}.join(',')
|
|
143
|
+
"#<Twilio.Api.V2010.UserDefinedMessageSubscriptionContext #{context}>"
|
|
144
|
+
end
|
|
145
|
+
end
|
|
146
|
+
|
|
147
|
+
class UserDefinedMessageSubscriptionInstance < InstanceResource
|
|
148
|
+
##
|
|
149
|
+
# Initialize the UserDefinedMessageSubscriptionInstance
|
|
150
|
+
# @param [Version] version Version that contains the resource
|
|
151
|
+
# @param [Hash] payload payload that contains response from Twilio
|
|
152
|
+
# @param [String] account_sid The SID of the
|
|
153
|
+
# {Account}[https://www.twilio.com/docs/iam/api/account] that subscribed to the
|
|
154
|
+
# User Defined Messages.
|
|
155
|
+
# @param [String] call_sid The SID of the
|
|
156
|
+
# {Call}[https://www.twilio.com/docs/voice/api/call-resource] the User Defined
|
|
157
|
+
# Messages subscription is associated with. This refers to the call sid that is
|
|
158
|
+
# producing the user defined messages.
|
|
159
|
+
# @param [String] sid The SID that uniquely identifies this User Defined Message
|
|
160
|
+
# Subscription.
|
|
161
|
+
# @return [UserDefinedMessageSubscriptionInstance] UserDefinedMessageSubscriptionInstance
|
|
162
|
+
def initialize(version, payload, account_sid: nil, call_sid: nil, sid: nil)
|
|
163
|
+
super(version)
|
|
164
|
+
|
|
165
|
+
# Marshaled Properties
|
|
166
|
+
@properties = {
|
|
167
|
+
'account_sid' => payload['account_sid'],
|
|
168
|
+
'call_sid' => payload['call_sid'],
|
|
169
|
+
'sid' => payload['sid'],
|
|
170
|
+
'date_created' => Twilio.deserialize_rfc2822(payload['date_created']),
|
|
171
|
+
'uri' => payload['uri'],
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
# Context
|
|
175
|
+
@instance_context = nil
|
|
176
|
+
@params = {'account_sid' => account_sid, 'call_sid' => call_sid, 'sid' => sid || @properties['sid'], }
|
|
177
|
+
end
|
|
178
|
+
|
|
179
|
+
##
|
|
180
|
+
# Generate an instance context for the instance, the context is capable of
|
|
181
|
+
# performing various actions. All instance actions are proxied to the context
|
|
182
|
+
# @return [UserDefinedMessageSubscriptionContext] UserDefinedMessageSubscriptionContext for this UserDefinedMessageSubscriptionInstance
|
|
183
|
+
def context
|
|
184
|
+
unless @instance_context
|
|
185
|
+
@instance_context = UserDefinedMessageSubscriptionContext.new(
|
|
186
|
+
@version,
|
|
187
|
+
@params['account_sid'],
|
|
188
|
+
@params['call_sid'],
|
|
189
|
+
@params['sid'],
|
|
190
|
+
)
|
|
191
|
+
end
|
|
192
|
+
@instance_context
|
|
193
|
+
end
|
|
194
|
+
|
|
195
|
+
##
|
|
196
|
+
# @return [String] Account Sid.
|
|
197
|
+
def account_sid
|
|
198
|
+
@properties['account_sid']
|
|
199
|
+
end
|
|
200
|
+
|
|
201
|
+
##
|
|
202
|
+
# @return [String] Call Sid.
|
|
203
|
+
def call_sid
|
|
204
|
+
@properties['call_sid']
|
|
205
|
+
end
|
|
206
|
+
|
|
207
|
+
##
|
|
208
|
+
# @return [String] User Defined Message Subscription Sid
|
|
209
|
+
def sid
|
|
210
|
+
@properties['sid']
|
|
211
|
+
end
|
|
212
|
+
|
|
213
|
+
##
|
|
214
|
+
# @return [Time] The date this User Defined Message Subscription was created
|
|
215
|
+
def date_created
|
|
216
|
+
@properties['date_created']
|
|
217
|
+
end
|
|
218
|
+
|
|
219
|
+
##
|
|
220
|
+
# @return [String] The URI of the resource, relative to `https://api.twilio.com`.
|
|
221
|
+
def uri
|
|
222
|
+
@properties['uri']
|
|
223
|
+
end
|
|
224
|
+
|
|
225
|
+
##
|
|
226
|
+
# Delete the UserDefinedMessageSubscriptionInstance
|
|
227
|
+
# @return [Boolean] true if delete succeeds, false otherwise
|
|
228
|
+
def delete
|
|
229
|
+
context.delete
|
|
230
|
+
end
|
|
231
|
+
|
|
232
|
+
##
|
|
233
|
+
# Provide a user friendly representation
|
|
234
|
+
def to_s
|
|
235
|
+
values = @params.map{|k, v| "#{k}: #{v}"}.join(" ")
|
|
236
|
+
"<Twilio.Api.V2010.UserDefinedMessageSubscriptionInstance #{values}>"
|
|
237
|
+
end
|
|
238
|
+
|
|
239
|
+
##
|
|
240
|
+
# Provide a detailed, user friendly representation
|
|
241
|
+
def inspect
|
|
242
|
+
values = @properties.map{|k, v| "#{k}: #{v}"}.join(" ")
|
|
243
|
+
"<Twilio.Api.V2010.UserDefinedMessageSubscriptionInstance #{values}>"
|
|
244
|
+
end
|
|
245
|
+
end
|
|
246
|
+
end
|
|
247
|
+
end
|
|
248
|
+
end
|
|
249
|
+
end
|
|
250
|
+
end
|
|
251
|
+
end
|