bandwidth-sdk 18.0.0 → 18.1.0

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 (82) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile.lock +4 -4
  3. data/README.md +28 -1
  4. data/bandwidth.yml +944 -19
  5. data/coverage/.last_run.json +1 -1
  6. data/coverage/.resultset.json +784 -152
  7. data/coverage/index.html +21650 -14800
  8. data/docs/BrtcError.md +26 -0
  9. data/docs/BrtcErrorResponse.md +22 -0
  10. data/docs/BrtcErrorSource.md +24 -0
  11. data/docs/BrtcLink.md +22 -0
  12. data/docs/CreateCall.md +2 -2
  13. data/docs/CreateEndpointRequestBase.md +26 -0
  14. data/docs/CreateEndpointResponse.md +22 -0
  15. data/docs/CreateEndpointResponseData.md +32 -0
  16. data/docs/CreateWebRtcConnectionRequest.md +28 -0
  17. data/docs/Device.md +24 -0
  18. data/docs/DeviceStatusEnum.md +15 -0
  19. data/docs/Endpoint.md +30 -0
  20. data/docs/EndpointDirectionEnum.md +15 -0
  21. data/docs/EndpointEvent.md +34 -0
  22. data/docs/EndpointEventTypeEnum.md +15 -0
  23. data/docs/EndpointResponse.md +22 -0
  24. data/docs/EndpointStatusEnum.md +15 -0
  25. data/docs/EndpointTypeEnum.md +15 -0
  26. data/docs/Endpoints.md +28 -0
  27. data/docs/EndpointsApi.md +395 -0
  28. data/docs/InboundCallback.md +2 -2
  29. data/docs/ListEndpointsResponse.md +24 -0
  30. data/docs/LookupResult.md +1 -1
  31. data/docs/MachineDetectionConfiguration.md +1 -1
  32. data/docs/MessageRequest.md +1 -1
  33. data/docs/Page.md +24 -0
  34. data/docs/RbmActionBase.md +1 -1
  35. data/docs/RbmSuggestionResponse.md +1 -1
  36. data/docs/SipConnectionMetadata.md +24 -0
  37. data/docs/SipCredentials.md +20 -0
  38. data/docs/StatusCallback.md +1 -1
  39. data/docs/SyncLookupRequest.md +3 -1
  40. data/docs/UpdateCall.md +1 -1
  41. data/docs/WebhookSubscriptionError.md +22 -0
  42. data/docs/WebhookSubscriptionsListBody.md +1 -1
  43. data/lib/bandwidth-sdk/api/endpoints_api.rb +397 -0
  44. data/lib/bandwidth-sdk/configuration.rb +30 -0
  45. data/lib/bandwidth-sdk/models/brtc_error.rb +219 -0
  46. data/lib/bandwidth-sdk/models/brtc_error_response.rb +204 -0
  47. data/lib/bandwidth-sdk/models/brtc_error_source.rb +176 -0
  48. data/lib/bandwidth-sdk/models/brtc_link.rb +166 -0
  49. data/lib/bandwidth-sdk/models/create_call.rb +7 -7
  50. data/lib/bandwidth-sdk/models/create_endpoint_request_base.rb +250 -0
  51. data/lib/bandwidth-sdk/models/create_endpoint_response.rb +218 -0
  52. data/lib/bandwidth-sdk/models/create_endpoint_response_data.rb +356 -0
  53. data/lib/bandwidth-sdk/models/create_web_rtc_connection_request.rb +266 -0
  54. data/lib/bandwidth-sdk/models/device.rb +258 -0
  55. data/lib/bandwidth-sdk/models/device_status_enum.rb +40 -0
  56. data/lib/bandwidth-sdk/models/endpoint.rb +329 -0
  57. data/lib/bandwidth-sdk/models/endpoint_direction_enum.rb +41 -0
  58. data/lib/bandwidth-sdk/models/endpoint_event.rb +381 -0
  59. data/lib/bandwidth-sdk/models/endpoint_event_type_enum.rb +40 -0
  60. data/lib/bandwidth-sdk/models/endpoint_response.rb +218 -0
  61. data/lib/bandwidth-sdk/models/endpoint_status_enum.rb +40 -0
  62. data/lib/bandwidth-sdk/models/endpoint_type_enum.rb +39 -0
  63. data/lib/bandwidth-sdk/models/endpoints.rb +311 -0
  64. data/lib/bandwidth-sdk/models/inbound_callback.rb +2 -2
  65. data/lib/bandwidth-sdk/models/list_endpoints_response.rb +229 -0
  66. data/lib/bandwidth-sdk/models/lookup_result.rb +1 -1
  67. data/lib/bandwidth-sdk/models/machine_detection_configuration.rb +1 -1
  68. data/lib/bandwidth-sdk/models/message_request.rb +1 -1
  69. data/lib/bandwidth-sdk/models/page.rb +259 -0
  70. data/lib/bandwidth-sdk/models/sip_connection_metadata.rb +175 -0
  71. data/lib/bandwidth-sdk/models/sip_credentials.rb +156 -0
  72. data/lib/bandwidth-sdk/models/status_callback.rb +1 -1
  73. data/lib/bandwidth-sdk/models/sync_lookup_request.rb +35 -4
  74. data/lib/bandwidth-sdk/models/update_call.rb +6 -6
  75. data/lib/bandwidth-sdk/models/webhook_subscription_error.rb +165 -0
  76. data/lib/bandwidth-sdk/models/webhook_subscriptions_list_body.rb +1 -1
  77. data/lib/bandwidth-sdk/version.rb +1 -1
  78. data/lib/bandwidth-sdk.rb +24 -1
  79. data/spec/smoke/endpoints_api_spec.rb +148 -0
  80. data/spec/unit/api/endpoints_api_spec.rb +172 -0
  81. data/spec/unit/api/phone_number_lookup_api_spec.rb +2 -0
  82. metadata +104 -52
@@ -0,0 +1,204 @@
1
+ =begin
2
+ #Bandwidth
3
+
4
+ #Bandwidth's Communication APIs
5
+
6
+ The version of the OpenAPI document: 1.0.0
7
+ Contact: letstalk@bandwidth.com
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.17.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module Bandwidth
17
+ class BrtcErrorResponse < ApiModelBase
18
+ attr_accessor :links
19
+
20
+ attr_accessor :data
21
+
22
+ attr_accessor :errors
23
+
24
+ # Attribute mapping from ruby-style variable name to JSON key.
25
+ def self.attribute_map
26
+ {
27
+ :'links' => :'links',
28
+ :'data' => :'data',
29
+ :'errors' => :'errors'
30
+ }
31
+ end
32
+
33
+ # Returns attribute mapping this model knows about
34
+ def self.acceptable_attribute_map
35
+ attribute_map
36
+ end
37
+
38
+ # Returns all the JSON keys this model knows about
39
+ def self.acceptable_attributes
40
+ acceptable_attribute_map.values
41
+ end
42
+
43
+ # Attribute type mapping.
44
+ def self.openapi_types
45
+ {
46
+ :'links' => :'Array<BrtcLink>',
47
+ :'data' => :'Object',
48
+ :'errors' => :'Array<BrtcError>'
49
+ }
50
+ end
51
+
52
+ # List of attributes with nullable: true
53
+ def self.openapi_nullable
54
+ Set.new([
55
+ :'data',
56
+ ])
57
+ end
58
+
59
+ # Initializes the object
60
+ # @param [Hash] attributes Model attributes in the form of hash
61
+ def initialize(attributes = {})
62
+ if (!attributes.is_a?(Hash))
63
+ fail ArgumentError, 'The input argument (attributes) must be a hash in `Bandwidth::BrtcErrorResponse` initialize method'
64
+ end
65
+
66
+ # check to see if the attribute exists and convert string to symbol for hash key
67
+ acceptable_attribute_map = self.class.acceptable_attribute_map
68
+ attributes = attributes.each_with_object({}) { |(k, v), h|
69
+ if (!acceptable_attribute_map.key?(k.to_sym))
70
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Bandwidth::BrtcErrorResponse`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
71
+ end
72
+ h[k.to_sym] = v
73
+ }
74
+
75
+ if attributes.key?(:'links')
76
+ if (value = attributes[:'links']).is_a?(Array)
77
+ self.links = value
78
+ end
79
+ else
80
+ self.links = nil
81
+ end
82
+
83
+ if attributes.key?(:'data')
84
+ self.data = attributes[:'data']
85
+ else
86
+ self.data = nil
87
+ end
88
+
89
+ if attributes.key?(:'errors')
90
+ if (value = attributes[:'errors']).is_a?(Array)
91
+ self.errors = value
92
+ end
93
+ else
94
+ self.errors = nil
95
+ end
96
+ end
97
+
98
+ # Show invalid properties with the reasons. Usually used together with valid?
99
+ # @return Array for valid properties with the reasons
100
+ def list_invalid_properties
101
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
102
+ invalid_properties = Array.new
103
+ if @links.nil?
104
+ invalid_properties.push('invalid value for "links", links cannot be nil.')
105
+ end
106
+
107
+ if @errors.nil?
108
+ invalid_properties.push('invalid value for "errors", errors cannot be nil.')
109
+ end
110
+
111
+ invalid_properties
112
+ end
113
+
114
+ # Check to see if the all the properties in the model are valid
115
+ # @return true if the model is valid
116
+ def valid?
117
+ warn '[DEPRECATED] the `valid?` method is obsolete'
118
+ return false if @links.nil?
119
+ return false if @errors.nil?
120
+ true
121
+ end
122
+
123
+ # Custom attribute writer method with validation
124
+ # @param [Object] links Value to be assigned
125
+ def links=(links)
126
+ if links.nil?
127
+ fail ArgumentError, 'links cannot be nil'
128
+ end
129
+
130
+ @links = links
131
+ end
132
+
133
+ # Custom attribute writer method with validation
134
+ # @param [Object] errors Value to be assigned
135
+ def errors=(errors)
136
+ if errors.nil?
137
+ fail ArgumentError, 'errors cannot be nil'
138
+ end
139
+
140
+ @errors = errors
141
+ end
142
+
143
+ # Checks equality by comparing each attribute.
144
+ # @param [Object] Object to be compared
145
+ def ==(o)
146
+ return true if self.equal?(o)
147
+ self.class == o.class &&
148
+ links == o.links &&
149
+ data == o.data &&
150
+ errors == o.errors
151
+ end
152
+
153
+ # @see the `==` method
154
+ # @param [Object] Object to be compared
155
+ def eql?(o)
156
+ self == o
157
+ end
158
+
159
+ # Calculates hash code according to all attributes.
160
+ # @return [Integer] Hash code
161
+ def hash
162
+ [links, data, errors].hash
163
+ end
164
+
165
+ # Builds the object from hash
166
+ # @param [Hash] attributes Model attributes in the form of hash
167
+ # @return [Object] Returns the model itself
168
+ def self.build_from_hash(attributes)
169
+ return nil unless attributes.is_a?(Hash)
170
+ attributes = attributes.transform_keys(&:to_sym)
171
+ transformed_hash = {}
172
+ openapi_types.each_pair do |key, type|
173
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
174
+ transformed_hash["#{key}"] = nil
175
+ elsif type =~ /\AArray<(.*)>/i
176
+ # check to ensure the input is an array given that the attribute
177
+ # is documented as an array but the input is not
178
+ if attributes[attribute_map[key]].is_a?(Array)
179
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
180
+ end
181
+ elsif !attributes[attribute_map[key]].nil?
182
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
183
+ end
184
+ end
185
+ new(transformed_hash)
186
+ end
187
+
188
+ # Returns the object in the form of hash
189
+ # @return [Hash] Returns the object in the form of hash
190
+ def to_hash
191
+ hash = {}
192
+ self.class.attribute_map.each_pair do |attr, param|
193
+ value = self.send(attr)
194
+ if value.nil?
195
+ is_nullable = self.class.openapi_nullable.include?(attr)
196
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
197
+ end
198
+
199
+ hash[param] = _to_hash(value)
200
+ end
201
+ hash
202
+ end
203
+ end
204
+ end
@@ -0,0 +1,176 @@
1
+ =begin
2
+ #Bandwidth
3
+
4
+ #Bandwidth's Communication APIs
5
+
6
+ The version of the OpenAPI document: 1.0.0
7
+ Contact: letstalk@bandwidth.com
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.17.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module Bandwidth
17
+ class BrtcErrorSource < ApiModelBase
18
+ # The URI parameter that caused the error.
19
+ attr_accessor :parameter
20
+
21
+ # The request body field that caused the error.
22
+ attr_accessor :field
23
+
24
+ # The header that caused the error.
25
+ attr_accessor :header
26
+
27
+ # The resource ID or path to the resource (or non-existent resource) causing the error.
28
+ attr_accessor :reference
29
+
30
+ # Attribute mapping from ruby-style variable name to JSON key.
31
+ def self.attribute_map
32
+ {
33
+ :'parameter' => :'parameter',
34
+ :'field' => :'field',
35
+ :'header' => :'header',
36
+ :'reference' => :'reference'
37
+ }
38
+ end
39
+
40
+ # Returns attribute mapping this model knows about
41
+ def self.acceptable_attribute_map
42
+ attribute_map
43
+ end
44
+
45
+ # Returns all the JSON keys this model knows about
46
+ def self.acceptable_attributes
47
+ acceptable_attribute_map.values
48
+ end
49
+
50
+ # Attribute type mapping.
51
+ def self.openapi_types
52
+ {
53
+ :'parameter' => :'String',
54
+ :'field' => :'String',
55
+ :'header' => :'String',
56
+ :'reference' => :'String'
57
+ }
58
+ end
59
+
60
+ # List of attributes with nullable: true
61
+ def self.openapi_nullable
62
+ Set.new([
63
+ ])
64
+ end
65
+
66
+ # Initializes the object
67
+ # @param [Hash] attributes Model attributes in the form of hash
68
+ def initialize(attributes = {})
69
+ if (!attributes.is_a?(Hash))
70
+ fail ArgumentError, 'The input argument (attributes) must be a hash in `Bandwidth::BrtcErrorSource` initialize method'
71
+ end
72
+
73
+ # check to see if the attribute exists and convert string to symbol for hash key
74
+ acceptable_attribute_map = self.class.acceptable_attribute_map
75
+ attributes = attributes.each_with_object({}) { |(k, v), h|
76
+ if (!acceptable_attribute_map.key?(k.to_sym))
77
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Bandwidth::BrtcErrorSource`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
78
+ end
79
+ h[k.to_sym] = v
80
+ }
81
+
82
+ if attributes.key?(:'parameter')
83
+ self.parameter = attributes[:'parameter']
84
+ end
85
+
86
+ if attributes.key?(:'field')
87
+ self.field = attributes[:'field']
88
+ end
89
+
90
+ if attributes.key?(:'header')
91
+ self.header = attributes[:'header']
92
+ end
93
+
94
+ if attributes.key?(:'reference')
95
+ self.reference = attributes[:'reference']
96
+ end
97
+ end
98
+
99
+ # Show invalid properties with the reasons. Usually used together with valid?
100
+ # @return Array for valid properties with the reasons
101
+ def list_invalid_properties
102
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
103
+ invalid_properties = Array.new
104
+ invalid_properties
105
+ end
106
+
107
+ # Check to see if the all the properties in the model are valid
108
+ # @return true if the model is valid
109
+ def valid?
110
+ warn '[DEPRECATED] the `valid?` method is obsolete'
111
+ true
112
+ end
113
+
114
+ # Checks equality by comparing each attribute.
115
+ # @param [Object] Object to be compared
116
+ def ==(o)
117
+ return true if self.equal?(o)
118
+ self.class == o.class &&
119
+ parameter == o.parameter &&
120
+ field == o.field &&
121
+ header == o.header &&
122
+ reference == o.reference
123
+ end
124
+
125
+ # @see the `==` method
126
+ # @param [Object] Object to be compared
127
+ def eql?(o)
128
+ self == o
129
+ end
130
+
131
+ # Calculates hash code according to all attributes.
132
+ # @return [Integer] Hash code
133
+ def hash
134
+ [parameter, field, header, reference].hash
135
+ end
136
+
137
+ # Builds the object from hash
138
+ # @param [Hash] attributes Model attributes in the form of hash
139
+ # @return [Object] Returns the model itself
140
+ def self.build_from_hash(attributes)
141
+ return nil unless attributes.is_a?(Hash)
142
+ attributes = attributes.transform_keys(&:to_sym)
143
+ transformed_hash = {}
144
+ openapi_types.each_pair do |key, type|
145
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
146
+ transformed_hash["#{key}"] = nil
147
+ elsif type =~ /\AArray<(.*)>/i
148
+ # check to ensure the input is an array given that the attribute
149
+ # is documented as an array but the input is not
150
+ if attributes[attribute_map[key]].is_a?(Array)
151
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
152
+ end
153
+ elsif !attributes[attribute_map[key]].nil?
154
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
155
+ end
156
+ end
157
+ new(transformed_hash)
158
+ end
159
+
160
+ # Returns the object in the form of hash
161
+ # @return [Hash] Returns the object in the form of hash
162
+ def to_hash
163
+ hash = {}
164
+ self.class.attribute_map.each_pair do |attr, param|
165
+ value = self.send(attr)
166
+ if value.nil?
167
+ is_nullable = self.class.openapi_nullable.include?(attr)
168
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
169
+ end
170
+
171
+ hash[param] = _to_hash(value)
172
+ end
173
+ hash
174
+ end
175
+ end
176
+ end
@@ -0,0 +1,166 @@
1
+ =begin
2
+ #Bandwidth
3
+
4
+ #Bandwidth's Communication APIs
5
+
6
+ The version of the OpenAPI document: 1.0.0
7
+ Contact: letstalk@bandwidth.com
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.17.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module Bandwidth
17
+ class BrtcLink < ApiModelBase
18
+ # The full URL of the link.
19
+ attr_accessor :href
20
+
21
+ # The relationship of the link to the current resource.
22
+ attr_accessor :rel
23
+
24
+ # The HTTP method to use when making the request.
25
+ attr_accessor :method
26
+
27
+ # Attribute mapping from ruby-style variable name to JSON key.
28
+ def self.attribute_map
29
+ {
30
+ :'href' => :'href',
31
+ :'rel' => :'rel',
32
+ :'method' => :'method'
33
+ }
34
+ end
35
+
36
+ # Returns attribute mapping this model knows about
37
+ def self.acceptable_attribute_map
38
+ attribute_map
39
+ end
40
+
41
+ # Returns all the JSON keys this model knows about
42
+ def self.acceptable_attributes
43
+ acceptable_attribute_map.values
44
+ end
45
+
46
+ # Attribute type mapping.
47
+ def self.openapi_types
48
+ {
49
+ :'href' => :'String',
50
+ :'rel' => :'String',
51
+ :'method' => :'String'
52
+ }
53
+ end
54
+
55
+ # List of attributes with nullable: true
56
+ def self.openapi_nullable
57
+ Set.new([
58
+ ])
59
+ end
60
+
61
+ # Initializes the object
62
+ # @param [Hash] attributes Model attributes in the form of hash
63
+ def initialize(attributes = {})
64
+ if (!attributes.is_a?(Hash))
65
+ fail ArgumentError, 'The input argument (attributes) must be a hash in `Bandwidth::BrtcLink` initialize method'
66
+ end
67
+
68
+ # check to see if the attribute exists and convert string to symbol for hash key
69
+ acceptable_attribute_map = self.class.acceptable_attribute_map
70
+ attributes = attributes.each_with_object({}) { |(k, v), h|
71
+ if (!acceptable_attribute_map.key?(k.to_sym))
72
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Bandwidth::BrtcLink`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
73
+ end
74
+ h[k.to_sym] = v
75
+ }
76
+
77
+ if attributes.key?(:'href')
78
+ self.href = attributes[:'href']
79
+ end
80
+
81
+ if attributes.key?(:'rel')
82
+ self.rel = attributes[:'rel']
83
+ end
84
+
85
+ if attributes.key?(:'method')
86
+ self.method = attributes[:'method']
87
+ end
88
+ end
89
+
90
+ # Show invalid properties with the reasons. Usually used together with valid?
91
+ # @return Array for valid properties with the reasons
92
+ def list_invalid_properties
93
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
94
+ invalid_properties = Array.new
95
+ invalid_properties
96
+ end
97
+
98
+ # Check to see if the all the properties in the model are valid
99
+ # @return true if the model is valid
100
+ def valid?
101
+ warn '[DEPRECATED] the `valid?` method is obsolete'
102
+ true
103
+ end
104
+
105
+ # Checks equality by comparing each attribute.
106
+ # @param [Object] Object to be compared
107
+ def ==(o)
108
+ return true if self.equal?(o)
109
+ self.class == o.class &&
110
+ href == o.href &&
111
+ rel == o.rel &&
112
+ method == o.method
113
+ end
114
+
115
+ # @see the `==` method
116
+ # @param [Object] Object to be compared
117
+ def eql?(o)
118
+ self == o
119
+ end
120
+
121
+ # Calculates hash code according to all attributes.
122
+ # @return [Integer] Hash code
123
+ def hash
124
+ [href, rel, method].hash
125
+ end
126
+
127
+ # Builds the object from hash
128
+ # @param [Hash] attributes Model attributes in the form of hash
129
+ # @return [Object] Returns the model itself
130
+ def self.build_from_hash(attributes)
131
+ return nil unless attributes.is_a?(Hash)
132
+ attributes = attributes.transform_keys(&:to_sym)
133
+ transformed_hash = {}
134
+ openapi_types.each_pair do |key, type|
135
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
136
+ transformed_hash["#{key}"] = nil
137
+ elsif type =~ /\AArray<(.*)>/i
138
+ # check to ensure the input is an array given that the attribute
139
+ # is documented as an array but the input is not
140
+ if attributes[attribute_map[key]].is_a?(Array)
141
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
142
+ end
143
+ elsif !attributes[attribute_map[key]].nil?
144
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
145
+ end
146
+ end
147
+ new(transformed_hash)
148
+ end
149
+
150
+ # Returns the object in the form of hash
151
+ # @return [Hash] Returns the object in the form of hash
152
+ def to_hash
153
+ hash = {}
154
+ self.class.attribute_map.each_pair do |attr, param|
155
+ value = self.send(attr)
156
+ if value.nil?
157
+ is_nullable = self.class.openapi_nullable.include?(attr)
158
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
159
+ end
160
+
161
+ hash[param] = _to_hash(value)
162
+ end
163
+ hash
164
+ end
165
+ end
166
+ end
@@ -24,7 +24,7 @@ module Bandwidth
24
24
  # Hide the calling number. The `displayName` field can be used to customize the displayed name.
25
25
  attr_accessor :privacy
26
26
 
27
- # The caller display name to use when the call is created. May not exceed 256 characters nor contain control characters such as new lines. If `privacy` is true, only the following values are valid: `Restricted`, `Anonymous`, `Private`, or `Unavailable`.
27
+ # The caller display name to use when the call is created. May not exceed 256 characters nor contain control characters such as new lines. If `privacy` is true, only the following values are valid: `Restricted`, `Anonymous`, `Private`, or `Unavailable`.
28
28
  attr_accessor :display_name
29
29
 
30
30
  # A comma-separated list of 'User-To-User' headers to be sent in the INVITE when calling a SIP URI. Each value must end with an 'encoding' parameter as described in <a href='https://tools.ietf.org/html/rfc7433'>RFC 7433</a>. Only 'jwt', 'base64' and 'hex' encodings are allowed. The entire value cannot exceed 350 characters, including parameters and separators.
@@ -71,7 +71,7 @@ module Bandwidth
71
71
  # The priority of this call over other calls from your account. For example, if during a call your application needs to place a new call and bridge it with the current call, you might want to create the call with priority 1 so that it will be the next call picked off your queue, ahead of other less time sensitive calls. A lower value means higher priority, so a priority 1 call takes precedence over a priority 2 call.
72
72
  attr_accessor :priority
73
73
 
74
- # A custom string that will be sent with all webhooks for this call unless overwritten by a future <a href='/docs/voice/bxml/tag'>`<Tag>`</a> verb or `tag` attribute on another verb, or cleared. May be cleared by setting `tag=\"\"` Max length 256 characters.
74
+ # A custom string that will be sent with all webhooks for this call unless overwritten by a future <a href='/docs/voice/bxml/tag'>`<Tag>`</a> verb or `tag` attribute on another verb, or cleared. May be cleared by setting `tag=\"\"` Max length 4096 characters.
75
75
  attr_accessor :tag
76
76
 
77
77
  class EnumAttributeValidator
@@ -380,8 +380,8 @@ module Bandwidth
380
380
  invalid_properties.push('invalid value for "priority", must be greater than or equal to 1.')
381
381
  end
382
382
 
383
- if !@tag.nil? && @tag.to_s.length > 256
384
- invalid_properties.push('invalid value for "tag", the character length must be smaller than or equal to 256.')
383
+ if !@tag.nil? && @tag.to_s.length > 4096
384
+ invalid_properties.push('invalid value for "tag", the character length must be smaller than or equal to 4096.')
385
385
  end
386
386
 
387
387
  invalid_properties
@@ -409,7 +409,7 @@ module Bandwidth
409
409
  return false if !@callback_timeout.nil? && @callback_timeout < 1
410
410
  return false if !@priority.nil? && @priority > 5
411
411
  return false if !@priority.nil? && @priority < 1
412
- return false if !@tag.nil? && @tag.to_s.length > 256
412
+ return false if !@tag.nil? && @tag.to_s.length > 4096
413
413
  true
414
414
  end
415
415
 
@@ -572,8 +572,8 @@ module Bandwidth
572
572
  # Custom attribute writer method with validation
573
573
  # @param [Object] tag Value to be assigned
574
574
  def tag=(tag)
575
- if !tag.nil? && tag.to_s.length > 256
576
- fail ArgumentError, 'invalid value for "tag", the character length must be smaller than or equal to 256.'
575
+ if !tag.nil? && tag.to_s.length > 4096
576
+ fail ArgumentError, 'invalid value for "tag", the character length must be smaller than or equal to 4096.'
577
577
  end
578
578
 
579
579
  @tag = tag