ultracart_api 4.1.100 → 4.1.102

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.
@@ -0,0 +1,277 @@
1
+ =begin
2
+ #UltraCart Rest API V2
3
+
4
+ #UltraCart REST API Version 2
5
+
6
+ The version of the OpenAPI document: 2.0.0
7
+ Contact: support@ultracart.com
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 6.0.1-SNAPSHOT
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module UltracartClient
17
+ class EmailCommseqEnrollmentResponse
18
+ # True if the customer was already enrolled and therefore not enrolled again
19
+ attr_accessor :already_enrolled
20
+
21
+ # True if the customer was newly enrolled into the sequence
22
+ attr_accessor :enrolled
23
+
24
+ attr_accessor :error
25
+
26
+ # The resolved ESP customer UUID for the enrolled email
27
+ attr_accessor :esp_customer_uuid
28
+
29
+ attr_accessor :metadata
30
+
31
+ # Indicates if API call was successful
32
+ attr_accessor :success
33
+
34
+ attr_accessor :warning
35
+
36
+ # Attribute mapping from ruby-style variable name to JSON key.
37
+ def self.attribute_map
38
+ {
39
+ :'already_enrolled' => :'already_enrolled',
40
+ :'enrolled' => :'enrolled',
41
+ :'error' => :'error',
42
+ :'esp_customer_uuid' => :'esp_customer_uuid',
43
+ :'metadata' => :'metadata',
44
+ :'success' => :'success',
45
+ :'warning' => :'warning'
46
+ }
47
+ end
48
+
49
+ # Returns all the JSON keys this model knows about
50
+ def self.acceptable_attributes
51
+ attribute_map.values
52
+ end
53
+
54
+ # Attribute type mapping.
55
+ def self.openapi_types
56
+ {
57
+ :'already_enrolled' => :'Boolean',
58
+ :'enrolled' => :'Boolean',
59
+ :'error' => :'Error',
60
+ :'esp_customer_uuid' => :'String',
61
+ :'metadata' => :'ResponseMetadata',
62
+ :'success' => :'Boolean',
63
+ :'warning' => :'Warning'
64
+ }
65
+ end
66
+
67
+ # List of attributes with nullable: true
68
+ def self.openapi_nullable
69
+ Set.new([
70
+ ])
71
+ end
72
+
73
+ # Initializes the object
74
+ # @param [Hash] attributes Model attributes in the form of hash
75
+ def initialize(attributes = {})
76
+ if (!attributes.is_a?(Hash))
77
+ fail ArgumentError, "The input argument (attributes) must be a hash in `UltracartClient::EmailCommseqEnrollmentResponse` initialize method"
78
+ end
79
+
80
+ # check to see if the attribute exists and convert string to symbol for hash key
81
+ attributes = attributes.each_with_object({}) { |(k, v), h|
82
+ if (!self.class.attribute_map.key?(k.to_sym))
83
+ fail ArgumentError, "`#{k}` is not a valid attribute in `UltracartClient::EmailCommseqEnrollmentResponse`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
84
+ end
85
+ h[k.to_sym] = v
86
+ }
87
+
88
+ if attributes.key?(:'already_enrolled')
89
+ self.already_enrolled = attributes[:'already_enrolled']
90
+ end
91
+
92
+ if attributes.key?(:'enrolled')
93
+ self.enrolled = attributes[:'enrolled']
94
+ end
95
+
96
+ if attributes.key?(:'error')
97
+ self.error = attributes[:'error']
98
+ end
99
+
100
+ if attributes.key?(:'esp_customer_uuid')
101
+ self.esp_customer_uuid = attributes[:'esp_customer_uuid']
102
+ end
103
+
104
+ if attributes.key?(:'metadata')
105
+ self.metadata = attributes[:'metadata']
106
+ end
107
+
108
+ if attributes.key?(:'success')
109
+ self.success = attributes[:'success']
110
+ end
111
+
112
+ if attributes.key?(:'warning')
113
+ self.warning = attributes[:'warning']
114
+ end
115
+ end
116
+
117
+ # Show invalid properties with the reasons. Usually used together with valid?
118
+ # @return Array for valid properties with the reasons
119
+ def list_invalid_properties
120
+ invalid_properties = Array.new
121
+ invalid_properties
122
+ end
123
+
124
+ # Check to see if the all the properties in the model are valid
125
+ # @return true if the model is valid
126
+ def valid?
127
+ true
128
+ end
129
+
130
+ # Checks equality by comparing each attribute.
131
+ # @param [Object] Object to be compared
132
+ def ==(o)
133
+ return true if self.equal?(o)
134
+ self.class == o.class &&
135
+ already_enrolled == o.already_enrolled &&
136
+ enrolled == o.enrolled &&
137
+ error == o.error &&
138
+ esp_customer_uuid == o.esp_customer_uuid &&
139
+ metadata == o.metadata &&
140
+ success == o.success &&
141
+ warning == o.warning
142
+ end
143
+
144
+ # @see the `==` method
145
+ # @param [Object] Object to be compared
146
+ def eql?(o)
147
+ self == o
148
+ end
149
+
150
+ # Calculates hash code according to all attributes.
151
+ # @return [Integer] Hash code
152
+ def hash
153
+ [already_enrolled, enrolled, error, esp_customer_uuid, metadata, success, warning].hash
154
+ end
155
+
156
+ # Builds the object from hash
157
+ # @param [Hash] attributes Model attributes in the form of hash
158
+ # @return [Object] Returns the model itself
159
+ def self.build_from_hash(attributes)
160
+ new.build_from_hash(attributes)
161
+ end
162
+
163
+ # Builds the object from hash
164
+ # @param [Hash] attributes Model attributes in the form of hash
165
+ # @return [Object] Returns the model itself
166
+ def build_from_hash(attributes)
167
+ return nil unless attributes.is_a?(Hash)
168
+ attributes = attributes.transform_keys(&:to_sym)
169
+ self.class.openapi_types.each_pair do |key, type|
170
+ if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
171
+ self.send("#{key}=", nil)
172
+ elsif type =~ /\AArray<(.*)>/i
173
+ # check to ensure the input is an array given that the attribute
174
+ # is documented as an array but the input is not
175
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
176
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
177
+ end
178
+ elsif !attributes[self.class.attribute_map[key]].nil?
179
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
180
+ end
181
+ end
182
+
183
+ self
184
+ end
185
+
186
+ # Deserializes the data based on type
187
+ # @param string type Data type
188
+ # @param string value Value to be deserialized
189
+ # @return [Object] Deserialized data
190
+ def _deserialize(type, value)
191
+ case type.to_sym
192
+ when :Time
193
+ Time.parse(value)
194
+ when :Date
195
+ Date.parse(value)
196
+ when :String
197
+ value.to_s
198
+ when :Integer
199
+ value.to_i
200
+ when :Float
201
+ value.to_f
202
+ when :Boolean
203
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
204
+ true
205
+ else
206
+ false
207
+ end
208
+ when :Object
209
+ # generic object (usually a Hash), return directly
210
+ value
211
+ when /\AArray<(?<inner_type>.+)>\z/
212
+ inner_type = Regexp.last_match[:inner_type]
213
+ value.map { |v| _deserialize(inner_type, v) }
214
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
215
+ k_type = Regexp.last_match[:k_type]
216
+ v_type = Regexp.last_match[:v_type]
217
+ {}.tap do |hash|
218
+ value.each do |k, v|
219
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
220
+ end
221
+ end
222
+ else # model
223
+ # models (e.g. Pet) or oneOf
224
+ klass = UltracartClient.const_get(type)
225
+ klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
226
+ end
227
+ end
228
+
229
+ # Returns the string representation of the object
230
+ # @return [String] String presentation of the object
231
+ def to_s
232
+ to_hash.to_s
233
+ end
234
+
235
+ # to_body is an alias to to_hash (backward compatibility)
236
+ # @return [Hash] Returns the object in the form of hash
237
+ def to_body
238
+ to_hash
239
+ end
240
+
241
+ # Returns the object in the form of hash
242
+ # @return [Hash] Returns the object in the form of hash
243
+ def to_hash
244
+ hash = {}
245
+ self.class.attribute_map.each_pair do |attr, param|
246
+ value = self.send(attr)
247
+ if value.nil?
248
+ is_nullable = self.class.openapi_nullable.include?(attr)
249
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
250
+ end
251
+
252
+ hash[param] = _to_hash(value)
253
+ end
254
+ hash
255
+ end
256
+
257
+ # Outputs non-array value in the form of hash
258
+ # For object, use to_hash. Otherwise, just return the value
259
+ # @param [Object] value Any valid value
260
+ # @return [Hash] Returns the value in the form of hash
261
+ def _to_hash(value)
262
+ if value.is_a?(Array)
263
+ value.compact.map { |v| _to_hash(v) }
264
+ elsif value.is_a?(Hash)
265
+ {}.tap do |hash|
266
+ value.each { |k, v| hash[k] = _to_hash(v) }
267
+ end
268
+ elsif value.respond_to? :to_hash
269
+ value.to_hash
270
+ else
271
+ value
272
+ end
273
+ end
274
+
275
+ end
276
+
277
+ end
@@ -270,6 +270,14 @@ module UltracartClient
270
270
  # @return Array for valid properties with the reasons
271
271
  def list_invalid_properties
272
272
  invalid_properties = Array.new
273
+ if !@merchant_comments.nil? && @merchant_comments.to_s.length > 2000
274
+ invalid_properties.push('invalid value for "merchant_comments", the character length must be smaller than or equal to 2000.')
275
+ end
276
+
277
+ if !@name.nil? && @name.to_s.length > 80
278
+ invalid_properties.push('invalid value for "name", the character length must be smaller than or equal to 80.')
279
+ end
280
+
273
281
  invalid_properties
274
282
  end
275
283
 
@@ -280,6 +288,8 @@ module UltracartClient
280
288
  return false unless api_version_validator.valid?(@api_version)
281
289
  authentication_type_validator = EnumAttributeValidator.new('String', ["none", "basic", "api user", "aws iam"])
282
290
  return false unless authentication_type_validator.valid?(@authentication_type)
291
+ return false if !@merchant_comments.nil? && @merchant_comments.to_s.length > 2000
292
+ return false if !@name.nil? && @name.to_s.length > 80
283
293
  true
284
294
  end
285
295
 
@@ -303,6 +313,26 @@ module UltracartClient
303
313
  @authentication_type = authentication_type
304
314
  end
305
315
 
316
+ # Custom attribute writer method with validation
317
+ # @param [Object] merchant_comments Value to be assigned
318
+ def merchant_comments=(merchant_comments)
319
+ if !merchant_comments.nil? && merchant_comments.to_s.length > 2000
320
+ fail ArgumentError, 'invalid value for "merchant_comments", the character length must be smaller than or equal to 2000.'
321
+ end
322
+
323
+ @merchant_comments = merchant_comments
324
+ end
325
+
326
+ # Custom attribute writer method with validation
327
+ # @param [Object] name Value to be assigned
328
+ def name=(name)
329
+ if !name.nil? && name.to_s.length > 80
330
+ fail ArgumentError, 'invalid value for "name", the character length must be smaller than or equal to 80.'
331
+ end
332
+
333
+ @name = name
334
+ end
335
+
306
336
  # Checks equality by comparing each attribute.
307
337
  # @param [Object] Object to be compared
308
338
  def ==(o)
@@ -11,5 +11,5 @@ OpenAPI Generator version: 6.0.1-SNAPSHOT
11
11
  =end
12
12
 
13
13
  module UltracartClient
14
- VERSION = '4.1.100'
14
+ VERSION = '4.1.102'
15
15
  end
data/lib/ultracart_api.rb CHANGED
@@ -258,6 +258,7 @@ require 'ultracart_api/models/conversation_pbx_call_timeline'
258
258
  require 'ultracart_api/models/conversation_pbx_call_transcript'
259
259
  require 'ultracart_api/models/conversation_pbx_call_transcript_segment'
260
260
  require 'ultracart_api/models/conversation_pbx_call_transfer'
261
+ require 'ultracart_api/models/conversation_pbx_call_update_request'
261
262
  require 'ultracart_api/models/conversation_pbx_class_of_service'
262
263
  require 'ultracart_api/models/conversation_pbx_class_of_service_response'
263
264
  require 'ultracart_api/models/conversation_pbx_class_of_services_response'
@@ -482,6 +483,8 @@ require 'ultracart_api/models/email_commseq_email_send_test_request'
482
483
  require 'ultracart_api/models/email_commseq_email_send_test_response'
483
484
  require 'ultracart_api/models/email_commseq_emails_request'
484
485
  require 'ultracart_api/models/email_commseq_emails_response'
486
+ require 'ultracart_api/models/email_commseq_enrollment_request'
487
+ require 'ultracart_api/models/email_commseq_enrollment_response'
485
488
  require 'ultracart_api/models/email_commseq_postcard'
486
489
  require 'ultracart_api/models/email_commseq_postcard_response'
487
490
  require 'ultracart_api/models/email_commseq_postcard_send_test_request'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ultracart_api
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.1.100
4
+ version: 4.1.102
5
5
  platform: ruby
6
6
  authors:
7
7
  - UltraCart
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2026-06-05 00:00:00.000000000 Z
11
+ date: 2026-06-17 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: typhoeus
@@ -308,6 +308,7 @@ files:
308
308
  - docs/ConversationPbxCallTranscript.md
309
309
  - docs/ConversationPbxCallTranscriptSegment.md
310
310
  - docs/ConversationPbxCallTransfer.md
311
+ - docs/ConversationPbxCallUpdateRequest.md
311
312
  - docs/ConversationPbxClassOfService.md
312
313
  - docs/ConversationPbxClassOfServiceResponse.md
313
314
  - docs/ConversationPbxClassOfServicesResponse.md
@@ -535,6 +536,8 @@ files:
535
536
  - docs/EmailCommseqEmailSendTestResponse.md
536
537
  - docs/EmailCommseqEmailsRequest.md
537
538
  - docs/EmailCommseqEmailsResponse.md
539
+ - docs/EmailCommseqEnrollmentRequest.md
540
+ - docs/EmailCommseqEnrollmentResponse.md
538
541
  - docs/EmailCommseqPostcard.md
539
542
  - docs/EmailCommseqPostcardResponse.md
540
543
  - docs/EmailCommseqPostcardSendTestRequest.md
@@ -1354,6 +1357,7 @@ files:
1354
1357
  - lib/ultracart_api/models/conversation_pbx_call_transcript.rb
1355
1358
  - lib/ultracart_api/models/conversation_pbx_call_transcript_segment.rb
1356
1359
  - lib/ultracart_api/models/conversation_pbx_call_transfer.rb
1360
+ - lib/ultracart_api/models/conversation_pbx_call_update_request.rb
1357
1361
  - lib/ultracart_api/models/conversation_pbx_class_of_service.rb
1358
1362
  - lib/ultracart_api/models/conversation_pbx_class_of_service_response.rb
1359
1363
  - lib/ultracart_api/models/conversation_pbx_class_of_services_response.rb
@@ -1578,6 +1582,8 @@ files:
1578
1582
  - lib/ultracart_api/models/email_commseq_email_send_test_response.rb
1579
1583
  - lib/ultracart_api/models/email_commseq_emails_request.rb
1580
1584
  - lib/ultracart_api/models/email_commseq_emails_response.rb
1585
+ - lib/ultracart_api/models/email_commseq_enrollment_request.rb
1586
+ - lib/ultracart_api/models/email_commseq_enrollment_response.rb
1581
1587
  - lib/ultracart_api/models/email_commseq_postcard.rb
1582
1588
  - lib/ultracart_api/models/email_commseq_postcard_response.rb
1583
1589
  - lib/ultracart_api/models/email_commseq_postcard_send_test_request.rb