@digital8/lighting-illusions-ts-sdk 0.0.2056 → 0.0.2057
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 +36 -16
- package/README.md +24 -13
- package/dist/apis/CartsApi.d.ts +8 -8
- package/dist/apis/CartsApi.js +8 -8
- package/dist/apis/CustomersApi.d.ts +17 -0
- package/dist/apis/CustomersApi.js +62 -0
- package/dist/apis/OrdersApi.d.ts +23 -8
- package/dist/apis/OrdersApi.js +69 -10
- package/dist/apis/ProductApi.d.ts +0 -16
- package/dist/apis/ProductApi.js +0 -59
- package/dist/apis/TransactionsApi.d.ts +3 -3
- package/dist/apis/TransactionsApi.js +2 -2
- package/dist/models/AddressResource.d.ts +0 -6
- package/dist/models/AddressResource.js +0 -2
- package/dist/models/AdminNoteResource.d.ts +12 -0
- package/dist/models/AdminNoteResource.js +8 -0
- package/dist/models/AdminOrderResource.d.ts +22 -4
- package/dist/models/AdminOrderResource.js +18 -6
- package/dist/models/AttachCartCouponRequest.d.ts +32 -0
- package/dist/models/AttachCartCouponRequest.js +51 -0
- package/dist/models/AttachCartItemRequest.d.ts +44 -0
- package/dist/models/{AttachLineItemRequest.js → AttachCartItemRequest.js} +13 -13
- package/dist/models/AttachOrderCouponRequest.d.ts +32 -0
- package/dist/models/AttachOrderCouponRequest.js +51 -0
- package/dist/models/AttachOrderLineItemRequest.d.ts +44 -0
- package/dist/models/AttachOrderLineItemRequest.js +57 -0
- package/dist/models/CartCouponLiteResource.d.ts +56 -0
- package/dist/models/CartCouponLiteResource.js +67 -0
- package/dist/models/CartCouponLiteResourceArrayResponse.d.ts +33 -0
- package/dist/models/CartCouponLiteResourceArrayResponse.js +50 -0
- package/dist/models/CartListResource.d.ts +48 -0
- package/dist/models/CartListResource.js +26 -0
- package/dist/models/CartResource.d.ts +5 -5
- package/dist/models/CartResource.js +5 -5
- package/dist/models/CreateTransactionRequest.d.ts +0 -6
- package/dist/models/CreateTransactionRequest.js +0 -2
- package/dist/models/CustomerListResource.d.ts +7 -0
- package/dist/models/CustomerListResource.js +5 -0
- package/dist/models/DetachCartCouponRequest.d.ts +32 -0
- package/dist/models/DetachCartCouponRequest.js +51 -0
- package/dist/models/DetachOrderCouponRequest.d.ts +32 -0
- package/dist/models/DetachOrderCouponRequest.js +51 -0
- package/dist/models/FrontendCartResource.d.ts +144 -0
- package/dist/models/FrontendCartResource.js +121 -0
- package/dist/models/FrontendCartResourceArrayResponse.d.ts +33 -0
- package/dist/models/FrontendCartResourceArrayResponse.js +50 -0
- package/dist/models/FrontendCartResourceCouponsInner.d.ts +56 -0
- package/dist/models/FrontendCartResourceCouponsInner.js +57 -0
- package/dist/models/FrontendLineItemResource.d.ts +81 -0
- package/dist/models/FrontendLineItemResource.js +82 -0
- package/dist/models/FrontendLineItemResourceArrayResponse.d.ts +33 -0
- package/dist/models/FrontendLineItemResourceArrayResponse.js +50 -0
- package/dist/models/FrontendOrderResource.d.ts +174 -0
- package/dist/models/FrontendOrderResource.js +139 -0
- package/dist/models/FrontendOrderResourceArrayResponse.d.ts +33 -0
- package/dist/models/FrontendOrderResourceArrayResponse.js +50 -0
- package/dist/models/PaymentSource.d.ts +1 -0
- package/dist/models/PaymentSource.js +2 -1
- package/dist/models/ProductChildLineItemLiteResource.d.ts +18 -0
- package/dist/models/ProductChildLineItemLiteResource.js +12 -0
- package/dist/models/SearchCartsRequest.d.ts +0 -1
- package/dist/models/SearchCartsRequest.js +1 -2
- package/dist/models/StoreFrontendResource.d.ts +2 -2
- package/dist/models/StoreFrontendResource.js +4 -4
- package/dist/models/StoreResource.d.ts +1 -1
- package/dist/models/StoreResource.js +1 -3
- package/dist/models/StoreSpecialDateResource.d.ts +2 -2
- package/dist/models/StoreSpecialDateResource.js +3 -1
- package/dist/models/TransactionLiteResource.d.ts +0 -12
- package/dist/models/TransactionLiteResource.js +0 -4
- package/dist/models/UpdateCartItemRequest.d.ts +38 -0
- package/dist/models/{UpdateLineItemRequest.js → UpdateCartItemRequest.js} +13 -13
- package/dist/models/UpdateCustomerRequest.d.ts +56 -0
- package/dist/models/UpdateCustomerRequest.js +63 -0
- package/dist/models/UpdateOrderLineItemRequest.d.ts +38 -0
- package/dist/models/UpdateOrderLineItemRequest.js +53 -0
- package/dist/models/UpdateOrderRequest.d.ts +0 -6
- package/dist/models/UpdateOrderRequest.js +0 -2
- package/dist/models/index.d.ts +18 -8
- package/dist/models/index.js +18 -8
- package/docs/AddressResource.md +0 -2
- package/docs/AdminNoteResource.md +4 -0
- package/docs/AdminOrderResource.md +9 -3
- package/docs/{AttachCouponRequest.md → AttachCartCouponRequest.md} +4 -4
- package/docs/{AttachLineItemRequest.md → AttachCartItemRequest.md} +4 -4
- package/docs/{SkuSearchProductChildRequest.md → AttachOrderCouponRequest.md} +6 -8
- package/docs/AttachOrderLineItemRequest.md +38 -0
- package/docs/CartCouponLiteResource.md +42 -0
- package/docs/{TransactionListResourceArrayResponse.md → CartCouponLiteResourceArrayResponse.md} +5 -5
- package/docs/CartListResource.md +16 -0
- package/docs/CartResource.md +3 -3
- package/docs/CartsApi.md +16 -16
- package/docs/CreateTransactionRequest.md +0 -2
- package/docs/CustomerListResource.md +2 -0
- package/docs/CustomersApi.md +69 -0
- package/docs/{DetachCouponRequest.md → DetachCartCouponRequest.md} +4 -4
- package/docs/DetachOrderCouponRequest.md +34 -0
- package/docs/FrontendCartResource.md +70 -0
- package/docs/FrontendCartResourceArrayResponse.md +34 -0
- package/docs/FrontendCartResourceCouponsInner.md +42 -0
- package/docs/FrontendLineItemResource.md +50 -0
- package/docs/FrontendLineItemResourceArrayResponse.md +34 -0
- package/docs/FrontendOrderResource.md +80 -0
- package/docs/FrontendOrderResourceArrayResponse.md +34 -0
- package/docs/OrdersApi.md +84 -18
- package/docs/ProductApi.md +0 -66
- package/docs/ProductChildLineItemLiteResource.md +6 -0
- package/docs/StoreSpecialDateResource.md +1 -1
- package/docs/TransactionLiteResource.md +0 -4
- package/docs/TransactionsApi.md +3 -3
- package/docs/{UpdateLineItemRequest.md → UpdateCartItemRequest.md} +4 -4
- package/docs/UpdateCustomerRequest.md +42 -0
- package/docs/UpdateOrderLineItemRequest.md +36 -0
- package/docs/UpdateOrderRequest.md +0 -2
- package/package.json +1 -1
- package/src/apis/CartsApi.ts +25 -25
- package/src/apis/CustomersApi.ts +58 -0
- package/src/apis/OrdersApi.ts +75 -26
- package/src/apis/ProductApi.ts +0 -49
- package/src/apis/TransactionsApi.ts +7 -7
- package/src/models/AddressResource.ts +0 -8
- package/src/models/AdminNoteResource.ts +18 -0
- package/src/models/AdminOrderResource.ts +42 -15
- package/src/models/AttachCartCouponRequest.ts +66 -0
- package/src/models/{AttachLineItemRequest.ts → AttachCartItemRequest.ts} +13 -13
- package/src/models/AttachOrderCouponRequest.ts +66 -0
- package/src/models/AttachOrderLineItemRequest.ts +83 -0
- package/src/models/CartCouponLiteResource.ts +102 -0
- package/src/models/CartCouponLiteResourceArrayResponse.ts +73 -0
- package/src/models/CartListResource.ts +69 -0
- package/src/models/CartResource.ts +15 -15
- package/src/models/CreateTransactionRequest.ts +0 -8
- package/src/models/CustomerListResource.ts +16 -0
- package/src/models/DetachCartCouponRequest.ts +66 -0
- package/src/models/DetachOrderCouponRequest.ts +66 -0
- package/src/models/FrontendCartResource.ts +254 -0
- package/src/models/FrontendCartResourceArrayResponse.ts +73 -0
- package/src/models/FrontendCartResourceCouponsInner.ts +97 -0
- package/src/models/FrontendLineItemResource.ts +145 -0
- package/src/models/FrontendLineItemResourceArrayResponse.ts +73 -0
- package/src/models/FrontendOrderResource.ts +298 -0
- package/src/models/FrontendOrderResourceArrayResponse.ts +73 -0
- package/src/models/PaymentSource.ts +2 -1
- package/src/models/ProductChildLineItemLiteResource.ts +27 -0
- package/src/models/SearchCartsRequest.ts +1 -2
- package/src/models/StoreFrontendResource.ts +5 -5
- package/src/models/StoreResource.ts +2 -3
- package/src/models/StoreSpecialDateResource.ts +4 -3
- package/src/models/TransactionLiteResource.ts +0 -16
- package/src/models/{UpdateLineItemRequest.ts → UpdateCartItemRequest.ts} +12 -12
- package/src/models/UpdateCustomerRequest.ts +100 -0
- package/src/models/UpdateOrderLineItemRequest.ts +74 -0
- package/src/models/UpdateOrderRequest.ts +0 -8
- package/src/models/index.ts +18 -8
- package/dist/models/AttachCouponRequest.d.ts +0 -32
- package/dist/models/AttachCouponRequest.js +0 -51
- package/dist/models/AttachLineItemRequest.d.ts +0 -44
- package/dist/models/DetachCouponRequest.d.ts +0 -32
- package/dist/models/DetachCouponRequest.js +0 -51
- package/dist/models/PaginatedTransactionListResourceResponse.d.ts +0 -40
- package/dist/models/PaginatedTransactionListResourceResponse.js +0 -57
- package/dist/models/SkuSearchProductChildRequest.d.ts +0 -38
- package/dist/models/SkuSearchProductChildRequest.js +0 -55
- package/dist/models/TransactionListResource.d.ts +0 -116
- package/dist/models/TransactionListResource.js +0 -97
- package/dist/models/TransactionListResourceArrayResponse.d.ts +0 -33
- package/dist/models/TransactionListResourceArrayResponse.js +0 -50
- package/dist/models/UpdateLineItemRequest.d.ts +0 -38
- package/docs/PaginatedTransactionListResourceResponse.md +0 -36
- package/docs/TransactionListResource.md +0 -62
- package/src/models/AttachCouponRequest.ts +0 -66
- package/src/models/DetachCouponRequest.ts +0 -66
- package/src/models/PaginatedTransactionListResourceResponse.ts +0 -90
- package/src/models/SkuSearchProductChildRequest.ts +0 -75
- package/src/models/TransactionListResource.ts +0 -187
- package/src/models/TransactionListResourceArrayResponse.ts +0 -73
|
@@ -16,43 +16,43 @@ import { mapValues } from '../runtime';
|
|
|
16
16
|
/**
|
|
17
17
|
*
|
|
18
18
|
* @export
|
|
19
|
-
* @interface
|
|
19
|
+
* @interface AttachCartItemRequest
|
|
20
20
|
*/
|
|
21
|
-
export interface
|
|
21
|
+
export interface AttachCartItemRequest {
|
|
22
22
|
/**
|
|
23
23
|
*
|
|
24
24
|
* @type {number}
|
|
25
|
-
* @memberof
|
|
25
|
+
* @memberof AttachCartItemRequest
|
|
26
26
|
*/
|
|
27
27
|
productChildId: number;
|
|
28
28
|
/**
|
|
29
29
|
*
|
|
30
30
|
* @type {number}
|
|
31
|
-
* @memberof
|
|
31
|
+
* @memberof AttachCartItemRequest
|
|
32
32
|
*/
|
|
33
33
|
quantity: number;
|
|
34
34
|
/**
|
|
35
35
|
*
|
|
36
36
|
* @type {number}
|
|
37
|
-
* @memberof
|
|
37
|
+
* @memberof AttachCartItemRequest
|
|
38
38
|
*/
|
|
39
39
|
productPrice?: number | null;
|
|
40
40
|
}
|
|
41
41
|
|
|
42
42
|
/**
|
|
43
|
-
* Check if a given object implements the
|
|
43
|
+
* Check if a given object implements the AttachCartItemRequest interface.
|
|
44
44
|
*/
|
|
45
|
-
export function
|
|
45
|
+
export function instanceOfAttachCartItemRequest(value: object): value is AttachCartItemRequest {
|
|
46
46
|
if (!('productChildId' in value) || value['productChildId'] === undefined) return false;
|
|
47
47
|
if (!('quantity' in value) || value['quantity'] === undefined) return false;
|
|
48
48
|
return true;
|
|
49
49
|
}
|
|
50
50
|
|
|
51
|
-
export function
|
|
52
|
-
return
|
|
51
|
+
export function AttachCartItemRequestFromJSON(json: any): AttachCartItemRequest {
|
|
52
|
+
return AttachCartItemRequestFromJSONTyped(json, false);
|
|
53
53
|
}
|
|
54
54
|
|
|
55
|
-
export function
|
|
55
|
+
export function AttachCartItemRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): AttachCartItemRequest {
|
|
56
56
|
if (json == null) {
|
|
57
57
|
return json;
|
|
58
58
|
}
|
|
@@ -64,11 +64,11 @@ export function AttachLineItemRequestFromJSONTyped(json: any, ignoreDiscriminato
|
|
|
64
64
|
};
|
|
65
65
|
}
|
|
66
66
|
|
|
67
|
-
export function
|
|
68
|
-
return
|
|
67
|
+
export function AttachCartItemRequestToJSON(json: any): AttachCartItemRequest {
|
|
68
|
+
return AttachCartItemRequestToJSONTyped(json, false);
|
|
69
69
|
}
|
|
70
70
|
|
|
71
|
-
export function
|
|
71
|
+
export function AttachCartItemRequestToJSONTyped(value?: AttachCartItemRequest | null, ignoreDiscriminator: boolean = false): any {
|
|
72
72
|
if (value == null) {
|
|
73
73
|
return value;
|
|
74
74
|
}
|
|
@@ -0,0 +1,66 @@
|
|
|
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 AttachOrderCouponRequest
|
|
20
|
+
*/
|
|
21
|
+
export interface AttachOrderCouponRequest {
|
|
22
|
+
/**
|
|
23
|
+
*
|
|
24
|
+
* @type {string}
|
|
25
|
+
* @memberof AttachOrderCouponRequest
|
|
26
|
+
*/
|
|
27
|
+
couponCode: string;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
* Check if a given object implements the AttachOrderCouponRequest interface.
|
|
32
|
+
*/
|
|
33
|
+
export function instanceOfAttachOrderCouponRequest(value: object): value is AttachOrderCouponRequest {
|
|
34
|
+
if (!('couponCode' in value) || value['couponCode'] === undefined) return false;
|
|
35
|
+
return true;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
export function AttachOrderCouponRequestFromJSON(json: any): AttachOrderCouponRequest {
|
|
39
|
+
return AttachOrderCouponRequestFromJSONTyped(json, false);
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
export function AttachOrderCouponRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): AttachOrderCouponRequest {
|
|
43
|
+
if (json == null) {
|
|
44
|
+
return json;
|
|
45
|
+
}
|
|
46
|
+
return {
|
|
47
|
+
|
|
48
|
+
'couponCode': json['coupon_code'],
|
|
49
|
+
};
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
export function AttachOrderCouponRequestToJSON(json: any): AttachOrderCouponRequest {
|
|
53
|
+
return AttachOrderCouponRequestToJSONTyped(json, false);
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
export function AttachOrderCouponRequestToJSONTyped(value?: AttachOrderCouponRequest | null, ignoreDiscriminator: boolean = false): any {
|
|
57
|
+
if (value == null) {
|
|
58
|
+
return value;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
return {
|
|
62
|
+
|
|
63
|
+
'coupon_code': value['couponCode'],
|
|
64
|
+
};
|
|
65
|
+
}
|
|
66
|
+
|
|
@@ -0,0 +1,83 @@
|
|
|
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 AttachOrderLineItemRequest
|
|
20
|
+
*/
|
|
21
|
+
export interface AttachOrderLineItemRequest {
|
|
22
|
+
/**
|
|
23
|
+
*
|
|
24
|
+
* @type {number}
|
|
25
|
+
* @memberof AttachOrderLineItemRequest
|
|
26
|
+
*/
|
|
27
|
+
productChildId: number;
|
|
28
|
+
/**
|
|
29
|
+
*
|
|
30
|
+
* @type {number}
|
|
31
|
+
* @memberof AttachOrderLineItemRequest
|
|
32
|
+
*/
|
|
33
|
+
quantity: number;
|
|
34
|
+
/**
|
|
35
|
+
*
|
|
36
|
+
* @type {number}
|
|
37
|
+
* @memberof AttachOrderLineItemRequest
|
|
38
|
+
*/
|
|
39
|
+
productPrice?: number | null;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
/**
|
|
43
|
+
* Check if a given object implements the AttachOrderLineItemRequest interface.
|
|
44
|
+
*/
|
|
45
|
+
export function instanceOfAttachOrderLineItemRequest(value: object): value is AttachOrderLineItemRequest {
|
|
46
|
+
if (!('productChildId' in value) || value['productChildId'] === undefined) return false;
|
|
47
|
+
if (!('quantity' in value) || value['quantity'] === undefined) return false;
|
|
48
|
+
return true;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
export function AttachOrderLineItemRequestFromJSON(json: any): AttachOrderLineItemRequest {
|
|
52
|
+
return AttachOrderLineItemRequestFromJSONTyped(json, false);
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
export function AttachOrderLineItemRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): AttachOrderLineItemRequest {
|
|
56
|
+
if (json == null) {
|
|
57
|
+
return json;
|
|
58
|
+
}
|
|
59
|
+
return {
|
|
60
|
+
|
|
61
|
+
'productChildId': json['product_child_id'],
|
|
62
|
+
'quantity': json['quantity'],
|
|
63
|
+
'productPrice': json['product_price'] == null ? undefined : json['product_price'],
|
|
64
|
+
};
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
export function AttachOrderLineItemRequestToJSON(json: any): AttachOrderLineItemRequest {
|
|
68
|
+
return AttachOrderLineItemRequestToJSONTyped(json, false);
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
export function AttachOrderLineItemRequestToJSONTyped(value?: AttachOrderLineItemRequest | null, ignoreDiscriminator: boolean = false): any {
|
|
72
|
+
if (value == null) {
|
|
73
|
+
return value;
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
return {
|
|
77
|
+
|
|
78
|
+
'product_child_id': value['productChildId'],
|
|
79
|
+
'quantity': value['quantity'],
|
|
80
|
+
'product_price': value['productPrice'],
|
|
81
|
+
};
|
|
82
|
+
}
|
|
83
|
+
|
|
@@ -0,0 +1,102 @@
|
|
|
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 CartCouponLiteResource
|
|
20
|
+
*/
|
|
21
|
+
export interface CartCouponLiteResource {
|
|
22
|
+
/**
|
|
23
|
+
*
|
|
24
|
+
* @type {number}
|
|
25
|
+
* @memberof CartCouponLiteResource
|
|
26
|
+
*/
|
|
27
|
+
id: number;
|
|
28
|
+
/**
|
|
29
|
+
*
|
|
30
|
+
* @type {string}
|
|
31
|
+
* @memberof CartCouponLiteResource
|
|
32
|
+
*/
|
|
33
|
+
code: string;
|
|
34
|
+
/**
|
|
35
|
+
*
|
|
36
|
+
* @type {string}
|
|
37
|
+
* @memberof CartCouponLiteResource
|
|
38
|
+
*/
|
|
39
|
+
name: string;
|
|
40
|
+
/**
|
|
41
|
+
*
|
|
42
|
+
* @type {number}
|
|
43
|
+
* @memberof CartCouponLiteResource
|
|
44
|
+
*/
|
|
45
|
+
discount: number;
|
|
46
|
+
/**
|
|
47
|
+
*
|
|
48
|
+
* @type {string}
|
|
49
|
+
* @memberof CartCouponLiteResource
|
|
50
|
+
*/
|
|
51
|
+
appliesTo: string;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
/**
|
|
55
|
+
* Check if a given object implements the CartCouponLiteResource interface.
|
|
56
|
+
*/
|
|
57
|
+
export function instanceOfCartCouponLiteResource(value: object): value is CartCouponLiteResource {
|
|
58
|
+
if (!('id' in value) || value['id'] === undefined) return false;
|
|
59
|
+
if (!('code' in value) || value['code'] === undefined) return false;
|
|
60
|
+
if (!('name' in value) || value['name'] === undefined) return false;
|
|
61
|
+
if (!('discount' in value) || value['discount'] === undefined) return false;
|
|
62
|
+
if (!('appliesTo' in value) || value['appliesTo'] === undefined) return false;
|
|
63
|
+
return true;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
export function CartCouponLiteResourceFromJSON(json: any): CartCouponLiteResource {
|
|
67
|
+
return CartCouponLiteResourceFromJSONTyped(json, false);
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
export function CartCouponLiteResourceFromJSONTyped(json: any, ignoreDiscriminator: boolean): CartCouponLiteResource {
|
|
71
|
+
if (json == null) {
|
|
72
|
+
return json;
|
|
73
|
+
}
|
|
74
|
+
return {
|
|
75
|
+
|
|
76
|
+
'id': json['id'],
|
|
77
|
+
'code': json['code'],
|
|
78
|
+
'name': json['name'],
|
|
79
|
+
'discount': json['discount'],
|
|
80
|
+
'appliesTo': json['appliesTo'],
|
|
81
|
+
};
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
export function CartCouponLiteResourceToJSON(json: any): CartCouponLiteResource {
|
|
85
|
+
return CartCouponLiteResourceToJSONTyped(json, false);
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
export function CartCouponLiteResourceToJSONTyped(value?: CartCouponLiteResource | null, ignoreDiscriminator: boolean = false): any {
|
|
89
|
+
if (value == null) {
|
|
90
|
+
return value;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
return {
|
|
94
|
+
|
|
95
|
+
'id': value['id'],
|
|
96
|
+
'code': value['code'],
|
|
97
|
+
'name': value['name'],
|
|
98
|
+
'discount': value['discount'],
|
|
99
|
+
'appliesTo': value['appliesTo'],
|
|
100
|
+
};
|
|
101
|
+
}
|
|
102
|
+
|
|
@@ -0,0 +1,73 @@
|
|
|
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 { CartCouponLiteResource } from './CartCouponLiteResource';
|
|
17
|
+
import {
|
|
18
|
+
CartCouponLiteResourceFromJSON,
|
|
19
|
+
CartCouponLiteResourceFromJSONTyped,
|
|
20
|
+
CartCouponLiteResourceToJSON,
|
|
21
|
+
CartCouponLiteResourceToJSONTyped,
|
|
22
|
+
} from './CartCouponLiteResource';
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
* @export
|
|
27
|
+
* @interface CartCouponLiteResourceArrayResponse
|
|
28
|
+
*/
|
|
29
|
+
export interface CartCouponLiteResourceArrayResponse {
|
|
30
|
+
/**
|
|
31
|
+
*
|
|
32
|
+
* @type {Array<CartCouponLiteResource>}
|
|
33
|
+
* @memberof CartCouponLiteResourceArrayResponse
|
|
34
|
+
*/
|
|
35
|
+
data?: Array<CartCouponLiteResource>;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* Check if a given object implements the CartCouponLiteResourceArrayResponse interface.
|
|
40
|
+
*/
|
|
41
|
+
export function instanceOfCartCouponLiteResourceArrayResponse(value: object): value is CartCouponLiteResourceArrayResponse {
|
|
42
|
+
return true;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
export function CartCouponLiteResourceArrayResponseFromJSON(json: any): CartCouponLiteResourceArrayResponse {
|
|
46
|
+
return CartCouponLiteResourceArrayResponseFromJSONTyped(json, false);
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export function CartCouponLiteResourceArrayResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): CartCouponLiteResourceArrayResponse {
|
|
50
|
+
if (json == null) {
|
|
51
|
+
return json;
|
|
52
|
+
}
|
|
53
|
+
return {
|
|
54
|
+
|
|
55
|
+
'data': json['data'] == null ? undefined : ((json['data'] as Array<any>).map(CartCouponLiteResourceFromJSON)),
|
|
56
|
+
};
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
export function CartCouponLiteResourceArrayResponseToJSON(json: any): CartCouponLiteResourceArrayResponse {
|
|
60
|
+
return CartCouponLiteResourceArrayResponseToJSONTyped(json, false);
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
export function CartCouponLiteResourceArrayResponseToJSONTyped(value?: CartCouponLiteResourceArrayResponse | null, ignoreDiscriminator: boolean = false): any {
|
|
64
|
+
if (value == null) {
|
|
65
|
+
return value;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
return {
|
|
69
|
+
|
|
70
|
+
'data': value['data'] == null ? undefined : ((value['data'] as Array<any>).map(CartCouponLiteResourceToJSON)),
|
|
71
|
+
};
|
|
72
|
+
}
|
|
73
|
+
|
|
@@ -59,6 +59,54 @@ export interface CartListResource {
|
|
|
59
59
|
* @memberof CartListResource
|
|
60
60
|
*/
|
|
61
61
|
source: string;
|
|
62
|
+
/**
|
|
63
|
+
*
|
|
64
|
+
* @type {string}
|
|
65
|
+
* @memberof CartListResource
|
|
66
|
+
*/
|
|
67
|
+
shippingType?: string | null;
|
|
68
|
+
/**
|
|
69
|
+
*
|
|
70
|
+
* @type {number}
|
|
71
|
+
* @memberof CartListResource
|
|
72
|
+
*/
|
|
73
|
+
shippingSubtotal?: number | null;
|
|
74
|
+
/**
|
|
75
|
+
*
|
|
76
|
+
* @type {boolean}
|
|
77
|
+
* @memberof CartListResource
|
|
78
|
+
*/
|
|
79
|
+
overrideShipping: boolean;
|
|
80
|
+
/**
|
|
81
|
+
*
|
|
82
|
+
* @type {number}
|
|
83
|
+
* @memberof CartListResource
|
|
84
|
+
*/
|
|
85
|
+
insuranceAmount?: number | null;
|
|
86
|
+
/**
|
|
87
|
+
*
|
|
88
|
+
* @type {boolean}
|
|
89
|
+
* @memberof CartListResource
|
|
90
|
+
*/
|
|
91
|
+
includeInsurance: boolean;
|
|
92
|
+
/**
|
|
93
|
+
*
|
|
94
|
+
* @type {boolean}
|
|
95
|
+
* @memberof CartListResource
|
|
96
|
+
*/
|
|
97
|
+
overrideInsurance: boolean;
|
|
98
|
+
/**
|
|
99
|
+
*
|
|
100
|
+
* @type {boolean}
|
|
101
|
+
* @memberof CartListResource
|
|
102
|
+
*/
|
|
103
|
+
useAsBillingAddress: boolean;
|
|
104
|
+
/**
|
|
105
|
+
*
|
|
106
|
+
* @type {Date}
|
|
107
|
+
* @memberof CartListResource
|
|
108
|
+
*/
|
|
109
|
+
expiryDate: Date;
|
|
62
110
|
/**
|
|
63
111
|
*
|
|
64
112
|
* @type {Date}
|
|
@@ -108,6 +156,11 @@ export interface CartListResource {
|
|
|
108
156
|
*/
|
|
109
157
|
export function instanceOfCartListResource(value: object): value is CartListResource {
|
|
110
158
|
if (!('source' in value) || value['source'] === undefined) return false;
|
|
159
|
+
if (!('overrideShipping' in value) || value['overrideShipping'] === undefined) return false;
|
|
160
|
+
if (!('includeInsurance' in value) || value['includeInsurance'] === undefined) return false;
|
|
161
|
+
if (!('overrideInsurance' in value) || value['overrideInsurance'] === undefined) return false;
|
|
162
|
+
if (!('useAsBillingAddress' in value) || value['useAsBillingAddress'] === undefined) return false;
|
|
163
|
+
if (!('expiryDate' in value) || value['expiryDate'] === undefined) return false;
|
|
111
164
|
if (!('site' in value) || value['site'] === undefined) return false;
|
|
112
165
|
if (!('customer' in value) || value['customer'] === undefined) return false;
|
|
113
166
|
if (!('lineItems' in value) || value['lineItems'] === undefined) return false;
|
|
@@ -129,6 +182,14 @@ export function CartListResourceFromJSONTyped(json: any, ignoreDiscriminator: bo
|
|
|
129
182
|
'id': json['id'] == null ? undefined : json['id'],
|
|
130
183
|
'guestEmail': json['guestEmail'] == null ? undefined : json['guestEmail'],
|
|
131
184
|
'source': json['source'],
|
|
185
|
+
'shippingType': json['shippingType'] == null ? undefined : json['shippingType'],
|
|
186
|
+
'shippingSubtotal': json['shippingSubtotal'] == null ? undefined : json['shippingSubtotal'],
|
|
187
|
+
'overrideShipping': json['overrideShipping'],
|
|
188
|
+
'insuranceAmount': json['insuranceAmount'] == null ? undefined : json['insuranceAmount'],
|
|
189
|
+
'includeInsurance': json['includeInsurance'],
|
|
190
|
+
'overrideInsurance': json['overrideInsurance'],
|
|
191
|
+
'useAsBillingAddress': json['useAsBillingAddress'],
|
|
192
|
+
'expiryDate': (new Date(json['expiryDate'])),
|
|
132
193
|
'checkoutCompletedAt': json['checkoutCompletedAt'] == null ? undefined : (new Date(json['checkoutCompletedAt'])),
|
|
133
194
|
'createdAt': json['createdAt'] == null ? undefined : (new Date(json['createdAt'])),
|
|
134
195
|
'site': SiteLiteResourceFromJSON(json['site']),
|
|
@@ -153,6 +214,14 @@ export function CartListResourceToJSONTyped(value?: CartListResource | null, ign
|
|
|
153
214
|
'id': value['id'],
|
|
154
215
|
'guestEmail': value['guestEmail'],
|
|
155
216
|
'source': value['source'],
|
|
217
|
+
'shippingType': value['shippingType'],
|
|
218
|
+
'shippingSubtotal': value['shippingSubtotal'],
|
|
219
|
+
'overrideShipping': value['overrideShipping'],
|
|
220
|
+
'insuranceAmount': value['insuranceAmount'],
|
|
221
|
+
'includeInsurance': value['includeInsurance'],
|
|
222
|
+
'overrideInsurance': value['overrideInsurance'],
|
|
223
|
+
'useAsBillingAddress': value['useAsBillingAddress'],
|
|
224
|
+
'expiryDate': value['expiryDate'].toISOString(),
|
|
156
225
|
'checkoutCompletedAt': value['checkoutCompletedAt'] == null ? value['checkoutCompletedAt'] : value['checkoutCompletedAt'].toISOString(),
|
|
157
226
|
'createdAt': value['createdAt'] == null ? value['createdAt'] : value['createdAt'].toISOString(),
|
|
158
227
|
'site': SiteLiteResourceToJSON(value['site']),
|
|
@@ -27,13 +27,6 @@ import {
|
|
|
27
27
|
LineItemListResourceToJSON,
|
|
28
28
|
LineItemListResourceToJSONTyped,
|
|
29
29
|
} from './LineItemListResource';
|
|
30
|
-
import type { CustomerResource } from './CustomerResource';
|
|
31
|
-
import {
|
|
32
|
-
CustomerResourceFromJSON,
|
|
33
|
-
CustomerResourceFromJSONTyped,
|
|
34
|
-
CustomerResourceToJSON,
|
|
35
|
-
CustomerResourceToJSONTyped,
|
|
36
|
-
} from './CustomerResource';
|
|
37
30
|
import type { LiAdminUserLiteResource } from './LiAdminUserLiteResource';
|
|
38
31
|
import {
|
|
39
32
|
LiAdminUserLiteResourceFromJSON,
|
|
@@ -41,6 +34,13 @@ import {
|
|
|
41
34
|
LiAdminUserLiteResourceToJSON,
|
|
42
35
|
LiAdminUserLiteResourceToJSONTyped,
|
|
43
36
|
} from './LiAdminUserLiteResource';
|
|
37
|
+
import type { CustomerListResource } from './CustomerListResource';
|
|
38
|
+
import {
|
|
39
|
+
CustomerListResourceFromJSON,
|
|
40
|
+
CustomerListResourceFromJSONTyped,
|
|
41
|
+
CustomerListResourceToJSON,
|
|
42
|
+
CustomerListResourceToJSONTyped,
|
|
43
|
+
} from './CustomerListResource';
|
|
44
44
|
import type { AddressResource } from './AddressResource';
|
|
45
45
|
import {
|
|
46
46
|
AddressResourceFromJSON,
|
|
@@ -129,10 +129,10 @@ export interface CartResource {
|
|
|
129
129
|
overrideShipping: boolean;
|
|
130
130
|
/**
|
|
131
131
|
*
|
|
132
|
-
* @type {
|
|
132
|
+
* @type {number}
|
|
133
133
|
* @memberof CartResource
|
|
134
134
|
*/
|
|
135
|
-
|
|
135
|
+
insuranceAmount?: number | null;
|
|
136
136
|
/**
|
|
137
137
|
*
|
|
138
138
|
* @type {boolean}
|
|
@@ -165,10 +165,10 @@ export interface CartResource {
|
|
|
165
165
|
site: SiteLiteResource | null;
|
|
166
166
|
/**
|
|
167
167
|
*
|
|
168
|
-
* @type {
|
|
168
|
+
* @type {CustomerListResource}
|
|
169
169
|
* @memberof CartResource
|
|
170
170
|
*/
|
|
171
|
-
customer:
|
|
171
|
+
customer: CustomerListResource | null;
|
|
172
172
|
/**
|
|
173
173
|
*
|
|
174
174
|
* @type {Array<LineItemListResource>}
|
|
@@ -315,13 +315,13 @@ export function CartResourceFromJSONTyped(json: any, ignoreDiscriminator: boolea
|
|
|
315
315
|
'shippingType': json['shippingType'],
|
|
316
316
|
'shippingSubtotal': json['shippingSubtotal'] == null ? undefined : json['shippingSubtotal'],
|
|
317
317
|
'overrideShipping': json['overrideShipping'],
|
|
318
|
-
'
|
|
318
|
+
'insuranceAmount': json['insuranceAmount'] == null ? undefined : json['insuranceAmount'],
|
|
319
319
|
'includeInsurance': json['includeInsurance'],
|
|
320
320
|
'overrideInsurance': json['overrideInsurance'],
|
|
321
321
|
'useAsBillingAddress': json['useAsBillingAddress'],
|
|
322
322
|
'admin': LiAdminUserLiteResourceFromJSON(json['admin']),
|
|
323
323
|
'site': SiteLiteResourceFromJSON(json['site']),
|
|
324
|
-
'customer':
|
|
324
|
+
'customer': CustomerListResourceFromJSON(json['customer']),
|
|
325
325
|
'lineItems': (json['lineItems'] == null ? null : (json['lineItems'] as Array<any>).map(LineItemListResourceFromJSON)),
|
|
326
326
|
'coupons': json['coupons'],
|
|
327
327
|
'shippingAddress': AddressResourceFromJSON(json['shippingAddress']),
|
|
@@ -363,13 +363,13 @@ export function CartResourceToJSONTyped(value?: CartResource | null, ignoreDiscr
|
|
|
363
363
|
'shippingType': value['shippingType'],
|
|
364
364
|
'shippingSubtotal': value['shippingSubtotal'],
|
|
365
365
|
'overrideShipping': value['overrideShipping'],
|
|
366
|
-
'
|
|
366
|
+
'insuranceAmount': value['insuranceAmount'],
|
|
367
367
|
'includeInsurance': value['includeInsurance'],
|
|
368
368
|
'overrideInsurance': value['overrideInsurance'],
|
|
369
369
|
'useAsBillingAddress': value['useAsBillingAddress'],
|
|
370
370
|
'admin': LiAdminUserLiteResourceToJSON(value['admin']),
|
|
371
371
|
'site': SiteLiteResourceToJSON(value['site']),
|
|
372
|
-
'customer':
|
|
372
|
+
'customer': CustomerListResourceToJSON(value['customer']),
|
|
373
373
|
'lineItems': (value['lineItems'] == null ? null : (value['lineItems'] as Array<any>).map(LineItemListResourceToJSON)),
|
|
374
374
|
'coupons': value['coupons'],
|
|
375
375
|
'shippingAddress': AddressResourceToJSON(value['shippingAddress']),
|
|
@@ -49,12 +49,6 @@ export interface CreateTransactionRequest {
|
|
|
49
49
|
* @memberof CreateTransactionRequest
|
|
50
50
|
*/
|
|
51
51
|
paymentMethod: CreateTransactionRequestPaymentMethodEnum;
|
|
52
|
-
/**
|
|
53
|
-
*
|
|
54
|
-
* @type {string}
|
|
55
|
-
* @memberof CreateTransactionRequest
|
|
56
|
-
*/
|
|
57
|
-
description?: string | null;
|
|
58
52
|
/**
|
|
59
53
|
*
|
|
60
54
|
* @type {string}
|
|
@@ -109,7 +103,6 @@ export function CreateTransactionRequestFromJSONTyped(json: any, ignoreDiscrimin
|
|
|
109
103
|
'amount': json['amount'] == null ? undefined : json['amount'],
|
|
110
104
|
'surcharge': json['surcharge'],
|
|
111
105
|
'paymentMethod': json['payment_method'],
|
|
112
|
-
'description': json['description'] == null ? undefined : json['description'],
|
|
113
106
|
'nonce': json['nonce'] == null ? undefined : json['nonce'],
|
|
114
107
|
'deviceData': json['device_data'] == null ? undefined : json['device_data'],
|
|
115
108
|
};
|
|
@@ -131,7 +124,6 @@ export function CreateTransactionRequestToJSONTyped(value?: CreateTransactionReq
|
|
|
131
124
|
'amount': value['amount'],
|
|
132
125
|
'surcharge': value['surcharge'],
|
|
133
126
|
'payment_method': value['paymentMethod'],
|
|
134
|
-
'description': value['description'],
|
|
135
127
|
'nonce': value['nonce'],
|
|
136
128
|
'device_data': value['deviceData'],
|
|
137
129
|
};
|
|
@@ -20,6 +20,13 @@ import {
|
|
|
20
20
|
SiteLiteResourceToJSON,
|
|
21
21
|
SiteLiteResourceToJSONTyped,
|
|
22
22
|
} from './SiteLiteResource';
|
|
23
|
+
import type { LiAddressResource } from './LiAddressResource';
|
|
24
|
+
import {
|
|
25
|
+
LiAddressResourceFromJSON,
|
|
26
|
+
LiAddressResourceFromJSONTyped,
|
|
27
|
+
LiAddressResourceToJSON,
|
|
28
|
+
LiAddressResourceToJSONTyped,
|
|
29
|
+
} from './LiAddressResource';
|
|
23
30
|
|
|
24
31
|
/**
|
|
25
32
|
*
|
|
@@ -63,6 +70,12 @@ export interface CustomerListResource {
|
|
|
63
70
|
* @memberof CustomerListResource
|
|
64
71
|
*/
|
|
65
72
|
site: SiteLiteResource | null;
|
|
73
|
+
/**
|
|
74
|
+
*
|
|
75
|
+
* @type {Array<LiAddressResource>}
|
|
76
|
+
* @memberof CustomerListResource
|
|
77
|
+
*/
|
|
78
|
+
addresses: Array<LiAddressResource> | null;
|
|
66
79
|
}
|
|
67
80
|
|
|
68
81
|
/**
|
|
@@ -74,6 +87,7 @@ export function instanceOfCustomerListResource(value: object): value is Customer
|
|
|
74
87
|
if (!('email' in value) || value['email'] === undefined) return false;
|
|
75
88
|
if (!('phone' in value) || value['phone'] === undefined) return false;
|
|
76
89
|
if (!('site' in value) || value['site'] === undefined) return false;
|
|
90
|
+
if (!('addresses' in value) || value['addresses'] === undefined) return false;
|
|
77
91
|
return true;
|
|
78
92
|
}
|
|
79
93
|
|
|
@@ -93,6 +107,7 @@ export function CustomerListResourceFromJSONTyped(json: any, ignoreDiscriminator
|
|
|
93
107
|
'email': json['email'],
|
|
94
108
|
'phone': json['phone'],
|
|
95
109
|
'site': SiteLiteResourceFromJSON(json['site']),
|
|
110
|
+
'addresses': (json['addresses'] == null ? null : (json['addresses'] as Array<any>).map(LiAddressResourceFromJSON)),
|
|
96
111
|
};
|
|
97
112
|
}
|
|
98
113
|
|
|
@@ -113,6 +128,7 @@ export function CustomerListResourceToJSONTyped(value?: CustomerListResource | n
|
|
|
113
128
|
'email': value['email'],
|
|
114
129
|
'phone': value['phone'],
|
|
115
130
|
'site': SiteLiteResourceToJSON(value['site']),
|
|
131
|
+
'addresses': (value['addresses'] == null ? null : (value['addresses'] as Array<any>).map(LiAddressResourceToJSON)),
|
|
116
132
|
};
|
|
117
133
|
}
|
|
118
134
|
|