ultracart_api 4.1.110 → 4.1.111
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/README.md +12 -2
- data/docs/EmailCustomerLookupResponse.md +28 -0
- data/docs/EmailDispatchLog.md +26 -0
- data/docs/EmailDispatchLogDetail.md +32 -0
- data/docs/EmailDispatchLogDetailResponse.md +26 -0
- data/docs/EmailDispatchLogsResponse.md +32 -0
- data/docs/StorefrontApi.md +233 -0
- data/lib/ultracart_api/api/storefront_api.rb +322 -0
- data/lib/ultracart_api/models/email_customer_lookup_response.rb +267 -0
- data/lib/ultracart_api/models/email_dispatch_log.rb +260 -0
- data/lib/ultracart_api/models/email_dispatch_log_detail.rb +290 -0
- data/lib/ultracart_api/models/email_dispatch_log_detail_response.rb +256 -0
- data/lib/ultracart_api/models/email_dispatch_logs_response.rb +289 -0
- data/lib/ultracart_api/version.rb +1 -1
- data/lib/ultracart_api.rb +5 -0
- metadata +12 -2
|
@@ -0,0 +1,256 @@
|
|
|
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 EmailDispatchLogDetailResponse
|
|
18
|
+
attr_accessor :dispatch_log
|
|
19
|
+
|
|
20
|
+
attr_accessor :error
|
|
21
|
+
|
|
22
|
+
attr_accessor :metadata
|
|
23
|
+
|
|
24
|
+
# Indicates if API call was successful
|
|
25
|
+
attr_accessor :success
|
|
26
|
+
|
|
27
|
+
attr_accessor :warning
|
|
28
|
+
|
|
29
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
30
|
+
def self.attribute_map
|
|
31
|
+
{
|
|
32
|
+
:'dispatch_log' => :'dispatch_log',
|
|
33
|
+
:'error' => :'error',
|
|
34
|
+
:'metadata' => :'metadata',
|
|
35
|
+
:'success' => :'success',
|
|
36
|
+
:'warning' => :'warning'
|
|
37
|
+
}
|
|
38
|
+
end
|
|
39
|
+
|
|
40
|
+
# Returns all the JSON keys this model knows about
|
|
41
|
+
def self.acceptable_attributes
|
|
42
|
+
attribute_map.values
|
|
43
|
+
end
|
|
44
|
+
|
|
45
|
+
# Attribute type mapping.
|
|
46
|
+
def self.openapi_types
|
|
47
|
+
{
|
|
48
|
+
:'dispatch_log' => :'EmailDispatchLogDetail',
|
|
49
|
+
:'error' => :'Error',
|
|
50
|
+
:'metadata' => :'ResponseMetadata',
|
|
51
|
+
:'success' => :'Boolean',
|
|
52
|
+
:'warning' => :'Warning'
|
|
53
|
+
}
|
|
54
|
+
end
|
|
55
|
+
|
|
56
|
+
# List of attributes with nullable: true
|
|
57
|
+
def self.openapi_nullable
|
|
58
|
+
Set.new([
|
|
59
|
+
])
|
|
60
|
+
end
|
|
61
|
+
|
|
62
|
+
# Initializes the object
|
|
63
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
64
|
+
def initialize(attributes = {})
|
|
65
|
+
if (!attributes.is_a?(Hash))
|
|
66
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `UltracartClient::EmailDispatchLogDetailResponse` initialize method"
|
|
67
|
+
end
|
|
68
|
+
|
|
69
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
|
70
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
71
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
|
72
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `UltracartClient::EmailDispatchLogDetailResponse`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
|
73
|
+
end
|
|
74
|
+
h[k.to_sym] = v
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
if attributes.key?(:'dispatch_log')
|
|
78
|
+
self.dispatch_log = attributes[:'dispatch_log']
|
|
79
|
+
end
|
|
80
|
+
|
|
81
|
+
if attributes.key?(:'error')
|
|
82
|
+
self.error = attributes[:'error']
|
|
83
|
+
end
|
|
84
|
+
|
|
85
|
+
if attributes.key?(:'metadata')
|
|
86
|
+
self.metadata = attributes[:'metadata']
|
|
87
|
+
end
|
|
88
|
+
|
|
89
|
+
if attributes.key?(:'success')
|
|
90
|
+
self.success = attributes[:'success']
|
|
91
|
+
end
|
|
92
|
+
|
|
93
|
+
if attributes.key?(:'warning')
|
|
94
|
+
self.warning = attributes[:'warning']
|
|
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
|
+
invalid_properties = Array.new
|
|
102
|
+
invalid_properties
|
|
103
|
+
end
|
|
104
|
+
|
|
105
|
+
# Check to see if the all the properties in the model are valid
|
|
106
|
+
# @return true if the model is valid
|
|
107
|
+
def valid?
|
|
108
|
+
true
|
|
109
|
+
end
|
|
110
|
+
|
|
111
|
+
# Checks equality by comparing each attribute.
|
|
112
|
+
# @param [Object] Object to be compared
|
|
113
|
+
def ==(o)
|
|
114
|
+
return true if self.equal?(o)
|
|
115
|
+
self.class == o.class &&
|
|
116
|
+
dispatch_log == o.dispatch_log &&
|
|
117
|
+
error == o.error &&
|
|
118
|
+
metadata == o.metadata &&
|
|
119
|
+
success == o.success &&
|
|
120
|
+
warning == o.warning
|
|
121
|
+
end
|
|
122
|
+
|
|
123
|
+
# @see the `==` method
|
|
124
|
+
# @param [Object] Object to be compared
|
|
125
|
+
def eql?(o)
|
|
126
|
+
self == o
|
|
127
|
+
end
|
|
128
|
+
|
|
129
|
+
# Calculates hash code according to all attributes.
|
|
130
|
+
# @return [Integer] Hash code
|
|
131
|
+
def hash
|
|
132
|
+
[dispatch_log, error, metadata, success, warning].hash
|
|
133
|
+
end
|
|
134
|
+
|
|
135
|
+
# Builds the object from hash
|
|
136
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
137
|
+
# @return [Object] Returns the model itself
|
|
138
|
+
def self.build_from_hash(attributes)
|
|
139
|
+
new.build_from_hash(attributes)
|
|
140
|
+
end
|
|
141
|
+
|
|
142
|
+
# Builds the object from hash
|
|
143
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
144
|
+
# @return [Object] Returns the model itself
|
|
145
|
+
def build_from_hash(attributes)
|
|
146
|
+
return nil unless attributes.is_a?(Hash)
|
|
147
|
+
attributes = attributes.transform_keys(&:to_sym)
|
|
148
|
+
self.class.openapi_types.each_pair do |key, type|
|
|
149
|
+
if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
|
|
150
|
+
self.send("#{key}=", nil)
|
|
151
|
+
elsif type =~ /\AArray<(.*)>/i
|
|
152
|
+
# check to ensure the input is an array given that the attribute
|
|
153
|
+
# is documented as an array but the input is not
|
|
154
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
|
155
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
|
156
|
+
end
|
|
157
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
|
158
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
|
159
|
+
end
|
|
160
|
+
end
|
|
161
|
+
|
|
162
|
+
self
|
|
163
|
+
end
|
|
164
|
+
|
|
165
|
+
# Deserializes the data based on type
|
|
166
|
+
# @param string type Data type
|
|
167
|
+
# @param string value Value to be deserialized
|
|
168
|
+
# @return [Object] Deserialized data
|
|
169
|
+
def _deserialize(type, value)
|
|
170
|
+
case type.to_sym
|
|
171
|
+
when :Time
|
|
172
|
+
Time.parse(value)
|
|
173
|
+
when :Date
|
|
174
|
+
Date.parse(value)
|
|
175
|
+
when :String
|
|
176
|
+
value.to_s
|
|
177
|
+
when :Integer
|
|
178
|
+
value.to_i
|
|
179
|
+
when :Float
|
|
180
|
+
value.to_f
|
|
181
|
+
when :Boolean
|
|
182
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
|
183
|
+
true
|
|
184
|
+
else
|
|
185
|
+
false
|
|
186
|
+
end
|
|
187
|
+
when :Object
|
|
188
|
+
# generic object (usually a Hash), return directly
|
|
189
|
+
value
|
|
190
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
|
191
|
+
inner_type = Regexp.last_match[:inner_type]
|
|
192
|
+
value.map { |v| _deserialize(inner_type, v) }
|
|
193
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
|
194
|
+
k_type = Regexp.last_match[:k_type]
|
|
195
|
+
v_type = Regexp.last_match[:v_type]
|
|
196
|
+
{}.tap do |hash|
|
|
197
|
+
value.each do |k, v|
|
|
198
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
|
199
|
+
end
|
|
200
|
+
end
|
|
201
|
+
else # model
|
|
202
|
+
# models (e.g. Pet) or oneOf
|
|
203
|
+
klass = UltracartClient.const_get(type)
|
|
204
|
+
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
|
205
|
+
end
|
|
206
|
+
end
|
|
207
|
+
|
|
208
|
+
# Returns the string representation of the object
|
|
209
|
+
# @return [String] String presentation of the object
|
|
210
|
+
def to_s
|
|
211
|
+
to_hash.to_s
|
|
212
|
+
end
|
|
213
|
+
|
|
214
|
+
# to_body is an alias to to_hash (backward compatibility)
|
|
215
|
+
# @return [Hash] Returns the object in the form of hash
|
|
216
|
+
def to_body
|
|
217
|
+
to_hash
|
|
218
|
+
end
|
|
219
|
+
|
|
220
|
+
# Returns the object in the form of hash
|
|
221
|
+
# @return [Hash] Returns the object in the form of hash
|
|
222
|
+
def to_hash
|
|
223
|
+
hash = {}
|
|
224
|
+
self.class.attribute_map.each_pair do |attr, param|
|
|
225
|
+
value = self.send(attr)
|
|
226
|
+
if value.nil?
|
|
227
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
|
228
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
|
229
|
+
end
|
|
230
|
+
|
|
231
|
+
hash[param] = _to_hash(value)
|
|
232
|
+
end
|
|
233
|
+
hash
|
|
234
|
+
end
|
|
235
|
+
|
|
236
|
+
# Outputs non-array value in the form of hash
|
|
237
|
+
# For object, use to_hash. Otherwise, just return the value
|
|
238
|
+
# @param [Object] value Any valid value
|
|
239
|
+
# @return [Hash] Returns the value in the form of hash
|
|
240
|
+
def _to_hash(value)
|
|
241
|
+
if value.is_a?(Array)
|
|
242
|
+
value.compact.map { |v| _to_hash(v) }
|
|
243
|
+
elsif value.is_a?(Hash)
|
|
244
|
+
{}.tap do |hash|
|
|
245
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
|
246
|
+
end
|
|
247
|
+
elsif value.respond_to? :to_hash
|
|
248
|
+
value.to_hash
|
|
249
|
+
else
|
|
250
|
+
value
|
|
251
|
+
end
|
|
252
|
+
end
|
|
253
|
+
|
|
254
|
+
end
|
|
255
|
+
|
|
256
|
+
end
|
|
@@ -0,0 +1,289 @@
|
|
|
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 EmailDispatchLogsResponse
|
|
18
|
+
# Dispatch log rows on this page
|
|
19
|
+
attr_accessor :dispatch_logs
|
|
20
|
+
|
|
21
|
+
attr_accessor :error
|
|
22
|
+
|
|
23
|
+
attr_accessor :metadata
|
|
24
|
+
|
|
25
|
+
# True when another page exists after this one
|
|
26
|
+
attr_accessor :more
|
|
27
|
+
|
|
28
|
+
# Page number (one based)
|
|
29
|
+
attr_accessor :page_number
|
|
30
|
+
|
|
31
|
+
# Number of records per page
|
|
32
|
+
attr_accessor :page_size
|
|
33
|
+
|
|
34
|
+
# Indicates if API call was successful
|
|
35
|
+
attr_accessor :success
|
|
36
|
+
|
|
37
|
+
attr_accessor :warning
|
|
38
|
+
|
|
39
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
40
|
+
def self.attribute_map
|
|
41
|
+
{
|
|
42
|
+
:'dispatch_logs' => :'dispatch_logs',
|
|
43
|
+
:'error' => :'error',
|
|
44
|
+
:'metadata' => :'metadata',
|
|
45
|
+
:'more' => :'more',
|
|
46
|
+
:'page_number' => :'page_number',
|
|
47
|
+
:'page_size' => :'page_size',
|
|
48
|
+
:'success' => :'success',
|
|
49
|
+
:'warning' => :'warning'
|
|
50
|
+
}
|
|
51
|
+
end
|
|
52
|
+
|
|
53
|
+
# Returns all the JSON keys this model knows about
|
|
54
|
+
def self.acceptable_attributes
|
|
55
|
+
attribute_map.values
|
|
56
|
+
end
|
|
57
|
+
|
|
58
|
+
# Attribute type mapping.
|
|
59
|
+
def self.openapi_types
|
|
60
|
+
{
|
|
61
|
+
:'dispatch_logs' => :'Array<EmailDispatchLog>',
|
|
62
|
+
:'error' => :'Error',
|
|
63
|
+
:'metadata' => :'ResponseMetadata',
|
|
64
|
+
:'more' => :'Boolean',
|
|
65
|
+
:'page_number' => :'Integer',
|
|
66
|
+
:'page_size' => :'Integer',
|
|
67
|
+
:'success' => :'Boolean',
|
|
68
|
+
:'warning' => :'Warning'
|
|
69
|
+
}
|
|
70
|
+
end
|
|
71
|
+
|
|
72
|
+
# List of attributes with nullable: true
|
|
73
|
+
def self.openapi_nullable
|
|
74
|
+
Set.new([
|
|
75
|
+
])
|
|
76
|
+
end
|
|
77
|
+
|
|
78
|
+
# Initializes the object
|
|
79
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
80
|
+
def initialize(attributes = {})
|
|
81
|
+
if (!attributes.is_a?(Hash))
|
|
82
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `UltracartClient::EmailDispatchLogsResponse` initialize method"
|
|
83
|
+
end
|
|
84
|
+
|
|
85
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
|
86
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
87
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
|
88
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `UltracartClient::EmailDispatchLogsResponse`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
|
89
|
+
end
|
|
90
|
+
h[k.to_sym] = v
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
if attributes.key?(:'dispatch_logs')
|
|
94
|
+
if (value = attributes[:'dispatch_logs']).is_a?(Array)
|
|
95
|
+
self.dispatch_logs = value
|
|
96
|
+
end
|
|
97
|
+
end
|
|
98
|
+
|
|
99
|
+
if attributes.key?(:'error')
|
|
100
|
+
self.error = attributes[:'error']
|
|
101
|
+
end
|
|
102
|
+
|
|
103
|
+
if attributes.key?(:'metadata')
|
|
104
|
+
self.metadata = attributes[:'metadata']
|
|
105
|
+
end
|
|
106
|
+
|
|
107
|
+
if attributes.key?(:'more')
|
|
108
|
+
self.more = attributes[:'more']
|
|
109
|
+
end
|
|
110
|
+
|
|
111
|
+
if attributes.key?(:'page_number')
|
|
112
|
+
self.page_number = attributes[:'page_number']
|
|
113
|
+
end
|
|
114
|
+
|
|
115
|
+
if attributes.key?(:'page_size')
|
|
116
|
+
self.page_size = attributes[:'page_size']
|
|
117
|
+
end
|
|
118
|
+
|
|
119
|
+
if attributes.key?(:'success')
|
|
120
|
+
self.success = attributes[:'success']
|
|
121
|
+
end
|
|
122
|
+
|
|
123
|
+
if attributes.key?(:'warning')
|
|
124
|
+
self.warning = attributes[:'warning']
|
|
125
|
+
end
|
|
126
|
+
end
|
|
127
|
+
|
|
128
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
|
129
|
+
# @return Array for valid properties with the reasons
|
|
130
|
+
def list_invalid_properties
|
|
131
|
+
invalid_properties = Array.new
|
|
132
|
+
invalid_properties
|
|
133
|
+
end
|
|
134
|
+
|
|
135
|
+
# Check to see if the all the properties in the model are valid
|
|
136
|
+
# @return true if the model is valid
|
|
137
|
+
def valid?
|
|
138
|
+
true
|
|
139
|
+
end
|
|
140
|
+
|
|
141
|
+
# Checks equality by comparing each attribute.
|
|
142
|
+
# @param [Object] Object to be compared
|
|
143
|
+
def ==(o)
|
|
144
|
+
return true if self.equal?(o)
|
|
145
|
+
self.class == o.class &&
|
|
146
|
+
dispatch_logs == o.dispatch_logs &&
|
|
147
|
+
error == o.error &&
|
|
148
|
+
metadata == o.metadata &&
|
|
149
|
+
more == o.more &&
|
|
150
|
+
page_number == o.page_number &&
|
|
151
|
+
page_size == o.page_size &&
|
|
152
|
+
success == o.success &&
|
|
153
|
+
warning == o.warning
|
|
154
|
+
end
|
|
155
|
+
|
|
156
|
+
# @see the `==` method
|
|
157
|
+
# @param [Object] Object to be compared
|
|
158
|
+
def eql?(o)
|
|
159
|
+
self == o
|
|
160
|
+
end
|
|
161
|
+
|
|
162
|
+
# Calculates hash code according to all attributes.
|
|
163
|
+
# @return [Integer] Hash code
|
|
164
|
+
def hash
|
|
165
|
+
[dispatch_logs, error, metadata, more, page_number, page_size, success, warning].hash
|
|
166
|
+
end
|
|
167
|
+
|
|
168
|
+
# Builds the object from hash
|
|
169
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
170
|
+
# @return [Object] Returns the model itself
|
|
171
|
+
def self.build_from_hash(attributes)
|
|
172
|
+
new.build_from_hash(attributes)
|
|
173
|
+
end
|
|
174
|
+
|
|
175
|
+
# Builds the object from hash
|
|
176
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
177
|
+
# @return [Object] Returns the model itself
|
|
178
|
+
def build_from_hash(attributes)
|
|
179
|
+
return nil unless attributes.is_a?(Hash)
|
|
180
|
+
attributes = attributes.transform_keys(&:to_sym)
|
|
181
|
+
self.class.openapi_types.each_pair do |key, type|
|
|
182
|
+
if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
|
|
183
|
+
self.send("#{key}=", nil)
|
|
184
|
+
elsif type =~ /\AArray<(.*)>/i
|
|
185
|
+
# check to ensure the input is an array given that the attribute
|
|
186
|
+
# is documented as an array but the input is not
|
|
187
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
|
188
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
|
189
|
+
end
|
|
190
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
|
191
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
|
192
|
+
end
|
|
193
|
+
end
|
|
194
|
+
|
|
195
|
+
self
|
|
196
|
+
end
|
|
197
|
+
|
|
198
|
+
# Deserializes the data based on type
|
|
199
|
+
# @param string type Data type
|
|
200
|
+
# @param string value Value to be deserialized
|
|
201
|
+
# @return [Object] Deserialized data
|
|
202
|
+
def _deserialize(type, value)
|
|
203
|
+
case type.to_sym
|
|
204
|
+
when :Time
|
|
205
|
+
Time.parse(value)
|
|
206
|
+
when :Date
|
|
207
|
+
Date.parse(value)
|
|
208
|
+
when :String
|
|
209
|
+
value.to_s
|
|
210
|
+
when :Integer
|
|
211
|
+
value.to_i
|
|
212
|
+
when :Float
|
|
213
|
+
value.to_f
|
|
214
|
+
when :Boolean
|
|
215
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
|
216
|
+
true
|
|
217
|
+
else
|
|
218
|
+
false
|
|
219
|
+
end
|
|
220
|
+
when :Object
|
|
221
|
+
# generic object (usually a Hash), return directly
|
|
222
|
+
value
|
|
223
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
|
224
|
+
inner_type = Regexp.last_match[:inner_type]
|
|
225
|
+
value.map { |v| _deserialize(inner_type, v) }
|
|
226
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
|
227
|
+
k_type = Regexp.last_match[:k_type]
|
|
228
|
+
v_type = Regexp.last_match[:v_type]
|
|
229
|
+
{}.tap do |hash|
|
|
230
|
+
value.each do |k, v|
|
|
231
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
|
232
|
+
end
|
|
233
|
+
end
|
|
234
|
+
else # model
|
|
235
|
+
# models (e.g. Pet) or oneOf
|
|
236
|
+
klass = UltracartClient.const_get(type)
|
|
237
|
+
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
|
238
|
+
end
|
|
239
|
+
end
|
|
240
|
+
|
|
241
|
+
# Returns the string representation of the object
|
|
242
|
+
# @return [String] String presentation of the object
|
|
243
|
+
def to_s
|
|
244
|
+
to_hash.to_s
|
|
245
|
+
end
|
|
246
|
+
|
|
247
|
+
# to_body is an alias to to_hash (backward compatibility)
|
|
248
|
+
# @return [Hash] Returns the object in the form of hash
|
|
249
|
+
def to_body
|
|
250
|
+
to_hash
|
|
251
|
+
end
|
|
252
|
+
|
|
253
|
+
# Returns the object in the form of hash
|
|
254
|
+
# @return [Hash] Returns the object in the form of hash
|
|
255
|
+
def to_hash
|
|
256
|
+
hash = {}
|
|
257
|
+
self.class.attribute_map.each_pair do |attr, param|
|
|
258
|
+
value = self.send(attr)
|
|
259
|
+
if value.nil?
|
|
260
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
|
261
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
|
262
|
+
end
|
|
263
|
+
|
|
264
|
+
hash[param] = _to_hash(value)
|
|
265
|
+
end
|
|
266
|
+
hash
|
|
267
|
+
end
|
|
268
|
+
|
|
269
|
+
# Outputs non-array value in the form of hash
|
|
270
|
+
# For object, use to_hash. Otherwise, just return the value
|
|
271
|
+
# @param [Object] value Any valid value
|
|
272
|
+
# @return [Hash] Returns the value in the form of hash
|
|
273
|
+
def _to_hash(value)
|
|
274
|
+
if value.is_a?(Array)
|
|
275
|
+
value.compact.map { |v| _to_hash(v) }
|
|
276
|
+
elsif value.is_a?(Hash)
|
|
277
|
+
{}.tap do |hash|
|
|
278
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
|
279
|
+
end
|
|
280
|
+
elsif value.respond_to? :to_hash
|
|
281
|
+
value.to_hash
|
|
282
|
+
else
|
|
283
|
+
value
|
|
284
|
+
end
|
|
285
|
+
end
|
|
286
|
+
|
|
287
|
+
end
|
|
288
|
+
|
|
289
|
+
end
|
data/lib/ultracart_api.rb
CHANGED
|
@@ -520,10 +520,15 @@ require 'ultracart_api/models/email_commseq_webhook_send_test_response'
|
|
|
520
520
|
require 'ultracart_api/models/email_commseqs_response'
|
|
521
521
|
require 'ultracart_api/models/email_customer'
|
|
522
522
|
require 'ultracart_api/models/email_customer_editor_url_response'
|
|
523
|
+
require 'ultracart_api/models/email_customer_lookup_response'
|
|
523
524
|
require 'ultracart_api/models/email_customers_response'
|
|
524
525
|
require 'ultracart_api/models/email_dashboard_activity'
|
|
525
526
|
require 'ultracart_api/models/email_dashboard_activity_response'
|
|
526
527
|
require 'ultracart_api/models/email_dashboard_stats_response'
|
|
528
|
+
require 'ultracart_api/models/email_dispatch_log'
|
|
529
|
+
require 'ultracart_api/models/email_dispatch_log_detail'
|
|
530
|
+
require 'ultracart_api/models/email_dispatch_log_detail_response'
|
|
531
|
+
require 'ultracart_api/models/email_dispatch_logs_response'
|
|
527
532
|
require 'ultracart_api/models/email_domain'
|
|
528
533
|
require 'ultracart_api/models/email_editor_token_response'
|
|
529
534
|
require 'ultracart_api/models/email_editor_values_response'
|
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.
|
|
4
|
+
version: 4.1.111
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- UltraCart
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2026-07-
|
|
11
|
+
date: 2026-07-08 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: typhoeus
|
|
@@ -574,10 +574,15 @@ files:
|
|
|
574
574
|
- docs/EmailCommseqsResponse.md
|
|
575
575
|
- docs/EmailCustomer.md
|
|
576
576
|
- docs/EmailCustomerEditorUrlResponse.md
|
|
577
|
+
- docs/EmailCustomerLookupResponse.md
|
|
577
578
|
- docs/EmailCustomersResponse.md
|
|
578
579
|
- docs/EmailDashboardActivity.md
|
|
579
580
|
- docs/EmailDashboardActivityResponse.md
|
|
580
581
|
- docs/EmailDashboardStatsResponse.md
|
|
582
|
+
- docs/EmailDispatchLog.md
|
|
583
|
+
- docs/EmailDispatchLogDetail.md
|
|
584
|
+
- docs/EmailDispatchLogDetailResponse.md
|
|
585
|
+
- docs/EmailDispatchLogsResponse.md
|
|
581
586
|
- docs/EmailDomain.md
|
|
582
587
|
- docs/EmailEditorTokenResponse.md
|
|
583
588
|
- docs/EmailEditorValuesResponse.md
|
|
@@ -1636,10 +1641,15 @@ files:
|
|
|
1636
1641
|
- lib/ultracart_api/models/email_commseqs_response.rb
|
|
1637
1642
|
- lib/ultracart_api/models/email_customer.rb
|
|
1638
1643
|
- lib/ultracart_api/models/email_customer_editor_url_response.rb
|
|
1644
|
+
- lib/ultracart_api/models/email_customer_lookup_response.rb
|
|
1639
1645
|
- lib/ultracart_api/models/email_customers_response.rb
|
|
1640
1646
|
- lib/ultracart_api/models/email_dashboard_activity.rb
|
|
1641
1647
|
- lib/ultracart_api/models/email_dashboard_activity_response.rb
|
|
1642
1648
|
- lib/ultracart_api/models/email_dashboard_stats_response.rb
|
|
1649
|
+
- lib/ultracart_api/models/email_dispatch_log.rb
|
|
1650
|
+
- lib/ultracart_api/models/email_dispatch_log_detail.rb
|
|
1651
|
+
- lib/ultracart_api/models/email_dispatch_log_detail_response.rb
|
|
1652
|
+
- lib/ultracart_api/models/email_dispatch_logs_response.rb
|
|
1643
1653
|
- lib/ultracart_api/models/email_domain.rb
|
|
1644
1654
|
- lib/ultracart_api/models/email_editor_token_response.rb
|
|
1645
1655
|
- lib/ultracart_api/models/email_editor_values_response.rb
|