ultracart_api 3.10.143 → 3.10.145
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +6 -4
- data/docs/OrderApi.md +8 -2
- data/docs/OrderShipping.md +1 -0
- data/lib/ultracart_api/api/order_api.rb +6 -0
- data/lib/ultracart_api/models/coupon.rb +29 -5
- data/lib/ultracart_api/models/order_shipping.rb +11 -1
- data/lib/ultracart_api/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3b06cffbb7b72a2dc4ab064fc4172d2b9685ec14ffa732712ce24afeb52a8bea
|
4
|
+
data.tar.gz: ad3bf1082daa3968c3f664d06211fe5be02ed28a640ff038d84a84f866e869ed
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 37d7bfe526da0a428bca7f179e4694fc2a5d4f7fac97a6b8971de21ee489f3f281a782ac9debc591f8457f5146c4551f17be99a8b19e537bc4598bda2cda5521
|
7
|
+
data.tar.gz: 04bab7d92531600ca1225fa45ebf3e01518acd6c62a9718147c74ad802d81617611968c989b7d77485f8295a8798b101915f88485b6a25d7accacae62844856e
|
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.
|
10
|
+
- Package version: 3.10.145
|
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.
|
27
|
+
gem install ./ultracart_api-3.10.145.gem
|
28
28
|
```
|
29
|
-
(for development, run `gem install --dev ./ultracart_api-3.10.
|
29
|
+
(for development, run `gem install --dev ./ultracart_api-3.10.145.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.
|
35
|
+
gem 'ultracart_api', '~> 3.10.145'
|
36
36
|
|
37
37
|
### Install from Git
|
38
38
|
|
@@ -1356,6 +1356,8 @@ Not every change is committed to every SDK.
|
|
1356
1356
|
|
1357
1357
|
| Version | Date | Comments |
|
1358
1358
|
| --: | :-: | --- |
|
1359
|
+
| 3.10.145 | 06/20/2023 | coupon add allowed values for usable_by and new OncePerNewCustomerForItem flag |
|
1360
|
+
| 3.10.144 | 06/15/2023 | add pickup_dts to order.shipping object |
|
1359
1361
|
| 3.10.143 | 06/14/2023 | dw bi: add request_dts on the execute queries request and report data set objects |
|
1360
1362
|
| 3.10.142 | 06/09/2023 | distribution center pickup times |
|
1361
1363
|
| 3.10.141 | 06/08/2023 | customer profile qb tax exempt reason code field |
|
data/docs/OrderApi.md
CHANGED
@@ -86,7 +86,7 @@ Name | Type | Description | Notes
|
|
86
86
|
|
87
87
|
|
88
88
|
# **cancel_order**
|
89
|
-
> BaseResponse cancel_order(order_id)
|
89
|
+
> BaseResponse cancel_order(order_id, opts)
|
90
90
|
|
91
91
|
Cancel an order
|
92
92
|
|
@@ -104,10 +104,14 @@ api_instance = UltracartClient::OrderApi.new_using_api_key(simple_key, false, fa
|
|
104
104
|
|
105
105
|
order_id = 'order_id_example' # String | The order id to cancel.
|
106
106
|
|
107
|
+
opts = {
|
108
|
+
lock_self_ship_orders: true, # BOOLEAN | Flag to prevent a order shipping during a refund process
|
109
|
+
skip_refund_and_hold: true # BOOLEAN | Skip refund and move order to Held Orders department
|
110
|
+
}
|
107
111
|
|
108
112
|
begin
|
109
113
|
#Cancel an order
|
110
|
-
result = api_instance.cancel_order(order_id)
|
114
|
+
result = api_instance.cancel_order(order_id, opts)
|
111
115
|
p result
|
112
116
|
rescue UltracartClient::ApiError => e
|
113
117
|
puts "Exception when calling OrderApi->cancel_order: #{e}"
|
@@ -119,6 +123,8 @@ end
|
|
119
123
|
Name | Type | Description | Notes
|
120
124
|
------------- | ------------- | ------------- | -------------
|
121
125
|
**order_id** | **String**| The order id to cancel. |
|
126
|
+
**lock_self_ship_orders** | **BOOLEAN**| Flag to prevent a order shipping during a refund process | [optional]
|
127
|
+
**skip_refund_and_hold** | **BOOLEAN**| Skip refund and move order to Held Orders department | [optional]
|
122
128
|
|
123
129
|
### Return type
|
124
130
|
|
data/docs/OrderShipping.md
CHANGED
@@ -18,6 +18,7 @@ Name | Type | Description | Notes
|
|
18
18
|
**least_cost_route** | **BOOLEAN** | If true, instructs UltraCart to apply the cheapest shipping method to this order. Used only for channel partner order inserts. | [optional]
|
19
19
|
**least_cost_route_shipping_methods** | **Array<String>** | List of shipping methods to consider if least_code_route is true. Used only for channel parter order inserts. | [optional]
|
20
20
|
**lift_gate** | **BOOLEAN** | Lift gate requested (LTL shipping methods only) | [optional]
|
21
|
+
**pickup_dts** | **String** | Date/time the order should be picked up locally. | [optional]
|
21
22
|
**postal_code** | **String** | Postal code | [optional]
|
22
23
|
**rma** | **String** | RMA number | [optional]
|
23
24
|
**ship_on_date** | **String** | Date the customer is requesting that the order ship on. Typically used for perishable product delivery. | [optional]
|
@@ -97,6 +97,8 @@ module UltracartClient
|
|
97
97
|
# Cancel an order on the UltraCart account. If the success flag is false, then consult the error message for why it failed.
|
98
98
|
# @param order_id The order id to cancel.
|
99
99
|
# @param [Hash] opts the optional parameters
|
100
|
+
# @option opts [BOOLEAN] :lock_self_ship_orders Flag to prevent a order shipping during a refund process
|
101
|
+
# @option opts [BOOLEAN] :skip_refund_and_hold Skip refund and move order to Held Orders department
|
100
102
|
# @return [BaseResponse]
|
101
103
|
def cancel_order(order_id, opts = {})
|
102
104
|
data, _status_code, _headers = cancel_order_with_http_info(order_id, opts)
|
@@ -107,6 +109,8 @@ module UltracartClient
|
|
107
109
|
# Cancel an order on the UltraCart account. If the success flag is false, then consult the error message for why it failed.
|
108
110
|
# @param order_id The order id to cancel.
|
109
111
|
# @param [Hash] opts the optional parameters
|
112
|
+
# @option opts [BOOLEAN] :lock_self_ship_orders Flag to prevent a order shipping during a refund process
|
113
|
+
# @option opts [BOOLEAN] :skip_refund_and_hold Skip refund and move order to Held Orders department
|
110
114
|
# @return [Array<(BaseResponse, Fixnum, Hash)>] BaseResponse data, response status code and response headers
|
111
115
|
def cancel_order_with_http_info(order_id, opts = {})
|
112
116
|
if @api_client.config.debugging
|
@@ -121,6 +125,8 @@ module UltracartClient
|
|
121
125
|
|
122
126
|
# query parameters
|
123
127
|
query_params = {}
|
128
|
+
query_params[:'lock_self_ship_orders'] = opts[:'lock_self_ship_orders'] if !opts[:'lock_self_ship_orders'].nil?
|
129
|
+
query_params[:'skip_refund_and_hold'] = opts[:'skip_refund_and_hold'] if !opts[:'skip_refund_and_hold'].nil?
|
124
130
|
|
125
131
|
# header parameters
|
126
132
|
header_params = {}
|
@@ -165,6 +165,28 @@ module UltracartClient
|
|
165
165
|
# Who may use this coupon.
|
166
166
|
attr_accessor :usable_by
|
167
167
|
|
168
|
+
class EnumAttributeValidator
|
169
|
+
attr_reader :datatype
|
170
|
+
attr_reader :allowable_values
|
171
|
+
|
172
|
+
def initialize(datatype, allowable_values)
|
173
|
+
@allowable_values = allowable_values.map do |value|
|
174
|
+
case datatype.to_s
|
175
|
+
when /Integer/i
|
176
|
+
value.to_i
|
177
|
+
when /Float/i
|
178
|
+
value.to_f
|
179
|
+
else
|
180
|
+
value
|
181
|
+
end
|
182
|
+
end
|
183
|
+
end
|
184
|
+
|
185
|
+
def valid?(value)
|
186
|
+
!value || allowable_values.include?(value)
|
187
|
+
end
|
188
|
+
end
|
189
|
+
|
168
190
|
# Attribute mapping from ruby-style variable name to JSON key.
|
169
191
|
def self.attribute_map
|
170
192
|
{
|
@@ -627,6 +649,8 @@ module UltracartClient
|
|
627
649
|
return false if !@merchant_code.nil? && @merchant_code.to_s.length > 20
|
628
650
|
return false if !@merchant_notes.nil? && @merchant_notes.to_s.length > 250
|
629
651
|
return false if !@quickbooks_code.nil? && @quickbooks_code.to_s.length > 20
|
652
|
+
usable_by_validator = EnumAttributeValidator.new('String', ['Anyone', 'UniqueCode', 'OncePerCustomer', 'OncePerNewCustomer', 'OncePerNewCustomerForItem'])
|
653
|
+
return false unless usable_by_validator.valid?(@usable_by)
|
630
654
|
return false if !@usable_by.nil? && @usable_by.to_s.length > 50
|
631
655
|
true
|
632
656
|
end
|
@@ -681,13 +705,13 @@ module UltracartClient
|
|
681
705
|
@quickbooks_code = quickbooks_code
|
682
706
|
end
|
683
707
|
|
684
|
-
# Custom attribute writer method
|
685
|
-
# @param [Object] usable_by
|
708
|
+
# Custom attribute writer method checking allowed values (enum).
|
709
|
+
# @param [Object] usable_by Object to be assigned
|
686
710
|
def usable_by=(usable_by)
|
687
|
-
|
688
|
-
|
711
|
+
validator = EnumAttributeValidator.new('String', ['Anyone', 'UniqueCode', 'OncePerCustomer', 'OncePerNewCustomer', 'OncePerNewCustomerForItem'])
|
712
|
+
unless validator.valid?(usable_by)
|
713
|
+
fail ArgumentError, 'invalid value for "usable_by", must be one of #{validator.allowable_values}.'
|
689
714
|
end
|
690
|
-
|
691
715
|
@usable_by = usable_by
|
692
716
|
end
|
693
717
|
|
@@ -59,6 +59,9 @@ module UltracartClient
|
|
59
59
|
# Lift gate requested (LTL shipping methods only)
|
60
60
|
attr_accessor :lift_gate
|
61
61
|
|
62
|
+
# Date/time the order should be picked up locally.
|
63
|
+
attr_accessor :pickup_dts
|
64
|
+
|
62
65
|
# Postal code
|
63
66
|
attr_accessor :postal_code
|
64
67
|
|
@@ -121,6 +124,7 @@ module UltracartClient
|
|
121
124
|
:'least_cost_route' => :'least_cost_route',
|
122
125
|
:'least_cost_route_shipping_methods' => :'least_cost_route_shipping_methods',
|
123
126
|
:'lift_gate' => :'lift_gate',
|
127
|
+
:'pickup_dts' => :'pickup_dts',
|
124
128
|
:'postal_code' => :'postal_code',
|
125
129
|
:'rma' => :'rma',
|
126
130
|
:'ship_on_date' => :'ship_on_date',
|
@@ -157,6 +161,7 @@ module UltracartClient
|
|
157
161
|
:'least_cost_route' => :'BOOLEAN',
|
158
162
|
:'least_cost_route_shipping_methods' => :'Array<String>',
|
159
163
|
:'lift_gate' => :'BOOLEAN',
|
164
|
+
:'pickup_dts' => :'String',
|
160
165
|
:'postal_code' => :'String',
|
161
166
|
:'rma' => :'String',
|
162
167
|
:'ship_on_date' => :'String',
|
@@ -245,6 +250,10 @@ module UltracartClient
|
|
245
250
|
self.lift_gate = attributes[:'lift_gate']
|
246
251
|
end
|
247
252
|
|
253
|
+
if attributes.has_key?(:'pickup_dts')
|
254
|
+
self.pickup_dts = attributes[:'pickup_dts']
|
255
|
+
end
|
256
|
+
|
248
257
|
if attributes.has_key?(:'postal_code')
|
249
258
|
self.postal_code = attributes[:'postal_code']
|
250
259
|
end
|
@@ -598,6 +607,7 @@ module UltracartClient
|
|
598
607
|
least_cost_route == o.least_cost_route &&
|
599
608
|
least_cost_route_shipping_methods == o.least_cost_route_shipping_methods &&
|
600
609
|
lift_gate == o.lift_gate &&
|
610
|
+
pickup_dts == o.pickup_dts &&
|
601
611
|
postal_code == o.postal_code &&
|
602
612
|
rma == o.rma &&
|
603
613
|
ship_on_date == o.ship_on_date &&
|
@@ -624,7 +634,7 @@ module UltracartClient
|
|
624
634
|
# Calculates hash code according to all attributes.
|
625
635
|
# @return [Fixnum] Hash code
|
626
636
|
def hash
|
627
|
-
[address1, address2, city, company, country_code, day_phone, day_phone_e164, delivery_date, evening_phone, evening_phone_e164, first_name, last_name, least_cost_route, least_cost_route_shipping_methods, lift_gate, postal_code, rma, ship_on_date, ship_to_residential, shipping_3rd_party_account_number, shipping_date, shipping_department_status, shipping_method, shipping_method_accounting_code, special_instructions, state_region, title, tracking_number_details, tracking_numbers, weight].hash
|
637
|
+
[address1, address2, city, company, country_code, day_phone, day_phone_e164, delivery_date, evening_phone, evening_phone_e164, first_name, last_name, least_cost_route, least_cost_route_shipping_methods, lift_gate, pickup_dts, postal_code, rma, ship_on_date, ship_to_residential, shipping_3rd_party_account_number, shipping_date, shipping_department_status, shipping_method, shipping_method_accounting_code, special_instructions, state_region, title, tracking_number_details, tracking_numbers, weight].hash
|
628
638
|
end
|
629
639
|
|
630
640
|
# Builds the object from hash
|
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.145
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- UltraCart
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-06-
|
11
|
+
date: 2023-06-20 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: typhoeus
|