@digital8/lighting-illusions-ts-sdk 0.0.2024 → 0.0.2025
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 +0 -14
- package/README.md +2 -9
- package/dist/models/AddressFrontendResource.d.ts +1 -1
- package/dist/models/AddressFrontendResource.js +3 -1
- package/dist/models/AddressResource.d.ts +2 -2
- package/dist/models/AddressResource.js +4 -4
- package/dist/models/ProductChildLineItemLiteResource.d.ts +0 -18
- package/dist/models/ProductChildLineItemLiteResource.js +0 -12
- package/dist/models/StoreResource.d.ts +1 -1
- package/dist/models/StoreResource.js +1 -3
- package/dist/models/index.d.ts +0 -7
- package/dist/models/index.js +0 -7
- package/docs/ProductChildLineItemLiteResource.md +0 -6
- package/package.json +1 -1
- package/src/models/AddressFrontendResource.ts +3 -2
- package/src/models/AddressResource.ts +5 -5
- package/src/models/ProductChildLineItemLiteResource.ts +0 -27
- package/src/models/StoreResource.ts +2 -3
- package/src/models/index.ts +0 -7
- package/dist/models/CartCouponLiteResource.d.ts +0 -56
- package/dist/models/CartCouponLiteResource.js +0 -67
- package/dist/models/CartCouponLiteResourceArrayResponse.d.ts +0 -33
- package/dist/models/CartCouponLiteResourceArrayResponse.js +0 -50
- package/dist/models/FrontendCartResource.d.ts +0 -138
- package/dist/models/FrontendCartResource.js +0 -119
- package/dist/models/FrontendCartResourceArrayResponse.d.ts +0 -33
- package/dist/models/FrontendCartResourceArrayResponse.js +0 -50
- package/dist/models/FrontendCartResourceCouponsInner.d.ts +0 -56
- package/dist/models/FrontendCartResourceCouponsInner.js +0 -57
- package/dist/models/FrontendLineItemResource.d.ts +0 -81
- package/dist/models/FrontendLineItemResource.js +0 -82
- package/dist/models/FrontendLineItemResourceArrayResponse.d.ts +0 -33
- package/dist/models/FrontendLineItemResourceArrayResponse.js +0 -50
- package/docs/CartCouponLiteResource.md +0 -42
- package/docs/CartCouponLiteResourceArrayResponse.md +0 -34
- package/docs/FrontendCartResource.md +0 -68
- package/docs/FrontendCartResourceArrayResponse.md +0 -34
- package/docs/FrontendCartResourceCouponsInner.md +0 -42
- package/docs/FrontendLineItemResource.md +0 -50
- package/docs/FrontendLineItemResourceArrayResponse.md +0 -34
- package/src/models/CartCouponLiteResource.ts +0 -102
- package/src/models/CartCouponLiteResourceArrayResponse.ts +0 -73
- package/src/models/FrontendCartResource.ts +0 -246
- package/src/models/FrontendCartResourceArrayResponse.ts +0 -73
- package/src/models/FrontendCartResourceCouponsInner.ts +0 -97
- package/src/models/FrontendLineItemResource.ts +0 -145
- package/src/models/FrontendLineItemResourceArrayResponse.ts +0 -73
|
@@ -1,82 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/* tslint:disable */
|
|
3
|
-
/* eslint-disable */
|
|
4
|
-
/**
|
|
5
|
-
* My API
|
|
6
|
-
* API documentation for my Laravel app
|
|
7
|
-
*
|
|
8
|
-
* The version of the OpenAPI document: 1.0.0
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
-
* https://openapi-generator.tech
|
|
13
|
-
* Do not edit the class manually.
|
|
14
|
-
*/
|
|
15
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
-
exports.instanceOfFrontendLineItemResource = instanceOfFrontendLineItemResource;
|
|
17
|
-
exports.FrontendLineItemResourceFromJSON = FrontendLineItemResourceFromJSON;
|
|
18
|
-
exports.FrontendLineItemResourceFromJSONTyped = FrontendLineItemResourceFromJSONTyped;
|
|
19
|
-
exports.FrontendLineItemResourceToJSON = FrontendLineItemResourceToJSON;
|
|
20
|
-
exports.FrontendLineItemResourceToJSONTyped = FrontendLineItemResourceToJSONTyped;
|
|
21
|
-
var ProductChildLineItemLiteResource_1 = require("./ProductChildLineItemLiteResource");
|
|
22
|
-
/**
|
|
23
|
-
* Check if a given object implements the FrontendLineItemResource interface.
|
|
24
|
-
*/
|
|
25
|
-
function instanceOfFrontendLineItemResource(value) {
|
|
26
|
-
if (!('quantity' in value) || value['quantity'] === undefined)
|
|
27
|
-
return false;
|
|
28
|
-
if (!('productPrice' in value) || value['productPrice'] === undefined)
|
|
29
|
-
return false;
|
|
30
|
-
if (!('subtotalAmount' in value) || value['subtotalAmount'] === undefined)
|
|
31
|
-
return false;
|
|
32
|
-
if (!('totalAmount' in value) || value['totalAmount'] === undefined)
|
|
33
|
-
return false;
|
|
34
|
-
if (!('promotionalSaving' in value) || value['promotionalSaving'] === undefined)
|
|
35
|
-
return false;
|
|
36
|
-
if (!('isAvailable' in value) || value['isAvailable'] === undefined)
|
|
37
|
-
return false;
|
|
38
|
-
if (!('isInStock' in value) || value['isInStock'] === undefined)
|
|
39
|
-
return false;
|
|
40
|
-
if (!('productChild' in value) || value['productChild'] === undefined)
|
|
41
|
-
return false;
|
|
42
|
-
return true;
|
|
43
|
-
}
|
|
44
|
-
function FrontendLineItemResourceFromJSON(json) {
|
|
45
|
-
return FrontendLineItemResourceFromJSONTyped(json, false);
|
|
46
|
-
}
|
|
47
|
-
function FrontendLineItemResourceFromJSONTyped(json, ignoreDiscriminator) {
|
|
48
|
-
if (json == null) {
|
|
49
|
-
return json;
|
|
50
|
-
}
|
|
51
|
-
return {
|
|
52
|
-
'id': json['id'] == null ? undefined : json['id'],
|
|
53
|
-
'quantity': json['quantity'],
|
|
54
|
-
'productPrice': json['productPrice'],
|
|
55
|
-
'subtotalAmount': json['subtotalAmount'],
|
|
56
|
-
'totalAmount': json['totalAmount'],
|
|
57
|
-
'promotionalSaving': json['promotionalSaving'],
|
|
58
|
-
'isAvailable': json['isAvailable'],
|
|
59
|
-
'isInStock': json['isInStock'],
|
|
60
|
-
'productChild': (0, ProductChildLineItemLiteResource_1.ProductChildLineItemLiteResourceFromJSON)(json['productChild']),
|
|
61
|
-
};
|
|
62
|
-
}
|
|
63
|
-
function FrontendLineItemResourceToJSON(json) {
|
|
64
|
-
return FrontendLineItemResourceToJSONTyped(json, false);
|
|
65
|
-
}
|
|
66
|
-
function FrontendLineItemResourceToJSONTyped(value, ignoreDiscriminator) {
|
|
67
|
-
if (ignoreDiscriminator === void 0) { ignoreDiscriminator = false; }
|
|
68
|
-
if (value == null) {
|
|
69
|
-
return value;
|
|
70
|
-
}
|
|
71
|
-
return {
|
|
72
|
-
'id': value['id'],
|
|
73
|
-
'quantity': value['quantity'],
|
|
74
|
-
'productPrice': value['productPrice'],
|
|
75
|
-
'subtotalAmount': value['subtotalAmount'],
|
|
76
|
-
'totalAmount': value['totalAmount'],
|
|
77
|
-
'promotionalSaving': value['promotionalSaving'],
|
|
78
|
-
'isAvailable': value['isAvailable'],
|
|
79
|
-
'isInStock': value['isInStock'],
|
|
80
|
-
'productChild': (0, ProductChildLineItemLiteResource_1.ProductChildLineItemLiteResourceToJSON)(value['productChild']),
|
|
81
|
-
};
|
|
82
|
-
}
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* My API
|
|
3
|
-
* API documentation for my Laravel app
|
|
4
|
-
*
|
|
5
|
-
* The version of the OpenAPI document: 1.0.0
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
-
* https://openapi-generator.tech
|
|
10
|
-
* Do not edit the class manually.
|
|
11
|
-
*/
|
|
12
|
-
import type { FrontendLineItemResource } from './FrontendLineItemResource';
|
|
13
|
-
/**
|
|
14
|
-
*
|
|
15
|
-
* @export
|
|
16
|
-
* @interface FrontendLineItemResourceArrayResponse
|
|
17
|
-
*/
|
|
18
|
-
export interface FrontendLineItemResourceArrayResponse {
|
|
19
|
-
/**
|
|
20
|
-
*
|
|
21
|
-
* @type {Array<FrontendLineItemResource>}
|
|
22
|
-
* @memberof FrontendLineItemResourceArrayResponse
|
|
23
|
-
*/
|
|
24
|
-
data?: Array<FrontendLineItemResource>;
|
|
25
|
-
}
|
|
26
|
-
/**
|
|
27
|
-
* Check if a given object implements the FrontendLineItemResourceArrayResponse interface.
|
|
28
|
-
*/
|
|
29
|
-
export declare function instanceOfFrontendLineItemResourceArrayResponse(value: object): value is FrontendLineItemResourceArrayResponse;
|
|
30
|
-
export declare function FrontendLineItemResourceArrayResponseFromJSON(json: any): FrontendLineItemResourceArrayResponse;
|
|
31
|
-
export declare function FrontendLineItemResourceArrayResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): FrontendLineItemResourceArrayResponse;
|
|
32
|
-
export declare function FrontendLineItemResourceArrayResponseToJSON(json: any): FrontendLineItemResourceArrayResponse;
|
|
33
|
-
export declare function FrontendLineItemResourceArrayResponseToJSONTyped(value?: FrontendLineItemResourceArrayResponse | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -1,50 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/* tslint:disable */
|
|
3
|
-
/* eslint-disable */
|
|
4
|
-
/**
|
|
5
|
-
* My API
|
|
6
|
-
* API documentation for my Laravel app
|
|
7
|
-
*
|
|
8
|
-
* The version of the OpenAPI document: 1.0.0
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
-
* https://openapi-generator.tech
|
|
13
|
-
* Do not edit the class manually.
|
|
14
|
-
*/
|
|
15
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
-
exports.instanceOfFrontendLineItemResourceArrayResponse = instanceOfFrontendLineItemResourceArrayResponse;
|
|
17
|
-
exports.FrontendLineItemResourceArrayResponseFromJSON = FrontendLineItemResourceArrayResponseFromJSON;
|
|
18
|
-
exports.FrontendLineItemResourceArrayResponseFromJSONTyped = FrontendLineItemResourceArrayResponseFromJSONTyped;
|
|
19
|
-
exports.FrontendLineItemResourceArrayResponseToJSON = FrontendLineItemResourceArrayResponseToJSON;
|
|
20
|
-
exports.FrontendLineItemResourceArrayResponseToJSONTyped = FrontendLineItemResourceArrayResponseToJSONTyped;
|
|
21
|
-
var FrontendLineItemResource_1 = require("./FrontendLineItemResource");
|
|
22
|
-
/**
|
|
23
|
-
* Check if a given object implements the FrontendLineItemResourceArrayResponse interface.
|
|
24
|
-
*/
|
|
25
|
-
function instanceOfFrontendLineItemResourceArrayResponse(value) {
|
|
26
|
-
return true;
|
|
27
|
-
}
|
|
28
|
-
function FrontendLineItemResourceArrayResponseFromJSON(json) {
|
|
29
|
-
return FrontendLineItemResourceArrayResponseFromJSONTyped(json, false);
|
|
30
|
-
}
|
|
31
|
-
function FrontendLineItemResourceArrayResponseFromJSONTyped(json, ignoreDiscriminator) {
|
|
32
|
-
if (json == null) {
|
|
33
|
-
return json;
|
|
34
|
-
}
|
|
35
|
-
return {
|
|
36
|
-
'data': json['data'] == null ? undefined : (json['data'].map(FrontendLineItemResource_1.FrontendLineItemResourceFromJSON)),
|
|
37
|
-
};
|
|
38
|
-
}
|
|
39
|
-
function FrontendLineItemResourceArrayResponseToJSON(json) {
|
|
40
|
-
return FrontendLineItemResourceArrayResponseToJSONTyped(json, false);
|
|
41
|
-
}
|
|
42
|
-
function FrontendLineItemResourceArrayResponseToJSONTyped(value, ignoreDiscriminator) {
|
|
43
|
-
if (ignoreDiscriminator === void 0) { ignoreDiscriminator = false; }
|
|
44
|
-
if (value == null) {
|
|
45
|
-
return value;
|
|
46
|
-
}
|
|
47
|
-
return {
|
|
48
|
-
'data': value['data'] == null ? undefined : (value['data'].map(FrontendLineItemResource_1.FrontendLineItemResourceToJSON)),
|
|
49
|
-
};
|
|
50
|
-
}
|
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
# CartCouponLiteResource
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
## Properties
|
|
6
|
-
|
|
7
|
-
Name | Type
|
|
8
|
-
------------ | -------------
|
|
9
|
-
`id` | number
|
|
10
|
-
`code` | string
|
|
11
|
-
`name` | string
|
|
12
|
-
`discount` | number
|
|
13
|
-
`appliesTo` | string
|
|
14
|
-
|
|
15
|
-
## Example
|
|
16
|
-
|
|
17
|
-
```typescript
|
|
18
|
-
import type { CartCouponLiteResource } from '@digital8/lighting-illusions-ts-sdk'
|
|
19
|
-
|
|
20
|
-
// TODO: Update the object below with actual values
|
|
21
|
-
const example = {
|
|
22
|
-
"id": null,
|
|
23
|
-
"code": null,
|
|
24
|
-
"name": null,
|
|
25
|
-
"discount": null,
|
|
26
|
-
"appliesTo": null,
|
|
27
|
-
} satisfies CartCouponLiteResource
|
|
28
|
-
|
|
29
|
-
console.log(example)
|
|
30
|
-
|
|
31
|
-
// Convert the instance to a JSON string
|
|
32
|
-
const exampleJSON: string = JSON.stringify(example)
|
|
33
|
-
console.log(exampleJSON)
|
|
34
|
-
|
|
35
|
-
// Parse the JSON string back to an object
|
|
36
|
-
const exampleParsed = JSON.parse(exampleJSON) as CartCouponLiteResource
|
|
37
|
-
console.log(exampleParsed)
|
|
38
|
-
```
|
|
39
|
-
|
|
40
|
-
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
41
|
-
|
|
42
|
-
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
# CartCouponLiteResourceArrayResponse
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
## Properties
|
|
6
|
-
|
|
7
|
-
Name | Type
|
|
8
|
-
------------ | -------------
|
|
9
|
-
`data` | [Array<CartCouponLiteResource>](CartCouponLiteResource.md)
|
|
10
|
-
|
|
11
|
-
## Example
|
|
12
|
-
|
|
13
|
-
```typescript
|
|
14
|
-
import type { CartCouponLiteResourceArrayResponse } from '@digital8/lighting-illusions-ts-sdk'
|
|
15
|
-
|
|
16
|
-
// TODO: Update the object below with actual values
|
|
17
|
-
const example = {
|
|
18
|
-
"data": null,
|
|
19
|
-
} satisfies CartCouponLiteResourceArrayResponse
|
|
20
|
-
|
|
21
|
-
console.log(example)
|
|
22
|
-
|
|
23
|
-
// Convert the instance to a JSON string
|
|
24
|
-
const exampleJSON: string = JSON.stringify(example)
|
|
25
|
-
console.log(exampleJSON)
|
|
26
|
-
|
|
27
|
-
// Parse the JSON string back to an object
|
|
28
|
-
const exampleParsed = JSON.parse(exampleJSON) as CartCouponLiteResourceArrayResponse
|
|
29
|
-
console.log(exampleParsed)
|
|
30
|
-
```
|
|
31
|
-
|
|
32
|
-
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
33
|
-
|
|
34
|
-
|
|
@@ -1,68 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
# FrontendCartResource
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
## Properties
|
|
6
|
-
|
|
7
|
-
Name | Type
|
|
8
|
-
------------ | -------------
|
|
9
|
-
`id` | number
|
|
10
|
-
`lifecycleStatus` | string
|
|
11
|
-
`siteId` | number
|
|
12
|
-
`sessionToken` | string
|
|
13
|
-
`customer` | [CustomerListResource](CustomerListResource.md)
|
|
14
|
-
`shippingType` | string
|
|
15
|
-
`shippingAddress` | [AddressResource](AddressResource.md)
|
|
16
|
-
`billingAddress` | [AddressResource](AddressResource.md)
|
|
17
|
-
`lineItems` | [Array<FrontendLineItemResource>](FrontendLineItemResource.md)
|
|
18
|
-
`coupons` | [Array<FrontendCartResourceCouponsInner>](FrontendCartResourceCouponsInner.md)
|
|
19
|
-
`subtotal` | number
|
|
20
|
-
`promotionalDiscount` | number
|
|
21
|
-
`couponSubtotalDiscount` | number
|
|
22
|
-
`couponShippingDiscount` | number
|
|
23
|
-
`shipping` | number
|
|
24
|
-
`transitInsurance` | number
|
|
25
|
-
`gst` | number
|
|
26
|
-
`grandTotal` | number
|
|
27
|
-
|
|
28
|
-
## Example
|
|
29
|
-
|
|
30
|
-
```typescript
|
|
31
|
-
import type { FrontendCartResource } from '@digital8/lighting-illusions-ts-sdk'
|
|
32
|
-
|
|
33
|
-
// TODO: Update the object below with actual values
|
|
34
|
-
const example = {
|
|
35
|
-
"id": null,
|
|
36
|
-
"lifecycleStatus": null,
|
|
37
|
-
"siteId": null,
|
|
38
|
-
"sessionToken": null,
|
|
39
|
-
"customer": null,
|
|
40
|
-
"shippingType": null,
|
|
41
|
-
"shippingAddress": null,
|
|
42
|
-
"billingAddress": null,
|
|
43
|
-
"lineItems": null,
|
|
44
|
-
"coupons": null,
|
|
45
|
-
"subtotal": null,
|
|
46
|
-
"promotionalDiscount": null,
|
|
47
|
-
"couponSubtotalDiscount": null,
|
|
48
|
-
"couponShippingDiscount": null,
|
|
49
|
-
"shipping": null,
|
|
50
|
-
"transitInsurance": null,
|
|
51
|
-
"gst": null,
|
|
52
|
-
"grandTotal": null,
|
|
53
|
-
} satisfies FrontendCartResource
|
|
54
|
-
|
|
55
|
-
console.log(example)
|
|
56
|
-
|
|
57
|
-
// Convert the instance to a JSON string
|
|
58
|
-
const exampleJSON: string = JSON.stringify(example)
|
|
59
|
-
console.log(exampleJSON)
|
|
60
|
-
|
|
61
|
-
// Parse the JSON string back to an object
|
|
62
|
-
const exampleParsed = JSON.parse(exampleJSON) as FrontendCartResource
|
|
63
|
-
console.log(exampleParsed)
|
|
64
|
-
```
|
|
65
|
-
|
|
66
|
-
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
67
|
-
|
|
68
|
-
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
# FrontendCartResourceArrayResponse
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
## Properties
|
|
6
|
-
|
|
7
|
-
Name | Type
|
|
8
|
-
------------ | -------------
|
|
9
|
-
`data` | [Array<FrontendCartResource>](FrontendCartResource.md)
|
|
10
|
-
|
|
11
|
-
## Example
|
|
12
|
-
|
|
13
|
-
```typescript
|
|
14
|
-
import type { FrontendCartResourceArrayResponse } from '@digital8/lighting-illusions-ts-sdk'
|
|
15
|
-
|
|
16
|
-
// TODO: Update the object below with actual values
|
|
17
|
-
const example = {
|
|
18
|
-
"data": null,
|
|
19
|
-
} satisfies FrontendCartResourceArrayResponse
|
|
20
|
-
|
|
21
|
-
console.log(example)
|
|
22
|
-
|
|
23
|
-
// Convert the instance to a JSON string
|
|
24
|
-
const exampleJSON: string = JSON.stringify(example)
|
|
25
|
-
console.log(exampleJSON)
|
|
26
|
-
|
|
27
|
-
// Parse the JSON string back to an object
|
|
28
|
-
const exampleParsed = JSON.parse(exampleJSON) as FrontendCartResourceArrayResponse
|
|
29
|
-
console.log(exampleParsed)
|
|
30
|
-
```
|
|
31
|
-
|
|
32
|
-
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
33
|
-
|
|
34
|
-
|
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
# FrontendCartResourceCouponsInner
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
## Properties
|
|
6
|
-
|
|
7
|
-
Name | Type
|
|
8
|
-
------------ | -------------
|
|
9
|
-
`id` | number
|
|
10
|
-
`code` | string
|
|
11
|
-
`name` | string
|
|
12
|
-
`discount` | number
|
|
13
|
-
`appliesTo` | string
|
|
14
|
-
|
|
15
|
-
## Example
|
|
16
|
-
|
|
17
|
-
```typescript
|
|
18
|
-
import type { FrontendCartResourceCouponsInner } from '@digital8/lighting-illusions-ts-sdk'
|
|
19
|
-
|
|
20
|
-
// TODO: Update the object below with actual values
|
|
21
|
-
const example = {
|
|
22
|
-
"id": null,
|
|
23
|
-
"code": null,
|
|
24
|
-
"name": null,
|
|
25
|
-
"discount": null,
|
|
26
|
-
"appliesTo": null,
|
|
27
|
-
} satisfies FrontendCartResourceCouponsInner
|
|
28
|
-
|
|
29
|
-
console.log(example)
|
|
30
|
-
|
|
31
|
-
// Convert the instance to a JSON string
|
|
32
|
-
const exampleJSON: string = JSON.stringify(example)
|
|
33
|
-
console.log(exampleJSON)
|
|
34
|
-
|
|
35
|
-
// Parse the JSON string back to an object
|
|
36
|
-
const exampleParsed = JSON.parse(exampleJSON) as FrontendCartResourceCouponsInner
|
|
37
|
-
console.log(exampleParsed)
|
|
38
|
-
```
|
|
39
|
-
|
|
40
|
-
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
41
|
-
|
|
42
|
-
|
|
@@ -1,50 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
# FrontendLineItemResource
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
## Properties
|
|
6
|
-
|
|
7
|
-
Name | Type
|
|
8
|
-
------------ | -------------
|
|
9
|
-
`id` | number
|
|
10
|
-
`quantity` | number
|
|
11
|
-
`productPrice` | number
|
|
12
|
-
`subtotalAmount` | number
|
|
13
|
-
`totalAmount` | number
|
|
14
|
-
`promotionalSaving` | number
|
|
15
|
-
`isAvailable` | boolean
|
|
16
|
-
`isInStock` | boolean
|
|
17
|
-
`productChild` | [ProductChildLineItemLiteResource](ProductChildLineItemLiteResource.md)
|
|
18
|
-
|
|
19
|
-
## Example
|
|
20
|
-
|
|
21
|
-
```typescript
|
|
22
|
-
import type { FrontendLineItemResource } from '@digital8/lighting-illusions-ts-sdk'
|
|
23
|
-
|
|
24
|
-
// TODO: Update the object below with actual values
|
|
25
|
-
const example = {
|
|
26
|
-
"id": null,
|
|
27
|
-
"quantity": null,
|
|
28
|
-
"productPrice": null,
|
|
29
|
-
"subtotalAmount": null,
|
|
30
|
-
"totalAmount": null,
|
|
31
|
-
"promotionalSaving": null,
|
|
32
|
-
"isAvailable": null,
|
|
33
|
-
"isInStock": null,
|
|
34
|
-
"productChild": null,
|
|
35
|
-
} satisfies FrontendLineItemResource
|
|
36
|
-
|
|
37
|
-
console.log(example)
|
|
38
|
-
|
|
39
|
-
// Convert the instance to a JSON string
|
|
40
|
-
const exampleJSON: string = JSON.stringify(example)
|
|
41
|
-
console.log(exampleJSON)
|
|
42
|
-
|
|
43
|
-
// Parse the JSON string back to an object
|
|
44
|
-
const exampleParsed = JSON.parse(exampleJSON) as FrontendLineItemResource
|
|
45
|
-
console.log(exampleParsed)
|
|
46
|
-
```
|
|
47
|
-
|
|
48
|
-
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
49
|
-
|
|
50
|
-
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
# FrontendLineItemResourceArrayResponse
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
## Properties
|
|
6
|
-
|
|
7
|
-
Name | Type
|
|
8
|
-
------------ | -------------
|
|
9
|
-
`data` | [Array<FrontendLineItemResource>](FrontendLineItemResource.md)
|
|
10
|
-
|
|
11
|
-
## Example
|
|
12
|
-
|
|
13
|
-
```typescript
|
|
14
|
-
import type { FrontendLineItemResourceArrayResponse } from '@digital8/lighting-illusions-ts-sdk'
|
|
15
|
-
|
|
16
|
-
// TODO: Update the object below with actual values
|
|
17
|
-
const example = {
|
|
18
|
-
"data": null,
|
|
19
|
-
} satisfies FrontendLineItemResourceArrayResponse
|
|
20
|
-
|
|
21
|
-
console.log(example)
|
|
22
|
-
|
|
23
|
-
// Convert the instance to a JSON string
|
|
24
|
-
const exampleJSON: string = JSON.stringify(example)
|
|
25
|
-
console.log(exampleJSON)
|
|
26
|
-
|
|
27
|
-
// Parse the JSON string back to an object
|
|
28
|
-
const exampleParsed = JSON.parse(exampleJSON) as FrontendLineItemResourceArrayResponse
|
|
29
|
-
console.log(exampleParsed)
|
|
30
|
-
```
|
|
31
|
-
|
|
32
|
-
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
33
|
-
|
|
34
|
-
|
|
@@ -1,102 +0,0 @@
|
|
|
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
|
-
|
|
@@ -1,73 +0,0 @@
|
|
|
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
|
-
|