ultracart_api 3.10.183 → 3.10.184
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 -4
- data/docs/EmailSmsOrder.md +11 -0
- data/docs/EmailSmsOrdersResponse.md +12 -0
- data/docs/EmailSmsStat.md +37 -0
- data/docs/EmailStatSmsSummaryRequest.md +9 -0
- data/docs/EmailStatSmsSummaryResponse.md +12 -0
- data/docs/PricingTier.md +1 -0
- data/docs/StorefrontApi.md +114 -0
- data/lib/ultracart_api/api/storefront_api.rb +133 -0
- data/lib/ultracart_api/models/email_sms_order.rb +214 -0
- data/lib/ultracart_api/models/email_sms_orders_response.rb +223 -0
- data/lib/ultracart_api/models/email_sms_stat.rb +476 -0
- data/lib/ultracart_api/models/email_stat_sms_summary_request.rb +195 -0
- data/lib/ultracart_api/models/email_stat_sms_summary_response.rb +223 -0
- data/lib/ultracart_api/models/pricing_tier.rb +11 -1
- data/lib/ultracart_api/version.rb +1 -1
- data/lib/ultracart_api.rb +5 -0
- metadata +12 -2
@@ -0,0 +1,223 @@
|
|
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 EmailStatSmsSummaryResponse
|
17
|
+
attr_accessor :error
|
18
|
+
|
19
|
+
attr_accessor :metadata
|
20
|
+
|
21
|
+
attr_accessor :stats
|
22
|
+
|
23
|
+
# Indicates if API call was successful
|
24
|
+
attr_accessor :success
|
25
|
+
|
26
|
+
attr_accessor :warning
|
27
|
+
|
28
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
29
|
+
def self.attribute_map
|
30
|
+
{
|
31
|
+
:'error' => :'error',
|
32
|
+
:'metadata' => :'metadata',
|
33
|
+
:'stats' => :'stats',
|
34
|
+
:'success' => :'success',
|
35
|
+
:'warning' => :'warning'
|
36
|
+
}
|
37
|
+
end
|
38
|
+
|
39
|
+
# Attribute type mapping.
|
40
|
+
def self.swagger_types
|
41
|
+
{
|
42
|
+
:'error' => :'Error',
|
43
|
+
:'metadata' => :'ResponseMetadata',
|
44
|
+
:'stats' => :'Array<EmailSmsStat>',
|
45
|
+
:'success' => :'BOOLEAN',
|
46
|
+
:'warning' => :'Warning'
|
47
|
+
}
|
48
|
+
end
|
49
|
+
|
50
|
+
# Initializes the object
|
51
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
52
|
+
def initialize(attributes = {})
|
53
|
+
return unless attributes.is_a?(Hash)
|
54
|
+
|
55
|
+
# convert string to symbol for hash key
|
56
|
+
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
57
|
+
|
58
|
+
if attributes.has_key?(:'error')
|
59
|
+
self.error = attributes[:'error']
|
60
|
+
end
|
61
|
+
|
62
|
+
if attributes.has_key?(:'metadata')
|
63
|
+
self.metadata = attributes[:'metadata']
|
64
|
+
end
|
65
|
+
|
66
|
+
if attributes.has_key?(:'stats')
|
67
|
+
if (value = attributes[:'stats']).is_a?(Array)
|
68
|
+
self.stats = value
|
69
|
+
end
|
70
|
+
end
|
71
|
+
|
72
|
+
if attributes.has_key?(:'success')
|
73
|
+
self.success = attributes[:'success']
|
74
|
+
end
|
75
|
+
|
76
|
+
if attributes.has_key?(:'warning')
|
77
|
+
self.warning = attributes[:'warning']
|
78
|
+
end
|
79
|
+
end
|
80
|
+
|
81
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
82
|
+
# @return Array for valid properties with the reasons
|
83
|
+
def list_invalid_properties
|
84
|
+
invalid_properties = Array.new
|
85
|
+
invalid_properties
|
86
|
+
end
|
87
|
+
|
88
|
+
# Check to see if the all the properties in the model are valid
|
89
|
+
# @return true if the model is valid
|
90
|
+
def valid?
|
91
|
+
true
|
92
|
+
end
|
93
|
+
|
94
|
+
# Checks equality by comparing each attribute.
|
95
|
+
# @param [Object] Object to be compared
|
96
|
+
def ==(o)
|
97
|
+
return true if self.equal?(o)
|
98
|
+
self.class == o.class &&
|
99
|
+
error == o.error &&
|
100
|
+
metadata == o.metadata &&
|
101
|
+
stats == o.stats &&
|
102
|
+
success == o.success &&
|
103
|
+
warning == o.warning
|
104
|
+
end
|
105
|
+
|
106
|
+
# @see the `==` method
|
107
|
+
# @param [Object] Object to be compared
|
108
|
+
def eql?(o)
|
109
|
+
self == o
|
110
|
+
end
|
111
|
+
|
112
|
+
# Calculates hash code according to all attributes.
|
113
|
+
# @return [Fixnum] Hash code
|
114
|
+
def hash
|
115
|
+
[error, metadata, stats, success, warning].hash
|
116
|
+
end
|
117
|
+
|
118
|
+
# Builds the object from hash
|
119
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
120
|
+
# @return [Object] Returns the model itself
|
121
|
+
def build_from_hash(attributes)
|
122
|
+
return nil unless attributes.is_a?(Hash)
|
123
|
+
self.class.swagger_types.each_pair do |key, type|
|
124
|
+
if type =~ /\AArray<(.*)>/i
|
125
|
+
# check to ensure the input is an array given that the attribute
|
126
|
+
# is documented as an array but the input is not
|
127
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
128
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
129
|
+
end
|
130
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
131
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
132
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
133
|
+
end
|
134
|
+
|
135
|
+
self
|
136
|
+
end
|
137
|
+
|
138
|
+
# Deserializes the data based on type
|
139
|
+
# @param string type Data type
|
140
|
+
# @param string value Value to be deserialized
|
141
|
+
# @return [Object] Deserialized data
|
142
|
+
def _deserialize(type, value)
|
143
|
+
case type.to_sym
|
144
|
+
when :DateTime
|
145
|
+
DateTime.parse(value)
|
146
|
+
when :Date
|
147
|
+
Date.parse(value)
|
148
|
+
when :String
|
149
|
+
value.to_s
|
150
|
+
when :Integer
|
151
|
+
value.to_i
|
152
|
+
when :Float
|
153
|
+
value.to_f
|
154
|
+
when :BOOLEAN
|
155
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
156
|
+
true
|
157
|
+
else
|
158
|
+
false
|
159
|
+
end
|
160
|
+
when :Object
|
161
|
+
# generic object (usually a Hash), return directly
|
162
|
+
value
|
163
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
164
|
+
inner_type = Regexp.last_match[:inner_type]
|
165
|
+
value.map { |v| _deserialize(inner_type, v) }
|
166
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
167
|
+
k_type = Regexp.last_match[:k_type]
|
168
|
+
v_type = Regexp.last_match[:v_type]
|
169
|
+
{}.tap do |hash|
|
170
|
+
value.each do |k, v|
|
171
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
172
|
+
end
|
173
|
+
end
|
174
|
+
else # model
|
175
|
+
temp_model = UltracartClient.const_get(type).new
|
176
|
+
temp_model.build_from_hash(value)
|
177
|
+
end
|
178
|
+
end
|
179
|
+
|
180
|
+
# Returns the string representation of the object
|
181
|
+
# @return [String] String presentation of the object
|
182
|
+
def to_s
|
183
|
+
to_hash.to_s
|
184
|
+
end
|
185
|
+
|
186
|
+
# to_body is an alias to to_hash (backward compatibility)
|
187
|
+
# @return [Hash] Returns the object in the form of hash
|
188
|
+
def to_body
|
189
|
+
to_hash
|
190
|
+
end
|
191
|
+
|
192
|
+
# Returns the object in the form of hash
|
193
|
+
# @return [Hash] Returns the object in the form of hash
|
194
|
+
def to_hash
|
195
|
+
hash = {}
|
196
|
+
self.class.attribute_map.each_pair do |attr, param|
|
197
|
+
value = self.send(attr)
|
198
|
+
next if value.nil?
|
199
|
+
hash[param] = _to_hash(value)
|
200
|
+
end
|
201
|
+
hash
|
202
|
+
end
|
203
|
+
|
204
|
+
# Outputs non-array value in the form of hash
|
205
|
+
# For object, use to_hash. Otherwise, just return the value
|
206
|
+
# @param [Object] value Any valid value
|
207
|
+
# @return [Hash] Returns the value in the form of hash
|
208
|
+
def _to_hash(value)
|
209
|
+
if value.is_a?(Array)
|
210
|
+
value.compact.map { |v| _to_hash(v) }
|
211
|
+
elsif value.is_a?(Hash)
|
212
|
+
{}.tap do |hash|
|
213
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
214
|
+
end
|
215
|
+
elsif value.respond_to? :to_hash
|
216
|
+
value.to_hash
|
217
|
+
else
|
218
|
+
value
|
219
|
+
end
|
220
|
+
end
|
221
|
+
|
222
|
+
end
|
223
|
+
end
|
@@ -34,6 +34,9 @@ module UltracartClient
|
|
34
34
|
# Auto approve purchase order
|
35
35
|
attr_accessor :auto_approve_purchase_order
|
36
36
|
|
37
|
+
# Any currency code specified on this pricing tier will force a shopping cart into that currency
|
38
|
+
attr_accessor :currency_code
|
39
|
+
|
37
40
|
# Default on wholesale signup
|
38
41
|
attr_accessor :default_on_wholesale_signup
|
39
42
|
|
@@ -121,6 +124,7 @@ module UltracartClient
|
|
121
124
|
:'approval_notification' => :'approval_notification',
|
122
125
|
:'auto_approve_cod' => :'auto_approve_cod',
|
123
126
|
:'auto_approve_purchase_order' => :'auto_approve_purchase_order',
|
127
|
+
:'currency_code' => :'currency_code',
|
124
128
|
:'default_on_wholesale_signup' => :'default_on_wholesale_signup',
|
125
129
|
:'default_percentage_discount' => :'default_percentage_discount',
|
126
130
|
:'default_shipping_method_oid' => :'default_shipping_method_oid',
|
@@ -160,6 +164,7 @@ module UltracartClient
|
|
160
164
|
:'approval_notification' => :'PricingTierNotification',
|
161
165
|
:'auto_approve_cod' => :'BOOLEAN',
|
162
166
|
:'auto_approve_purchase_order' => :'BOOLEAN',
|
167
|
+
:'currency_code' => :'String',
|
163
168
|
:'default_on_wholesale_signup' => :'BOOLEAN',
|
164
169
|
:'default_percentage_discount' => :'Float',
|
165
170
|
:'default_shipping_method_oid' => :'Integer',
|
@@ -225,6 +230,10 @@ module UltracartClient
|
|
225
230
|
self.auto_approve_purchase_order = attributes[:'auto_approve_purchase_order']
|
226
231
|
end
|
227
232
|
|
233
|
+
if attributes.has_key?(:'currency_code')
|
234
|
+
self.currency_code = attributes[:'currency_code']
|
235
|
+
end
|
236
|
+
|
228
237
|
if attributes.has_key?(:'default_on_wholesale_signup')
|
229
238
|
self.default_on_wholesale_signup = attributes[:'default_on_wholesale_signup']
|
230
239
|
end
|
@@ -370,6 +379,7 @@ module UltracartClient
|
|
370
379
|
approval_notification == o.approval_notification &&
|
371
380
|
auto_approve_cod == o.auto_approve_cod &&
|
372
381
|
auto_approve_purchase_order == o.auto_approve_purchase_order &&
|
382
|
+
currency_code == o.currency_code &&
|
373
383
|
default_on_wholesale_signup == o.default_on_wholesale_signup &&
|
374
384
|
default_percentage_discount == o.default_percentage_discount &&
|
375
385
|
default_shipping_method_oid == o.default_shipping_method_oid &&
|
@@ -407,7 +417,7 @@ module UltracartClient
|
|
407
417
|
# Calculates hash code according to all attributes.
|
408
418
|
# @return [Fixnum] Hash code
|
409
419
|
def hash
|
410
|
-
[allow_3rd_party_billing, allow_cod, allow_purchase_order, allow_quote_request, approval_notification, auto_approve_cod, auto_approve_purchase_order, default_on_wholesale_signup, default_percentage_discount, default_shipping_method_oid, default_tier, display_on_wholesale_signup, exclude_from_free_promotion, exempt_loyalty_rewards, exempt_shipping_handling_charge, free_shipping, free_shipping_minimum, maximum_item_count, minimum_item_count, minimum_subtotal, name, no_coupons, no_free_shipping, no_realtime_charge, not_valid_when_coupon_present, pricing_tier_oid, realtime_percentage_discount, restrict_to_distribution_center_oid, signup_notification, suppress_buysafe, suppress_mailing_list, tax_exempt, track_separately].hash
|
420
|
+
[allow_3rd_party_billing, allow_cod, allow_purchase_order, allow_quote_request, approval_notification, auto_approve_cod, auto_approve_purchase_order, currency_code, default_on_wholesale_signup, default_percentage_discount, default_shipping_method_oid, default_tier, display_on_wholesale_signup, exclude_from_free_promotion, exempt_loyalty_rewards, exempt_shipping_handling_charge, free_shipping, free_shipping_minimum, maximum_item_count, minimum_item_count, minimum_subtotal, name, no_coupons, no_free_shipping, no_realtime_charge, not_valid_when_coupon_present, pricing_tier_oid, realtime_percentage_discount, restrict_to_distribution_center_oid, signup_notification, suppress_buysafe, suppress_mailing_list, tax_exempt, track_separately].hash
|
411
421
|
end
|
412
422
|
|
413
423
|
# Builds the object from hash
|
data/lib/ultracart_api.rb
CHANGED
@@ -408,9 +408,14 @@ require 'ultracart_api/models/email_sending_domain_response'
|
|
408
408
|
require 'ultracart_api/models/email_sending_domains_response'
|
409
409
|
require 'ultracart_api/models/email_settings'
|
410
410
|
require 'ultracart_api/models/email_settings_response'
|
411
|
+
require 'ultracart_api/models/email_sms_order'
|
412
|
+
require 'ultracart_api/models/email_sms_orders_response'
|
413
|
+
require 'ultracart_api/models/email_sms_stat'
|
411
414
|
require 'ultracart_api/models/email_stat'
|
412
415
|
require 'ultracart_api/models/email_stat_postcard_summary_request'
|
413
416
|
require 'ultracart_api/models/email_stat_postcard_summary_response'
|
417
|
+
require 'ultracart_api/models/email_stat_sms_summary_request'
|
418
|
+
require 'ultracart_api/models/email_stat_sms_summary_response'
|
414
419
|
require 'ultracart_api/models/email_stat_summary_request'
|
415
420
|
require 'ultracart_api/models/email_stat_summary_response'
|
416
421
|
require 'ultracart_api/models/email_step_stat'
|
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.10.
|
4
|
+
version: 3.10.184
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- UltraCart
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-02-
|
11
|
+
date: 2024-02-27 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: typhoeus
|
@@ -621,9 +621,14 @@ files:
|
|
621
621
|
- docs/EmailSendingDomainsResponse.md
|
622
622
|
- docs/EmailSettings.md
|
623
623
|
- docs/EmailSettingsResponse.md
|
624
|
+
- docs/EmailSmsOrder.md
|
625
|
+
- docs/EmailSmsOrdersResponse.md
|
626
|
+
- docs/EmailSmsStat.md
|
624
627
|
- docs/EmailStat.md
|
625
628
|
- docs/EmailStatPostcardSummaryRequest.md
|
626
629
|
- docs/EmailStatPostcardSummaryResponse.md
|
630
|
+
- docs/EmailStatSmsSummaryRequest.md
|
631
|
+
- docs/EmailStatSmsSummaryResponse.md
|
627
632
|
- docs/EmailStatSummaryRequest.md
|
628
633
|
- docs/EmailStatSummaryResponse.md
|
629
634
|
- docs/EmailStepStat.md
|
@@ -1460,9 +1465,14 @@ files:
|
|
1460
1465
|
- lib/ultracart_api/models/email_sending_domains_response.rb
|
1461
1466
|
- lib/ultracart_api/models/email_settings.rb
|
1462
1467
|
- lib/ultracart_api/models/email_settings_response.rb
|
1468
|
+
- lib/ultracart_api/models/email_sms_order.rb
|
1469
|
+
- lib/ultracart_api/models/email_sms_orders_response.rb
|
1470
|
+
- lib/ultracart_api/models/email_sms_stat.rb
|
1463
1471
|
- lib/ultracart_api/models/email_stat.rb
|
1464
1472
|
- lib/ultracart_api/models/email_stat_postcard_summary_request.rb
|
1465
1473
|
- lib/ultracart_api/models/email_stat_postcard_summary_response.rb
|
1474
|
+
- lib/ultracart_api/models/email_stat_sms_summary_request.rb
|
1475
|
+
- lib/ultracart_api/models/email_stat_sms_summary_response.rb
|
1466
1476
|
- lib/ultracart_api/models/email_stat_summary_request.rb
|
1467
1477
|
- lib/ultracart_api/models/email_stat_summary_response.rb
|
1468
1478
|
- lib/ultracart_api/models/email_step_stat.rb
|