twilio-ruby 7.6.1 → 7.6.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (49) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGES.md +64 -0
  3. data/README.md +2 -2
  4. data/lib/twilio-ruby/http/client_token_manager.rb +2 -2
  5. data/lib/twilio-ruby/http/org_token_manager.rb +2 -2
  6. data/lib/twilio-ruby/rest/api/v2010/account/address/dependent_phone_number.rb +5 -5
  7. data/lib/twilio-ruby/rest/api/v2010/account/recording.rb +1 -1
  8. data/lib/twilio-ruby/rest/bulkexports/v1/export/export_custom_job.rb +1 -1
  9. data/lib/twilio-ruby/rest/bulkexports/v1/export/job.rb +1 -1
  10. data/lib/twilio-ruby/rest/client.rb +0 -10
  11. data/lib/twilio-ruby/rest/lookups/v2/bucket.rb +315 -0
  12. data/lib/twilio-ruby/rest/lookups/v2/lookup_override.rb +390 -0
  13. data/lib/twilio-ruby/rest/lookups/v2/query.rb +456 -0
  14. data/lib/twilio-ruby/rest/lookups/v2/rate_limit.rb +136 -0
  15. data/lib/twilio-ruby/rest/lookups/v2.rb +86 -0
  16. data/lib/twilio-ruby/rest/messaging/v1/service/destination_alpha_sender.rb +9 -3
  17. data/lib/twilio-ruby/rest/messaging/v1/service.rb +4 -4
  18. data/lib/twilio-ruby/rest/messaging/v2/channels_sender.rb +87 -19
  19. data/lib/twilio-ruby/rest/numbers/v1/porting_port_in.rb +3 -3
  20. data/lib/twilio-ruby/rest/numbers/v1/{porting_webhook_configuration_fetch.rb → webhook.rb} +20 -20
  21. data/lib/twilio-ruby/rest/numbers/v1.rb +6 -6
  22. data/lib/twilio-ruby/rest/proxy/v1/service.rb +0 -27
  23. data/lib/twilio-ruby/rest/serverless/v1/service/environment/log.rb +1 -1
  24. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task.rb +1 -1
  25. data/lib/twilio-ruby/rest/trunking/v1/trunk.rb +7 -0
  26. data/lib/twilio-ruby/rest/verify/v2/service.rb +1 -1
  27. data/lib/twilio-ruby/rest/verify/v2/verification_attempt.rb +3 -3
  28. data/lib/twilio-ruby/rest/verify/v2/verification_attempts_summary.rb +2 -2
  29. data/lib/twilio-ruby/rest/{proxy/v1/service/short_code.rb → video/v1/room/transcriptions.rb} +110 -123
  30. data/lib/twilio-ruby/rest/video/v1/room.rb +27 -0
  31. data/lib/twilio-ruby/twiml/voice_response.rb +24 -0
  32. data/lib/twilio-ruby/version.rb +1 -1
  33. metadata +8 -20
  34. data/lib/twilio-ruby/rest/knowledge/v1/knowledge/chunk.rb +0 -232
  35. data/lib/twilio-ruby/rest/knowledge/v1/knowledge/knowledge_status.rb +0 -213
  36. data/lib/twilio-ruby/rest/knowledge/v1/knowledge.rb +0 -617
  37. data/lib/twilio-ruby/rest/knowledge/v1.rb +0 -49
  38. data/lib/twilio-ruby/rest/knowledge.rb +0 -6
  39. data/lib/twilio-ruby/rest/knowledge_base.rb +0 -38
  40. data/lib/twilio-ruby/rest/microvisor/v1/account_config.rb +0 -382
  41. data/lib/twilio-ruby/rest/microvisor/v1/account_secret.rb +0 -375
  42. data/lib/twilio-ruby/rest/microvisor/v1/app/app_manifest.rb +0 -213
  43. data/lib/twilio-ruby/rest/microvisor/v1/app.rb +0 -361
  44. data/lib/twilio-ruby/rest/microvisor/v1/device/device_config.rb +0 -398
  45. data/lib/twilio-ruby/rest/microvisor/v1/device/device_secret.rb +0 -391
  46. data/lib/twilio-ruby/rest/microvisor/v1/device.rb +0 -441
  47. data/lib/twilio-ruby/rest/microvisor/v1.rb +0 -94
  48. data/lib/twilio-ruby/rest/microvisor.rb +0 -24
  49. data/lib/twilio-ruby/rest/microvisor_base.rb +0 -38
@@ -21,9 +21,85 @@ module Twilio
21
21
  def initialize(domain)
22
22
  super
23
23
  @version = 'v2'
24
+ @bucket = nil
25
+ @lookup_overrides = nil
24
26
  @phone_numbers = nil
27
+ @query = nil
28
+ @rate_limits = nil
25
29
  end
26
30
 
31
+ ##
32
+ # @param [String] field bucket name
33
+ # @param [String] bucket bucket name
34
+ # @return [Twilio::REST::Lookups::V2::BucketContext] if field was passed.
35
+ # @return [Twilio::REST::Lookups::V2::BucketList]
36
+ def bucket(field=:unset, bucket=:unset)
37
+ if field.nil?
38
+ raise ArgumentError, 'field cannot be nil'
39
+ end
40
+ if bucket.nil?
41
+ raise ArgumentError, 'bucket cannot be nil'
42
+ end
43
+ if field == :unset && bucket == :unset
44
+ @bucket ||= BucketList.new self
45
+ else
46
+ BucketContext.new(self, field, bucket)
47
+ end
48
+ end
49
+ ##
50
+ # @param [String] field bucket name
51
+ # @param [String] bucket bucket name
52
+ # @return [Twilio::REST::Lookups::V2::BucketContext] if bucket was passed.
53
+ # @return [Twilio::REST::Lookups::V2::BucketList]
54
+ def bucket(field=:unset, bucket=:unset)
55
+ if field.nil?
56
+ raise ArgumentError, 'field cannot be nil'
57
+ end
58
+ if bucket.nil?
59
+ raise ArgumentError, 'bucket cannot be nil'
60
+ end
61
+ if field == :unset && bucket == :unset
62
+ @bucket ||= BucketList.new self
63
+ else
64
+ BucketContext.new(self, field, bucket)
65
+ end
66
+ end
67
+ ##
68
+ # @param [String] field
69
+ # @param [String] phone_number
70
+ # @return [Twilio::REST::Lookups::V2::LookupOverrideContext] if field was passed.
71
+ # @return [Twilio::REST::Lookups::V2::LookupOverrideList]
72
+ def lookup_overrides(field=:unset, phone_number=:unset)
73
+ if field.nil?
74
+ raise ArgumentError, 'field cannot be nil'
75
+ end
76
+ if phone_number.nil?
77
+ raise ArgumentError, 'phone_number cannot be nil'
78
+ end
79
+ if field == :unset && phone_number == :unset
80
+ @lookup_overrides ||= LookupOverrideList.new self
81
+ else
82
+ LookupOverrideContext.new(self, field, phone_number)
83
+ end
84
+ end
85
+ ##
86
+ # @param [String] field
87
+ # @param [String] phone_number
88
+ # @return [Twilio::REST::Lookups::V2::LookupOverrideContext] if phoneNumber was passed.
89
+ # @return [Twilio::REST::Lookups::V2::LookupOverrideList]
90
+ def lookup_overrides(field=:unset, phone_number=:unset)
91
+ if field.nil?
92
+ raise ArgumentError, 'field cannot be nil'
93
+ end
94
+ if phone_number.nil?
95
+ raise ArgumentError, 'phone_number cannot be nil'
96
+ end
97
+ if field == :unset && phone_number == :unset
98
+ @lookup_overrides ||= LookupOverrideList.new self
99
+ else
100
+ LookupOverrideContext.new(self, field, phone_number)
101
+ end
102
+ end
27
103
  ##
28
104
  # @param [String] phone_number The phone number to lookup in E.164 or national format. Default country code is +1 (North America).
29
105
  # @return [Twilio::REST::Lookups::V2::PhoneNumberContext] if phoneNumber was passed.
@@ -39,6 +115,16 @@ module Twilio
39
115
  end
40
116
  end
41
117
  ##
118
+ # @return [Twilio::REST::Lookups::V2::QueryList]
119
+ def query
120
+ @query ||= QueryList.new self
121
+ end
122
+ ##
123
+ # @return [Twilio::REST::Lookups::V2::RateLimitList]
124
+ def rate_limits
125
+ @rate_limits ||= RateLimitList.new self
126
+ end
127
+ ##
42
128
  # Provide a user friendly representation
43
129
  def to_s
44
130
  '<Twilio::REST::Lookups::V2>';
@@ -66,6 +66,7 @@ module Twilio
66
66
  # Lists DestinationAlphaSenderInstance records from the API as a list.
67
67
  # Unlike stream(), this operation is eager and will load `limit` records into
68
68
  # memory before returning.
69
+ # @param [String] iso_country_code Optional filter to return only alphanumeric sender IDs associated with the specified two-character ISO country code.
69
70
  # @param [Integer] limit Upper limit for the number of records to return. stream()
70
71
  # guarantees to never return more than limit. Default is no limit
71
72
  # @param [Integer] page_size Number of records to fetch per request, when
@@ -73,8 +74,9 @@ module Twilio
73
74
  # but a limit is defined, stream() will attempt to read the limit with the most
74
75
  # efficient page size, i.e. min(limit, 1000)
75
76
  # @return [Array] Array of up to limit results
76
- def list(limit: nil, page_size: nil)
77
+ def list(iso_country_code: :unset, limit: nil, page_size: nil)
77
78
  self.stream(
79
+ iso_country_code: iso_country_code,
78
80
  limit: limit,
79
81
  page_size: page_size
80
82
  ).entries
@@ -84,6 +86,7 @@ module Twilio
84
86
  # Streams Instance records from the API as an Enumerable.
85
87
  # This operation lazily loads records as efficiently as possible until the limit
86
88
  # is reached.
89
+ # @param [String] iso_country_code Optional filter to return only alphanumeric sender IDs associated with the specified two-character ISO country code.
87
90
  # @param [Integer] limit Upper limit for the number of records to return. stream()
88
91
  # guarantees to never return more than limit. Default is no limit
89
92
  # @param [Integer] page_size Number of records to fetch per request, when
@@ -91,10 +94,11 @@ module Twilio
91
94
  # but a limit is defined, stream() will attempt to read the limit with the most
92
95
  # efficient page size, i.e. min(limit, 1000)
93
96
  # @return [Enumerable] Enumerable that will yield up to limit results
94
- def stream(limit: nil, page_size: nil)
97
+ def stream(iso_country_code: :unset, limit: nil, page_size: nil)
95
98
  limits = @version.read_limits(limit, page_size)
96
99
 
97
100
  page = self.page(
101
+ iso_country_code: iso_country_code,
98
102
  page_size: limits[:page_size], )
99
103
 
100
104
  @version.stream(page, limit: limits[:limit], page_limit: limits[:page_limit])
@@ -117,12 +121,14 @@ module Twilio
117
121
  ##
118
122
  # Retrieve a single page of DestinationAlphaSenderInstance records from the API.
119
123
  # Request is executed immediately.
124
+ # @param [String] iso_country_code Optional filter to return only alphanumeric sender IDs associated with the specified two-character ISO country code.
120
125
  # @param [String] page_token PageToken provided by the API
121
126
  # @param [Integer] page_number Page Number, this value is simply for client state
122
127
  # @param [Integer] page_size Number of records to return, defaults to 50
123
128
  # @return [Page] Page of DestinationAlphaSenderInstance
124
- def page(page_token: :unset, page_number: :unset, page_size: :unset)
129
+ def page(iso_country_code: :unset, page_token: :unset, page_number: :unset, page_size: :unset)
125
130
  params = Twilio::Values.of({
131
+ 'IsoCountryCode' => iso_country_code,
126
132
  'PageToken' => page_token,
127
133
  'Page' => page_number,
128
134
  'PageSize' => page_size,
@@ -44,7 +44,7 @@ module Twilio
44
44
  # @param [ScanMessageContent] scan_message_content
45
45
  # @param [Boolean] fallback_to_long_code [OBSOLETE] Former feature used to fallback to long code sender after certain short code message failures.
46
46
  # @param [Boolean] area_code_geomatch Whether to enable [Area Code Geomatch](https://www.twilio.com/docs/messaging/services#area-code-geomatch) on the Service Instance.
47
- # @param [String] validity_period How long, in seconds, messages sent from the Service are valid. Can be an integer from `1` to `14,400`. Default value is `14,400`.
47
+ # @param [String] validity_period How long, in seconds, messages sent from the Service are valid. Can be an integer from `1` to `36,000`. Default value is `36,000`.
48
48
  # @param [Boolean] synchronous_validation Reserved.
49
49
  # @param [String] usecase A string that describes the scenario in which the Messaging Service will be used. Possible values are `notifications`, `marketing`, `verification`, `discussion`, `poll`, `undeclared`.
50
50
  # @param [Boolean] use_inbound_webhook_on_number A boolean value that indicates either the webhook url configured on the phone number will be used or `inbound_request_url`/`fallback_url` url will be called when a message is received from the phone number. If this field is enabled then the webhook url defined on the phone number will override the `inbound_request_url`/`fallback_url` defined for the Messaging Service.
@@ -264,7 +264,7 @@ module Twilio
264
264
  # @param [ScanMessageContent] scan_message_content
265
265
  # @param [Boolean] fallback_to_long_code [OBSOLETE] Former feature used to fallback to long code sender after certain short code message failures.
266
266
  # @param [Boolean] area_code_geomatch Whether to enable [Area Code Geomatch](https://www.twilio.com/docs/messaging/services#area-code-geomatch) on the Service Instance.
267
- # @param [String] validity_period How long, in seconds, messages sent from the Service are valid. Can be an integer from `1` to `14,400`. Default value is `14,400`.
267
+ # @param [String] validity_period How long, in seconds, messages sent from the Service are valid. Can be an integer from `1` to `36,000`. Default value is `36,000`.
268
268
  # @param [Boolean] synchronous_validation Reserved.
269
269
  # @param [String] usecase A string that describes the scenario in which the Messaging Service will be used. Possible values are `notifications`, `marketing`, `verification`, `discussion`, `poll`, `undeclared`.
270
270
  # @param [Boolean] use_inbound_webhook_on_number A boolean value that indicates either the webhook url configured on the phone number will be used or `inbound_request_url`/`fallback_url` url will be called when a message is received from the phone number. If this field is enabled then the webhook url defined on the phone number will override the `inbound_request_url`/`fallback_url` defined for the Messaging Service.
@@ -649,7 +649,7 @@ module Twilio
649
649
  end
650
650
 
651
651
  ##
652
- # @return [String] How long, in seconds, messages sent from the Service are valid. Can be an integer from `1` to `14,400`. Default value is `14,400`.
652
+ # @return [String] How long, in seconds, messages sent from the Service are valid. Can be an integer from `1` to `36,000`. Default value is `36,000`.
653
653
  def validity_period
654
654
  @properties['validity_period']
655
655
  end
@@ -714,7 +714,7 @@ module Twilio
714
714
  # @param [ScanMessageContent] scan_message_content
715
715
  # @param [Boolean] fallback_to_long_code [OBSOLETE] Former feature used to fallback to long code sender after certain short code message failures.
716
716
  # @param [Boolean] area_code_geomatch Whether to enable [Area Code Geomatch](https://www.twilio.com/docs/messaging/services#area-code-geomatch) on the Service Instance.
717
- # @param [String] validity_period How long, in seconds, messages sent from the Service are valid. Can be an integer from `1` to `14,400`. Default value is `14,400`.
717
+ # @param [String] validity_period How long, in seconds, messages sent from the Service are valid. Can be an integer from `1` to `36,000`. Default value is `36,000`.
718
718
  # @param [Boolean] synchronous_validation Reserved.
719
719
  # @param [String] usecase A string that describes the scenario in which the Messaging Service will be used. Possible values are `notifications`, `marketing`, `verification`, `discussion`, `poll`, `undeclared`.
720
720
  # @param [Boolean] use_inbound_webhook_on_number A boolean value that indicates either the webhook url configured on the phone number will be used or `inbound_request_url`/`fallback_url` url will be called when a message is received from the phone number. If this field is enabled then the webhook url defined on the phone number will override the `inbound_request_url`/`fallback_url` defined for the Messaging Service.
@@ -19,9 +19,43 @@ module Twilio
19
19
  class V2 < Version
20
20
  class ChannelsSenderList < ListResource
21
21
 
22
- class MessagingV2ChannelsSenderProfileEmails
23
- # @param [email]: [String] The email of the sender.
24
- # @param [label]: [String] The label of the sender.
22
+ class MessagingV2ChannelsSenderProfile
23
+ # @param [name]: [String] The name of the sender.
24
+ # @param [about]: [String] The about text of the sender.
25
+ # @param [address]: [String] The address of the sender.
26
+ # @param [description]: [String] The description of the sender.
27
+ # @param [emails]: [Hash] The emails of the sender.
28
+ # @param [logo_url]: [String] The logo URL of the sender.
29
+ # @param [vertical]: [String] The vertical of the sender. Allowed values are: - \"Automotive\" - \"Beauty, Spa and Salon\" - \"Clothing and Apparel\" - \"Education\" - \"Entertainment\" - \"Event Planning and Service\" - \"Finance and Banking\" - \"Food and Grocery\" - \"Public Service\" - \"Hotel and Lodging\" - \"Medical and Health\" - \"Non-profit\" - \"Professional Services\" - \"Shopping and Retail\" - \"Travel and Transportation\" - \"Restaurant\" - \"Other\"
30
+ # @param [websites]: [Hash] The websites of the sender.
31
+ attr_accessor :name, :about, :address, :description, :emails, :logo_url, :vertical, :websites
32
+ def initialize(payload)
33
+ @name = payload["name"]
34
+ @about = payload["about"]
35
+ @address = payload["address"]
36
+ @description = payload["description"]
37
+ @emails = payload["emails"]
38
+ @logo_url = payload["logo_url"]
39
+ @vertical = payload["vertical"]
40
+ @websites = payload["websites"]
41
+ end
42
+ def to_json(options = {})
43
+ {
44
+ "name": @name,
45
+ "about": @about,
46
+ "address": @address,
47
+ "description": @description,
48
+ "emails": @emails,
49
+ "logo_url": @logo_url,
50
+ "vertical": @vertical,
51
+ "websites": @websites,
52
+ }.to_json(options)
53
+ end
54
+ end
55
+
56
+ class MessagingV2ChannelsSenderProfileResponseEmails
57
+ # @param [email]: [String]
58
+ # @param [label]: [String]
25
59
  attr_accessor :email, :label
26
60
  def initialize(payload)
27
61
  @email = payload["email"]
@@ -35,18 +69,18 @@ module Twilio
35
69
  end
36
70
  end
37
71
 
38
- class MessagingV2ChannelsSenderProfileWebsites
39
- # @param [label]: [String] The label of the sender.
40
- # @param [website]: [String] The website of the sender.
41
- attr_accessor :label, :website
72
+ class MessagingV2ChannelsSenderProfileResponseWebsites
73
+ # @param [website]: [String]
74
+ # @param [label]: [String]
75
+ attr_accessor :website, :label
42
76
  def initialize(payload)
43
- @label = payload["label"]
44
77
  @website = payload["website"]
78
+ @label = payload["label"]
45
79
  end
46
80
  def to_json(options = {})
47
81
  {
48
- "label": @label,
49
82
  "website": @website,
83
+ "label": @label,
50
84
  }.to_json(options)
51
85
  end
52
86
  end
@@ -93,9 +127,43 @@ module Twilio
93
127
  end
94
128
 
95
129
 
96
- class MessagingV2ChannelsSenderProfileEmails
97
- # @param [email]: [String] The email of the sender.
98
- # @param [label]: [String] The label of the sender.
130
+ class MessagingV2ChannelsSenderProfile
131
+ # @param [name]: [String] The name of the sender.
132
+ # @param [about]: [String] The about text of the sender.
133
+ # @param [address]: [String] The address of the sender.
134
+ # @param [description]: [String] The description of the sender.
135
+ # @param [emails]: [Hash] The emails of the sender.
136
+ # @param [logo_url]: [String] The logo URL of the sender.
137
+ # @param [vertical]: [String] The vertical of the sender. Allowed values are: - \"Automotive\" - \"Beauty, Spa and Salon\" - \"Clothing and Apparel\" - \"Education\" - \"Entertainment\" - \"Event Planning and Service\" - \"Finance and Banking\" - \"Food and Grocery\" - \"Public Service\" - \"Hotel and Lodging\" - \"Medical and Health\" - \"Non-profit\" - \"Professional Services\" - \"Shopping and Retail\" - \"Travel and Transportation\" - \"Restaurant\" - \"Other\"
138
+ # @param [websites]: [Hash] The websites of the sender.
139
+ attr_accessor :name, :about, :address, :description, :emails, :logo_url, :vertical, :websites
140
+ def initialize(payload)
141
+ @name = payload["name"]
142
+ @about = payload["about"]
143
+ @address = payload["address"]
144
+ @description = payload["description"]
145
+ @emails = payload["emails"]
146
+ @logo_url = payload["logo_url"]
147
+ @vertical = payload["vertical"]
148
+ @websites = payload["websites"]
149
+ end
150
+ def to_json(options = {})
151
+ {
152
+ "name": @name,
153
+ "about": @about,
154
+ "address": @address,
155
+ "description": @description,
156
+ "emails": @emails,
157
+ "logo_url": @logo_url,
158
+ "vertical": @vertical,
159
+ "websites": @websites,
160
+ }.to_json(options)
161
+ end
162
+ end
163
+
164
+ class MessagingV2ChannelsSenderProfileResponseEmails
165
+ # @param [email]: [String]
166
+ # @param [label]: [String]
99
167
  attr_accessor :email, :label
100
168
  def initialize(payload)
101
169
  @email = payload["email"]
@@ -109,18 +177,18 @@ module Twilio
109
177
  end
110
178
  end
111
179
 
112
- class MessagingV2ChannelsSenderProfileWebsites
113
- # @param [label]: [String] The label of the sender.
114
- # @param [website]: [String] The website of the sender.
115
- attr_accessor :label, :website
180
+ class MessagingV2ChannelsSenderProfileResponseWebsites
181
+ # @param [website]: [String]
182
+ # @param [label]: [String]
183
+ attr_accessor :website, :label
116
184
  def initialize(payload)
117
- @label = payload["label"]
118
185
  @website = payload["website"]
186
+ @label = payload["label"]
119
187
  end
120
188
  def to_json(options = {})
121
189
  {
122
- "label": @label,
123
190
  "website": @website,
191
+ "label": @label,
124
192
  }.to_json(options)
125
193
  end
126
194
  end
@@ -485,7 +553,7 @@ module Twilio
485
553
  end
486
554
 
487
555
  ##
488
- # @return [MessagingV2ChannelsSenderProfile]
556
+ # @return [MessagingV2ChannelsSenderProfileResponse]
489
557
  def profile
490
558
  @properties['profile']
491
559
  end
@@ -220,19 +220,19 @@ module Twilio
220
220
  end
221
221
 
222
222
  ##
223
- # @return [Date] Target date to port the number. We cannot guarantee that this date will be honored by the other carriers, please work with Ops to get a confirmation of the firm order commitment (FOC) date. Expected format is ISO Local Date, example: ‘2011-12-03`. This date must be at least 7 days in the future for US ports and 10 days in the future for Japanese ports. (This value is only available for custom porting customers.)
223
+ # @return [Date] Target date to port the number. We cannot guarantee that this date will be honored by the other carriers, please work with Ops to get a confirmation of the firm order commitment (FOC) date. Expected format is ISO Local Date, example: ‘2011-12-03`. This date must be at least 7 days in the future for US ports and 10 days in the future for Japanese ports. We can't guarantee the exact date and time, as this depends on the losing carrier
224
224
  def target_port_in_date
225
225
  @properties['target_port_in_date']
226
226
  end
227
227
 
228
228
  ##
229
- # @return [String] The earliest time that the port should occur on the target port in date. Expected format is ISO Offset Time, example: ‘10:15:00-08:00'. (This value is only available for custom porting customers.)
229
+ # @return [String] The earliest time that the port should occur on the target port in date. Expected format is ISO Offset Time, example: ‘10:15:00-08:00'. We can't guarantee the exact date and time, as this depends on the losing carrier
230
230
  def target_port_in_time_range_start
231
231
  @properties['target_port_in_time_range_start']
232
232
  end
233
233
 
234
234
  ##
235
- # @return [String] The latest time that the port should occur on the target port in date. Expected format is ISO Offset Time, example: ‘10:15:00-08:00'. (This value is only available for custom porting customers.)
235
+ # @return [String] The latest time that the port should occur on the target port in date. Expected format is ISO Offset Time, example: ‘10:15:00-08:00'. We can't guarantee the exact date and time, as this depends on the losing carrier
236
236
  def target_port_in_time_range_end
237
237
  @properties['target_port_in_time_range_end']
238
238
  end
@@ -17,12 +17,12 @@ module Twilio
17
17
  module REST
18
18
  class Numbers < NumbersBase
19
19
  class V1 < Version
20
- class PortingWebhookConfigurationFetchList < ListResource
20
+ class WebhookList < ListResource
21
21
 
22
22
  ##
23
- # Initialize the PortingWebhookConfigurationFetchList
23
+ # Initialize the WebhookList
24
24
  # @param [Version] version Version that contains the resource
25
- # @return [PortingWebhookConfigurationFetchList] PortingWebhookConfigurationFetchList
25
+ # @return [WebhookList] WebhookList
26
26
  def initialize(version)
27
27
  super(version)
28
28
  # Path Solution
@@ -31,8 +31,8 @@ module Twilio
31
31
 
32
32
  end
33
33
  ##
34
- # Fetch the PortingWebhookConfigurationFetchInstance
35
- # @return [PortingWebhookConfigurationFetchInstance] Fetched PortingWebhookConfigurationFetchInstance
34
+ # Fetch the WebhookInstance
35
+ # @return [WebhookInstance] Fetched WebhookInstance
36
36
  def fetch
37
37
 
38
38
  headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', })
@@ -42,7 +42,7 @@ module Twilio
42
42
 
43
43
 
44
44
  payload = @version.fetch('GET', @uri, headers: headers)
45
- PortingWebhookConfigurationFetchInstance.new(
45
+ WebhookInstance.new(
46
46
  @version,
47
47
  payload,
48
48
  )
@@ -53,17 +53,17 @@ module Twilio
53
53
 
54
54
  # Provide a user friendly representation
55
55
  def to_s
56
- '#<Twilio.Numbers.V1.PortingWebhookConfigurationFetchList>'
56
+ '#<Twilio.Numbers.V1.WebhookList>'
57
57
  end
58
58
  end
59
59
 
60
- class PortingWebhookConfigurationFetchPage < Page
60
+ class WebhookPage < Page
61
61
  ##
62
- # Initialize the PortingWebhookConfigurationFetchPage
62
+ # Initialize the WebhookPage
63
63
  # @param [Version] version Version that contains the resource
64
64
  # @param [Response] response Response from the API
65
65
  # @param [Hash] solution Path solution for the resource
66
- # @return [PortingWebhookConfigurationFetchPage] PortingWebhookConfigurationFetchPage
66
+ # @return [WebhookPage] WebhookPage
67
67
  def initialize(version, response, solution)
68
68
  super(version, response)
69
69
 
@@ -72,29 +72,29 @@ module Twilio
72
72
  end
73
73
 
74
74
  ##
75
- # Build an instance of PortingWebhookConfigurationFetchInstance
75
+ # Build an instance of WebhookInstance
76
76
  # @param [Hash] payload Payload response from the API
77
- # @return [PortingWebhookConfigurationFetchInstance] PortingWebhookConfigurationFetchInstance
77
+ # @return [WebhookInstance] WebhookInstance
78
78
  def get_instance(payload)
79
- PortingWebhookConfigurationFetchInstance.new(@version, payload)
79
+ WebhookInstance.new(@version, payload)
80
80
  end
81
81
 
82
82
  ##
83
83
  # Provide a user friendly representation
84
84
  def to_s
85
- '<Twilio.Numbers.V1.PortingWebhookConfigurationFetchPage>'
85
+ '<Twilio.Numbers.V1.WebhookPage>'
86
86
  end
87
87
  end
88
- class PortingWebhookConfigurationFetchInstance < InstanceResource
88
+ class WebhookInstance < InstanceResource
89
89
  ##
90
- # Initialize the PortingWebhookConfigurationFetchInstance
90
+ # Initialize the WebhookInstance
91
91
  # @param [Version] version Version that contains the resource
92
92
  # @param [Hash] payload payload that contains response from Twilio
93
93
  # @param [String] account_sid The SID of the
94
- # {Account}[https://www.twilio.com/docs/iam/api/account] that created this PortingWebhookConfigurationFetch
94
+ # {Account}[https://www.twilio.com/docs/iam/api/account] that created this Webhook
95
95
  # resource.
96
96
  # @param [String] sid The SID of the Call resource to fetch.
97
- # @return [PortingWebhookConfigurationFetchInstance] PortingWebhookConfigurationFetchInstance
97
+ # @return [WebhookInstance] WebhookInstance
98
98
  def initialize(version, payload )
99
99
  super(version)
100
100
 
@@ -149,13 +149,13 @@ module Twilio
149
149
  ##
150
150
  # Provide a user friendly representation
151
151
  def to_s
152
- "<Twilio.Numbers.V1.PortingWebhookConfigurationFetchInstance>"
152
+ "<Twilio.Numbers.V1.WebhookInstance>"
153
153
  end
154
154
 
155
155
  ##
156
156
  # Provide a detailed, user friendly representation
157
157
  def inspect
158
- "<Twilio.Numbers.V1.PortingWebhookConfigurationFetchInstance>"
158
+ "<Twilio.Numbers.V1.WebhookInstance>"
159
159
  end
160
160
  end
161
161
 
@@ -28,8 +28,8 @@ module Twilio
28
28
  @porting_portabilities = nil
29
29
  @porting_webhook_configurations = nil
30
30
  @porting_webhook_configurations_delete = nil
31
- @porting_webhook_configuration_fetch = nil
32
31
  @signing_request_configurations = nil
32
+ @webhook = nil
33
33
  end
34
34
 
35
35
  ##
@@ -135,16 +135,16 @@ module Twilio
135
135
  end
136
136
  end
137
137
  ##
138
- # @return [Twilio::REST::Numbers::V1::PortingWebhookConfigurationFetchList]
139
- def porting_webhook_configuration_fetch
140
- @porting_webhook_configuration_fetch ||= PortingWebhookConfigurationFetchList.new self
141
- end
142
- ##
143
138
  # @return [Twilio::REST::Numbers::V1::SigningRequestConfigurationList]
144
139
  def signing_request_configurations
145
140
  @signing_request_configurations ||= SigningRequestConfigurationList.new self
146
141
  end
147
142
  ##
143
+ # @return [Twilio::REST::Numbers::V1::WebhookList]
144
+ def webhook
145
+ @webhook ||= WebhookList.new self
146
+ end
147
+ ##
148
148
  # Provide a user friendly representation
149
149
  def to_s
150
150
  '<Twilio::REST::Numbers::V1>';
@@ -188,7 +188,6 @@ module Twilio
188
188
 
189
189
  # Dependents
190
190
  @sessions = nil
191
- @short_codes = nil
192
191
  @phone_numbers = nil
193
192
  end
194
193
  ##
@@ -289,25 +288,6 @@ module Twilio
289
288
  @sessions
290
289
  end
291
290
  ##
292
- # Access the short_codes
293
- # @return [ShortCodeList]
294
- # @return [ShortCodeContext] if sid was passed.
295
- def short_codes(sid=:unset)
296
-
297
- raise ArgumentError, 'sid cannot be nil' if sid.nil?
298
-
299
- if sid != :unset
300
- return ShortCodeContext.new(@version, @solution[:sid],sid )
301
- end
302
-
303
- unless @short_codes
304
- @short_codes = ShortCodeList.new(
305
- @version, service_sid: @solution[:sid], )
306
- end
307
-
308
- @short_codes
309
- end
310
- ##
311
291
  # Access the phone_numbers
312
292
  # @return [PhoneNumberList]
313
293
  # @return [PhoneNumberContext] if sid was passed.
@@ -558,13 +538,6 @@ module Twilio
558
538
  context.sessions
559
539
  end
560
540
 
561
- ##
562
- # Access the short_codes
563
- # @return [short_codes] short_codes
564
- def short_codes
565
- context.short_codes
566
- end
567
-
568
541
  ##
569
542
  # Access the phone_numbers
570
543
  # @return [phone_numbers] phone_numbers
@@ -324,7 +324,7 @@ module Twilio
324
324
  end
325
325
 
326
326
  ##
327
- # @return [Level]
327
+ # @return [String] The log level.
328
328
  def level
329
329
  @properties['level']
330
330
  end
@@ -38,7 +38,7 @@ module Twilio
38
38
  # @param [String] priority The priority to assign the new task and override the default. When supplied, the new Task will have this priority unless it matches a Workflow Target with a Priority set. When not supplied, the new Task will have the priority of the matching Workflow Target. Value can be 0 to 2^31^ (2,147,483,647).
39
39
  # @param [String] task_channel When MultiTasking is enabled, specify the TaskChannel by passing either its `unique_name` or `sid`. Default value is `default`.
40
40
  # @param [String] workflow_sid The SID of the Workflow that you would like to handle routing for the new Task. If there is only one Workflow defined for the Workspace that you are posting the new task to, this parameter is optional.
41
- # @param [String] attributes A URL-encoded JSON string with the attributes of the new task. This value is passed to the Workflow's `assignment_callback_url` when the Task is assigned to a Worker. For example: `{ \\\"task_type\\\": \\\"call\\\", \\\"twilio_call_sid\\\": \\\"CAxxx\\\", \\\"customer_ticket_number\\\": \\\"12345\\\" }`.
41
+ # @param [String] attributes A JSON string with the attributes of the new task. This value is passed to the Workflow's `assignment_callback_url` when the Task is assigned to a Worker. For example: `{ \\\"task_type\\\": \\\"call\\\", \\\"twilio_call_sid\\\": \\\"CAxxx\\\", \\\"customer_ticket_number\\\": \\\"12345\\\" }`.
42
42
  # @param [Time] virtual_start_time The virtual start time to assign the new task and override the default. When supplied, the new task will have this virtual start time. When not supplied, the new task will have the virtual start time equal to `date_created`. Value can't be in the future or before the year of 1900.
43
43
  # @param [String] routing_target A SID of a Worker, Queue, or Workflow to route a Task to
44
44
  # @param [String] ignore_capacity A boolean that indicates if the Task should respect a Worker's capacity and availability during assignment. This field can only be used when the `RoutingTarget` field is set to a Worker SID. By setting `IgnoreCapacity` to a value of `true`, `1`, or `yes`, the Task will be routed to the Worker without respecting their capacity and availability. Any other value will enforce the Worker's capacity and availability. The default value of `IgnoreCapacity` is `true` when the `RoutingTarget` is set to a Worker SID.
@@ -427,6 +427,7 @@ module Twilio
427
427
  'transfer_caller_id' => payload['transfer_caller_id'],
428
428
  'cnam_lookup_enabled' => payload['cnam_lookup_enabled'],
429
429
  'auth_type' => payload['auth_type'],
430
+ 'symmetric_rtp_enabled' => payload['symmetric_rtp_enabled'],
430
431
  'auth_type_set' => payload['auth_type_set'],
431
432
  'date_created' => Twilio.deserialize_iso8601_datetime(payload['date_created']),
432
433
  'date_updated' => Twilio.deserialize_iso8601_datetime(payload['date_updated']),
@@ -517,6 +518,12 @@ module Twilio
517
518
  @properties['auth_type']
518
519
  end
519
520
 
521
+ ##
522
+ # @return [Boolean] Whether Symmetric RTP is enabled for the trunk. When Symmetric RTP is disabled, Twilio will send RTP to the destination negotiated in the SDP. Disabling Symmetric RTP is considered to be more secure and therefore recommended. See [Symmetric RTP](https://www.twilio.com/docs/sip-trunking#symmetric-rtp) for more information.
523
+ def symmetric_rtp_enabled
524
+ @properties['symmetric_rtp_enabled']
525
+ end
526
+
520
527
  ##
521
528
  # @return [Array<String>] Reserved.
522
529
  def auth_type_set
@@ -580,7 +580,7 @@ module Twilio
580
580
  end
581
581
 
582
582
  ##
583
- # @return [String] The name that appears in the body of your verification messages. It can be up to 30 characters long and can include letters, numbers, spaces, dashes, underscores. Phone numbers, special characters or links are NOT allowed. **This value should not contain PII.**
583
+ # @return [String] The name that appears in the body of your verification messages. It can be up to 30 characters long and can include letters, numbers, spaces, dashes, underscores. Phone numbers, special characters or links are NOT allowed. It cannot contain more than 4 (consecutive or non-consecutive) digits. **This value should not contain PII.**
584
584
  def friendly_name
585
585
  @properties['friendly_name']
586
586
  end