ultracart_api 4.0.112.rc → 4.0.114.rc
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 +7 -4
- data/docs/CartItem.md +2 -0
- data/docs/CartItemProperty.md +24 -0
- data/docs/PointOfSaleLocation.md +2 -0
- data/lib/ultracart_api/models/cart_item.rb +13 -1
- data/lib/ultracart_api/models/cart_item_property.rb +280 -0
- data/lib/ultracart_api/models/point_of_sale_location.rb +26 -1
- data/lib/ultracart_api/version.rb +1 -1
- data/lib/ultracart_api.rb +1 -0
- metadata +4 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2cbe969b1879e1447f4c5cc480455804560096da75aae25cef839717469265a9
|
4
|
+
data.tar.gz: 295b6db45dc49ccc9ad9cbb17d9bf916e6aba08e28b6f3288da670c2965aac4d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a0cc1fbf0b604a4d1a713197578c862ba515a9d8c962afd65be2baa015dc9a9f9e4be594a3b380c360094853967997ab9eb44e2c0cd0e76ec5d78ec869bf2c02
|
7
|
+
data.tar.gz: bf709a9c7d9852c039c9aac1f06bcfdf97aa56b80db729314f52407f7b9c03d29f62bdf20a30a12ab9246028a2a5bb05fe9771b5f79502a4792d521610f31502
|
data/README.md
CHANGED
@@ -7,7 +7,7 @@ UltraCart REST API Version 2
|
|
7
7
|
This SDK is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
|
8
8
|
|
9
9
|
- API version: 2.0.0
|
10
|
-
- Package version: 4.0.
|
10
|
+
- Package version: 4.0.114.rc
|
11
11
|
- Build package: org.openapitools.codegen.languages.RubyClientCodegen
|
12
12
|
For more information, please visit [http://www.ultracart.com](http://www.ultracart.com)
|
13
13
|
|
@@ -24,16 +24,16 @@ gem build ultracart_api.gemspec
|
|
24
24
|
Then either install the gem locally:
|
25
25
|
|
26
26
|
```shell
|
27
|
-
gem install ./ultracart_api-4.0.
|
27
|
+
gem install ./ultracart_api-4.0.114.rc.gem
|
28
28
|
```
|
29
29
|
|
30
|
-
(for development, run `gem install --dev ./ultracart_api-4.0.
|
30
|
+
(for development, run `gem install --dev ./ultracart_api-4.0.114.rc.gem` to install the development dependencies)
|
31
31
|
|
32
32
|
or publish the gem to a gem hosting service, e.g. [RubyGems](https://rubygems.org/).
|
33
33
|
|
34
34
|
Finally add this to the Gemfile:
|
35
35
|
|
36
|
-
gem 'ultracart_api', '~> 4.0.
|
36
|
+
gem 'ultracart_api', '~> 4.0.114.rc'
|
37
37
|
|
38
38
|
### Install from Git
|
39
39
|
|
@@ -553,6 +553,7 @@ Class | Method | HTTP request | Description
|
|
553
553
|
- [UltracartClient::CartItemOption](docs/CartItemOption.md)
|
554
554
|
- [UltracartClient::CartItemOptionValue](docs/CartItemOptionValue.md)
|
555
555
|
- [UltracartClient::CartItemPhysical](docs/CartItemPhysical.md)
|
556
|
+
- [UltracartClient::CartItemProperty](docs/CartItemProperty.md)
|
556
557
|
- [UltracartClient::CartItemVariationSelection](docs/CartItemVariationSelection.md)
|
557
558
|
- [UltracartClient::CartKitComponentOption](docs/CartKitComponentOption.md)
|
558
559
|
- [UltracartClient::CartMarketing](docs/CartMarketing.md)
|
@@ -1289,6 +1290,8 @@ Not every change is committed to every SDK.
|
|
1289
1290
|
|
1290
1291
|
| Version | Date | Comments |
|
1291
1292
|
| --: | :-: | --- |
|
1293
|
+
| 4.0.114-RC | 01/17/2023 | support for checkout item properties |
|
1294
|
+
| 4.0.113-RC | 01/14/2023 | add external_id to the point of sale location object |
|
1292
1295
|
| 4.0.112-RC | 01/13/2023 | channel - ops to manage ship to prefs |
|
1293
1296
|
| 4.0.111-RC | 01/11/2023 | conversations - adjust search results to return multiple convo summaries |
|
1294
1297
|
| 4.0.110-RC | 01/10/2023 | add method to query integration log record by oid |
|
data/docs/CartItem.md
CHANGED
@@ -24,6 +24,7 @@
|
|
24
24
|
| **phsyical** | [**CartItemPhysical**](CartItemPhysical.md) | | [optional] |
|
25
25
|
| **position** | **Integer** | Position of the item in the cart | [optional] |
|
26
26
|
| **preorder** | **Boolean** | True if this item is on pre-order | [optional] |
|
27
|
+
| **properties** | [**Array<CartItemProperty>**](CartItemProperty.md) | Properties associated with the item | [optional] |
|
27
28
|
| **quantity** | **Float** | quantity | [optional] |
|
28
29
|
| **schedules** | **Array<String>** | Customer selectable auto order schedules | [optional] |
|
29
30
|
| **total_cost** | [**Currency**](Currency.md) | | [optional] |
|
@@ -60,6 +61,7 @@ instance = UltracartClient::CartItem.new(
|
|
60
61
|
phsyical: null,
|
61
62
|
position: null,
|
62
63
|
preorder: null,
|
64
|
+
properties: null,
|
63
65
|
quantity: null,
|
64
66
|
schedules: null,
|
65
67
|
total_cost: null,
|
@@ -0,0 +1,24 @@
|
|
1
|
+
# UltracartClient::CartItemProperty
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **display** | **Boolean** | True if this property is displayed to the customer | [optional] |
|
8
|
+
| **expiration_dts** | **String** | The date/time that the property expires and is deleted | [optional] |
|
9
|
+
| **name** | **String** | Name | [optional] |
|
10
|
+
| **value** | **String** | Value | [optional] |
|
11
|
+
|
12
|
+
## Example
|
13
|
+
|
14
|
+
```ruby
|
15
|
+
require 'ultracart_api'
|
16
|
+
|
17
|
+
instance = UltracartClient::CartItemProperty.new(
|
18
|
+
display: null,
|
19
|
+
expiration_dts: null,
|
20
|
+
name: null,
|
21
|
+
value: null
|
22
|
+
)
|
23
|
+
```
|
24
|
+
|
data/docs/PointOfSaleLocation.md
CHANGED
@@ -9,6 +9,7 @@
|
|
9
9
|
| **city** | **String** | City | [optional] |
|
10
10
|
| **country** | **String** | Country | [optional] |
|
11
11
|
| **distribution_center_code** | **String** | The distribution center code where inventory is reduced from for this sale. | [optional] |
|
12
|
+
| **external_id** | **String** | External Id useful for syncing with a remote filesystem, this may be an MD5 hash or whatever suits your needs. | [optional] |
|
12
13
|
| **merchant_id** | **String** | Merchant ID that owns this location | [optional] |
|
13
14
|
| **pos_location_oid** | **Integer** | Object identifier of the point of sale location. | [optional] |
|
14
15
|
| **postal_code** | **String** | Postal code | [optional] |
|
@@ -25,6 +26,7 @@ instance = UltracartClient::PointOfSaleLocation.new(
|
|
25
26
|
city: null,
|
26
27
|
country: null,
|
27
28
|
distribution_center_code: null,
|
29
|
+
external_id: null,
|
28
30
|
merchant_id: null,
|
29
31
|
pos_location_oid: null,
|
30
32
|
postal_code: null,
|
@@ -71,6 +71,9 @@ module UltracartClient
|
|
71
71
|
# True if this item is on pre-order
|
72
72
|
attr_accessor :preorder
|
73
73
|
|
74
|
+
# Properties associated with the item
|
75
|
+
attr_accessor :properties
|
76
|
+
|
74
77
|
# quantity
|
75
78
|
attr_accessor :quantity
|
76
79
|
|
@@ -117,6 +120,7 @@ module UltracartClient
|
|
117
120
|
:'phsyical' => :'phsyical',
|
118
121
|
:'position' => :'position',
|
119
122
|
:'preorder' => :'preorder',
|
123
|
+
:'properties' => :'properties',
|
120
124
|
:'quantity' => :'quantity',
|
121
125
|
:'schedules' => :'schedules',
|
122
126
|
:'total_cost' => :'total_cost',
|
@@ -157,6 +161,7 @@ module UltracartClient
|
|
157
161
|
:'phsyical' => :'CartItemPhysical',
|
158
162
|
:'position' => :'Integer',
|
159
163
|
:'preorder' => :'Boolean',
|
164
|
+
:'properties' => :'Array<CartItemProperty>',
|
160
165
|
:'quantity' => :'Float',
|
161
166
|
:'schedules' => :'Array<String>',
|
162
167
|
:'total_cost' => :'Currency',
|
@@ -278,6 +283,12 @@ module UltracartClient
|
|
278
283
|
self.preorder = attributes[:'preorder']
|
279
284
|
end
|
280
285
|
|
286
|
+
if attributes.key?(:'properties')
|
287
|
+
if (value = attributes[:'properties']).is_a?(Array)
|
288
|
+
self.properties = value
|
289
|
+
end
|
290
|
+
end
|
291
|
+
|
281
292
|
if attributes.key?(:'quantity')
|
282
293
|
self.quantity = attributes[:'quantity']
|
283
294
|
end
|
@@ -357,6 +368,7 @@ module UltracartClient
|
|
357
368
|
phsyical == o.phsyical &&
|
358
369
|
position == o.position &&
|
359
370
|
preorder == o.preorder &&
|
371
|
+
properties == o.properties &&
|
360
372
|
quantity == o.quantity &&
|
361
373
|
schedules == o.schedules &&
|
362
374
|
total_cost == o.total_cost &&
|
@@ -377,7 +389,7 @@ module UltracartClient
|
|
377
389
|
# Calculates hash code according to all attributes.
|
378
390
|
# @return [Integer] Hash code
|
379
391
|
def hash
|
380
|
-
[arbitrary_unit_cost, attributes, auto_order_schedule, default_image_url, default_thumbnail_url, description, discount, extended_description, item_id, item_oid, kit, kit_component_options, manufacturer_suggested_retail_price, maximum_quantity, minimum_quantity, multimedia, options, phsyical, position, preorder, quantity, schedules, total_cost, total_cost_with_discount, unit_cost, unit_cost_with_discount, upsell, variations, view_url].hash
|
392
|
+
[arbitrary_unit_cost, attributes, auto_order_schedule, default_image_url, default_thumbnail_url, description, discount, extended_description, item_id, item_oid, kit, kit_component_options, manufacturer_suggested_retail_price, maximum_quantity, minimum_quantity, multimedia, options, phsyical, position, preorder, properties, quantity, schedules, total_cost, total_cost_with_discount, unit_cost, unit_cost_with_discount, upsell, variations, view_url].hash
|
381
393
|
end
|
382
394
|
|
383
395
|
# Builds the object from hash
|
@@ -0,0 +1,280 @@
|
|
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 CartItemProperty
|
18
|
+
# True if this property is displayed to the customer
|
19
|
+
attr_accessor :display
|
20
|
+
|
21
|
+
# The date/time that the property expires and is deleted
|
22
|
+
attr_accessor :expiration_dts
|
23
|
+
|
24
|
+
# Name
|
25
|
+
attr_accessor :name
|
26
|
+
|
27
|
+
# Value
|
28
|
+
attr_accessor :value
|
29
|
+
|
30
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
31
|
+
def self.attribute_map
|
32
|
+
{
|
33
|
+
:'display' => :'display',
|
34
|
+
:'expiration_dts' => :'expiration_dts',
|
35
|
+
:'name' => :'name',
|
36
|
+
:'value' => :'value'
|
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
|
+
:'display' => :'Boolean',
|
49
|
+
:'expiration_dts' => :'String',
|
50
|
+
:'name' => :'String',
|
51
|
+
:'value' => :'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 `UltracartClient::CartItemProperty` initialize method"
|
66
|
+
end
|
67
|
+
|
68
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
69
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
70
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
71
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `UltracartClient::CartItemProperty`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
72
|
+
end
|
73
|
+
h[k.to_sym] = v
|
74
|
+
}
|
75
|
+
|
76
|
+
if attributes.key?(:'display')
|
77
|
+
self.display = attributes[:'display']
|
78
|
+
end
|
79
|
+
|
80
|
+
if attributes.key?(:'expiration_dts')
|
81
|
+
self.expiration_dts = attributes[:'expiration_dts']
|
82
|
+
end
|
83
|
+
|
84
|
+
if attributes.key?(:'name')
|
85
|
+
self.name = attributes[:'name']
|
86
|
+
end
|
87
|
+
|
88
|
+
if attributes.key?(:'value')
|
89
|
+
self.value = attributes[:'value']
|
90
|
+
end
|
91
|
+
end
|
92
|
+
|
93
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
94
|
+
# @return Array for valid properties with the reasons
|
95
|
+
def list_invalid_properties
|
96
|
+
invalid_properties = Array.new
|
97
|
+
if !@name.nil? && @name.to_s.length > 100
|
98
|
+
invalid_properties.push('invalid value for "name", the character length must be smaller than or equal to 100.')
|
99
|
+
end
|
100
|
+
|
101
|
+
if !@value.nil? && @value.to_s.length > 3800
|
102
|
+
invalid_properties.push('invalid value for "value", the character length must be smaller than or equal to 3800.')
|
103
|
+
end
|
104
|
+
|
105
|
+
invalid_properties
|
106
|
+
end
|
107
|
+
|
108
|
+
# Check to see if the all the properties in the model are valid
|
109
|
+
# @return true if the model is valid
|
110
|
+
def valid?
|
111
|
+
return false if !@name.nil? && @name.to_s.length > 100
|
112
|
+
return false if !@value.nil? && @value.to_s.length > 3800
|
113
|
+
true
|
114
|
+
end
|
115
|
+
|
116
|
+
# Custom attribute writer method with validation
|
117
|
+
# @param [Object] name Value to be assigned
|
118
|
+
def name=(name)
|
119
|
+
if !name.nil? && name.to_s.length > 100
|
120
|
+
fail ArgumentError, 'invalid value for "name", the character length must be smaller than or equal to 100.'
|
121
|
+
end
|
122
|
+
|
123
|
+
@name = name
|
124
|
+
end
|
125
|
+
|
126
|
+
# Custom attribute writer method with validation
|
127
|
+
# @param [Object] value Value to be assigned
|
128
|
+
def value=(value)
|
129
|
+
if !value.nil? && value.to_s.length > 3800
|
130
|
+
fail ArgumentError, 'invalid value for "value", the character length must be smaller than or equal to 3800.'
|
131
|
+
end
|
132
|
+
|
133
|
+
@value = value
|
134
|
+
end
|
135
|
+
|
136
|
+
# Checks equality by comparing each attribute.
|
137
|
+
# @param [Object] Object to be compared
|
138
|
+
def ==(o)
|
139
|
+
return true if self.equal?(o)
|
140
|
+
self.class == o.class &&
|
141
|
+
display == o.display &&
|
142
|
+
expiration_dts == o.expiration_dts &&
|
143
|
+
name == o.name &&
|
144
|
+
value == o.value
|
145
|
+
end
|
146
|
+
|
147
|
+
# @see the `==` method
|
148
|
+
# @param [Object] Object to be compared
|
149
|
+
def eql?(o)
|
150
|
+
self == o
|
151
|
+
end
|
152
|
+
|
153
|
+
# Calculates hash code according to all attributes.
|
154
|
+
# @return [Integer] Hash code
|
155
|
+
def hash
|
156
|
+
[display, expiration_dts, name, value].hash
|
157
|
+
end
|
158
|
+
|
159
|
+
# Builds the object from hash
|
160
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
161
|
+
# @return [Object] Returns the model itself
|
162
|
+
def self.build_from_hash(attributes)
|
163
|
+
new.build_from_hash(attributes)
|
164
|
+
end
|
165
|
+
|
166
|
+
# Builds the object from hash
|
167
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
168
|
+
# @return [Object] Returns the model itself
|
169
|
+
def build_from_hash(attributes)
|
170
|
+
return nil unless attributes.is_a?(Hash)
|
171
|
+
attributes = attributes.transform_keys(&:to_sym)
|
172
|
+
self.class.openapi_types.each_pair do |key, type|
|
173
|
+
if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
|
174
|
+
self.send("#{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[self.class.attribute_map[key]].is_a?(Array)
|
179
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
180
|
+
end
|
181
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
182
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
183
|
+
end
|
184
|
+
end
|
185
|
+
|
186
|
+
self
|
187
|
+
end
|
188
|
+
|
189
|
+
# Deserializes the data based on type
|
190
|
+
# @param string type Data type
|
191
|
+
# @param string value Value to be deserialized
|
192
|
+
# @return [Object] Deserialized data
|
193
|
+
def _deserialize(type, value)
|
194
|
+
case type.to_sym
|
195
|
+
when :Time
|
196
|
+
Time.parse(value)
|
197
|
+
when :Date
|
198
|
+
Date.parse(value)
|
199
|
+
when :String
|
200
|
+
value.to_s
|
201
|
+
when :Integer
|
202
|
+
value.to_i
|
203
|
+
when :Float
|
204
|
+
value.to_f
|
205
|
+
when :Boolean
|
206
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
207
|
+
true
|
208
|
+
else
|
209
|
+
false
|
210
|
+
end
|
211
|
+
when :Object
|
212
|
+
# generic object (usually a Hash), return directly
|
213
|
+
value
|
214
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
215
|
+
inner_type = Regexp.last_match[:inner_type]
|
216
|
+
value.map { |v| _deserialize(inner_type, v) }
|
217
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
218
|
+
k_type = Regexp.last_match[:k_type]
|
219
|
+
v_type = Regexp.last_match[:v_type]
|
220
|
+
{}.tap do |hash|
|
221
|
+
value.each do |k, v|
|
222
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
223
|
+
end
|
224
|
+
end
|
225
|
+
else # model
|
226
|
+
# models (e.g. Pet) or oneOf
|
227
|
+
klass = UltracartClient.const_get(type)
|
228
|
+
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
229
|
+
end
|
230
|
+
end
|
231
|
+
|
232
|
+
# Returns the string representation of the object
|
233
|
+
# @return [String] String presentation of the object
|
234
|
+
def to_s
|
235
|
+
to_hash.to_s
|
236
|
+
end
|
237
|
+
|
238
|
+
# to_body is an alias to to_hash (backward compatibility)
|
239
|
+
# @return [Hash] Returns the object in the form of hash
|
240
|
+
def to_body
|
241
|
+
to_hash
|
242
|
+
end
|
243
|
+
|
244
|
+
# Returns the object in the form of hash
|
245
|
+
# @return [Hash] Returns the object in the form of hash
|
246
|
+
def to_hash
|
247
|
+
hash = {}
|
248
|
+
self.class.attribute_map.each_pair do |attr, param|
|
249
|
+
value = self.send(attr)
|
250
|
+
if value.nil?
|
251
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
252
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
253
|
+
end
|
254
|
+
|
255
|
+
hash[param] = _to_hash(value)
|
256
|
+
end
|
257
|
+
hash
|
258
|
+
end
|
259
|
+
|
260
|
+
# Outputs non-array value in the form of hash
|
261
|
+
# For object, use to_hash. Otherwise, just return the value
|
262
|
+
# @param [Object] value Any valid value
|
263
|
+
# @return [Hash] Returns the value in the form of hash
|
264
|
+
def _to_hash(value)
|
265
|
+
if value.is_a?(Array)
|
266
|
+
value.compact.map { |v| _to_hash(v) }
|
267
|
+
elsif value.is_a?(Hash)
|
268
|
+
{}.tap do |hash|
|
269
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
270
|
+
end
|
271
|
+
elsif value.respond_to? :to_hash
|
272
|
+
value.to_hash
|
273
|
+
else
|
274
|
+
value
|
275
|
+
end
|
276
|
+
end
|
277
|
+
|
278
|
+
end
|
279
|
+
|
280
|
+
end
|
@@ -30,6 +30,9 @@ module UltracartClient
|
|
30
30
|
# The distribution center code where inventory is reduced from for this sale.
|
31
31
|
attr_accessor :distribution_center_code
|
32
32
|
|
33
|
+
# External Id useful for syncing with a remote filesystem, this may be an MD5 hash or whatever suits your needs.
|
34
|
+
attr_accessor :external_id
|
35
|
+
|
33
36
|
# Merchant ID that owns this location
|
34
37
|
attr_accessor :merchant_id
|
35
38
|
|
@@ -50,6 +53,7 @@ module UltracartClient
|
|
50
53
|
:'city' => :'city',
|
51
54
|
:'country' => :'country',
|
52
55
|
:'distribution_center_code' => :'distribution_center_code',
|
56
|
+
:'external_id' => :'external_id',
|
53
57
|
:'merchant_id' => :'merchant_id',
|
54
58
|
:'pos_location_oid' => :'pos_location_oid',
|
55
59
|
:'postal_code' => :'postal_code',
|
@@ -70,6 +74,7 @@ module UltracartClient
|
|
70
74
|
:'city' => :'String',
|
71
75
|
:'country' => :'String',
|
72
76
|
:'distribution_center_code' => :'String',
|
77
|
+
:'external_id' => :'String',
|
73
78
|
:'merchant_id' => :'String',
|
74
79
|
:'pos_location_oid' => :'Integer',
|
75
80
|
:'postal_code' => :'String',
|
@@ -118,6 +123,10 @@ module UltracartClient
|
|
118
123
|
self.distribution_center_code = attributes[:'distribution_center_code']
|
119
124
|
end
|
120
125
|
|
126
|
+
if attributes.key?(:'external_id')
|
127
|
+
self.external_id = attributes[:'external_id']
|
128
|
+
end
|
129
|
+
|
121
130
|
if attributes.key?(:'merchant_id')
|
122
131
|
self.merchant_id = attributes[:'merchant_id']
|
123
132
|
end
|
@@ -139,15 +148,30 @@ module UltracartClient
|
|
139
148
|
# @return Array for valid properties with the reasons
|
140
149
|
def list_invalid_properties
|
141
150
|
invalid_properties = Array.new
|
151
|
+
if !@external_id.nil? && @external_id.to_s.length > 100
|
152
|
+
invalid_properties.push('invalid value for "external_id", the character length must be smaller than or equal to 100.')
|
153
|
+
end
|
154
|
+
|
142
155
|
invalid_properties
|
143
156
|
end
|
144
157
|
|
145
158
|
# Check to see if the all the properties in the model are valid
|
146
159
|
# @return true if the model is valid
|
147
160
|
def valid?
|
161
|
+
return false if !@external_id.nil? && @external_id.to_s.length > 100
|
148
162
|
true
|
149
163
|
end
|
150
164
|
|
165
|
+
# Custom attribute writer method with validation
|
166
|
+
# @param [Object] external_id Value to be assigned
|
167
|
+
def external_id=(external_id)
|
168
|
+
if !external_id.nil? && external_id.to_s.length > 100
|
169
|
+
fail ArgumentError, 'invalid value for "external_id", the character length must be smaller than or equal to 100.'
|
170
|
+
end
|
171
|
+
|
172
|
+
@external_id = external_id
|
173
|
+
end
|
174
|
+
|
151
175
|
# Checks equality by comparing each attribute.
|
152
176
|
# @param [Object] Object to be compared
|
153
177
|
def ==(o)
|
@@ -158,6 +182,7 @@ module UltracartClient
|
|
158
182
|
city == o.city &&
|
159
183
|
country == o.country &&
|
160
184
|
distribution_center_code == o.distribution_center_code &&
|
185
|
+
external_id == o.external_id &&
|
161
186
|
merchant_id == o.merchant_id &&
|
162
187
|
pos_location_oid == o.pos_location_oid &&
|
163
188
|
postal_code == o.postal_code &&
|
@@ -173,7 +198,7 @@ module UltracartClient
|
|
173
198
|
# Calculates hash code according to all attributes.
|
174
199
|
# @return [Integer] Hash code
|
175
200
|
def hash
|
176
|
-
[adddress2, address1, city, country, distribution_center_code, merchant_id, pos_location_oid, postal_code, state_province].hash
|
201
|
+
[adddress2, address1, city, country, distribution_center_code, external_id, merchant_id, pos_location_oid, postal_code, state_province].hash
|
177
202
|
end
|
178
203
|
|
179
204
|
# Builds the object from hash
|
data/lib/ultracart_api.rb
CHANGED
@@ -79,6 +79,7 @@ require 'ultracart_api/models/cart_item_multimedia_thumbnail'
|
|
79
79
|
require 'ultracart_api/models/cart_item_option'
|
80
80
|
require 'ultracart_api/models/cart_item_option_value'
|
81
81
|
require 'ultracart_api/models/cart_item_physical'
|
82
|
+
require 'ultracart_api/models/cart_item_property'
|
82
83
|
require 'ultracart_api/models/cart_item_variation_selection'
|
83
84
|
require 'ultracart_api/models/cart_kit_component_option'
|
84
85
|
require 'ultracart_api/models/cart_marketing'
|
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.0.
|
4
|
+
version: 4.0.114.rc
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- UltraCart
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-01-
|
11
|
+
date: 2023-01-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: typhoeus
|
@@ -125,6 +125,7 @@ files:
|
|
125
125
|
- docs/CartItemOption.md
|
126
126
|
- docs/CartItemOptionValue.md
|
127
127
|
- docs/CartItemPhysical.md
|
128
|
+
- docs/CartItemProperty.md
|
128
129
|
- docs/CartItemVariationSelection.md
|
129
130
|
- docs/CartKitComponentOption.md
|
130
131
|
- docs/CartMarketing.md
|
@@ -891,6 +892,7 @@ files:
|
|
891
892
|
- lib/ultracart_api/models/cart_item_option.rb
|
892
893
|
- lib/ultracart_api/models/cart_item_option_value.rb
|
893
894
|
- lib/ultracart_api/models/cart_item_physical.rb
|
895
|
+
- lib/ultracart_api/models/cart_item_property.rb
|
894
896
|
- lib/ultracart_api/models/cart_item_variation_selection.rb
|
895
897
|
- lib/ultracart_api/models/cart_kit_component_option.rb
|
896
898
|
- lib/ultracart_api/models/cart_marketing.rb
|