@digital8/lighting-illusions-ts-sdk 0.0.2496 → 0.0.2498
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/.openapi-generator/FILES +15 -9
- package/README.md +2 -2
- package/dist/apis/CouponsApi.d.ts +85 -0
- package/dist/apis/CouponsApi.js +355 -0
- package/dist/apis/index.d.ts +1 -1
- package/dist/apis/index.js +1 -1
- package/dist/models/AppliedCouponResource.d.ts +30 -0
- package/dist/models/AppliedCouponResource.js +20 -0
- package/dist/models/CouponListResource.d.ts +99 -0
- package/dist/models/CouponListResource.js +91 -0
- package/dist/models/CouponListResourceArrayResponse.d.ts +33 -0
- package/dist/models/CouponListResourceArrayResponse.js +50 -0
- package/dist/models/CouponLiteResource.d.ts +44 -0
- package/dist/models/CouponLiteResource.js +57 -0
- package/dist/models/CouponLiteResourceArrayResponse.d.ts +33 -0
- package/dist/models/CouponLiteResourceArrayResponse.js +50 -0
- package/dist/models/CouponResource.d.ts +163 -0
- package/dist/models/CouponResource.js +135 -0
- package/dist/models/CouponResourceArrayResponse.d.ts +33 -0
- package/dist/models/CouponResourceArrayResponse.js +50 -0
- package/dist/models/CouponType.d.ts +26 -0
- package/dist/models/CouponType.js +52 -0
- package/dist/models/CreateCouponRequest.d.ts +126 -0
- package/dist/models/CreateCouponRequest.js +107 -0
- package/dist/models/CreateCouponRequestCouponablesInner.d.ts +48 -0
- package/dist/models/CreateCouponRequestCouponablesInner.js +61 -0
- package/dist/models/FrontendCartResource.d.ts +6 -0
- package/dist/models/FrontendCartResource.js +2 -0
- package/dist/models/FrontendOrderResource.d.ts +0 -7
- package/dist/models/FrontendOrderResource.js +0 -5
- package/dist/models/OrderFulfillmentResource.d.ts +1 -1
- package/dist/models/OrderFulfillmentResource.js +3 -1
- package/dist/models/PaginatedCouponListResourceResponse.d.ts +40 -0
- package/dist/models/PaginatedCouponListResourceResponse.js +57 -0
- package/dist/models/PaginatedCouponResourceResponse.d.ts +40 -0
- package/dist/models/PaginatedCouponResourceResponse.js +57 -0
- package/dist/models/ProductCategoryLiteResource.d.ts +6 -0
- package/dist/models/ProductCategoryLiteResource.js +4 -0
- package/dist/models/ProductChildListResource.d.ts +6 -0
- package/dist/models/ProductChildListResource.js +4 -0
- package/dist/models/SearchAllCouponsRequest.d.ts +101 -0
- package/dist/models/SearchAllCouponsRequest.js +85 -0
- package/dist/models/SearchCartsRequest.d.ts +6 -0
- package/dist/models/SearchCartsRequest.js +2 -0
- package/dist/models/SearchCouponsRequest.d.ts +137 -0
- package/dist/models/SearchCouponsRequest.js +97 -0
- package/dist/models/SearchOrdersRequest.d.ts +6 -0
- package/dist/models/SearchOrdersRequest.js +2 -0
- package/dist/models/StoreFrontendResource.d.ts +1 -1
- package/dist/models/StoreFrontendResource.js +3 -1
- package/dist/models/StoreListResource.d.ts +2 -2
- package/dist/models/StoreListResource.js +2 -6
- package/dist/models/StoreResource.d.ts +1 -1
- package/dist/models/StoreResource.js +3 -1
- package/dist/models/UpdateCouponRequest.d.ts +120 -0
- package/dist/models/UpdateCouponRequest.js +103 -0
- package/dist/models/index.d.ts +14 -8
- package/dist/models/index.js +14 -8
- package/package.json +1 -1
- package/src/apis/CouponsApi.ts +286 -0
- package/src/apis/index.ts +1 -1
- package/src/models/AppliedCouponResource.ts +45 -0
- package/src/models/CouponListResource.ts +170 -0
- package/src/models/CouponListResourceArrayResponse.ts +73 -0
- package/src/models/CouponLiteResource.ts +83 -0
- package/src/models/CouponLiteResourceArrayResponse.ts +73 -0
- package/src/models/CouponResource.ts +288 -0
- package/src/models/CouponResourceArrayResponse.ts +73 -0
- package/src/models/CouponType.ts +54 -0
- package/src/models/CreateCouponRequest.ts +207 -0
- package/src/models/CreateCouponRequestCouponablesInner.ts +86 -0
- package/src/models/FrontendCartResource.ts +8 -0
- package/src/models/FrontendOrderResource.ts +0 -16
- package/src/models/OrderFulfillmentResource.ts +3 -2
- package/src/models/PaginatedCouponListResourceResponse.ts +90 -0
- package/src/models/PaginatedCouponResourceResponse.ts +90 -0
- package/src/models/ProductCategoryLiteResource.ts +9 -0
- package/src/models/ProductChildListResource.ts +9 -0
- package/src/models/SearchAllCouponsRequest.ts +154 -0
- package/src/models/SearchCartsRequest.ts +8 -0
- package/src/models/SearchCouponsRequest.ts +202 -0
- package/src/models/SearchOrdersRequest.ts +8 -0
- package/src/models/StoreFrontendResource.ts +3 -2
- package/src/models/StoreListResource.ts +4 -6
- package/src/models/StoreResource.ts +3 -2
- package/src/models/UpdateCouponRequest.ts +198 -0
- package/src/models/index.ts +14 -8
- package/dist/apis/AuspostApi.d.ts +0 -29
- package/dist/apis/AuspostApi.js +0 -125
- package/dist/models/FrontendOrderFulfillmentResource.d.ts +0 -62
- package/dist/models/FrontendOrderFulfillmentResource.js +0 -71
- package/dist/models/FrontendOrderFulfillmentResourceArrayResponse.d.ts +0 -33
- package/dist/models/FrontendOrderFulfillmentResourceArrayResponse.js +0 -50
- package/dist/models/FrontendOrderListResource.d.ts +0 -70
- package/dist/models/FrontendOrderListResource.js +0 -77
- package/dist/models/FrontendOrderListResourceArrayResponse.d.ts +0 -33
- package/dist/models/FrontendOrderListResourceArrayResponse.js +0 -50
- package/dist/models/PaginatedFrontendOrderListResourceResponse.d.ts +0 -40
- package/dist/models/PaginatedFrontendOrderListResourceResponse.js +0 -57
- package/dist/models/SuburbValidationResource.d.ts +0 -32
- package/dist/models/SuburbValidationResource.js +0 -51
- package/dist/models/SuburbValidationResourceArrayResponse.d.ts +0 -33
- package/dist/models/SuburbValidationResourceArrayResponse.js +0 -50
- package/dist/models/ValidateSuburbRequest.d.ts +0 -50
- package/dist/models/ValidateSuburbRequest.js +0 -63
- package/src/apis/AuspostApi.ts +0 -69
- package/src/models/FrontendOrderFulfillmentResource.ts +0 -111
- package/src/models/FrontendOrderFulfillmentResourceArrayResponse.ts +0 -73
- package/src/models/FrontendOrderListResource.ts +0 -135
- package/src/models/FrontendOrderListResourceArrayResponse.ts +0 -73
- package/src/models/PaginatedFrontendOrderListResourceResponse.ts +0 -90
- package/src/models/SuburbValidationResource.ts +0 -66
- package/src/models/SuburbValidationResourceArrayResponse.ts +0 -73
- package/src/models/ValidateSuburbRequest.ts +0 -93
|
@@ -0,0 +1,207 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* My API
|
|
5
|
+
* API documentation for my Laravel app
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
import type { CreateCouponRequestCouponablesInner } from './CreateCouponRequestCouponablesInner';
|
|
17
|
+
import {
|
|
18
|
+
CreateCouponRequestCouponablesInnerFromJSON,
|
|
19
|
+
CreateCouponRequestCouponablesInnerFromJSONTyped,
|
|
20
|
+
CreateCouponRequestCouponablesInnerToJSON,
|
|
21
|
+
CreateCouponRequestCouponablesInnerToJSONTyped,
|
|
22
|
+
} from './CreateCouponRequestCouponablesInner';
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
* @export
|
|
27
|
+
* @interface CreateCouponRequest
|
|
28
|
+
*/
|
|
29
|
+
export interface CreateCouponRequest {
|
|
30
|
+
/**
|
|
31
|
+
*
|
|
32
|
+
* @type {number}
|
|
33
|
+
* @memberof CreateCouponRequest
|
|
34
|
+
*/
|
|
35
|
+
siteId: number;
|
|
36
|
+
/**
|
|
37
|
+
*
|
|
38
|
+
* @type {string}
|
|
39
|
+
* @memberof CreateCouponRequest
|
|
40
|
+
*/
|
|
41
|
+
name: string;
|
|
42
|
+
/**
|
|
43
|
+
*
|
|
44
|
+
* @type {string}
|
|
45
|
+
* @memberof CreateCouponRequest
|
|
46
|
+
*/
|
|
47
|
+
code: string;
|
|
48
|
+
/**
|
|
49
|
+
*
|
|
50
|
+
* @type {string}
|
|
51
|
+
* @memberof CreateCouponRequest
|
|
52
|
+
*/
|
|
53
|
+
type: CreateCouponRequestTypeEnum;
|
|
54
|
+
/**
|
|
55
|
+
*
|
|
56
|
+
* @type {string}
|
|
57
|
+
* @memberof CreateCouponRequest
|
|
58
|
+
*/
|
|
59
|
+
discountType: string;
|
|
60
|
+
/**
|
|
61
|
+
*
|
|
62
|
+
* @type {number}
|
|
63
|
+
* @memberof CreateCouponRequest
|
|
64
|
+
*/
|
|
65
|
+
discountAmount: number;
|
|
66
|
+
/**
|
|
67
|
+
*
|
|
68
|
+
* @type {number}
|
|
69
|
+
* @memberof CreateCouponRequest
|
|
70
|
+
*/
|
|
71
|
+
minAmount: number;
|
|
72
|
+
/**
|
|
73
|
+
*
|
|
74
|
+
* @type {number}
|
|
75
|
+
* @memberof CreateCouponRequest
|
|
76
|
+
*/
|
|
77
|
+
minProducts: number;
|
|
78
|
+
/**
|
|
79
|
+
*
|
|
80
|
+
* @type {number}
|
|
81
|
+
* @memberof CreateCouponRequest
|
|
82
|
+
*/
|
|
83
|
+
totalUseLimit: number;
|
|
84
|
+
/**
|
|
85
|
+
*
|
|
86
|
+
* @type {number}
|
|
87
|
+
* @memberof CreateCouponRequest
|
|
88
|
+
*/
|
|
89
|
+
customerUseLimit: number;
|
|
90
|
+
/**
|
|
91
|
+
*
|
|
92
|
+
* @type {string}
|
|
93
|
+
* @memberof CreateCouponRequest
|
|
94
|
+
*/
|
|
95
|
+
startDate?: string | null;
|
|
96
|
+
/**
|
|
97
|
+
*
|
|
98
|
+
* @type {string}
|
|
99
|
+
* @memberof CreateCouponRequest
|
|
100
|
+
*/
|
|
101
|
+
endDate?: string | null;
|
|
102
|
+
/**
|
|
103
|
+
*
|
|
104
|
+
* @type {boolean}
|
|
105
|
+
* @memberof CreateCouponRequest
|
|
106
|
+
*/
|
|
107
|
+
isForAllProducts?: boolean;
|
|
108
|
+
/**
|
|
109
|
+
*
|
|
110
|
+
* @type {boolean}
|
|
111
|
+
* @memberof CreateCouponRequest
|
|
112
|
+
*/
|
|
113
|
+
isForAllCustomers?: boolean;
|
|
114
|
+
/**
|
|
115
|
+
*
|
|
116
|
+
* @type {Array<CreateCouponRequestCouponablesInner>}
|
|
117
|
+
* @memberof CreateCouponRequest
|
|
118
|
+
*/
|
|
119
|
+
couponables?: Array<CreateCouponRequestCouponablesInner>;
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
|
|
123
|
+
/**
|
|
124
|
+
* @export
|
|
125
|
+
*/
|
|
126
|
+
export const CreateCouponRequestTypeEnum = {
|
|
127
|
+
Subtotal: 'subtotal',
|
|
128
|
+
Product: 'product',
|
|
129
|
+
Shipping: 'shipping'
|
|
130
|
+
} as const;
|
|
131
|
+
export type CreateCouponRequestTypeEnum = typeof CreateCouponRequestTypeEnum[keyof typeof CreateCouponRequestTypeEnum];
|
|
132
|
+
|
|
133
|
+
|
|
134
|
+
/**
|
|
135
|
+
* Check if a given object implements the CreateCouponRequest interface.
|
|
136
|
+
*/
|
|
137
|
+
export function instanceOfCreateCouponRequest(value: object): value is CreateCouponRequest {
|
|
138
|
+
if (!('siteId' in value) || value['siteId'] === undefined) return false;
|
|
139
|
+
if (!('name' in value) || value['name'] === undefined) return false;
|
|
140
|
+
if (!('code' in value) || value['code'] === undefined) return false;
|
|
141
|
+
if (!('type' in value) || value['type'] === undefined) return false;
|
|
142
|
+
if (!('discountType' in value) || value['discountType'] === undefined) return false;
|
|
143
|
+
if (!('discountAmount' in value) || value['discountAmount'] === undefined) return false;
|
|
144
|
+
if (!('minAmount' in value) || value['minAmount'] === undefined) return false;
|
|
145
|
+
if (!('minProducts' in value) || value['minProducts'] === undefined) return false;
|
|
146
|
+
if (!('totalUseLimit' in value) || value['totalUseLimit'] === undefined) return false;
|
|
147
|
+
if (!('customerUseLimit' in value) || value['customerUseLimit'] === undefined) return false;
|
|
148
|
+
return true;
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
export function CreateCouponRequestFromJSON(json: any): CreateCouponRequest {
|
|
152
|
+
return CreateCouponRequestFromJSONTyped(json, false);
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
export function CreateCouponRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): CreateCouponRequest {
|
|
156
|
+
if (json == null) {
|
|
157
|
+
return json;
|
|
158
|
+
}
|
|
159
|
+
return {
|
|
160
|
+
|
|
161
|
+
'siteId': json['site_id'],
|
|
162
|
+
'name': json['name'],
|
|
163
|
+
'code': json['code'],
|
|
164
|
+
'type': json['type'],
|
|
165
|
+
'discountType': json['discount_type'],
|
|
166
|
+
'discountAmount': json['discount_amount'],
|
|
167
|
+
'minAmount': json['min_amount'],
|
|
168
|
+
'minProducts': json['min_products'],
|
|
169
|
+
'totalUseLimit': json['total_use_limit'],
|
|
170
|
+
'customerUseLimit': json['customer_use_limit'],
|
|
171
|
+
'startDate': json['start_date'] == null ? undefined : json['start_date'],
|
|
172
|
+
'endDate': json['end_date'] == null ? undefined : json['end_date'],
|
|
173
|
+
'isForAllProducts': json['is_for_all_products'] == null ? undefined : json['is_for_all_products'],
|
|
174
|
+
'isForAllCustomers': json['is_for_all_customers'] == null ? undefined : json['is_for_all_customers'],
|
|
175
|
+
'couponables': json['couponables'] == null ? undefined : ((json['couponables'] as Array<any>).map(CreateCouponRequestCouponablesInnerFromJSON)),
|
|
176
|
+
};
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
export function CreateCouponRequestToJSON(json: any): CreateCouponRequest {
|
|
180
|
+
return CreateCouponRequestToJSONTyped(json, false);
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
export function CreateCouponRequestToJSONTyped(value?: CreateCouponRequest | null, ignoreDiscriminator: boolean = false): any {
|
|
184
|
+
if (value == null) {
|
|
185
|
+
return value;
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
return {
|
|
189
|
+
|
|
190
|
+
'site_id': value['siteId'],
|
|
191
|
+
'name': value['name'],
|
|
192
|
+
'code': value['code'],
|
|
193
|
+
'type': value['type'],
|
|
194
|
+
'discount_type': value['discountType'],
|
|
195
|
+
'discount_amount': value['discountAmount'],
|
|
196
|
+
'min_amount': value['minAmount'],
|
|
197
|
+
'min_products': value['minProducts'],
|
|
198
|
+
'total_use_limit': value['totalUseLimit'],
|
|
199
|
+
'customer_use_limit': value['customerUseLimit'],
|
|
200
|
+
'start_date': value['startDate'],
|
|
201
|
+
'end_date': value['endDate'],
|
|
202
|
+
'is_for_all_products': value['isForAllProducts'],
|
|
203
|
+
'is_for_all_customers': value['isForAllCustomers'],
|
|
204
|
+
'couponables': value['couponables'] == null ? undefined : ((value['couponables'] as Array<any>).map(CreateCouponRequestCouponablesInnerToJSON)),
|
|
205
|
+
};
|
|
206
|
+
}
|
|
207
|
+
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* My API
|
|
5
|
+
* API documentation for my Laravel app
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
/**
|
|
17
|
+
*
|
|
18
|
+
* @export
|
|
19
|
+
* @interface CreateCouponRequestCouponablesInner
|
|
20
|
+
*/
|
|
21
|
+
export interface CreateCouponRequestCouponablesInner {
|
|
22
|
+
/**
|
|
23
|
+
*
|
|
24
|
+
* @type {string}
|
|
25
|
+
* @memberof CreateCouponRequestCouponablesInner
|
|
26
|
+
*/
|
|
27
|
+
type?: CreateCouponRequestCouponablesInnerTypeEnum;
|
|
28
|
+
/**
|
|
29
|
+
*
|
|
30
|
+
* @type {number}
|
|
31
|
+
* @memberof CreateCouponRequestCouponablesInner
|
|
32
|
+
*/
|
|
33
|
+
id?: number;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* @export
|
|
39
|
+
*/
|
|
40
|
+
export const CreateCouponRequestCouponablesInnerTypeEnum = {
|
|
41
|
+
ProductChild: 'productChild',
|
|
42
|
+
ProductCategory: 'productCategory',
|
|
43
|
+
Supplier: 'supplier',
|
|
44
|
+
Customer: 'customer'
|
|
45
|
+
} as const;
|
|
46
|
+
export type CreateCouponRequestCouponablesInnerTypeEnum = typeof CreateCouponRequestCouponablesInnerTypeEnum[keyof typeof CreateCouponRequestCouponablesInnerTypeEnum];
|
|
47
|
+
|
|
48
|
+
|
|
49
|
+
/**
|
|
50
|
+
* Check if a given object implements the CreateCouponRequestCouponablesInner interface.
|
|
51
|
+
*/
|
|
52
|
+
export function instanceOfCreateCouponRequestCouponablesInner(value: object): value is CreateCouponRequestCouponablesInner {
|
|
53
|
+
return true;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
export function CreateCouponRequestCouponablesInnerFromJSON(json: any): CreateCouponRequestCouponablesInner {
|
|
57
|
+
return CreateCouponRequestCouponablesInnerFromJSONTyped(json, false);
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
export function CreateCouponRequestCouponablesInnerFromJSONTyped(json: any, ignoreDiscriminator: boolean): CreateCouponRequestCouponablesInner {
|
|
61
|
+
if (json == null) {
|
|
62
|
+
return json;
|
|
63
|
+
}
|
|
64
|
+
return {
|
|
65
|
+
|
|
66
|
+
'type': json['type'] == null ? undefined : json['type'],
|
|
67
|
+
'id': json['id'] == null ? undefined : json['id'],
|
|
68
|
+
};
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
export function CreateCouponRequestCouponablesInnerToJSON(json: any): CreateCouponRequestCouponablesInner {
|
|
72
|
+
return CreateCouponRequestCouponablesInnerToJSONTyped(json, false);
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
export function CreateCouponRequestCouponablesInnerToJSONTyped(value?: CreateCouponRequestCouponablesInner | null, ignoreDiscriminator: boolean = false): any {
|
|
76
|
+
if (value == null) {
|
|
77
|
+
return value;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
return {
|
|
81
|
+
|
|
82
|
+
'type': value['type'],
|
|
83
|
+
'id': value['id'],
|
|
84
|
+
};
|
|
85
|
+
}
|
|
86
|
+
|
|
@@ -114,6 +114,12 @@ export interface FrontendCartResource {
|
|
|
114
114
|
* @memberof FrontendCartResource
|
|
115
115
|
*/
|
|
116
116
|
coupons: Array<FrontendCartResourceCouponsInner>;
|
|
117
|
+
/**
|
|
118
|
+
*
|
|
119
|
+
* @type {string}
|
|
120
|
+
* @memberof FrontendCartResource
|
|
121
|
+
*/
|
|
122
|
+
couponWarning?: string | null;
|
|
117
123
|
/**
|
|
118
124
|
*
|
|
119
125
|
* @type {number}
|
|
@@ -229,6 +235,7 @@ export function FrontendCartResourceFromJSONTyped(json: any, ignoreDiscriminator
|
|
|
229
235
|
'billingAddress': AddressResourceFromJSON(json['billingAddress']),
|
|
230
236
|
'lineItems': (json['lineItems'] == null ? null : (json['lineItems'] as Array<any>).map(FrontendLineItemResourceFromJSON)),
|
|
231
237
|
'coupons': ((json['coupons'] as Array<any>).map(FrontendCartResourceCouponsInnerFromJSON)),
|
|
238
|
+
'couponWarning': json['couponWarning'] == null ? undefined : json['couponWarning'],
|
|
232
239
|
'subtotal': json['subtotal'],
|
|
233
240
|
'subtotalAfterDiscounts': json['subtotalAfterDiscounts'],
|
|
234
241
|
'promotionalDiscount': json['promotionalDiscount'],
|
|
@@ -265,6 +272,7 @@ export function FrontendCartResourceToJSONTyped(value?: FrontendCartResource | n
|
|
|
265
272
|
'billingAddress': AddressResourceToJSON(value['billingAddress']),
|
|
266
273
|
'lineItems': (value['lineItems'] == null ? null : (value['lineItems'] as Array<any>).map(FrontendLineItemResourceToJSON)),
|
|
267
274
|
'coupons': ((value['coupons'] as Array<any>).map(FrontendCartResourceCouponsInnerToJSON)),
|
|
275
|
+
'couponWarning': value['couponWarning'],
|
|
268
276
|
'subtotal': value['subtotal'],
|
|
269
277
|
'subtotalAfterDiscounts': value['subtotalAfterDiscounts'],
|
|
270
278
|
'promotionalDiscount': value['promotionalDiscount'],
|
|
@@ -41,13 +41,6 @@ import {
|
|
|
41
41
|
AddressResourceToJSON,
|
|
42
42
|
AddressResourceToJSONTyped,
|
|
43
43
|
} from './AddressResource';
|
|
44
|
-
import type { FrontendOrderFulfillmentResource } from './FrontendOrderFulfillmentResource';
|
|
45
|
-
import {
|
|
46
|
-
FrontendOrderFulfillmentResourceFromJSON,
|
|
47
|
-
FrontendOrderFulfillmentResourceFromJSONTyped,
|
|
48
|
-
FrontendOrderFulfillmentResourceToJSON,
|
|
49
|
-
FrontendOrderFulfillmentResourceToJSONTyped,
|
|
50
|
-
} from './FrontendOrderFulfillmentResource';
|
|
51
44
|
|
|
52
45
|
/**
|
|
53
46
|
*
|
|
@@ -133,12 +126,6 @@ export interface FrontendOrderResource {
|
|
|
133
126
|
* @memberof FrontendOrderResource
|
|
134
127
|
*/
|
|
135
128
|
lineItems: Array<FrontendLineItemResource> | null;
|
|
136
|
-
/**
|
|
137
|
-
*
|
|
138
|
-
* @type {Array<FrontendOrderFulfillmentResource>}
|
|
139
|
-
* @memberof FrontendOrderResource
|
|
140
|
-
*/
|
|
141
|
-
fulfillments: Array<FrontendOrderFulfillmentResource> | null;
|
|
142
129
|
/**
|
|
143
130
|
*
|
|
144
131
|
* @type {Array<FrontendCartResourceCouponsInner>}
|
|
@@ -221,7 +208,6 @@ export function instanceOfFrontendOrderResource(value: object): value is Fronten
|
|
|
221
208
|
if (!('shippingAddress' in value) || value['shippingAddress'] === undefined) return false;
|
|
222
209
|
if (!('billingAddress' in value) || value['billingAddress'] === undefined) return false;
|
|
223
210
|
if (!('lineItems' in value) || value['lineItems'] === undefined) return false;
|
|
224
|
-
if (!('fulfillments' in value) || value['fulfillments'] === undefined) return false;
|
|
225
211
|
if (!('coupons' in value) || value['coupons'] === undefined) return false;
|
|
226
212
|
if (!('subtotal' in value) || value['subtotal'] === undefined) return false;
|
|
227
213
|
if (!('promotionalDiscount' in value) || value['promotionalDiscount'] === undefined) return false;
|
|
@@ -259,7 +245,6 @@ export function FrontendOrderResourceFromJSONTyped(json: any, ignoreDiscriminato
|
|
|
259
245
|
'shippingAddress': AddressResourceFromJSON(json['shippingAddress']),
|
|
260
246
|
'billingAddress': AddressResourceFromJSON(json['billingAddress']),
|
|
261
247
|
'lineItems': (json['lineItems'] == null ? null : (json['lineItems'] as Array<any>).map(FrontendLineItemResourceFromJSON)),
|
|
262
|
-
'fulfillments': (json['fulfillments'] == null ? null : (json['fulfillments'] as Array<any>).map(FrontendOrderFulfillmentResourceFromJSON)),
|
|
263
248
|
'coupons': ((json['coupons'] as Array<any>).map(FrontendCartResourceCouponsInnerFromJSON)),
|
|
264
249
|
'subtotal': json['subtotal'],
|
|
265
250
|
'promotionalDiscount': json['promotionalDiscount'],
|
|
@@ -298,7 +283,6 @@ export function FrontendOrderResourceToJSONTyped(value?: FrontendOrderResource |
|
|
|
298
283
|
'shippingAddress': AddressResourceToJSON(value['shippingAddress']),
|
|
299
284
|
'billingAddress': AddressResourceToJSON(value['billingAddress']),
|
|
300
285
|
'lineItems': (value['lineItems'] == null ? null : (value['lineItems'] as Array<any>).map(FrontendLineItemResourceToJSON)),
|
|
301
|
-
'fulfillments': (value['fulfillments'] == null ? null : (value['fulfillments'] as Array<any>).map(FrontendOrderFulfillmentResourceToJSON)),
|
|
302
286
|
'coupons': ((value['coupons'] as Array<any>).map(FrontendCartResourceCouponsInnerToJSON)),
|
|
303
287
|
'subtotal': value['subtotal'],
|
|
304
288
|
'promotionalDiscount': value['promotionalDiscount'],
|
|
@@ -56,7 +56,7 @@ export interface OrderFulfillmentResource {
|
|
|
56
56
|
* @type {string}
|
|
57
57
|
* @memberof OrderFulfillmentResource
|
|
58
58
|
*/
|
|
59
|
-
trackingUrl
|
|
59
|
+
trackingUrl: string;
|
|
60
60
|
/**
|
|
61
61
|
*
|
|
62
62
|
* @type {string}
|
|
@@ -103,6 +103,7 @@ export function instanceOfOrderFulfillmentResource(value: object): value is Orde
|
|
|
103
103
|
if (!('orderId' in value) || value['orderId'] === undefined) return false;
|
|
104
104
|
if (!('dateShipped' in value) || value['dateShipped'] === undefined) return false;
|
|
105
105
|
if (!('trackingNumber' in value) || value['trackingNumber'] === undefined) return false;
|
|
106
|
+
if (!('trackingUrl' in value) || value['trackingUrl'] === undefined) return false;
|
|
106
107
|
if (!('trackingCompany' in value) || value['trackingCompany'] === undefined) return false;
|
|
107
108
|
if (!('docnum' in value) || value['docnum'] === undefined) return false;
|
|
108
109
|
if (!('netsuiteId' in value) || value['netsuiteId'] === undefined) return false;
|
|
@@ -124,7 +125,7 @@ export function OrderFulfillmentResourceFromJSONTyped(json: any, ignoreDiscrimin
|
|
|
124
125
|
'orderId': json['orderId'],
|
|
125
126
|
'dateShipped': (new Date(json['dateShipped'])),
|
|
126
127
|
'trackingNumber': json['trackingNumber'],
|
|
127
|
-
'trackingUrl': json['trackingUrl']
|
|
128
|
+
'trackingUrl': json['trackingUrl'],
|
|
128
129
|
'trackingCompany': json['trackingCompany'],
|
|
129
130
|
'docnum': json['docnum'],
|
|
130
131
|
'netsuiteId': json['netsuiteId'],
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* My API
|
|
5
|
+
* API documentation for my Laravel app
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
import type { PagingMetadata } from './PagingMetadata';
|
|
17
|
+
import {
|
|
18
|
+
PagingMetadataFromJSON,
|
|
19
|
+
PagingMetadataFromJSONTyped,
|
|
20
|
+
PagingMetadataToJSON,
|
|
21
|
+
PagingMetadataToJSONTyped,
|
|
22
|
+
} from './PagingMetadata';
|
|
23
|
+
import type { CouponListResource } from './CouponListResource';
|
|
24
|
+
import {
|
|
25
|
+
CouponListResourceFromJSON,
|
|
26
|
+
CouponListResourceFromJSONTyped,
|
|
27
|
+
CouponListResourceToJSON,
|
|
28
|
+
CouponListResourceToJSONTyped,
|
|
29
|
+
} from './CouponListResource';
|
|
30
|
+
|
|
31
|
+
/**
|
|
32
|
+
*
|
|
33
|
+
* @export
|
|
34
|
+
* @interface PaginatedCouponListResourceResponse
|
|
35
|
+
*/
|
|
36
|
+
export interface PaginatedCouponListResourceResponse {
|
|
37
|
+
/**
|
|
38
|
+
*
|
|
39
|
+
* @type {Array<CouponListResource>}
|
|
40
|
+
* @memberof PaginatedCouponListResourceResponse
|
|
41
|
+
*/
|
|
42
|
+
data: Array<CouponListResource>;
|
|
43
|
+
/**
|
|
44
|
+
*
|
|
45
|
+
* @type {PagingMetadata}
|
|
46
|
+
* @memberof PaginatedCouponListResourceResponse
|
|
47
|
+
*/
|
|
48
|
+
meta: PagingMetadata;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
/**
|
|
52
|
+
* Check if a given object implements the PaginatedCouponListResourceResponse interface.
|
|
53
|
+
*/
|
|
54
|
+
export function instanceOfPaginatedCouponListResourceResponse(value: object): value is PaginatedCouponListResourceResponse {
|
|
55
|
+
if (!('data' in value) || value['data'] === undefined) return false;
|
|
56
|
+
if (!('meta' in value) || value['meta'] === undefined) return false;
|
|
57
|
+
return true;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
export function PaginatedCouponListResourceResponseFromJSON(json: any): PaginatedCouponListResourceResponse {
|
|
61
|
+
return PaginatedCouponListResourceResponseFromJSONTyped(json, false);
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
export function PaginatedCouponListResourceResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): PaginatedCouponListResourceResponse {
|
|
65
|
+
if (json == null) {
|
|
66
|
+
return json;
|
|
67
|
+
}
|
|
68
|
+
return {
|
|
69
|
+
|
|
70
|
+
'data': ((json['data'] as Array<any>).map(CouponListResourceFromJSON)),
|
|
71
|
+
'meta': PagingMetadataFromJSON(json['meta']),
|
|
72
|
+
};
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
export function PaginatedCouponListResourceResponseToJSON(json: any): PaginatedCouponListResourceResponse {
|
|
76
|
+
return PaginatedCouponListResourceResponseToJSONTyped(json, false);
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
export function PaginatedCouponListResourceResponseToJSONTyped(value?: PaginatedCouponListResourceResponse | null, ignoreDiscriminator: boolean = false): any {
|
|
80
|
+
if (value == null) {
|
|
81
|
+
return value;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
return {
|
|
85
|
+
|
|
86
|
+
'data': ((value['data'] as Array<any>).map(CouponListResourceToJSON)),
|
|
87
|
+
'meta': PagingMetadataToJSON(value['meta']),
|
|
88
|
+
};
|
|
89
|
+
}
|
|
90
|
+
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* My API
|
|
5
|
+
* API documentation for my Laravel app
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
import type { PagingMetadata } from './PagingMetadata';
|
|
17
|
+
import {
|
|
18
|
+
PagingMetadataFromJSON,
|
|
19
|
+
PagingMetadataFromJSONTyped,
|
|
20
|
+
PagingMetadataToJSON,
|
|
21
|
+
PagingMetadataToJSONTyped,
|
|
22
|
+
} from './PagingMetadata';
|
|
23
|
+
import type { CouponResource } from './CouponResource';
|
|
24
|
+
import {
|
|
25
|
+
CouponResourceFromJSON,
|
|
26
|
+
CouponResourceFromJSONTyped,
|
|
27
|
+
CouponResourceToJSON,
|
|
28
|
+
CouponResourceToJSONTyped,
|
|
29
|
+
} from './CouponResource';
|
|
30
|
+
|
|
31
|
+
/**
|
|
32
|
+
*
|
|
33
|
+
* @export
|
|
34
|
+
* @interface PaginatedCouponResourceResponse
|
|
35
|
+
*/
|
|
36
|
+
export interface PaginatedCouponResourceResponse {
|
|
37
|
+
/**
|
|
38
|
+
*
|
|
39
|
+
* @type {Array<CouponResource>}
|
|
40
|
+
* @memberof PaginatedCouponResourceResponse
|
|
41
|
+
*/
|
|
42
|
+
data: Array<CouponResource>;
|
|
43
|
+
/**
|
|
44
|
+
*
|
|
45
|
+
* @type {PagingMetadata}
|
|
46
|
+
* @memberof PaginatedCouponResourceResponse
|
|
47
|
+
*/
|
|
48
|
+
meta: PagingMetadata;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
/**
|
|
52
|
+
* Check if a given object implements the PaginatedCouponResourceResponse interface.
|
|
53
|
+
*/
|
|
54
|
+
export function instanceOfPaginatedCouponResourceResponse(value: object): value is PaginatedCouponResourceResponse {
|
|
55
|
+
if (!('data' in value) || value['data'] === undefined) return false;
|
|
56
|
+
if (!('meta' in value) || value['meta'] === undefined) return false;
|
|
57
|
+
return true;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
export function PaginatedCouponResourceResponseFromJSON(json: any): PaginatedCouponResourceResponse {
|
|
61
|
+
return PaginatedCouponResourceResponseFromJSONTyped(json, false);
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
export function PaginatedCouponResourceResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): PaginatedCouponResourceResponse {
|
|
65
|
+
if (json == null) {
|
|
66
|
+
return json;
|
|
67
|
+
}
|
|
68
|
+
return {
|
|
69
|
+
|
|
70
|
+
'data': ((json['data'] as Array<any>).map(CouponResourceFromJSON)),
|
|
71
|
+
'meta': PagingMetadataFromJSON(json['meta']),
|
|
72
|
+
};
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
export function PaginatedCouponResourceResponseToJSON(json: any): PaginatedCouponResourceResponse {
|
|
76
|
+
return PaginatedCouponResourceResponseToJSONTyped(json, false);
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
export function PaginatedCouponResourceResponseToJSONTyped(value?: PaginatedCouponResourceResponse | null, ignoreDiscriminator: boolean = false): any {
|
|
80
|
+
if (value == null) {
|
|
81
|
+
return value;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
return {
|
|
85
|
+
|
|
86
|
+
'data': ((value['data'] as Array<any>).map(CouponResourceToJSON)),
|
|
87
|
+
'meta': PagingMetadataToJSON(value['meta']),
|
|
88
|
+
};
|
|
89
|
+
}
|
|
90
|
+
|
|
@@ -43,6 +43,12 @@ export interface ProductCategoryLiteResource {
|
|
|
43
43
|
* @memberof ProductCategoryLiteResource
|
|
44
44
|
*/
|
|
45
45
|
isAutomated: boolean;
|
|
46
|
+
/**
|
|
47
|
+
*
|
|
48
|
+
* @type {boolean}
|
|
49
|
+
* @memberof ProductCategoryLiteResource
|
|
50
|
+
*/
|
|
51
|
+
isParent: boolean;
|
|
46
52
|
}
|
|
47
53
|
|
|
48
54
|
/**
|
|
@@ -52,6 +58,7 @@ export function instanceOfProductCategoryLiteResource(value: object): value is P
|
|
|
52
58
|
if (!('name' in value) || value['name'] === undefined) return false;
|
|
53
59
|
if (!('siteId' in value) || value['siteId'] === undefined) return false;
|
|
54
60
|
if (!('isAutomated' in value) || value['isAutomated'] === undefined) return false;
|
|
61
|
+
if (!('isParent' in value) || value['isParent'] === undefined) return false;
|
|
55
62
|
return true;
|
|
56
63
|
}
|
|
57
64
|
|
|
@@ -69,6 +76,7 @@ export function ProductCategoryLiteResourceFromJSONTyped(json: any, ignoreDiscri
|
|
|
69
76
|
'name': json['name'],
|
|
70
77
|
'siteId': json['siteId'],
|
|
71
78
|
'isAutomated': json['isAutomated'],
|
|
79
|
+
'isParent': json['isParent'],
|
|
72
80
|
};
|
|
73
81
|
}
|
|
74
82
|
|
|
@@ -87,6 +95,7 @@ export function ProductCategoryLiteResourceToJSONTyped(value?: ProductCategoryLi
|
|
|
87
95
|
'name': value['name'],
|
|
88
96
|
'siteId': value['siteId'],
|
|
89
97
|
'isAutomated': value['isAutomated'],
|
|
98
|
+
'isParent': value['isParent'],
|
|
90
99
|
};
|
|
91
100
|
}
|
|
92
101
|
|
|
@@ -58,6 +58,12 @@ export interface ProductChildListResource {
|
|
|
58
58
|
* @memberof ProductChildListResource
|
|
59
59
|
*/
|
|
60
60
|
name: string;
|
|
61
|
+
/**
|
|
62
|
+
*
|
|
63
|
+
* @type {string}
|
|
64
|
+
* @memberof ProductChildListResource
|
|
65
|
+
*/
|
|
66
|
+
fullName: string;
|
|
61
67
|
/**
|
|
62
68
|
*
|
|
63
69
|
* @type {string}
|
|
@@ -115,6 +121,7 @@ export function instanceOfProductChildListResource(value: object): value is Prod
|
|
|
115
121
|
if (!('id' in value) || value['id'] === undefined) return false;
|
|
116
122
|
if (!('sku' in value) || value['sku'] === undefined) return false;
|
|
117
123
|
if (!('name' in value) || value['name'] === undefined) return false;
|
|
124
|
+
if (!('fullName' in value) || value['fullName'] === undefined) return false;
|
|
118
125
|
if (!('model' in value) || value['model'] === undefined) return false;
|
|
119
126
|
if (!('stock' in value) || value['stock'] === undefined) return false;
|
|
120
127
|
if (!('displayInSocialFeed' in value) || value['displayInSocialFeed'] === undefined) return false;
|
|
@@ -138,6 +145,7 @@ export function ProductChildListResourceFromJSONTyped(json: any, ignoreDiscrimin
|
|
|
138
145
|
'parentId': json['parentId'] == null ? undefined : json['parentId'],
|
|
139
146
|
'sku': json['sku'],
|
|
140
147
|
'name': json['name'],
|
|
148
|
+
'fullName': json['fullName'],
|
|
141
149
|
'model': json['model'],
|
|
142
150
|
'stock': json['stock'],
|
|
143
151
|
'isDisabled': json['isDisabled'] == null ? undefined : json['isDisabled'],
|
|
@@ -164,6 +172,7 @@ export function ProductChildListResourceToJSONTyped(value?: ProductChildListReso
|
|
|
164
172
|
'parentId': value['parentId'],
|
|
165
173
|
'sku': value['sku'],
|
|
166
174
|
'name': value['name'],
|
|
175
|
+
'fullName': value['fullName'],
|
|
167
176
|
'model': value['model'],
|
|
168
177
|
'stock': value['stock'],
|
|
169
178
|
'isDisabled': value['isDisabled'],
|