ultracart_api 3.10.74 → 3.10.75

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 795509c775e549ec21470723b95b3281bfef9774f98fbd1274c15b5f68be9a8e
4
- data.tar.gz: 1e7fa410b20512c29fe53339d1d155bc83771bde4326250da20f848bb6d97ba9
3
+ metadata.gz: 198b91e063c30c96bb9f0e4a9a4af1ca8ee50add9ffcc0dcd19e25dec00523c9
4
+ data.tar.gz: 95e079ea08231a7d6812b441d6f614a8d27cfa934e79e7605e22d585518b99fe
5
5
  SHA512:
6
- metadata.gz: af643b839f56f518ba0479ec3831046e67d1a2d5a40fdafa65792d777b082927e2fa4562a8a0947d6c16b439ccf4ac2fd89dc93aa95873323f2548a53d06f317
7
- data.tar.gz: 2ac4b0d11bea4cd3434b3d0cbd2be798f0874de7883e6694ecc9ca8f4c634a2ac8f374dee44b564b06480e5bdfbb6ad23bce9981767dfc16dfc38592abf9950e
6
+ metadata.gz: ed093f4fe75d93356fbfd1bbfdcdf54772e3a5121f04e7ad17df5ace7f3b5ffc60900a0d558bbe28a99dcaf2f0a031ac7f19657b343f4ac58f80dbda52a62b5d
7
+ data.tar.gz: 054cafd6de5fd9e6ac07173e37f0f6aeb47d499a76c7e977fd3ae5dfeb95735ef546cdb0863423085d0a00d104b46e2ac11c4fe177c3cc0f6a3977f5fe5533ee
data/README.md CHANGED
@@ -7,7 +7,7 @@ UltraCart REST API Version 2
7
7
  This SDK is automatically generated by the [Swagger Codegen](https://github.com/swagger-api/swagger-codegen) project:
8
8
 
9
9
  - API version: 2.0.0
10
- - Package version: 3.10.74
10
+ - Package version: 3.10.75
11
11
  - Build package: io.swagger.codegen.languages.RubyClientCodegen
12
12
  For more information, please visit [http://www.ultracart.com](http://www.ultracart.com)
13
13
 
@@ -24,15 +24,15 @@ gem build ultracart_api.gemspec
24
24
  Then either install the gem locally:
25
25
 
26
26
  ```shell
27
- gem install ./ultracart_api-3.10.74.gem
27
+ gem install ./ultracart_api-3.10.75.gem
28
28
  ```
29
- (for development, run `gem install --dev ./ultracart_api-3.10.74.gem` to install the development dependencies)
29
+ (for development, run `gem install --dev ./ultracart_api-3.10.75.gem` to install the development dependencies)
30
30
 
31
31
  or publish the gem to a gem hosting service, e.g. [RubyGems](https://rubygems.org/).
32
32
 
33
33
  Finally add this to the Gemfile:
34
34
 
35
- gem 'ultracart_api', '~> 3.10.74'
35
+ gem 'ultracart_api', '~> 3.10.75'
36
36
 
37
37
  ### Install from Git
38
38
 
@@ -561,6 +561,7 @@ Class | Method | HTTP request | Description
561
561
  - [UltracartClient::CartUpsellAfter](docs/CartUpsellAfter.md)
562
562
  - [UltracartClient::CartValidationRequest](docs/CartValidationRequest.md)
563
563
  - [UltracartClient::CartValidationResponse](docs/CartValidationResponse.md)
564
+ - [UltracartClient::ChannelPartner](docs/ChannelPartner.md)
564
565
  - [UltracartClient::ChannelPartnerCancelResponse](docs/ChannelPartnerCancelResponse.md)
565
566
  - [UltracartClient::ChannelPartnerEstimateShippingResponse](docs/ChannelPartnerEstimateShippingResponse.md)
566
567
  - [UltracartClient::ChannelPartnerEstimateTaxResponse](docs/ChannelPartnerEstimateTaxResponse.md)
@@ -683,6 +684,7 @@ Class | Method | HTTP request | Description
683
684
  - [UltracartClient::CustomerAttachment](docs/CustomerAttachment.md)
684
685
  - [UltracartClient::CustomerBilling](docs/CustomerBilling.md)
685
686
  - [UltracartClient::CustomerCard](docs/CustomerCard.md)
687
+ - [UltracartClient::CustomerEDI](docs/CustomerEDI.md)
686
688
  - [UltracartClient::CustomerEditorValues](docs/CustomerEditorValues.md)
687
689
  - [UltracartClient::CustomerEmail](docs/CustomerEmail.md)
688
690
  - [UltracartClient::CustomerEmailListChanges](docs/CustomerEmailListChanges.md)
@@ -1225,6 +1227,7 @@ Not every change is committed to every SDK.
1225
1227
 
1226
1228
  | Version | Date | Comments |
1227
1229
  | --: | :-: | --- |
1230
+ | 3.10.75 | 12/06/2022 | customer api - expose edi information and editor values |
1228
1231
  | 3.10.74 | 12/02/2022 | conversations - customer last unresponded dts |
1229
1232
  | 3.10.73 | 11/30/2022 | conversations - add order and auto order information to webchat context |
1230
1233
  | 3.10.72 | 11/30/2022 | order item - addl fields for linking kits to kit components |
@@ -0,0 +1,14 @@
1
+ # UltracartClient::ChannelPartner
2
+
3
+ ## Properties
4
+ Name | Type | Description | Notes
5
+ ------------ | ------------- | ------------- | -------------
6
+ **channel_partner_oid** | **Integer** | Channel partner object id | [optional]
7
+ **code** | **String** | Code associated with the channel partner | [optional]
8
+ **communication_method** | **String** | Communication method of the channel partner | [optional]
9
+ **inactive** | **BOOLEAN** | True if the channel partner is inactive | [optional]
10
+ **merchant_id** | **String** | Merchant ID of the channel partner | [optional]
11
+ **name** | **String** | Name of the channel partner | [optional]
12
+ **skip_customer_emails** | **BOOLEAN** | True if emails to the customer are skipped for this channel partner. | [optional]
13
+
14
+
data/docs/Customer.md CHANGED
@@ -22,6 +22,7 @@ Name | Type | Description | Notes
22
22
  **customer_profile_oid** | **Integer** | Customer profile object identifier | [optional]
23
23
  **dhl_account_number** | **String** | DHL account number | [optional]
24
24
  **dhl_duty_account_number** | **String** | DHL duty account number | [optional]
25
+ **edi** | [**CustomerEDI**](CustomerEDI.md) | | [optional]
25
26
  **email** | **String** | Email address of this customer profile | [optional]
26
27
  **exempt_shipping_handling_charge** | **BOOLEAN** | Exempt shipping handling charge | [optional]
27
28
  **fedex_account_number** | **String** | FedEx account number | [optional]
@@ -0,0 +1,10 @@
1
+ # UltracartClient::CustomerEDI
2
+
3
+ ## Properties
4
+ Name | Type | Description | Notes
5
+ ------------ | ------------- | ------------- | -------------
6
+ **channel_partner_oid** | **Integer** | EDI channel partner this customer profile is associated with | [optional]
7
+ **distribution_center_number** | **String** | The EDI distribution center number associated with this customer profile. | [optional]
8
+ **store_number** | **String** | The EDI store number associated with this customer profile. | [optional]
9
+
10
+
@@ -8,6 +8,7 @@ Name | Type | Description | Notes
8
8
  **card_exp_years** | **Array<String>** | card_exp_years | [optional]
9
9
  **card_types** | **Array<String>** | card_types | [optional]
10
10
  **countries** | [**Array<Country>**](Country.md) | countries | [optional]
11
+ **edi_channel_partners** | [**Array<ChannelPartner>**](ChannelPartner.md) | EDI channel partners | [optional]
11
12
  **loyalty_ledger_descriptions** | **Array<String>** | loyalty_ledger_descriptions | [optional]
12
13
  **loyalty_program_type** | **String** | loyalty_program_type | [optional]
13
14
  **qb_classes** | **Array<String>** | qb_classes | [optional]
@@ -0,0 +1,245 @@
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 ChannelPartner
17
+ # Channel partner object id
18
+ attr_accessor :channel_partner_oid
19
+
20
+ # Code associated with the channel partner
21
+ attr_accessor :code
22
+
23
+ # Communication method of the channel partner
24
+ attr_accessor :communication_method
25
+
26
+ # True if the channel partner is inactive
27
+ attr_accessor :inactive
28
+
29
+ # Merchant ID of the channel partner
30
+ attr_accessor :merchant_id
31
+
32
+ # Name of the channel partner
33
+ attr_accessor :name
34
+
35
+ # True if emails to the customer are skipped for this channel partner.
36
+ attr_accessor :skip_customer_emails
37
+
38
+ # Attribute mapping from ruby-style variable name to JSON key.
39
+ def self.attribute_map
40
+ {
41
+ :'channel_partner_oid' => :'channel_partner_oid',
42
+ :'code' => :'code',
43
+ :'communication_method' => :'communication_method',
44
+ :'inactive' => :'inactive',
45
+ :'merchant_id' => :'merchant_id',
46
+ :'name' => :'name',
47
+ :'skip_customer_emails' => :'skip_customer_emails'
48
+ }
49
+ end
50
+
51
+ # Attribute type mapping.
52
+ def self.swagger_types
53
+ {
54
+ :'channel_partner_oid' => :'Integer',
55
+ :'code' => :'String',
56
+ :'communication_method' => :'String',
57
+ :'inactive' => :'BOOLEAN',
58
+ :'merchant_id' => :'String',
59
+ :'name' => :'String',
60
+ :'skip_customer_emails' => :'BOOLEAN'
61
+ }
62
+ end
63
+
64
+ # Initializes the object
65
+ # @param [Hash] attributes Model attributes in the form of hash
66
+ def initialize(attributes = {})
67
+ return unless attributes.is_a?(Hash)
68
+
69
+ # convert string to symbol for hash key
70
+ attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
71
+
72
+ if attributes.has_key?(:'channel_partner_oid')
73
+ self.channel_partner_oid = attributes[:'channel_partner_oid']
74
+ end
75
+
76
+ if attributes.has_key?(:'code')
77
+ self.code = attributes[:'code']
78
+ end
79
+
80
+ if attributes.has_key?(:'communication_method')
81
+ self.communication_method = attributes[:'communication_method']
82
+ end
83
+
84
+ if attributes.has_key?(:'inactive')
85
+ self.inactive = attributes[:'inactive']
86
+ end
87
+
88
+ if attributes.has_key?(:'merchant_id')
89
+ self.merchant_id = attributes[:'merchant_id']
90
+ end
91
+
92
+ if attributes.has_key?(:'name')
93
+ self.name = attributes[:'name']
94
+ end
95
+
96
+ if attributes.has_key?(:'skip_customer_emails')
97
+ self.skip_customer_emails = attributes[:'skip_customer_emails']
98
+ end
99
+ end
100
+
101
+ # Show invalid properties with the reasons. Usually used together with valid?
102
+ # @return Array for valid properties with the reasons
103
+ def list_invalid_properties
104
+ invalid_properties = Array.new
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
+ true
112
+ end
113
+
114
+ # Checks equality by comparing each attribute.
115
+ # @param [Object] Object to be compared
116
+ def ==(o)
117
+ return true if self.equal?(o)
118
+ self.class == o.class &&
119
+ channel_partner_oid == o.channel_partner_oid &&
120
+ code == o.code &&
121
+ communication_method == o.communication_method &&
122
+ inactive == o.inactive &&
123
+ merchant_id == o.merchant_id &&
124
+ name == o.name &&
125
+ skip_customer_emails == o.skip_customer_emails
126
+ end
127
+
128
+ # @see the `==` method
129
+ # @param [Object] Object to be compared
130
+ def eql?(o)
131
+ self == o
132
+ end
133
+
134
+ # Calculates hash code according to all attributes.
135
+ # @return [Fixnum] Hash code
136
+ def hash
137
+ [channel_partner_oid, code, communication_method, inactive, merchant_id, name, skip_customer_emails].hash
138
+ end
139
+
140
+ # Builds the object from hash
141
+ # @param [Hash] attributes Model attributes in the form of hash
142
+ # @return [Object] Returns the model itself
143
+ def build_from_hash(attributes)
144
+ return nil unless attributes.is_a?(Hash)
145
+ self.class.swagger_types.each_pair do |key, type|
146
+ if type =~ /\AArray<(.*)>/i
147
+ # check to ensure the input is an array given that the attribute
148
+ # is documented as an array but the input is not
149
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
150
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
151
+ end
152
+ elsif !attributes[self.class.attribute_map[key]].nil?
153
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
154
+ end # or else data not found in attributes(hash), not an issue as the data can be optional
155
+ end
156
+
157
+ self
158
+ end
159
+
160
+ # Deserializes the data based on type
161
+ # @param string type Data type
162
+ # @param string value Value to be deserialized
163
+ # @return [Object] Deserialized data
164
+ def _deserialize(type, value)
165
+ case type.to_sym
166
+ when :DateTime
167
+ DateTime.parse(value)
168
+ when :Date
169
+ Date.parse(value)
170
+ when :String
171
+ value.to_s
172
+ when :Integer
173
+ value.to_i
174
+ when :Float
175
+ value.to_f
176
+ when :BOOLEAN
177
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
178
+ true
179
+ else
180
+ false
181
+ end
182
+ when :Object
183
+ # generic object (usually a Hash), return directly
184
+ value
185
+ when /\AArray<(?<inner_type>.+)>\z/
186
+ inner_type = Regexp.last_match[:inner_type]
187
+ value.map { |v| _deserialize(inner_type, v) }
188
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
189
+ k_type = Regexp.last_match[:k_type]
190
+ v_type = Regexp.last_match[:v_type]
191
+ {}.tap do |hash|
192
+ value.each do |k, v|
193
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
194
+ end
195
+ end
196
+ else # model
197
+ temp_model = UltracartClient.const_get(type).new
198
+ temp_model.build_from_hash(value)
199
+ end
200
+ end
201
+
202
+ # Returns the string representation of the object
203
+ # @return [String] String presentation of the object
204
+ def to_s
205
+ to_hash.to_s
206
+ end
207
+
208
+ # to_body is an alias to to_hash (backward compatibility)
209
+ # @return [Hash] Returns the object in the form of hash
210
+ def to_body
211
+ to_hash
212
+ end
213
+
214
+ # Returns the object in the form of hash
215
+ # @return [Hash] Returns the object in the form of hash
216
+ def to_hash
217
+ hash = {}
218
+ self.class.attribute_map.each_pair do |attr, param|
219
+ value = self.send(attr)
220
+ next if value.nil?
221
+ hash[param] = _to_hash(value)
222
+ end
223
+ hash
224
+ end
225
+
226
+ # Outputs non-array value in the form of hash
227
+ # For object, use to_hash. Otherwise, just return the value
228
+ # @param [Object] value Any valid value
229
+ # @return [Hash] Returns the value in the form of hash
230
+ def _to_hash(value)
231
+ if value.is_a?(Array)
232
+ value.compact.map { |v| _to_hash(v) }
233
+ elsif value.is_a?(Hash)
234
+ {}.tap do |hash|
235
+ value.each { |k, v| hash[k] = _to_hash(v) }
236
+ end
237
+ elsif value.respond_to? :to_hash
238
+ value.to_hash
239
+ else
240
+ value
241
+ end
242
+ end
243
+
244
+ end
245
+ end
@@ -70,6 +70,8 @@ module UltracartClient
70
70
  # DHL duty account number
71
71
  attr_accessor :dhl_duty_account_number
72
72
 
73
+ attr_accessor :edi
74
+
73
75
  # Email address of this customer profile
74
76
  attr_accessor :email
75
77
 
@@ -209,6 +211,7 @@ module UltracartClient
209
211
  :'customer_profile_oid' => :'customer_profile_oid',
210
212
  :'dhl_account_number' => :'dhl_account_number',
211
213
  :'dhl_duty_account_number' => :'dhl_duty_account_number',
214
+ :'edi' => :'edi',
212
215
  :'email' => :'email',
213
216
  :'exempt_shipping_handling_charge' => :'exempt_shipping_handling_charge',
214
217
  :'fedex_account_number' => :'fedex_account_number',
@@ -275,6 +278,7 @@ module UltracartClient
275
278
  :'customer_profile_oid' => :'Integer',
276
279
  :'dhl_account_number' => :'String',
277
280
  :'dhl_duty_account_number' => :'String',
281
+ :'edi' => :'CustomerEDI',
278
282
  :'email' => :'String',
279
283
  :'exempt_shipping_handling_charge' => :'BOOLEAN',
280
284
  :'fedex_account_number' => :'String',
@@ -411,6 +415,10 @@ module UltracartClient
411
415
  self.dhl_duty_account_number = attributes[:'dhl_duty_account_number']
412
416
  end
413
417
 
418
+ if attributes.has_key?(:'edi')
419
+ self.edi = attributes[:'edi']
420
+ end
421
+
414
422
  if attributes.has_key?(:'email')
415
423
  self.email = attributes[:'email']
416
424
  end
@@ -790,6 +798,7 @@ module UltracartClient
790
798
  customer_profile_oid == o.customer_profile_oid &&
791
799
  dhl_account_number == o.dhl_account_number &&
792
800
  dhl_duty_account_number == o.dhl_duty_account_number &&
801
+ edi == o.edi &&
793
802
  email == o.email &&
794
803
  exempt_shipping_handling_charge == o.exempt_shipping_handling_charge &&
795
804
  fedex_account_number == o.fedex_account_number &&
@@ -842,7 +851,7 @@ module UltracartClient
842
851
  # Calculates hash code according to all attributes.
843
852
  # @return [Fixnum] Hash code
844
853
  def hash
845
- [activity, affiliate_oid, allow_3rd_party_billing, allow_cod, allow_drop_shipping, allow_purchase_order, allow_quote_request, allow_selection_of_address_type, attachments, auto_approve_cod, auto_approve_purchase_order, automatic_merchant_notes, billing, business_notes, cards, cc_emails, customer_profile_oid, dhl_account_number, dhl_duty_account_number, email, exempt_shipping_handling_charge, fedex_account_number, free_shipping, free_shipping_minimum, last_modified_by, last_modified_dts, loyalty, maximum_item_count, merchant_id, minimum_item_count, minimum_subtotal, no_coupons, no_free_shipping, no_realtime_charge, orders, orders_summary, password, pricing_tiers, privacy, qb_class, qb_code, quotes, quotes_summary, referral_source, reviewer, sales_rep_code, send_signup_notification, shipping, signup_dts, software_entitlements, suppress_buysafe, tags, tax_codes, tax_exempt, tax_id, terms, track_separately, unapproved, ups_account_number, website_url].hash
854
+ [activity, affiliate_oid, allow_3rd_party_billing, allow_cod, allow_drop_shipping, allow_purchase_order, allow_quote_request, allow_selection_of_address_type, attachments, auto_approve_cod, auto_approve_purchase_order, automatic_merchant_notes, billing, business_notes, cards, cc_emails, customer_profile_oid, dhl_account_number, dhl_duty_account_number, edi, email, exempt_shipping_handling_charge, fedex_account_number, free_shipping, free_shipping_minimum, last_modified_by, last_modified_dts, loyalty, maximum_item_count, merchant_id, minimum_item_count, minimum_subtotal, no_coupons, no_free_shipping, no_realtime_charge, orders, orders_summary, password, pricing_tiers, privacy, qb_class, qb_code, quotes, quotes_summary, referral_source, reviewer, sales_rep_code, send_signup_notification, shipping, signup_dts, software_entitlements, suppress_buysafe, tags, tax_codes, tax_exempt, tax_id, terms, track_separately, unapproved, ups_account_number, website_url].hash
846
855
  end
847
856
 
848
857
  # Builds the object from hash
@@ -0,0 +1,205 @@
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 CustomerEDI
17
+ # EDI channel partner this customer profile is associated with
18
+ attr_accessor :channel_partner_oid
19
+
20
+ # The EDI distribution center number associated with this customer profile.
21
+ attr_accessor :distribution_center_number
22
+
23
+ # The EDI store number associated with this customer profile.
24
+ attr_accessor :store_number
25
+
26
+ # Attribute mapping from ruby-style variable name to JSON key.
27
+ def self.attribute_map
28
+ {
29
+ :'channel_partner_oid' => :'channel_partner_oid',
30
+ :'distribution_center_number' => :'distribution_center_number',
31
+ :'store_number' => :'store_number'
32
+ }
33
+ end
34
+
35
+ # Attribute type mapping.
36
+ def self.swagger_types
37
+ {
38
+ :'channel_partner_oid' => :'Integer',
39
+ :'distribution_center_number' => :'String',
40
+ :'store_number' => :'String'
41
+ }
42
+ end
43
+
44
+ # Initializes the object
45
+ # @param [Hash] attributes Model attributes in the form of hash
46
+ def initialize(attributes = {})
47
+ return unless attributes.is_a?(Hash)
48
+
49
+ # convert string to symbol for hash key
50
+ attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
51
+
52
+ if attributes.has_key?(:'channel_partner_oid')
53
+ self.channel_partner_oid = attributes[:'channel_partner_oid']
54
+ end
55
+
56
+ if attributes.has_key?(:'distribution_center_number')
57
+ self.distribution_center_number = attributes[:'distribution_center_number']
58
+ end
59
+
60
+ if attributes.has_key?(:'store_number')
61
+ self.store_number = attributes[:'store_number']
62
+ end
63
+ end
64
+
65
+ # Show invalid properties with the reasons. Usually used together with valid?
66
+ # @return Array for valid properties with the reasons
67
+ def list_invalid_properties
68
+ invalid_properties = Array.new
69
+ invalid_properties
70
+ end
71
+
72
+ # Check to see if the all the properties in the model are valid
73
+ # @return true if the model is valid
74
+ def valid?
75
+ true
76
+ end
77
+
78
+ # Checks equality by comparing each attribute.
79
+ # @param [Object] Object to be compared
80
+ def ==(o)
81
+ return true if self.equal?(o)
82
+ self.class == o.class &&
83
+ channel_partner_oid == o.channel_partner_oid &&
84
+ distribution_center_number == o.distribution_center_number &&
85
+ store_number == o.store_number
86
+ end
87
+
88
+ # @see the `==` method
89
+ # @param [Object] Object to be compared
90
+ def eql?(o)
91
+ self == o
92
+ end
93
+
94
+ # Calculates hash code according to all attributes.
95
+ # @return [Fixnum] Hash code
96
+ def hash
97
+ [channel_partner_oid, distribution_center_number, store_number].hash
98
+ end
99
+
100
+ # Builds the object from hash
101
+ # @param [Hash] attributes Model attributes in the form of hash
102
+ # @return [Object] Returns the model itself
103
+ def build_from_hash(attributes)
104
+ return nil unless attributes.is_a?(Hash)
105
+ self.class.swagger_types.each_pair do |key, type|
106
+ if type =~ /\AArray<(.*)>/i
107
+ # check to ensure the input is an array given that the attribute
108
+ # is documented as an array but the input is not
109
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
110
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
111
+ end
112
+ elsif !attributes[self.class.attribute_map[key]].nil?
113
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
114
+ end # or else data not found in attributes(hash), not an issue as the data can be optional
115
+ end
116
+
117
+ self
118
+ end
119
+
120
+ # Deserializes the data based on type
121
+ # @param string type Data type
122
+ # @param string value Value to be deserialized
123
+ # @return [Object] Deserialized data
124
+ def _deserialize(type, value)
125
+ case type.to_sym
126
+ when :DateTime
127
+ DateTime.parse(value)
128
+ when :Date
129
+ Date.parse(value)
130
+ when :String
131
+ value.to_s
132
+ when :Integer
133
+ value.to_i
134
+ when :Float
135
+ value.to_f
136
+ when :BOOLEAN
137
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
138
+ true
139
+ else
140
+ false
141
+ end
142
+ when :Object
143
+ # generic object (usually a Hash), return directly
144
+ value
145
+ when /\AArray<(?<inner_type>.+)>\z/
146
+ inner_type = Regexp.last_match[:inner_type]
147
+ value.map { |v| _deserialize(inner_type, v) }
148
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
149
+ k_type = Regexp.last_match[:k_type]
150
+ v_type = Regexp.last_match[:v_type]
151
+ {}.tap do |hash|
152
+ value.each do |k, v|
153
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
154
+ end
155
+ end
156
+ else # model
157
+ temp_model = UltracartClient.const_get(type).new
158
+ temp_model.build_from_hash(value)
159
+ end
160
+ end
161
+
162
+ # Returns the string representation of the object
163
+ # @return [String] String presentation of the object
164
+ def to_s
165
+ to_hash.to_s
166
+ end
167
+
168
+ # to_body is an alias to to_hash (backward compatibility)
169
+ # @return [Hash] Returns the object in the form of hash
170
+ def to_body
171
+ to_hash
172
+ end
173
+
174
+ # Returns the object in the form of hash
175
+ # @return [Hash] Returns the object in the form of hash
176
+ def to_hash
177
+ hash = {}
178
+ self.class.attribute_map.each_pair do |attr, param|
179
+ value = self.send(attr)
180
+ next if value.nil?
181
+ hash[param] = _to_hash(value)
182
+ end
183
+ hash
184
+ end
185
+
186
+ # Outputs non-array value in the form of hash
187
+ # For object, use to_hash. Otherwise, just return the value
188
+ # @param [Object] value Any valid value
189
+ # @return [Hash] Returns the value in the form of hash
190
+ def _to_hash(value)
191
+ if value.is_a?(Array)
192
+ value.compact.map { |v| _to_hash(v) }
193
+ elsif value.is_a?(Hash)
194
+ {}.tap do |hash|
195
+ value.each { |k, v| hash[k] = _to_hash(v) }
196
+ end
197
+ elsif value.respond_to? :to_hash
198
+ value.to_hash
199
+ else
200
+ value
201
+ end
202
+ end
203
+
204
+ end
205
+ end
@@ -29,6 +29,9 @@ module UltracartClient
29
29
  # countries
30
30
  attr_accessor :countries
31
31
 
32
+ # EDI channel partners
33
+ attr_accessor :edi_channel_partners
34
+
32
35
  # loyalty_ledger_descriptions
33
36
  attr_accessor :loyalty_ledger_descriptions
34
37
 
@@ -55,6 +58,7 @@ module UltracartClient
55
58
  :'card_exp_years' => :'card_exp_years',
56
59
  :'card_types' => :'card_types',
57
60
  :'countries' => :'countries',
61
+ :'edi_channel_partners' => :'edi_channel_partners',
58
62
  :'loyalty_ledger_descriptions' => :'loyalty_ledger_descriptions',
59
63
  :'loyalty_program_type' => :'loyalty_program_type',
60
64
  :'qb_classes' => :'qb_classes',
@@ -72,6 +76,7 @@ module UltracartClient
72
76
  :'card_exp_years' => :'Array<String>',
73
77
  :'card_types' => :'Array<String>',
74
78
  :'countries' => :'Array<Country>',
79
+ :'edi_channel_partners' => :'Array<ChannelPartner>',
75
80
  :'loyalty_ledger_descriptions' => :'Array<String>',
76
81
  :'loyalty_program_type' => :'String',
77
82
  :'qb_classes' => :'Array<String>',
@@ -119,6 +124,12 @@ module UltracartClient
119
124
  end
120
125
  end
121
126
 
127
+ if attributes.has_key?(:'edi_channel_partners')
128
+ if (value = attributes[:'edi_channel_partners']).is_a?(Array)
129
+ self.edi_channel_partners = value
130
+ end
131
+ end
132
+
122
133
  if attributes.has_key?(:'loyalty_ledger_descriptions')
123
134
  if (value = attributes[:'loyalty_ledger_descriptions']).is_a?(Array)
124
135
  self.loyalty_ledger_descriptions = value
@@ -177,6 +188,7 @@ module UltracartClient
177
188
  card_exp_years == o.card_exp_years &&
178
189
  card_types == o.card_types &&
179
190
  countries == o.countries &&
191
+ edi_channel_partners == o.edi_channel_partners &&
180
192
  loyalty_ledger_descriptions == o.loyalty_ledger_descriptions &&
181
193
  loyalty_program_type == o.loyalty_program_type &&
182
194
  qb_classes == o.qb_classes &&
@@ -194,7 +206,7 @@ module UltracartClient
194
206
  # Calculates hash code according to all attributes.
195
207
  # @return [Fixnum] Hash code
196
208
  def hash
197
- [affiliates, card_exp_months, card_exp_years, card_types, countries, loyalty_ledger_descriptions, loyalty_program_type, qb_classes, sales_rep_codes, state_optional_countries, terms].hash
209
+ [affiliates, card_exp_months, card_exp_years, card_types, countries, edi_channel_partners, loyalty_ledger_descriptions, loyalty_program_type, qb_classes, sales_rep_codes, state_optional_countries, terms].hash
198
210
  end
199
211
 
200
212
  # 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.10.74'
14
+ VERSION = '3.10.75'
15
15
  end
data/lib/ultracart_api.rb CHANGED
@@ -114,6 +114,7 @@ require 'ultracart_api/models/cart_taxes'
114
114
  require 'ultracart_api/models/cart_upsell_after'
115
115
  require 'ultracart_api/models/cart_validation_request'
116
116
  require 'ultracart_api/models/cart_validation_response'
117
+ require 'ultracart_api/models/channel_partner'
117
118
  require 'ultracart_api/models/channel_partner_cancel_response'
118
119
  require 'ultracart_api/models/channel_partner_estimate_shipping_response'
119
120
  require 'ultracart_api/models/channel_partner_estimate_tax_response'
@@ -236,6 +237,7 @@ require 'ultracart_api/models/customer_affiliate'
236
237
  require 'ultracart_api/models/customer_attachment'
237
238
  require 'ultracart_api/models/customer_billing'
238
239
  require 'ultracart_api/models/customer_card'
240
+ require 'ultracart_api/models/customer_edi'
239
241
  require 'ultracart_api/models/customer_editor_values'
240
242
  require 'ultracart_api/models/customer_email'
241
243
  require 'ultracart_api/models/customer_email_list_changes'
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.74
4
+ version: 3.10.75
5
5
  platform: ruby
6
6
  authors:
7
7
  - UltraCart
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-12-02 00:00:00.000000000 Z
11
+ date: 2022-12-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: typhoeus
@@ -320,6 +320,7 @@ files:
320
320
  - docs/CartUpsellAfter.md
321
321
  - docs/CartValidationRequest.md
322
322
  - docs/CartValidationResponse.md
323
+ - docs/ChannelPartner.md
323
324
  - docs/ChannelPartnerApi.md
324
325
  - docs/ChannelPartnerCancelResponse.md
325
326
  - docs/ChannelPartnerEstimateShippingResponse.md
@@ -448,6 +449,7 @@ files:
448
449
  - docs/CustomerAttachment.md
449
450
  - docs/CustomerBilling.md
450
451
  - docs/CustomerCard.md
452
+ - docs/CustomerEDI.md
451
453
  - docs/CustomerEditorValues.md
452
454
  - docs/CustomerEmail.md
453
455
  - docs/CustomerEmailListChanges.md
@@ -1052,6 +1054,7 @@ files:
1052
1054
  - lib/ultracart_api/models/cart_upsell_after.rb
1053
1055
  - lib/ultracart_api/models/cart_validation_request.rb
1054
1056
  - lib/ultracart_api/models/cart_validation_response.rb
1057
+ - lib/ultracart_api/models/channel_partner.rb
1055
1058
  - lib/ultracart_api/models/channel_partner_cancel_response.rb
1056
1059
  - lib/ultracart_api/models/channel_partner_estimate_shipping_response.rb
1057
1060
  - lib/ultracart_api/models/channel_partner_estimate_tax_response.rb
@@ -1174,6 +1177,7 @@ files:
1174
1177
  - lib/ultracart_api/models/customer_attachment.rb
1175
1178
  - lib/ultracart_api/models/customer_billing.rb
1176
1179
  - lib/ultracart_api/models/customer_card.rb
1180
+ - lib/ultracart_api/models/customer_edi.rb
1177
1181
  - lib/ultracart_api/models/customer_editor_values.rb
1178
1182
  - lib/ultracart_api/models/customer_email.rb
1179
1183
  - lib/ultracart_api/models/customer_email_list_changes.rb