@digital8/lighting-illusions-ts-sdk 0.0.1896 → 0.0.1897
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 -48
- package/README.md +3 -37
- package/dist/apis/CartsApi.d.ts +6 -21
- package/dist/apis/CartsApi.js +5 -62
- package/dist/apis/index.d.ts +0 -1
- package/dist/apis/index.js +0 -1
- package/dist/models/AddressFrontendResource.d.ts +1 -1
- package/dist/models/AddressFrontendResource.js +1 -3
- package/dist/models/AddressResource.d.ts +3 -3
- package/dist/models/AddressResource.js +7 -7
- package/dist/models/CartResource.d.ts +6 -37
- package/dist/models/CartResource.js +12 -35
- package/dist/models/ExternalApiLogResource.d.ts +1 -1
- package/dist/models/ExternalApiLogResource.js +3 -1
- package/dist/models/LineItemListResource.d.ts +4 -35
- package/dist/models/LineItemListResource.js +4 -25
- package/dist/models/StoreCartRequestShippingAddress.d.ts +2 -2
- package/dist/models/StoreCartRequestShippingAddress.js +2 -2
- package/dist/models/StoreFrontendResource.d.ts +1 -1
- package/dist/models/StoreFrontendResource.js +3 -1
- package/dist/models/StoreListResource.d.ts +1 -1
- package/dist/models/StoreListResource.js +1 -3
- package/dist/models/StoreResource.d.ts +2 -2
- package/dist/models/StoreResource.js +4 -4
- package/dist/models/StoreStoreRequestAddress.d.ts +6 -0
- package/dist/models/StoreStoreRequestAddress.js +2 -0
- package/dist/models/index.d.ts +0 -23
- package/dist/models/index.js +0 -23
- package/docs/AddressResource.md +2 -2
- package/docs/CartResource.md +7 -17
- package/docs/CartsApi.md +8 -74
- package/docs/LineItemListResource.md +1 -11
- package/docs/StoreCartRequestShippingAddress.md +2 -2
- package/docs/StoreStoreRequestAddress.md +2 -0
- package/package.json +1 -1
- package/src/apis/CartsApi.ts +14 -64
- package/src/apis/index.ts +0 -1
- package/src/models/AddressFrontendResource.ts +2 -3
- package/src/models/AddressResource.ts +9 -9
- package/src/models/CartResource.ts +18 -71
- package/src/models/ExternalApiLogResource.ts +3 -2
- package/src/models/LineItemListResource.ts +12 -64
- package/src/models/StoreCartRequestShippingAddress.ts +4 -4
- package/src/models/StoreFrontendResource.ts +3 -2
- package/src/models/StoreListResource.ts +2 -3
- package/src/models/StoreResource.ts +5 -5
- package/src/models/StoreStoreRequestAddress.ts +8 -0
- package/src/models/index.ts +0 -23
- package/dist/apis/OrdersApi.d.ts +0 -170
- package/dist/apis/OrdersApi.js +0 -678
- package/dist/models/AdminOrderResource.d.ts +0 -262
- package/dist/models/AdminOrderResource.js +0 -187
- package/dist/models/AdminOrderResourceArrayResponse.d.ts +0 -33
- package/dist/models/AdminOrderResourceArrayResponse.js +0 -50
- package/dist/models/AttachItemOrderRequest.d.ts +0 -44
- package/dist/models/AttachItemOrderRequest.js +0 -57
- package/dist/models/CartCouponResource.d.ts +0 -50
- package/dist/models/CartCouponResource.js +0 -63
- package/dist/models/CartCouponResourceArrayResponse.d.ts +0 -33
- package/dist/models/CartCouponResourceArrayResponse.js +0 -50
- package/dist/models/DetachCouponCartRequest.d.ts +0 -32
- package/dist/models/DetachCouponCartRequest.js +0 -51
- package/dist/models/DiscountType.d.ts +0 -26
- package/dist/models/DiscountType.js +0 -52
- package/dist/models/DiscountValueType.d.ts +0 -25
- package/dist/models/DiscountValueType.js +0 -51
- package/dist/models/GetAllOrderRequest.d.ts +0 -104
- package/dist/models/GetAllOrderRequest.js +0 -84
- package/dist/models/IndexOrderRequest.d.ts +0 -140
- package/dist/models/IndexOrderRequest.js +0 -96
- package/dist/models/LineItemDiscountResource.d.ts +0 -50
- package/dist/models/LineItemDiscountResource.js +0 -63
- package/dist/models/LineItemDiscountResourceArrayResponse.d.ts +0 -33
- package/dist/models/LineItemDiscountResourceArrayResponse.js +0 -50
- package/dist/models/OrderListResource.d.ts +0 -101
- package/dist/models/OrderListResource.js +0 -90
- package/dist/models/OrderListResourceArrayResponse.d.ts +0 -33
- package/dist/models/OrderListResourceArrayResponse.js +0 -50
- package/dist/models/OrderLiteResource.d.ts +0 -62
- package/dist/models/OrderLiteResource.js +0 -67
- package/dist/models/OrderLiteResourceArrayResponse.d.ts +0 -33
- package/dist/models/OrderLiteResourceArrayResponse.js +0 -50
- package/dist/models/PaginatedOrderListResourceResponse.d.ts +0 -40
- package/dist/models/PaginatedOrderListResourceResponse.js +0 -57
- package/dist/models/ProductChildCartLiteResource.d.ts +0 -88
- package/dist/models/ProductChildCartLiteResource.js +0 -89
- package/dist/models/ProductChildCartLiteResourceArrayResponse.d.ts +0 -33
- package/dist/models/ProductChildCartLiteResourceArrayResponse.js +0 -50
- package/dist/models/UpdateItemOrderRequest.d.ts +0 -38
- package/dist/models/UpdateItemOrderRequest.js +0 -53
- package/dist/models/UpdateOrderRequest.d.ts +0 -111
- package/dist/models/UpdateOrderRequest.js +0 -99
- package/dist/models/UpdateOrderRequestBillingAddress.d.ts +0 -80
- package/dist/models/UpdateOrderRequestBillingAddress.js +0 -67
- package/dist/models/UpdateOrderRequestShippingAddress.d.ts +0 -80
- package/dist/models/UpdateOrderRequestShippingAddress.js +0 -67
- package/docs/AdminOrderResource.md +0 -110
- package/docs/AdminOrderResourceArrayResponse.md +0 -34
- package/docs/AttachItemOrderRequest.md +0 -38
- package/docs/CartCouponResource.md +0 -40
- package/docs/CartCouponResourceArrayResponse.md +0 -34
- package/docs/DetachCouponCartRequest.md +0 -34
- package/docs/DiscountType.md +0 -32
- package/docs/DiscountValueType.md +0 -32
- package/docs/GetAllOrderRequest.md +0 -52
- package/docs/IndexOrderRequest.md +0 -64
- package/docs/LineItemDiscountResource.md +0 -40
- package/docs/LineItemDiscountResourceArrayResponse.md +0 -34
- package/docs/OrderListResource.md +0 -56
- package/docs/OrderListResourceArrayResponse.md +0 -34
- package/docs/OrderLiteResource.md +0 -44
- package/docs/OrderLiteResourceArrayResponse.md +0 -34
- package/docs/OrdersApi.md +0 -675
- package/docs/PaginatedOrderListResourceResponse.md +0 -36
- package/docs/ProductChildCartLiteResource.md +0 -52
- package/docs/ProductChildCartLiteResourceArrayResponse.md +0 -34
- package/docs/UpdateItemOrderRequest.md +0 -36
- package/docs/UpdateOrderRequest.md +0 -52
- package/docs/UpdateOrderRequestBillingAddress.md +0 -50
- package/docs/UpdateOrderRequestShippingAddress.md +0 -50
- package/src/apis/OrdersApi.ts +0 -552
- package/src/models/AdminOrderResource.ts +0 -414
- package/src/models/AdminOrderResourceArrayResponse.ts +0 -73
- package/src/models/AttachItemOrderRequest.ts +0 -83
- package/src/models/CartCouponResource.ts +0 -93
- package/src/models/CartCouponResourceArrayResponse.ts +0 -73
- package/src/models/DetachCouponCartRequest.ts +0 -66
- package/src/models/DiscountType.ts +0 -54
- package/src/models/DiscountValueType.ts +0 -53
- package/src/models/GetAllOrderRequest.ts +0 -159
- package/src/models/IndexOrderRequest.ts +0 -207
- package/src/models/LineItemDiscountResource.ts +0 -93
- package/src/models/LineItemDiscountResourceArrayResponse.ts +0 -73
- package/src/models/OrderListResource.ts +0 -183
- package/src/models/OrderListResourceArrayResponse.ts +0 -73
- package/src/models/OrderLiteResource.ts +0 -109
- package/src/models/OrderLiteResourceArrayResponse.ts +0 -73
- package/src/models/PaginatedOrderListResourceResponse.ts +0 -90
- package/src/models/ProductChildCartLiteResource.ts +0 -162
- package/src/models/ProductChildCartLiteResourceArrayResponse.ts +0 -73
- package/src/models/UpdateItemOrderRequest.ts +0 -74
- package/src/models/UpdateOrderRequest.ts +0 -183
- package/src/models/UpdateOrderRequestBillingAddress.ts +0 -130
- package/src/models/UpdateOrderRequestShippingAddress.ts +0 -130
package/dist/models/index.js
CHANGED
|
@@ -21,8 +21,6 @@ __exportStar(require("./AddressFrontendResourceArrayResponse"), exports);
|
|
|
21
21
|
__exportStar(require("./AddressResource"), exports);
|
|
22
22
|
__exportStar(require("./AddressResourceArrayResponse"), exports);
|
|
23
23
|
__exportStar(require("./AddressType"), exports);
|
|
24
|
-
__exportStar(require("./AdminOrderResource"), exports);
|
|
25
|
-
__exportStar(require("./AdminOrderResourceArrayResponse"), exports);
|
|
26
24
|
__exportStar(require("./AssetFileForUploadResource"), exports);
|
|
27
25
|
__exportStar(require("./AssetFileForUploadResourceArrayResponse"), exports);
|
|
28
26
|
__exportStar(require("./AssetFrontendResource"), exports);
|
|
@@ -46,7 +44,6 @@ __exportStar(require("./AttachDocumentsProductChildRequest"), exports);
|
|
|
46
44
|
__exportStar(require("./AttachDocumentsProductChildRequestDocumentsInner"), exports);
|
|
47
45
|
__exportStar(require("./AttachDocumentsProductRangeRequest"), exports);
|
|
48
46
|
__exportStar(require("./AttachItemCartRequest"), exports);
|
|
49
|
-
__exportStar(require("./AttachItemOrderRequest"), exports);
|
|
50
47
|
__exportStar(require("./AttachProductTypeAttributeRequest"), exports);
|
|
51
48
|
__exportStar(require("./AttachProductsProductCategoryRequest"), exports);
|
|
52
49
|
__exportStar(require("./AttachStoresSupplierRequest"), exports);
|
|
@@ -63,8 +60,6 @@ __exportStar(require("./AttributeResourceArrayResponse"), exports);
|
|
|
63
60
|
__exportStar(require("./AttributeType"), exports);
|
|
64
61
|
__exportStar(require("./AttributeValueResource"), exports);
|
|
65
62
|
__exportStar(require("./AttributeValueResourceArrayResponse"), exports);
|
|
66
|
-
__exportStar(require("./CartCouponResource"), exports);
|
|
67
|
-
__exportStar(require("./CartCouponResourceArrayResponse"), exports);
|
|
68
63
|
__exportStar(require("./CartListResource"), exports);
|
|
69
64
|
__exportStar(require("./CartListResourceArrayResponse"), exports);
|
|
70
65
|
__exportStar(require("./CartOrderSource"), exports);
|
|
@@ -95,7 +90,6 @@ __exportStar(require("./DestroyAttributeValueRequest"), exports);
|
|
|
95
90
|
__exportStar(require("./DetachAccessoriesProductRangeRequest"), exports);
|
|
96
91
|
__exportStar(require("./DetachAssetableOverlayTemplateRequest"), exports);
|
|
97
92
|
__exportStar(require("./DetachAttributesProductRangeRequest"), exports);
|
|
98
|
-
__exportStar(require("./DetachCouponCartRequest"), exports);
|
|
99
93
|
__exportStar(require("./DetachDocumentablesDocumentRequest"), exports);
|
|
100
94
|
__exportStar(require("./DetachDocumentablesDocumentRequestDocumentablesInner"), exports);
|
|
101
95
|
__exportStar(require("./DetachDocumentsProductChildRequest"), exports);
|
|
@@ -103,8 +97,6 @@ __exportStar(require("./DetachDocumentsProductRangeRequest"), exports);
|
|
|
103
97
|
__exportStar(require("./DetachProductsProductCategoryRequest"), exports);
|
|
104
98
|
__exportStar(require("./DetachStoresSupplierRequest"), exports);
|
|
105
99
|
__exportStar(require("./DetachSuppliersStoreRequest"), exports);
|
|
106
|
-
__exportStar(require("./DiscountType"), exports);
|
|
107
|
-
__exportStar(require("./DiscountValueType"), exports);
|
|
108
100
|
__exportStar(require("./DocumentFileForUploadResource"), exports);
|
|
109
101
|
__exportStar(require("./DocumentFileForUploadResourceArrayResponse"), exports);
|
|
110
102
|
__exportStar(require("./DocumentFrontendResource"), exports);
|
|
@@ -127,7 +119,6 @@ __exportStar(require("./GetAllDocumentRequest"), exports);
|
|
|
127
119
|
__exportStar(require("./GetAllGoogleCategoryRequest"), exports);
|
|
128
120
|
__exportStar(require("./GetAllMenuItemRequest"), exports);
|
|
129
121
|
__exportStar(require("./GetAllMenuRequest"), exports);
|
|
130
|
-
__exportStar(require("./GetAllOrderRequest"), exports);
|
|
131
122
|
__exportStar(require("./GetAllOverlayTemplateRequest"), exports);
|
|
132
123
|
__exportStar(require("./GetAllProductCategoryRequest"), exports);
|
|
133
124
|
__exportStar(require("./GetAllProductChildRequest"), exports);
|
|
@@ -160,7 +151,6 @@ __exportStar(require("./IndexExternalApiLogRequest"), exports);
|
|
|
160
151
|
__exportStar(require("./IndexLabelRequest"), exports);
|
|
161
152
|
__exportStar(require("./IndexMenuRequest"), exports);
|
|
162
153
|
__exportStar(require("./IndexModelAttributeRequest"), exports);
|
|
163
|
-
__exportStar(require("./IndexOrderRequest"), exports);
|
|
164
154
|
__exportStar(require("./IndexOverlayTemplateRequest"), exports);
|
|
165
155
|
__exportStar(require("./IndexProductCategoryRequest"), exports);
|
|
166
156
|
__exportStar(require("./IndexProductChildRequest"), exports);
|
|
@@ -182,8 +172,6 @@ __exportStar(require("./LabelResource"), exports);
|
|
|
182
172
|
__exportStar(require("./LabelResourceArrayResponse"), exports);
|
|
183
173
|
__exportStar(require("./LiAddressResource"), exports);
|
|
184
174
|
__exportStar(require("./LiAddressResourceArrayResponse"), exports);
|
|
185
|
-
__exportStar(require("./LineItemDiscountResource"), exports);
|
|
186
|
-
__exportStar(require("./LineItemDiscountResourceArrayResponse"), exports);
|
|
187
175
|
__exportStar(require("./LineItemListResource"), exports);
|
|
188
176
|
__exportStar(require("./LineItemListResourceArrayResponse"), exports);
|
|
189
177
|
__exportStar(require("./ListAssetsProductRegistrationRequest"), exports);
|
|
@@ -207,10 +195,6 @@ __exportStar(require("./ModelAttributeListResource"), exports);
|
|
|
207
195
|
__exportStar(require("./ModelAttributeListResourceArrayResponse"), exports);
|
|
208
196
|
__exportStar(require("./ModelAttributeResource"), exports);
|
|
209
197
|
__exportStar(require("./ModelAttributeResourceArrayResponse"), exports);
|
|
210
|
-
__exportStar(require("./OrderListResource"), exports);
|
|
211
|
-
__exportStar(require("./OrderListResourceArrayResponse"), exports);
|
|
212
|
-
__exportStar(require("./OrderLiteResource"), exports);
|
|
213
|
-
__exportStar(require("./OrderLiteResourceArrayResponse"), exports);
|
|
214
198
|
__exportStar(require("./OverlayTemplateAssetFrontendResource"), exports);
|
|
215
199
|
__exportStar(require("./OverlayTemplateAssetFrontendResourceArrayResponse"), exports);
|
|
216
200
|
__exportStar(require("./OverlayTemplateAssetPosition"), exports);
|
|
@@ -239,7 +223,6 @@ __exportStar(require("./PaginatedGoogleCategoryResourceResponse"), exports);
|
|
|
239
223
|
__exportStar(require("./PaginatedLabelListResourceResponse"), exports);
|
|
240
224
|
__exportStar(require("./PaginatedMenuListResourceResponse"), exports);
|
|
241
225
|
__exportStar(require("./PaginatedModelAttributeListResourceResponse"), exports);
|
|
242
|
-
__exportStar(require("./PaginatedOrderListResourceResponse"), exports);
|
|
243
226
|
__exportStar(require("./PaginatedOverlayTemplateListResourceResponse"), exports);
|
|
244
227
|
__exportStar(require("./PaginatedOverlayTemplateLiteResourceResponse"), exports);
|
|
245
228
|
__exportStar(require("./PaginatedOverlayTemplateResourceResponse"), exports);
|
|
@@ -298,8 +281,6 @@ __exportStar(require("./ProductChildAttributeGroupedResource"), exports);
|
|
|
298
281
|
__exportStar(require("./ProductChildAttributeGroupedResourceArrayResponse"), exports);
|
|
299
282
|
__exportStar(require("./ProductChildAttributeResource"), exports);
|
|
300
283
|
__exportStar(require("./ProductChildAttributeResourceArrayResponse"), exports);
|
|
301
|
-
__exportStar(require("./ProductChildCartLiteResource"), exports);
|
|
302
|
-
__exportStar(require("./ProductChildCartLiteResourceArrayResponse"), exports);
|
|
303
284
|
__exportStar(require("./ProductChildListResource"), exports);
|
|
304
285
|
__exportStar(require("./ProductChildListResourceArrayResponse"), exports);
|
|
305
286
|
__exportStar(require("./ProductChildLiteResource"), exports);
|
|
@@ -476,15 +457,11 @@ __exportStar(require("./UpdateDocumentRequest"), exports);
|
|
|
476
457
|
__exportStar(require("./UpdateFilterOrderAttributeRequest"), exports);
|
|
477
458
|
__exportStar(require("./UpdateFilterOrderAttributeRequestValuesInner"), exports);
|
|
478
459
|
__exportStar(require("./UpdateItemCartRequest"), exports);
|
|
479
|
-
__exportStar(require("./UpdateItemOrderRequest"), exports);
|
|
480
460
|
__exportStar(require("./UpdateLabelRequest"), exports);
|
|
481
461
|
__exportStar(require("./UpdateMenuItemRequest"), exports);
|
|
482
462
|
__exportStar(require("./UpdateMenuRequest"), exports);
|
|
483
463
|
__exportStar(require("./UpdateMenuRequestMenuItemOrderInner"), exports);
|
|
484
464
|
__exportStar(require("./UpdateModelAttributeRequest"), exports);
|
|
485
|
-
__exportStar(require("./UpdateOrderRequest"), exports);
|
|
486
|
-
__exportStar(require("./UpdateOrderRequestBillingAddress"), exports);
|
|
487
|
-
__exportStar(require("./UpdateOrderRequestShippingAddress"), exports);
|
|
488
465
|
__exportStar(require("./UpdateOverlayTemplateAssetRequest"), exports);
|
|
489
466
|
__exportStar(require("./UpdateOverlayTemplateRequest"), exports);
|
|
490
467
|
__exportStar(require("./UpdateProductCategoryRequest"), exports);
|
package/docs/AddressResource.md
CHANGED
|
@@ -8,8 +8,8 @@ Name | Type
|
|
|
8
8
|
------------ | -------------
|
|
9
9
|
`id` | number
|
|
10
10
|
`sourceAddressId` | number
|
|
11
|
+
`addresseeName` | string
|
|
11
12
|
`company` | string
|
|
12
|
-
`addressee` | string
|
|
13
13
|
`line1` | string
|
|
14
14
|
`line2` | string
|
|
15
15
|
`postcode` | string
|
|
@@ -27,8 +27,8 @@ import type { AddressResource } from '@digital8/lighting-illusions-ts-sdk'
|
|
|
27
27
|
const example = {
|
|
28
28
|
"id": null,
|
|
29
29
|
"sourceAddressId": null,
|
|
30
|
+
"addresseeName": null,
|
|
30
31
|
"company": null,
|
|
31
|
-
"addressee": null,
|
|
32
32
|
"line1": null,
|
|
33
33
|
"line2": null,
|
|
34
34
|
"postcode": null,
|
package/docs/CartResource.md
CHANGED
|
@@ -25,18 +25,13 @@ Name | Type
|
|
|
25
25
|
`site` | [SiteLiteResource](SiteLiteResource.md)
|
|
26
26
|
`customer` | [CustomerListResource](CustomerListResource.md)
|
|
27
27
|
`lineItems` | [Array<LineItemListResource>](LineItemListResource.md)
|
|
28
|
-
`coupons` |
|
|
28
|
+
`coupons` | object
|
|
29
29
|
`shippingAddress` | [AddressResource](AddressResource.md)
|
|
30
30
|
`billingAddress` | [AddressResource](AddressResource.md)
|
|
31
|
-
`discountPreview` | number
|
|
32
31
|
`subtotal` | number
|
|
33
|
-
`
|
|
34
|
-
`
|
|
35
|
-
`
|
|
36
|
-
`productDiscountAmount` | number
|
|
37
|
-
`shippingDiscountAmount` | number
|
|
38
|
-
`cartDiscountAmount` | number
|
|
39
|
-
`finalTotalAmount` | number
|
|
32
|
+
`discountPreview` | number
|
|
33
|
+
`shippingEstimate` | number
|
|
34
|
+
`insuranceEstimate` | number
|
|
40
35
|
`status` | string
|
|
41
36
|
|
|
42
37
|
## Example
|
|
@@ -68,15 +63,10 @@ const example = {
|
|
|
68
63
|
"coupons": null,
|
|
69
64
|
"shippingAddress": null,
|
|
70
65
|
"billingAddress": null,
|
|
71
|
-
"discountPreview": null,
|
|
72
66
|
"subtotal": null,
|
|
73
|
-
"
|
|
74
|
-
"
|
|
75
|
-
"
|
|
76
|
-
"productDiscountAmount": null,
|
|
77
|
-
"shippingDiscountAmount": null,
|
|
78
|
-
"cartDiscountAmount": null,
|
|
79
|
-
"finalTotalAmount": null,
|
|
67
|
+
"discountPreview": null,
|
|
68
|
+
"shippingEstimate": null,
|
|
69
|
+
"insuranceEstimate": null,
|
|
80
70
|
"status": null,
|
|
81
71
|
} satisfies CartResource
|
|
82
72
|
|
package/docs/CartsApi.md
CHANGED
|
@@ -7,13 +7,12 @@ All URIs are relative to *http://localhost/api*
|
|
|
7
7
|
| [**attachCouponCart**](CartsApi.md#attachcouponcartoperation) | **POST** /admin-api/carts/{cart}/coupons/attach | Auto-generated: attachCouponCart |
|
|
8
8
|
| [**attachItemCart**](CartsApi.md#attachitemcartoperation) | **POST** /admin-api/carts/{cart}/items/attach | Auto-generated: attachItemCart |
|
|
9
9
|
| [**destroyCart**](CartsApi.md#destroycart) | **DELETE** /admin-api/carts/{cart}/delete | Auto-generated: destroyCart |
|
|
10
|
-
| [**detachCouponCart**](CartsApi.md#
|
|
10
|
+
| [**detachCouponCart**](CartsApi.md#detachcouponcart) | **DELETE** /admin-api/carts/{cart}/coupons/{coupon}/detach | Auto-generated: detachCouponCart |
|
|
11
11
|
| [**detachItemCart**](CartsApi.md#detachitemcart) | **DELETE** /admin-api/carts/{cart}/items/{lineItem}/detach | Auto-generated: detachItemCart |
|
|
12
12
|
| [**indexCart**](CartsApi.md#indexcartoperation) | **POST** /admin-api/carts/list | Auto-generated: indexCart |
|
|
13
13
|
| [**sendPaymentLinkCart**](CartsApi.md#sendpaymentlinkcart) | **POST** /admin-api/carts/{cart}/send-payment-link | Auto-generated: sendPaymentLinkCart |
|
|
14
14
|
| [**showCart**](CartsApi.md#showcart) | **GET** /admin-api/carts/{cart} | Auto-generated: showCart |
|
|
15
15
|
| [**storeCart**](CartsApi.md#storecartoperation) | **POST** /admin-api/carts/create | Auto-generated: storeCart |
|
|
16
|
-
| [**storeFromCartOrder**](CartsApi.md#storefromcartorder) | **POST** /admin-api/carts/{cart}/place-order | Auto-generated: storeFromCartOrder |
|
|
17
16
|
| [**updateCart**](CartsApi.md#updatecartoperation) | **PUT** /admin-api/carts/{cart}/update | Auto-generated: updateCart |
|
|
18
17
|
| [**updateItemCart**](CartsApi.md#updateitemcartoperation) | **PUT** /admin-api/carts/{cart}/items/{lineItem}/update | Auto-generated: updateItemCart |
|
|
19
18
|
|
|
@@ -222,7 +221,7 @@ No authorization required
|
|
|
222
221
|
|
|
223
222
|
## detachCouponCart
|
|
224
223
|
|
|
225
|
-
> CartResource detachCouponCart(cart,
|
|
224
|
+
> CartResource detachCouponCart(cart, coupon)
|
|
226
225
|
|
|
227
226
|
Auto-generated: detachCouponCart
|
|
228
227
|
|
|
@@ -233,7 +232,7 @@ import {
|
|
|
233
232
|
Configuration,
|
|
234
233
|
CartsApi,
|
|
235
234
|
} from '@digital8/lighting-illusions-ts-sdk';
|
|
236
|
-
import type {
|
|
235
|
+
import type { DetachCouponCartRequest } from '@digital8/lighting-illusions-ts-sdk';
|
|
237
236
|
|
|
238
237
|
async function example() {
|
|
239
238
|
console.log("🚀 Testing @digital8/lighting-illusions-ts-sdk SDK...");
|
|
@@ -242,9 +241,9 @@ async function example() {
|
|
|
242
241
|
const body = {
|
|
243
242
|
// number | The id of the cart
|
|
244
243
|
cart: 56,
|
|
245
|
-
//
|
|
246
|
-
|
|
247
|
-
} satisfies
|
|
244
|
+
// number | The id of the coupon
|
|
245
|
+
coupon: 56,
|
|
246
|
+
} satisfies DetachCouponCartRequest;
|
|
248
247
|
|
|
249
248
|
try {
|
|
250
249
|
const data = await api.detachCouponCart(body);
|
|
@@ -264,7 +263,7 @@ example().catch(console.error);
|
|
|
264
263
|
| Name | Type | Description | Notes |
|
|
265
264
|
|------------- | ------------- | ------------- | -------------|
|
|
266
265
|
| **cart** | `number` | The id of the cart | [Defaults to `undefined`] |
|
|
267
|
-
| **
|
|
266
|
+
| **coupon** | `number` | The id of the coupon | [Defaults to `undefined`] |
|
|
268
267
|
|
|
269
268
|
### Return type
|
|
270
269
|
|
|
@@ -276,7 +275,7 @@ No authorization required
|
|
|
276
275
|
|
|
277
276
|
### HTTP request headers
|
|
278
277
|
|
|
279
|
-
- **Content-Type**:
|
|
278
|
+
- **Content-Type**: Not defined
|
|
280
279
|
- **Accept**: `application/json`
|
|
281
280
|
|
|
282
281
|
|
|
@@ -616,71 +615,6 @@ No authorization required
|
|
|
616
615
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
617
616
|
|
|
618
617
|
|
|
619
|
-
## storeFromCartOrder
|
|
620
|
-
|
|
621
|
-
> AdminOrderResource storeFromCartOrder(cart)
|
|
622
|
-
|
|
623
|
-
Auto-generated: storeFromCartOrder
|
|
624
|
-
|
|
625
|
-
### Example
|
|
626
|
-
|
|
627
|
-
```ts
|
|
628
|
-
import {
|
|
629
|
-
Configuration,
|
|
630
|
-
CartsApi,
|
|
631
|
-
} from '@digital8/lighting-illusions-ts-sdk';
|
|
632
|
-
import type { StoreFromCartOrderRequest } from '@digital8/lighting-illusions-ts-sdk';
|
|
633
|
-
|
|
634
|
-
async function example() {
|
|
635
|
-
console.log("🚀 Testing @digital8/lighting-illusions-ts-sdk SDK...");
|
|
636
|
-
const api = new CartsApi();
|
|
637
|
-
|
|
638
|
-
const body = {
|
|
639
|
-
// number | The id of the cart
|
|
640
|
-
cart: 56,
|
|
641
|
-
} satisfies StoreFromCartOrderRequest;
|
|
642
|
-
|
|
643
|
-
try {
|
|
644
|
-
const data = await api.storeFromCartOrder(body);
|
|
645
|
-
console.log(data);
|
|
646
|
-
} catch (error) {
|
|
647
|
-
console.error(error);
|
|
648
|
-
}
|
|
649
|
-
}
|
|
650
|
-
|
|
651
|
-
// Run the test
|
|
652
|
-
example().catch(console.error);
|
|
653
|
-
```
|
|
654
|
-
|
|
655
|
-
### Parameters
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
| Name | Type | Description | Notes |
|
|
659
|
-
|------------- | ------------- | ------------- | -------------|
|
|
660
|
-
| **cart** | `number` | The id of the cart | [Defaults to `undefined`] |
|
|
661
|
-
|
|
662
|
-
### Return type
|
|
663
|
-
|
|
664
|
-
[**AdminOrderResource**](AdminOrderResource.md)
|
|
665
|
-
|
|
666
|
-
### Authorization
|
|
667
|
-
|
|
668
|
-
No authorization required
|
|
669
|
-
|
|
670
|
-
### HTTP request headers
|
|
671
|
-
|
|
672
|
-
- **Content-Type**: Not defined
|
|
673
|
-
- **Accept**: `application/json`
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
### HTTP response details
|
|
677
|
-
| Status code | Description | Response headers |
|
|
678
|
-
|-------------|-------------|------------------|
|
|
679
|
-
| **200** | Successful resource response | - |
|
|
680
|
-
|
|
681
|
-
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
682
|
-
|
|
683
|
-
|
|
684
618
|
## updateCart
|
|
685
619
|
|
|
686
620
|
> CartResource updateCart(cart, updateCartRequest)
|
|
@@ -9,12 +9,7 @@ Name | Type
|
|
|
9
9
|
`id` | number
|
|
10
10
|
`quantity` | number
|
|
11
11
|
`productPrice` | number
|
|
12
|
-
`
|
|
13
|
-
`productDiscount` | number
|
|
14
|
-
`totalDiscount` | number
|
|
15
|
-
`lineSubtotal` | number
|
|
16
|
-
`discounts` | [Array<LineItemDiscountResource>](LineItemDiscountResource.md)
|
|
17
|
-
`productChild` | [ProductChildCartLiteResource](ProductChildCartLiteResource.md)
|
|
12
|
+
`productChild` | [ProductChildListResource](ProductChildListResource.md)
|
|
18
13
|
|
|
19
14
|
## Example
|
|
20
15
|
|
|
@@ -26,11 +21,6 @@ const example = {
|
|
|
26
21
|
"id": null,
|
|
27
22
|
"quantity": null,
|
|
28
23
|
"productPrice": null,
|
|
29
|
-
"labelId": null,
|
|
30
|
-
"productDiscount": null,
|
|
31
|
-
"totalDiscount": null,
|
|
32
|
-
"lineSubtotal": null,
|
|
33
|
-
"discounts": null,
|
|
34
24
|
"productChild": null,
|
|
35
25
|
} satisfies LineItemListResource
|
|
36
26
|
|
|
@@ -6,8 +6,8 @@
|
|
|
6
6
|
|
|
7
7
|
Name | Type
|
|
8
8
|
------------ | -------------
|
|
9
|
+
`addresseeName` | string
|
|
9
10
|
`company` | string
|
|
10
|
-
`addressee` | string
|
|
11
11
|
`line1` | string
|
|
12
12
|
`line2` | string
|
|
13
13
|
`suburb` | string
|
|
@@ -22,8 +22,8 @@ import type { StoreCartRequestShippingAddress } from '@digital8/lighting-illusio
|
|
|
22
22
|
|
|
23
23
|
// TODO: Update the object below with actual values
|
|
24
24
|
const example = {
|
|
25
|
+
"addresseeName": null,
|
|
25
26
|
"company": null,
|
|
26
|
-
"addressee": null,
|
|
27
27
|
"line1": null,
|
|
28
28
|
"line2": null,
|
|
29
29
|
"suburb": null,
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
|
|
7
7
|
Name | Type
|
|
8
8
|
------------ | -------------
|
|
9
|
+
`addresseeName` | string
|
|
9
10
|
`company` | string
|
|
10
11
|
`line1` | string
|
|
11
12
|
`line2` | string
|
|
@@ -21,6 +22,7 @@ import type { StoreStoreRequestAddress } from '@digital8/lighting-illusions-ts-s
|
|
|
21
22
|
|
|
22
23
|
// TODO: Update the object below with actual values
|
|
23
24
|
const example = {
|
|
25
|
+
"addresseeName": null,
|
|
24
26
|
"company": null,
|
|
25
27
|
"line1": null,
|
|
26
28
|
"line2": null,
|
package/package.json
CHANGED
package/src/apis/CartsApi.ts
CHANGED
|
@@ -15,11 +15,9 @@
|
|
|
15
15
|
|
|
16
16
|
import * as runtime from '../runtime';
|
|
17
17
|
import type {
|
|
18
|
-
AdminOrderResource,
|
|
19
18
|
AttachCouponCartRequest,
|
|
20
19
|
AttachItemCartRequest,
|
|
21
20
|
CartResource,
|
|
22
|
-
DetachCouponCartRequest,
|
|
23
21
|
GenericResponse,
|
|
24
22
|
IndexCartRequest,
|
|
25
23
|
PaginatedCartListResourceResponse,
|
|
@@ -28,16 +26,12 @@ import type {
|
|
|
28
26
|
UpdateItemCartRequest,
|
|
29
27
|
} from '../models/index';
|
|
30
28
|
import {
|
|
31
|
-
AdminOrderResourceFromJSON,
|
|
32
|
-
AdminOrderResourceToJSON,
|
|
33
29
|
AttachCouponCartRequestFromJSON,
|
|
34
30
|
AttachCouponCartRequestToJSON,
|
|
35
31
|
AttachItemCartRequestFromJSON,
|
|
36
32
|
AttachItemCartRequestToJSON,
|
|
37
33
|
CartResourceFromJSON,
|
|
38
34
|
CartResourceToJSON,
|
|
39
|
-
DetachCouponCartRequestFromJSON,
|
|
40
|
-
DetachCouponCartRequestToJSON,
|
|
41
35
|
GenericResponseFromJSON,
|
|
42
36
|
GenericResponseToJSON,
|
|
43
37
|
IndexCartRequestFromJSON,
|
|
@@ -66,9 +60,9 @@ export interface DestroyCartRequest {
|
|
|
66
60
|
cart: number;
|
|
67
61
|
}
|
|
68
62
|
|
|
69
|
-
export interface
|
|
63
|
+
export interface DetachCouponCartRequest {
|
|
70
64
|
cart: number;
|
|
71
|
-
|
|
65
|
+
coupon: number;
|
|
72
66
|
}
|
|
73
67
|
|
|
74
68
|
export interface DetachItemCartRequest {
|
|
@@ -92,10 +86,6 @@ export interface StoreCartOperationRequest {
|
|
|
92
86
|
storeCartRequest?: StoreCartRequest;
|
|
93
87
|
}
|
|
94
88
|
|
|
95
|
-
export interface StoreFromCartOrderRequest {
|
|
96
|
-
cart: number;
|
|
97
|
-
}
|
|
98
|
-
|
|
99
89
|
export interface UpdateCartOperationRequest {
|
|
100
90
|
cart: number;
|
|
101
91
|
updateCartRequest?: UpdateCartRequest;
|
|
@@ -256,7 +246,7 @@ export class CartsApi extends runtime.BaseAPI {
|
|
|
256
246
|
/**
|
|
257
247
|
* Creates request options for detachCouponCart without sending the request
|
|
258
248
|
*/
|
|
259
|
-
async detachCouponCartRequestOpts(requestParameters:
|
|
249
|
+
async detachCouponCartRequestOpts(requestParameters: DetachCouponCartRequest): Promise<runtime.RequestOpts> {
|
|
260
250
|
if (requestParameters['cart'] == null) {
|
|
261
251
|
throw new runtime.RequiredError(
|
|
262
252
|
'cart',
|
|
@@ -264,29 +254,34 @@ export class CartsApi extends runtime.BaseAPI {
|
|
|
264
254
|
);
|
|
265
255
|
}
|
|
266
256
|
|
|
257
|
+
if (requestParameters['coupon'] == null) {
|
|
258
|
+
throw new runtime.RequiredError(
|
|
259
|
+
'coupon',
|
|
260
|
+
'Required parameter "coupon" was null or undefined when calling detachCouponCart().'
|
|
261
|
+
);
|
|
262
|
+
}
|
|
263
|
+
|
|
267
264
|
const queryParameters: any = {};
|
|
268
265
|
|
|
269
266
|
const headerParameters: runtime.HTTPHeaders = {};
|
|
270
267
|
|
|
271
|
-
headerParameters['Content-Type'] = 'application/json';
|
|
272
|
-
|
|
273
268
|
|
|
274
|
-
let urlPath = `/admin-api/carts/{cart}/coupons/detach`;
|
|
269
|
+
let urlPath = `/admin-api/carts/{cart}/coupons/{coupon}/detach`;
|
|
275
270
|
urlPath = urlPath.replace(`{${"cart"}}`, encodeURIComponent(String(requestParameters['cart'])));
|
|
271
|
+
urlPath = urlPath.replace(`{${"coupon"}}`, encodeURIComponent(String(requestParameters['coupon'])));
|
|
276
272
|
|
|
277
273
|
return {
|
|
278
274
|
path: urlPath,
|
|
279
275
|
method: 'DELETE',
|
|
280
276
|
headers: headerParameters,
|
|
281
277
|
query: queryParameters,
|
|
282
|
-
body: DetachCouponCartRequestToJSON(requestParameters['detachCouponCartRequest']),
|
|
283
278
|
};
|
|
284
279
|
}
|
|
285
280
|
|
|
286
281
|
/**
|
|
287
282
|
* Auto-generated: detachCouponCart
|
|
288
283
|
*/
|
|
289
|
-
async detachCouponCartRaw(requestParameters:
|
|
284
|
+
async detachCouponCartRaw(requestParameters: DetachCouponCartRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CartResource>> {
|
|
290
285
|
const requestOptions = await this.detachCouponCartRequestOpts(requestParameters);
|
|
291
286
|
const response = await this.request(requestOptions, initOverrides);
|
|
292
287
|
|
|
@@ -296,7 +291,7 @@ export class CartsApi extends runtime.BaseAPI {
|
|
|
296
291
|
/**
|
|
297
292
|
* Auto-generated: detachCouponCart
|
|
298
293
|
*/
|
|
299
|
-
async detachCouponCart(requestParameters:
|
|
294
|
+
async detachCouponCart(requestParameters: DetachCouponCartRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CartResource> {
|
|
300
295
|
const response = await this.detachCouponCartRaw(requestParameters, initOverrides);
|
|
301
296
|
return await response.value();
|
|
302
297
|
}
|
|
@@ -524,51 +519,6 @@ export class CartsApi extends runtime.BaseAPI {
|
|
|
524
519
|
return await response.value();
|
|
525
520
|
}
|
|
526
521
|
|
|
527
|
-
/**
|
|
528
|
-
* Creates request options for storeFromCartOrder without sending the request
|
|
529
|
-
*/
|
|
530
|
-
async storeFromCartOrderRequestOpts(requestParameters: StoreFromCartOrderRequest): Promise<runtime.RequestOpts> {
|
|
531
|
-
if (requestParameters['cart'] == null) {
|
|
532
|
-
throw new runtime.RequiredError(
|
|
533
|
-
'cart',
|
|
534
|
-
'Required parameter "cart" was null or undefined when calling storeFromCartOrder().'
|
|
535
|
-
);
|
|
536
|
-
}
|
|
537
|
-
|
|
538
|
-
const queryParameters: any = {};
|
|
539
|
-
|
|
540
|
-
const headerParameters: runtime.HTTPHeaders = {};
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
let urlPath = `/admin-api/carts/{cart}/place-order`;
|
|
544
|
-
urlPath = urlPath.replace(`{${"cart"}}`, encodeURIComponent(String(requestParameters['cart'])));
|
|
545
|
-
|
|
546
|
-
return {
|
|
547
|
-
path: urlPath,
|
|
548
|
-
method: 'POST',
|
|
549
|
-
headers: headerParameters,
|
|
550
|
-
query: queryParameters,
|
|
551
|
-
};
|
|
552
|
-
}
|
|
553
|
-
|
|
554
|
-
/**
|
|
555
|
-
* Auto-generated: storeFromCartOrder
|
|
556
|
-
*/
|
|
557
|
-
async storeFromCartOrderRaw(requestParameters: StoreFromCartOrderRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AdminOrderResource>> {
|
|
558
|
-
const requestOptions = await this.storeFromCartOrderRequestOpts(requestParameters);
|
|
559
|
-
const response = await this.request(requestOptions, initOverrides);
|
|
560
|
-
|
|
561
|
-
return new runtime.JSONApiResponse(response, (jsonValue) => AdminOrderResourceFromJSON(jsonValue));
|
|
562
|
-
}
|
|
563
|
-
|
|
564
|
-
/**
|
|
565
|
-
* Auto-generated: storeFromCartOrder
|
|
566
|
-
*/
|
|
567
|
-
async storeFromCartOrder(requestParameters: StoreFromCartOrderRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AdminOrderResource> {
|
|
568
|
-
const response = await this.storeFromCartOrderRaw(requestParameters, initOverrides);
|
|
569
|
-
return await response.value();
|
|
570
|
-
}
|
|
571
|
-
|
|
572
522
|
/**
|
|
573
523
|
* Creates request options for updateCart without sending the request
|
|
574
524
|
*/
|
package/src/apis/index.ts
CHANGED
|
@@ -12,7 +12,6 @@ export * from './GoogleCategoryApi';
|
|
|
12
12
|
export * from './LabelApi';
|
|
13
13
|
export * from './MenuApi';
|
|
14
14
|
export * from './MenuItemsApi';
|
|
15
|
-
export * from './OrdersApi';
|
|
16
15
|
export * from './OverlayTemplateApi';
|
|
17
16
|
export * from './ProductApi';
|
|
18
17
|
export * from './ProductCategoryApi';
|
|
@@ -24,7 +24,7 @@ export interface AddressFrontendResource {
|
|
|
24
24
|
* @type {string}
|
|
25
25
|
* @memberof AddressFrontendResource
|
|
26
26
|
*/
|
|
27
|
-
company
|
|
27
|
+
company?: string | null;
|
|
28
28
|
/**
|
|
29
29
|
*
|
|
30
30
|
* @type {string}
|
|
@@ -73,7 +73,6 @@ export interface AddressFrontendResource {
|
|
|
73
73
|
* Check if a given object implements the AddressFrontendResource interface.
|
|
74
74
|
*/
|
|
75
75
|
export function instanceOfAddressFrontendResource(value: object): value is AddressFrontendResource {
|
|
76
|
-
if (!('company' in value) || value['company'] === undefined) return false;
|
|
77
76
|
if (!('line1' in value) || value['line1'] === undefined) return false;
|
|
78
77
|
if (!('postcode' in value) || value['postcode'] === undefined) return false;
|
|
79
78
|
if (!('suburb' in value) || value['suburb'] === undefined) return false;
|
|
@@ -93,7 +92,7 @@ export function AddressFrontendResourceFromJSONTyped(json: any, ignoreDiscrimina
|
|
|
93
92
|
}
|
|
94
93
|
return {
|
|
95
94
|
|
|
96
|
-
'company': json['company'],
|
|
95
|
+
'company': json['company'] == null ? undefined : json['company'],
|
|
97
96
|
'line1': json['line1'],
|
|
98
97
|
'line2': json['line2'] == null ? undefined : json['line2'],
|
|
99
98
|
'postcode': json['postcode'],
|
|
@@ -36,13 +36,13 @@ export interface AddressResource {
|
|
|
36
36
|
* @type {string}
|
|
37
37
|
* @memberof AddressResource
|
|
38
38
|
*/
|
|
39
|
-
|
|
39
|
+
addresseeName: string;
|
|
40
40
|
/**
|
|
41
41
|
*
|
|
42
42
|
* @type {string}
|
|
43
43
|
* @memberof AddressResource
|
|
44
44
|
*/
|
|
45
|
-
|
|
45
|
+
company: string;
|
|
46
46
|
/**
|
|
47
47
|
*
|
|
48
48
|
* @type {string}
|
|
@@ -54,7 +54,7 @@ export interface AddressResource {
|
|
|
54
54
|
* @type {string}
|
|
55
55
|
* @memberof AddressResource
|
|
56
56
|
*/
|
|
57
|
-
line2
|
|
57
|
+
line2?: string | null;
|
|
58
58
|
/**
|
|
59
59
|
*
|
|
60
60
|
* @type {string}
|
|
@@ -91,9 +91,9 @@ export interface AddressResource {
|
|
|
91
91
|
* Check if a given object implements the AddressResource interface.
|
|
92
92
|
*/
|
|
93
93
|
export function instanceOfAddressResource(value: object): value is AddressResource {
|
|
94
|
-
if (!('
|
|
94
|
+
if (!('addresseeName' in value) || value['addresseeName'] === undefined) return false;
|
|
95
|
+
if (!('company' in value) || value['company'] === undefined) return false;
|
|
95
96
|
if (!('line1' in value) || value['line1'] === undefined) return false;
|
|
96
|
-
if (!('line2' in value) || value['line2'] === undefined) return false;
|
|
97
97
|
if (!('postcode' in value) || value['postcode'] === undefined) return false;
|
|
98
98
|
if (!('suburb' in value) || value['suburb'] === undefined) return false;
|
|
99
99
|
if (!('country' in value) || value['country'] === undefined) return false;
|
|
@@ -114,10 +114,10 @@ export function AddressResourceFromJSONTyped(json: any, ignoreDiscriminator: boo
|
|
|
114
114
|
|
|
115
115
|
'id': json['id'] == null ? undefined : json['id'],
|
|
116
116
|
'sourceAddressId': json['source_address_id'] == null ? undefined : json['source_address_id'],
|
|
117
|
-
'
|
|
118
|
-
'
|
|
117
|
+
'addresseeName': json['addressee_name'],
|
|
118
|
+
'company': json['company'],
|
|
119
119
|
'line1': json['line_1'],
|
|
120
|
-
'line2': json['line_2'],
|
|
120
|
+
'line2': json['line_2'] == null ? undefined : json['line_2'],
|
|
121
121
|
'postcode': json['postcode'],
|
|
122
122
|
'suburb': json['suburb'],
|
|
123
123
|
'country': json['country'],
|
|
@@ -139,8 +139,8 @@ export function AddressResourceToJSONTyped(value?: AddressResource | null, ignor
|
|
|
139
139
|
|
|
140
140
|
'id': value['id'],
|
|
141
141
|
'source_address_id': value['sourceAddressId'],
|
|
142
|
+
'addressee_name': value['addresseeName'],
|
|
142
143
|
'company': value['company'],
|
|
143
|
-
'addressee': value['addressee'],
|
|
144
144
|
'line_1': value['line1'],
|
|
145
145
|
'line_2': value['line2'],
|
|
146
146
|
'postcode': value['postcode'],
|