ultracart_api 3.11.15 → 3.11.17

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 (33) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +25 -7
  3. data/docs/CustomDashboard.md +11 -0
  4. data/docs/CustomDashboardPage.md +10 -0
  5. data/docs/CustomDashboardPageReport.md +12 -0
  6. data/docs/CustomDashboardResponse.md +12 -0
  7. data/docs/CustomDashboardsResponse.md +12 -0
  8. data/docs/CustomReportExecutionResponse.md +15 -0
  9. data/docs/CustomReportsExecutionReportData.md +10 -0
  10. data/docs/CustomReportsExecutionRequest.md +9 -0
  11. data/docs/CustomReportsExecutionResponse.md +13 -0
  12. data/docs/CustomReportsResponse.md +12 -0
  13. data/docs/DatawarehouseApi.md +351 -2
  14. data/docs/EmailWebhookEditorValuesResponse.md +1 -0
  15. data/docs/OrderApi.md +4 -75
  16. data/docs/WebhookApi.md +0 -16
  17. data/lib/ultracart_api/api/datawarehouse_api.rb +381 -3
  18. data/lib/ultracart_api/api/order_api.rb +4 -86
  19. data/lib/ultracart_api/api/webhook_api.rb +0 -24
  20. data/lib/ultracart_api/models/custom_dashboard.rb +213 -0
  21. data/lib/ultracart_api/models/custom_dashboard_page.rb +204 -0
  22. data/lib/ultracart_api/models/custom_dashboard_page_report.rb +220 -0
  23. data/lib/ultracart_api/models/custom_dashboard_response.rb +221 -0
  24. data/lib/ultracart_api/models/custom_dashboards_response.rb +224 -0
  25. data/lib/ultracart_api/models/custom_report_execution_response.rb +250 -0
  26. data/lib/ultracart_api/models/custom_reports_execution_report_data.rb +202 -0
  27. data/lib/ultracart_api/models/custom_reports_execution_request.rb +197 -0
  28. data/lib/ultracart_api/models/custom_reports_execution_response.rb +234 -0
  29. data/lib/ultracart_api/models/custom_reports_response.rb +224 -0
  30. data/lib/ultracart_api/models/email_webhook_editor_values_response.rb +12 -1
  31. data/lib/ultracart_api/version.rb +1 -1
  32. data/lib/ultracart_api.rb +10 -0
  33. metadata +22 -2
@@ -0,0 +1,224 @@
1
+ =begin
2
+ #UltraCart Rest API V2
3
+
4
+ #UltraCart REST API Version 2
5
+
6
+ OpenAPI spec version: 2.0.0
7
+ Contact: support@ultracart.com
8
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
9
+ Swagger Codegen version: 2.4.15-SNAPSHOT
10
+
11
+ =end
12
+
13
+ require 'date'
14
+
15
+ module UltracartClient
16
+ class CustomReportsResponse
17
+ attr_accessor :error
18
+
19
+ attr_accessor :metadata
20
+
21
+ # reports
22
+ attr_accessor :reports
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
+ :'error' => :'error',
33
+ :'metadata' => :'metadata',
34
+ :'reports' => :'reports',
35
+ :'success' => :'success',
36
+ :'warning' => :'warning'
37
+ }
38
+ end
39
+
40
+ # Attribute type mapping.
41
+ def self.swagger_types
42
+ {
43
+ :'error' => :'Error',
44
+ :'metadata' => :'ResponseMetadata',
45
+ :'reports' => :'Array<CustomReport>',
46
+ :'success' => :'BOOLEAN',
47
+ :'warning' => :'Warning'
48
+ }
49
+ end
50
+
51
+ # Initializes the object
52
+ # @param [Hash] attributes Model attributes in the form of hash
53
+ def initialize(attributes = {})
54
+ return unless attributes.is_a?(Hash)
55
+
56
+ # convert string to symbol for hash key
57
+ attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
58
+
59
+ if attributes.has_key?(:'error')
60
+ self.error = attributes[:'error']
61
+ end
62
+
63
+ if attributes.has_key?(:'metadata')
64
+ self.metadata = attributes[:'metadata']
65
+ end
66
+
67
+ if attributes.has_key?(:'reports')
68
+ if (value = attributes[:'reports']).is_a?(Array)
69
+ self.reports = value
70
+ end
71
+ end
72
+
73
+ if attributes.has_key?(:'success')
74
+ self.success = attributes[:'success']
75
+ end
76
+
77
+ if attributes.has_key?(:'warning')
78
+ self.warning = attributes[:'warning']
79
+ end
80
+ end
81
+
82
+ # Show invalid properties with the reasons. Usually used together with valid?
83
+ # @return Array for valid properties with the reasons
84
+ def list_invalid_properties
85
+ invalid_properties = Array.new
86
+ invalid_properties
87
+ end
88
+
89
+ # Check to see if the all the properties in the model are valid
90
+ # @return true if the model is valid
91
+ def valid?
92
+ true
93
+ end
94
+
95
+ # Checks equality by comparing each attribute.
96
+ # @param [Object] Object to be compared
97
+ def ==(o)
98
+ return true if self.equal?(o)
99
+ self.class == o.class &&
100
+ error == o.error &&
101
+ metadata == o.metadata &&
102
+ reports == o.reports &&
103
+ success == o.success &&
104
+ warning == o.warning
105
+ end
106
+
107
+ # @see the `==` method
108
+ # @param [Object] Object to be compared
109
+ def eql?(o)
110
+ self == o
111
+ end
112
+
113
+ # Calculates hash code according to all attributes.
114
+ # @return [Fixnum] Hash code
115
+ def hash
116
+ [error, metadata, reports, success, warning].hash
117
+ end
118
+
119
+ # Builds the object from hash
120
+ # @param [Hash] attributes Model attributes in the form of hash
121
+ # @return [Object] Returns the model itself
122
+ def build_from_hash(attributes)
123
+ return nil unless attributes.is_a?(Hash)
124
+ self.class.swagger_types.each_pair do |key, type|
125
+ if type =~ /\AArray<(.*)>/i
126
+ # check to ensure the input is an array given that the attribute
127
+ # is documented as an array but the input is not
128
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
129
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
130
+ end
131
+ elsif !attributes[self.class.attribute_map[key]].nil?
132
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
133
+ end # or else data not found in attributes(hash), not an issue as the data can be optional
134
+ end
135
+
136
+ self
137
+ end
138
+
139
+ # Deserializes the data based on type
140
+ # @param string type Data type
141
+ # @param string value Value to be deserialized
142
+ # @return [Object] Deserialized data
143
+ def _deserialize(type, value)
144
+ case type.to_sym
145
+ when :DateTime
146
+ DateTime.parse(value)
147
+ when :Date
148
+ Date.parse(value)
149
+ when :String
150
+ value.to_s
151
+ when :Integer
152
+ value.to_i
153
+ when :Float
154
+ value.to_f
155
+ when :BOOLEAN
156
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
157
+ true
158
+ else
159
+ false
160
+ end
161
+ when :Object
162
+ # generic object (usually a Hash), return directly
163
+ value
164
+ when /\AArray<(?<inner_type>.+)>\z/
165
+ inner_type = Regexp.last_match[:inner_type]
166
+ value.map { |v| _deserialize(inner_type, v) }
167
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
168
+ k_type = Regexp.last_match[:k_type]
169
+ v_type = Regexp.last_match[:v_type]
170
+ {}.tap do |hash|
171
+ value.each do |k, v|
172
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
173
+ end
174
+ end
175
+ else # model
176
+ temp_model = UltracartClient.const_get(type).new
177
+ temp_model.build_from_hash(value)
178
+ end
179
+ end
180
+
181
+ # Returns the string representation of the object
182
+ # @return [String] String presentation of the object
183
+ def to_s
184
+ to_hash.to_s
185
+ end
186
+
187
+ # to_body is an alias to to_hash (backward compatibility)
188
+ # @return [Hash] Returns the object in the form of hash
189
+ def to_body
190
+ to_hash
191
+ end
192
+
193
+ # Returns the object in the form of hash
194
+ # @return [Hash] Returns the object in the form of hash
195
+ def to_hash
196
+ hash = {}
197
+ self.class.attribute_map.each_pair do |attr, param|
198
+ value = self.send(attr)
199
+ next if value.nil?
200
+ hash[param] = _to_hash(value)
201
+ end
202
+ hash
203
+ end
204
+
205
+ # Outputs non-array value in the form of hash
206
+ # For object, use to_hash. Otherwise, just return the value
207
+ # @param [Object] value Any valid value
208
+ # @return [Hash] Returns the value in the form of hash
209
+ def _to_hash(value)
210
+ if value.is_a?(Array)
211
+ value.compact.map { |v| _to_hash(v) }
212
+ elsif value.is_a?(Hash)
213
+ {}.tap do |hash|
214
+ value.each { |k, v| hash[k] = _to_hash(v) }
215
+ end
216
+ elsif value.respond_to? :to_hash
217
+ value.to_hash
218
+ else
219
+ value
220
+ end
221
+ end
222
+
223
+ end
224
+ end
@@ -20,6 +20,8 @@ module UltracartClient
20
20
 
21
21
  attr_accessor :error
22
22
 
23
+ attr_accessor :loyalty_tiers
24
+
23
25
  attr_accessor :metadata
24
26
 
25
27
  attr_accessor :rest_object_type
@@ -35,6 +37,7 @@ module UltracartClient
35
37
  :'available_expansions' => :'available_expansions',
36
38
  :'available_tokens' => :'available_tokens',
37
39
  :'error' => :'error',
40
+ :'loyalty_tiers' => :'loyalty_tiers',
38
41
  :'metadata' => :'metadata',
39
42
  :'rest_object_type' => :'rest_object_type',
40
43
  :'success' => :'success',
@@ -48,6 +51,7 @@ module UltracartClient
48
51
  :'available_expansions' => :'Array<String>',
49
52
  :'available_tokens' => :'Array<String>',
50
53
  :'error' => :'Error',
54
+ :'loyalty_tiers' => :'Array<String>',
51
55
  :'metadata' => :'ResponseMetadata',
52
56
  :'rest_object_type' => :'String',
53
57
  :'success' => :'BOOLEAN',
@@ -79,6 +83,12 @@ module UltracartClient
79
83
  self.error = attributes[:'error']
80
84
  end
81
85
 
86
+ if attributes.has_key?(:'loyalty_tiers')
87
+ if (value = attributes[:'loyalty_tiers']).is_a?(Array)
88
+ self.loyalty_tiers = value
89
+ end
90
+ end
91
+
82
92
  if attributes.has_key?(:'metadata')
83
93
  self.metadata = attributes[:'metadata']
84
94
  end
@@ -117,6 +127,7 @@ module UltracartClient
117
127
  available_expansions == o.available_expansions &&
118
128
  available_tokens == o.available_tokens &&
119
129
  error == o.error &&
130
+ loyalty_tiers == o.loyalty_tiers &&
120
131
  metadata == o.metadata &&
121
132
  rest_object_type == o.rest_object_type &&
122
133
  success == o.success &&
@@ -132,7 +143,7 @@ module UltracartClient
132
143
  # Calculates hash code according to all attributes.
133
144
  # @return [Fixnum] Hash code
134
145
  def hash
135
- [available_expansions, available_tokens, error, metadata, rest_object_type, success, warning].hash
146
+ [available_expansions, available_tokens, error, loyalty_tiers, metadata, rest_object_type, success, warning].hash
136
147
  end
137
148
 
138
149
  # Builds the object from hash
@@ -11,5 +11,5 @@ Swagger Codegen version: 2.4.15-SNAPSHOT
11
11
  =end
12
12
 
13
13
  module UltracartClient
14
- VERSION = '3.11.15'
14
+ VERSION = '3.11.17'
15
15
  end
data/lib/ultracart_api.rb CHANGED
@@ -322,16 +322,26 @@ require 'ultracart_api/models/coupon_type'
322
322
  require 'ultracart_api/models/coupons_request'
323
323
  require 'ultracart_api/models/coupons_response'
324
324
  require 'ultracart_api/models/currency'
325
+ require 'ultracart_api/models/custom_dashboard'
326
+ require 'ultracart_api/models/custom_dashboard_page'
327
+ require 'ultracart_api/models/custom_dashboard_page_report'
328
+ require 'ultracart_api/models/custom_dashboard_response'
329
+ require 'ultracart_api/models/custom_dashboards_response'
325
330
  require 'ultracart_api/models/custom_report'
326
331
  require 'ultracart_api/models/custom_report_account_config'
327
332
  require 'ultracart_api/models/custom_report_account_config_response'
328
333
  require 'ultracart_api/models/custom_report_execution_parameter'
329
334
  require 'ultracart_api/models/custom_report_execution_request'
335
+ require 'ultracart_api/models/custom_report_execution_response'
330
336
  require 'ultracart_api/models/custom_report_parameter'
331
337
  require 'ultracart_api/models/custom_report_parameter_option'
332
338
  require 'ultracart_api/models/custom_report_query'
333
339
  require 'ultracart_api/models/custom_report_response'
334
340
  require 'ultracart_api/models/custom_report_tooltip'
341
+ require 'ultracart_api/models/custom_reports_execution_report_data'
342
+ require 'ultracart_api/models/custom_reports_execution_request'
343
+ require 'ultracart_api/models/custom_reports_execution_response'
344
+ require 'ultracart_api/models/custom_reports_response'
335
345
  require 'ultracart_api/models/customer'
336
346
  require 'ultracart_api/models/customer_activity'
337
347
  require 'ultracart_api/models/customer_affiliate'
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: 3.11.15
4
+ version: 3.11.17
5
5
  platform: ruby
6
6
  authors:
7
7
  - UltraCart
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2025-07-28 00:00:00.000000000 Z
11
+ date: 2025-08-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: typhoeus
@@ -533,16 +533,26 @@ files:
533
533
  - docs/CouponsRequest.md
534
534
  - docs/CouponsResponse.md
535
535
  - docs/Currency.md
536
+ - docs/CustomDashboard.md
537
+ - docs/CustomDashboardPage.md
538
+ - docs/CustomDashboardPageReport.md
539
+ - docs/CustomDashboardResponse.md
540
+ - docs/CustomDashboardsResponse.md
536
541
  - docs/CustomReport.md
537
542
  - docs/CustomReportAccountConfig.md
538
543
  - docs/CustomReportAccountConfigResponse.md
539
544
  - docs/CustomReportExecutionParameter.md
540
545
  - docs/CustomReportExecutionRequest.md
546
+ - docs/CustomReportExecutionResponse.md
541
547
  - docs/CustomReportParameter.md
542
548
  - docs/CustomReportParameterOption.md
543
549
  - docs/CustomReportQuery.md
544
550
  - docs/CustomReportResponse.md
545
551
  - docs/CustomReportTooltip.md
552
+ - docs/CustomReportsExecutionReportData.md
553
+ - docs/CustomReportsExecutionRequest.md
554
+ - docs/CustomReportsExecutionResponse.md
555
+ - docs/CustomReportsResponse.md
546
556
  - docs/Customer.md
547
557
  - docs/CustomerActivity.md
548
558
  - docs/CustomerAffiliate.md
@@ -1447,16 +1457,26 @@ files:
1447
1457
  - lib/ultracart_api/models/coupons_request.rb
1448
1458
  - lib/ultracart_api/models/coupons_response.rb
1449
1459
  - lib/ultracart_api/models/currency.rb
1460
+ - lib/ultracart_api/models/custom_dashboard.rb
1461
+ - lib/ultracart_api/models/custom_dashboard_page.rb
1462
+ - lib/ultracart_api/models/custom_dashboard_page_report.rb
1463
+ - lib/ultracart_api/models/custom_dashboard_response.rb
1464
+ - lib/ultracart_api/models/custom_dashboards_response.rb
1450
1465
  - lib/ultracart_api/models/custom_report.rb
1451
1466
  - lib/ultracart_api/models/custom_report_account_config.rb
1452
1467
  - lib/ultracart_api/models/custom_report_account_config_response.rb
1453
1468
  - lib/ultracart_api/models/custom_report_execution_parameter.rb
1454
1469
  - lib/ultracart_api/models/custom_report_execution_request.rb
1470
+ - lib/ultracart_api/models/custom_report_execution_response.rb
1455
1471
  - lib/ultracart_api/models/custom_report_parameter.rb
1456
1472
  - lib/ultracart_api/models/custom_report_parameter_option.rb
1457
1473
  - lib/ultracart_api/models/custom_report_query.rb
1458
1474
  - lib/ultracart_api/models/custom_report_response.rb
1459
1475
  - lib/ultracart_api/models/custom_report_tooltip.rb
1476
+ - lib/ultracart_api/models/custom_reports_execution_report_data.rb
1477
+ - lib/ultracart_api/models/custom_reports_execution_request.rb
1478
+ - lib/ultracart_api/models/custom_reports_execution_response.rb
1479
+ - lib/ultracart_api/models/custom_reports_response.rb
1460
1480
  - lib/ultracart_api/models/customer.rb
1461
1481
  - lib/ultracart_api/models/customer_activity.rb
1462
1482
  - lib/ultracart_api/models/customer_affiliate.rb