ultracart_rest_api_v2_typescript 4.0.160 → 4.0.162
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.
- package/README.md +4 -2
- package/dist/apis/OrderApi.d.ts +4 -0
- package/dist/apis/OrderApi.js +6 -0
- package/dist/models/Coupon.d.ts +12 -1
- package/dist/models/Coupon.js +11 -1
- package/dist/models/OrderShipping.d.ts +6 -0
- package/dist/models/OrderShipping.js +2 -0
- package/package.json +1 -1
- package/src/apis/OrderApi.ts +12 -0
- package/src/models/Coupon.ts +15 -1
- package/src/models/OrderShipping.ts +8 -0
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
## ultracart_rest_api_v2_typescript@4.0.
|
|
1
|
+
## ultracart_rest_api_v2_typescript@4.0.162
|
|
2
2
|
|
|
3
3
|
This generator creates TypeScript/JavaScript client that utilizes [Fetch API](https://fetch.spec.whatwg.org/). The generated Node module can be used in the following environments:
|
|
4
4
|
|
|
@@ -36,7 +36,7 @@ navigate to the folder of your consuming project and run one of the following co
|
|
|
36
36
|
_published:_
|
|
37
37
|
|
|
38
38
|
```
|
|
39
|
-
npm install ultracart_rest_api_v2_typescript@4.0.
|
|
39
|
+
npm install ultracart_rest_api_v2_typescript@4.0.162 --save
|
|
40
40
|
```
|
|
41
41
|
|
|
42
42
|
_unPublished (not recommended):_
|
|
@@ -54,6 +54,8 @@ Not every change is committed to every SDK.
|
|
|
54
54
|
|
|
55
55
|
| Version | Date | Comments |
|
|
56
56
|
| --: | :-: | --- |
|
|
57
|
+
| 4.0.162 | 06/20/2023 | coupon add allowed values for usable_by and new OncePerNewCustomerForItem flag |
|
|
58
|
+
| 4.0.161 | 06/15/2023 | add pickup_dts to order.shipping object |
|
|
57
59
|
| 4.0.160 | 06/14/2023 | dw bi: add request_dts on the execute queries request and report data set objects |
|
|
58
60
|
| 4.0.159 | 06/09/2023 | distribution center pickup times |
|
|
59
61
|
| 4.0.158 | 06/08/2023 | customer profile qb tax exempt reason code field |
|
package/dist/apis/OrderApi.d.ts
CHANGED
|
@@ -17,6 +17,8 @@ export interface AdjustOrderTotalRequest {
|
|
|
17
17
|
}
|
|
18
18
|
export interface CancelOrderRequest {
|
|
19
19
|
orderId: string;
|
|
20
|
+
lockSelfShipOrders?: boolean;
|
|
21
|
+
skipRefundAndHold?: boolean;
|
|
20
22
|
}
|
|
21
23
|
export interface DeleteOrderRequest {
|
|
22
24
|
orderId: string;
|
|
@@ -167,6 +169,8 @@ export interface OrderApiInterface {
|
|
|
167
169
|
* Cancel an order on the UltraCart account. If the success flag is false, then consult the error message for why it failed.
|
|
168
170
|
* @summary Cancel an order
|
|
169
171
|
* @param {string} orderId The order id to cancel.
|
|
172
|
+
* @param {boolean} [lockSelfShipOrders] Flag to prevent a order shipping during a refund process
|
|
173
|
+
* @param {boolean} [skipRefundAndHold] Skip refund and move order to Held Orders department
|
|
170
174
|
* @param {*} [options] Override http request option.
|
|
171
175
|
* @throws {RequiredError}
|
|
172
176
|
* @memberof OrderApiInterface
|
package/dist/apis/OrderApi.js
CHANGED
|
@@ -151,6 +151,12 @@ var OrderApi = /** @class */ (function (_super) {
|
|
|
151
151
|
throw new runtime.RequiredError('orderId', 'Required parameter requestParameters.orderId was null or undefined when calling cancelOrder.');
|
|
152
152
|
}
|
|
153
153
|
queryParameters = {};
|
|
154
|
+
if (requestParameters.lockSelfShipOrders !== undefined) {
|
|
155
|
+
queryParameters['lock_self_ship_orders'] = requestParameters.lockSelfShipOrders;
|
|
156
|
+
}
|
|
157
|
+
if (requestParameters.skipRefundAndHold !== undefined) {
|
|
158
|
+
queryParameters['skip_refund_and_hold'] = requestParameters.skipRefundAndHold;
|
|
159
|
+
}
|
|
154
160
|
headerParameters = {};
|
|
155
161
|
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 2];
|
|
156
162
|
// oauth required
|
package/dist/models/Coupon.d.ts
CHANGED
|
@@ -458,8 +458,19 @@ export interface Coupon {
|
|
|
458
458
|
* @type {string}
|
|
459
459
|
* @memberof Coupon
|
|
460
460
|
*/
|
|
461
|
-
usable_by?:
|
|
461
|
+
usable_by?: CouponUsableByEnum;
|
|
462
462
|
}
|
|
463
|
+
/**
|
|
464
|
+
* @export
|
|
465
|
+
*/
|
|
466
|
+
export declare const CouponUsableByEnum: {
|
|
467
|
+
readonly Anyone: "Anyone";
|
|
468
|
+
readonly UniqueCode: "UniqueCode";
|
|
469
|
+
readonly OncePerCustomer: "OncePerCustomer";
|
|
470
|
+
readonly OncePerNewCustomer: "OncePerNewCustomer";
|
|
471
|
+
readonly OncePerNewCustomerForItem: "OncePerNewCustomerForItem";
|
|
472
|
+
};
|
|
473
|
+
export type CouponUsableByEnum = typeof CouponUsableByEnum[keyof typeof CouponUsableByEnum];
|
|
463
474
|
export declare function CouponFromJSON(json: any): Coupon;
|
|
464
475
|
export declare function CouponFromJSONTyped(json: any, ignoreDiscriminator: boolean): Coupon;
|
|
465
476
|
export declare function CouponToJSON(value?: Coupon | null): any;
|
package/dist/models/Coupon.js
CHANGED
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
* Do not edit the class manually.
|
|
14
14
|
*/
|
|
15
15
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
-
exports.CouponToJSON = exports.CouponFromJSONTyped = exports.CouponFromJSON = void 0;
|
|
16
|
+
exports.CouponToJSON = exports.CouponFromJSONTyped = exports.CouponFromJSON = exports.CouponUsableByEnum = void 0;
|
|
17
17
|
var runtime_1 = require("../runtime");
|
|
18
18
|
var CouponAmountOffItems_1 = require("./CouponAmountOffItems");
|
|
19
19
|
var CouponAmountOffShipping_1 = require("./CouponAmountOffShipping");
|
|
@@ -63,6 +63,16 @@ var CouponTieredPercentOffItems_1 = require("./CouponTieredPercentOffItems");
|
|
|
63
63
|
var CouponTieredPercentOffShipping_1 = require("./CouponTieredPercentOffShipping");
|
|
64
64
|
var CouponTieredPercentOffSubtotal_1 = require("./CouponTieredPercentOffSubtotal");
|
|
65
65
|
var CouponTieredPercentOffSubtotalBasedOnMSRP_1 = require("./CouponTieredPercentOffSubtotalBasedOnMSRP");
|
|
66
|
+
/**
|
|
67
|
+
* @export
|
|
68
|
+
*/
|
|
69
|
+
exports.CouponUsableByEnum = {
|
|
70
|
+
Anyone: 'Anyone',
|
|
71
|
+
UniqueCode: 'UniqueCode',
|
|
72
|
+
OncePerCustomer: 'OncePerCustomer',
|
|
73
|
+
OncePerNewCustomer: 'OncePerNewCustomer',
|
|
74
|
+
OncePerNewCustomerForItem: 'OncePerNewCustomerForItem'
|
|
75
|
+
};
|
|
66
76
|
function CouponFromJSON(json) {
|
|
67
77
|
return CouponFromJSONTyped(json, false);
|
|
68
78
|
}
|
|
@@ -107,6 +107,12 @@ export interface OrderShipping {
|
|
|
107
107
|
* @memberof OrderShipping
|
|
108
108
|
*/
|
|
109
109
|
lift_gate?: boolean;
|
|
110
|
+
/**
|
|
111
|
+
* Date/time the order should be picked up locally.
|
|
112
|
+
* @type {string}
|
|
113
|
+
* @memberof OrderShipping
|
|
114
|
+
*/
|
|
115
|
+
pickup_dts?: string;
|
|
110
116
|
/**
|
|
111
117
|
* Postal code
|
|
112
118
|
* @type {string}
|
|
@@ -41,6 +41,7 @@ function OrderShippingFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
41
41
|
'least_cost_route': !(0, runtime_1.exists)(json, 'least_cost_route') ? undefined : json['least_cost_route'],
|
|
42
42
|
'least_cost_route_shipping_methods': !(0, runtime_1.exists)(json, 'least_cost_route_shipping_methods') ? undefined : json['least_cost_route_shipping_methods'],
|
|
43
43
|
'lift_gate': !(0, runtime_1.exists)(json, 'lift_gate') ? undefined : json['lift_gate'],
|
|
44
|
+
'pickup_dts': !(0, runtime_1.exists)(json, 'pickup_dts') ? undefined : json['pickup_dts'],
|
|
44
45
|
'postal_code': !(0, runtime_1.exists)(json, 'postal_code') ? undefined : json['postal_code'],
|
|
45
46
|
'rma': !(0, runtime_1.exists)(json, 'rma') ? undefined : json['rma'],
|
|
46
47
|
'ship_on_date': !(0, runtime_1.exists)(json, 'ship_on_date') ? undefined : json['ship_on_date'],
|
|
@@ -82,6 +83,7 @@ function OrderShippingToJSON(value) {
|
|
|
82
83
|
'least_cost_route': value.least_cost_route,
|
|
83
84
|
'least_cost_route_shipping_methods': value.least_cost_route_shipping_methods,
|
|
84
85
|
'lift_gate': value.lift_gate,
|
|
86
|
+
'pickup_dts': value.pickup_dts,
|
|
85
87
|
'postal_code': value.postal_code,
|
|
86
88
|
'rma': value.rma,
|
|
87
89
|
'ship_on_date': value.ship_on_date,
|
package/package.json
CHANGED
package/src/apis/OrderApi.ts
CHANGED
|
@@ -90,6 +90,8 @@ export interface AdjustOrderTotalRequest {
|
|
|
90
90
|
|
|
91
91
|
export interface CancelOrderRequest {
|
|
92
92
|
orderId: string;
|
|
93
|
+
lockSelfShipOrders?: boolean;
|
|
94
|
+
skipRefundAndHold?: boolean;
|
|
93
95
|
}
|
|
94
96
|
|
|
95
97
|
export interface DeleteOrderRequest {
|
|
@@ -266,6 +268,8 @@ export interface OrderApiInterface {
|
|
|
266
268
|
* Cancel an order on the UltraCart account. If the success flag is false, then consult the error message for why it failed.
|
|
267
269
|
* @summary Cancel an order
|
|
268
270
|
* @param {string} orderId The order id to cancel.
|
|
271
|
+
* @param {boolean} [lockSelfShipOrders] Flag to prevent a order shipping during a refund process
|
|
272
|
+
* @param {boolean} [skipRefundAndHold] Skip refund and move order to Held Orders department
|
|
269
273
|
* @param {*} [options] Override http request option.
|
|
270
274
|
* @throws {RequiredError}
|
|
271
275
|
* @memberof OrderApiInterface
|
|
@@ -778,6 +782,14 @@ export class OrderApi extends runtime.BaseAPI implements OrderApiInterface {
|
|
|
778
782
|
|
|
779
783
|
const queryParameters: any = {};
|
|
780
784
|
|
|
785
|
+
if (requestParameters.lockSelfShipOrders !== undefined) {
|
|
786
|
+
queryParameters['lock_self_ship_orders'] = requestParameters.lockSelfShipOrders;
|
|
787
|
+
}
|
|
788
|
+
|
|
789
|
+
if (requestParameters.skipRefundAndHold !== undefined) {
|
|
790
|
+
queryParameters['skip_refund_and_hold'] = requestParameters.skipRefundAndHold;
|
|
791
|
+
}
|
|
792
|
+
|
|
781
793
|
const headerParameters: runtime.HTTPHeaders = {};
|
|
782
794
|
|
|
783
795
|
if (this.configuration && this.configuration.accessToken) {
|
package/src/models/Coupon.ts
CHANGED
|
@@ -703,9 +703,23 @@ export interface Coupon {
|
|
|
703
703
|
* @type {string}
|
|
704
704
|
* @memberof Coupon
|
|
705
705
|
*/
|
|
706
|
-
usable_by?:
|
|
706
|
+
usable_by?: CouponUsableByEnum;
|
|
707
707
|
}
|
|
708
708
|
|
|
709
|
+
|
|
710
|
+
/**
|
|
711
|
+
* @export
|
|
712
|
+
*/
|
|
713
|
+
export const CouponUsableByEnum = {
|
|
714
|
+
Anyone: 'Anyone',
|
|
715
|
+
UniqueCode: 'UniqueCode',
|
|
716
|
+
OncePerCustomer: 'OncePerCustomer',
|
|
717
|
+
OncePerNewCustomer: 'OncePerNewCustomer',
|
|
718
|
+
OncePerNewCustomerForItem: 'OncePerNewCustomerForItem'
|
|
719
|
+
} as const;
|
|
720
|
+
export type CouponUsableByEnum = typeof CouponUsableByEnum[keyof typeof CouponUsableByEnum];
|
|
721
|
+
|
|
722
|
+
|
|
709
723
|
export function CouponFromJSON(json: any): Coupon {
|
|
710
724
|
return CouponFromJSONTyped(json, false);
|
|
711
725
|
}
|
|
@@ -122,6 +122,12 @@ export interface OrderShipping {
|
|
|
122
122
|
* @memberof OrderShipping
|
|
123
123
|
*/
|
|
124
124
|
lift_gate?: boolean;
|
|
125
|
+
/**
|
|
126
|
+
* Date/time the order should be picked up locally.
|
|
127
|
+
* @type {string}
|
|
128
|
+
* @memberof OrderShipping
|
|
129
|
+
*/
|
|
130
|
+
pickup_dts?: string;
|
|
125
131
|
/**
|
|
126
132
|
* Postal code
|
|
127
133
|
* @type {string}
|
|
@@ -239,6 +245,7 @@ export function OrderShippingFromJSONTyped(json: any, ignoreDiscriminator: boole
|
|
|
239
245
|
'least_cost_route': !exists(json, 'least_cost_route') ? undefined : json['least_cost_route'],
|
|
240
246
|
'least_cost_route_shipping_methods': !exists(json, 'least_cost_route_shipping_methods') ? undefined : json['least_cost_route_shipping_methods'],
|
|
241
247
|
'lift_gate': !exists(json, 'lift_gate') ? undefined : json['lift_gate'],
|
|
248
|
+
'pickup_dts': !exists(json, 'pickup_dts') ? undefined : json['pickup_dts'],
|
|
242
249
|
'postal_code': !exists(json, 'postal_code') ? undefined : json['postal_code'],
|
|
243
250
|
'rma': !exists(json, 'rma') ? undefined : json['rma'],
|
|
244
251
|
'ship_on_date': !exists(json, 'ship_on_date') ? undefined : json['ship_on_date'],
|
|
@@ -281,6 +288,7 @@ export function OrderShippingToJSON(value?: OrderShipping | null): any {
|
|
|
281
288
|
'least_cost_route': value.least_cost_route,
|
|
282
289
|
'least_cost_route_shipping_methods': value.least_cost_route_shipping_methods,
|
|
283
290
|
'lift_gate': value.lift_gate,
|
|
291
|
+
'pickup_dts': value.pickup_dts,
|
|
284
292
|
'postal_code': value.postal_code,
|
|
285
293
|
'rma': value.rma,
|
|
286
294
|
'ship_on_date': value.ship_on_date,
|