@teemill/inserts 0.2.1 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +55 -2
- package/api.ts +257 -1
- package/base.ts +1 -1
- package/common.ts +1 -1
- package/configuration.ts +1 -1
- package/dist/api.d.ts +247 -1
- package/dist/api.js +17 -2
- package/dist/base.d.ts +1 -1
- package/dist/base.js +1 -1
- package/dist/common.d.ts +1 -1
- package/dist/common.js +1 -1
- package/dist/configuration.d.ts +1 -1
- package/dist/configuration.js +1 -1
- package/dist/esm/api.d.ts +247 -1
- package/dist/esm/api.js +16 -1
- package/dist/esm/base.d.ts +1 -1
- package/dist/esm/base.js +1 -1
- package/dist/esm/common.d.ts +1 -1
- package/dist/esm/common.js +1 -1
- package/dist/esm/configuration.d.ts +1 -1
- package/dist/esm/configuration.js +1 -1
- package/dist/esm/index.d.ts +1 -1
- package/dist/esm/index.js +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/docs/ApiError.md +22 -0
- package/docs/CreateInsertRequest.md +26 -0
- package/docs/CreateInsertRequestConfig.md +20 -0
- package/docs/CreateInsertRequestConfigCoupon.md +34 -0
- package/docs/Insert.md +32 -0
- package/docs/InsertConfig.md +21 -0
- package/docs/InsertConfigCoupon.md +34 -0
- package/docs/InsertType.md +26 -0
- package/docs/InsertsApi.md +256 -0
- package/docs/InsertsTypesApi.md +132 -0
- package/docs/ListInsertTypes200Response.md +22 -0
- package/docs/ListInserts200Response.md +22 -0
- package/docs/UpdateInsertRequest.md +26 -0
- package/docs/UpdateInsertRequestConfig.md +20 -0
- package/docs/UpdateInsertRequestConfigCoupon.md +34 -0
- package/docs/Value.md +19 -0
- package/index.ts +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
## @teemill/inserts@0.
|
|
1
|
+
## @teemill/inserts@0.4.0
|
|
2
2
|
|
|
3
3
|
This generator creates TypeScript/JavaScript client that utilizes [axios](https://github.com/axios/axios). The generated Node module can be used in the following environments:
|
|
4
4
|
|
|
@@ -36,7 +36,7 @@ navigate to the folder of your consuming project and run one of the following co
|
|
|
36
36
|
_published:_
|
|
37
37
|
|
|
38
38
|
```
|
|
39
|
-
npm install @teemill/inserts@0.
|
|
39
|
+
npm install @teemill/inserts@0.4.0 --save
|
|
40
40
|
```
|
|
41
41
|
|
|
42
42
|
_unPublished (not recommended):_
|
|
@@ -44,3 +44,56 @@ _unPublished (not recommended):_
|
|
|
44
44
|
```
|
|
45
45
|
npm install PATH_TO_GENERATED_PACKAGE --save
|
|
46
46
|
```
|
|
47
|
+
|
|
48
|
+
### Documentation for API Endpoints
|
|
49
|
+
|
|
50
|
+
All URIs are relative to *https://api.localhost:8080*
|
|
51
|
+
|
|
52
|
+
Class | Method | HTTP request | Description
|
|
53
|
+
------------ | ------------- | ------------- | -------------
|
|
54
|
+
*InsertsApi* | [**createInsert**](docs/InsertsApi.md#createinsert) | **POST** /v1/inserts | Create an insert
|
|
55
|
+
*InsertsApi* | [**getInsert**](docs/InsertsApi.md#getinsert) | **GET** /v1/inserts/{insertId} | Retrieve an insert for a project
|
|
56
|
+
*InsertsApi* | [**listInserts**](docs/InsertsApi.md#listinserts) | **GET** /v1/inserts | List project inserts
|
|
57
|
+
*InsertsApi* | [**updateInsert**](docs/InsertsApi.md#updateinsert) | **PATCH** /v1/inserts/{insertId} | Update an insert
|
|
58
|
+
*InsertsTypesApi* | [**getInsertType**](docs/InsertsTypesApi.md#getinserttype) | **GET** /v1/inserts/types/{insertTypeId} | Retrieve an insert type
|
|
59
|
+
*InsertsTypesApi* | [**listInsertTypes**](docs/InsertsTypesApi.md#listinserttypes) | **GET** /v1/inserts/types | List insert types
|
|
60
|
+
|
|
61
|
+
|
|
62
|
+
### Documentation For Models
|
|
63
|
+
|
|
64
|
+
- [ApiError](docs/ApiError.md)
|
|
65
|
+
- [CreateInsertRequest](docs/CreateInsertRequest.md)
|
|
66
|
+
- [CreateInsertRequestConfig](docs/CreateInsertRequestConfig.md)
|
|
67
|
+
- [CreateInsertRequestConfigCoupon](docs/CreateInsertRequestConfigCoupon.md)
|
|
68
|
+
- [Insert](docs/Insert.md)
|
|
69
|
+
- [InsertConfig](docs/InsertConfig.md)
|
|
70
|
+
- [InsertConfigCoupon](docs/InsertConfigCoupon.md)
|
|
71
|
+
- [InsertType](docs/InsertType.md)
|
|
72
|
+
- [ListInsertTypes200Response](docs/ListInsertTypes200Response.md)
|
|
73
|
+
- [ListInserts200Response](docs/ListInserts200Response.md)
|
|
74
|
+
- [UpdateInsertRequest](docs/UpdateInsertRequest.md)
|
|
75
|
+
- [UpdateInsertRequestConfig](docs/UpdateInsertRequestConfig.md)
|
|
76
|
+
- [UpdateInsertRequestConfigCoupon](docs/UpdateInsertRequestConfigCoupon.md)
|
|
77
|
+
- [Value](docs/Value.md)
|
|
78
|
+
|
|
79
|
+
|
|
80
|
+
<a id="documentation-for-authorization"></a>
|
|
81
|
+
## Documentation For Authorization
|
|
82
|
+
|
|
83
|
+
|
|
84
|
+
Authentication schemes defined for the API:
|
|
85
|
+
<a id="api-key"></a>
|
|
86
|
+
### api-key
|
|
87
|
+
|
|
88
|
+
- **Type**: API key
|
|
89
|
+
- **API key parameter name**: Authorization
|
|
90
|
+
- **Location**: HTTP header
|
|
91
|
+
|
|
92
|
+
<a id="session-oauth"></a>
|
|
93
|
+
### session-oauth
|
|
94
|
+
|
|
95
|
+
- **Type**: OAuth
|
|
96
|
+
- **Flow**: password
|
|
97
|
+
- **Authorization URL**:
|
|
98
|
+
- **Scopes**: N/A
|
|
99
|
+
|
package/api.ts
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Inserts API
|
|
5
5
|
* An API for managing order inserts in PodOS that automatically adds a free item to a customer\'s order when specific conditions are met, such as a first-time purchase.
|
|
6
6
|
*
|
|
7
|
-
* The version of the OpenAPI document: 0.
|
|
7
|
+
* The version of the OpenAPI document: 0.4.0
|
|
8
8
|
*
|
|
9
9
|
*
|
|
10
10
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -66,7 +66,90 @@ export interface CreateInsertRequest {
|
|
|
66
66
|
* @memberof CreateInsertRequest
|
|
67
67
|
*/
|
|
68
68
|
'typeRef': string;
|
|
69
|
+
/**
|
|
70
|
+
*
|
|
71
|
+
* @type {CreateInsertRequestConfig}
|
|
72
|
+
* @memberof CreateInsertRequest
|
|
73
|
+
*/
|
|
74
|
+
'config'?: CreateInsertRequestConfig;
|
|
75
|
+
}
|
|
76
|
+
/**
|
|
77
|
+
*
|
|
78
|
+
* @export
|
|
79
|
+
* @interface CreateInsertRequestConfig
|
|
80
|
+
*/
|
|
81
|
+
export interface CreateInsertRequestConfig {
|
|
82
|
+
/**
|
|
83
|
+
*
|
|
84
|
+
* @type {CreateInsertRequestConfigCoupon}
|
|
85
|
+
* @memberof CreateInsertRequestConfig
|
|
86
|
+
*/
|
|
87
|
+
'coupon'?: CreateInsertRequestConfigCoupon;
|
|
88
|
+
}
|
|
89
|
+
/**
|
|
90
|
+
*
|
|
91
|
+
* @export
|
|
92
|
+
* @interface CreateInsertRequestConfigCoupon
|
|
93
|
+
*/
|
|
94
|
+
export interface CreateInsertRequestConfigCoupon {
|
|
95
|
+
/**
|
|
96
|
+
* The prefix of the coupon code to apply to the insert
|
|
97
|
+
* @type {string}
|
|
98
|
+
* @memberof CreateInsertRequestConfigCoupon
|
|
99
|
+
*/
|
|
100
|
+
'prefix': string;
|
|
101
|
+
/**
|
|
102
|
+
* The type of coupon to apply to the insert
|
|
103
|
+
* @type {string}
|
|
104
|
+
* @memberof CreateInsertRequestConfigCoupon
|
|
105
|
+
*/
|
|
106
|
+
'type': CreateInsertRequestConfigCouponTypeEnum;
|
|
107
|
+
/**
|
|
108
|
+
* The number of hours after creation which the coupon will expire
|
|
109
|
+
* @type {number}
|
|
110
|
+
* @memberof CreateInsertRequestConfigCoupon
|
|
111
|
+
*/
|
|
112
|
+
'expiryHours': number;
|
|
113
|
+
/**
|
|
114
|
+
* The number of times the coupon can be used
|
|
115
|
+
* @type {number}
|
|
116
|
+
* @memberof CreateInsertRequestConfigCoupon
|
|
117
|
+
*/
|
|
118
|
+
'numberOfUses': number;
|
|
119
|
+
/**
|
|
120
|
+
*
|
|
121
|
+
* @type {Value}
|
|
122
|
+
* @memberof CreateInsertRequestConfigCoupon
|
|
123
|
+
*/
|
|
124
|
+
'value': Value;
|
|
125
|
+
/**
|
|
126
|
+
* The minimum order value to apply the coupon to
|
|
127
|
+
* @type {number}
|
|
128
|
+
* @memberof CreateInsertRequestConfigCoupon
|
|
129
|
+
*/
|
|
130
|
+
'minimumOrderValue': number;
|
|
131
|
+
/**
|
|
132
|
+
* A list of delivery methods that will be used for the discount. **Note:** Adding delivery methods requires the delivery integration to be installed on your project.
|
|
133
|
+
* @type {Array<string>}
|
|
134
|
+
* @memberof CreateInsertRequestConfigCoupon
|
|
135
|
+
*/
|
|
136
|
+
'freeDeliveryMethods'?: Array<string>;
|
|
137
|
+
/**
|
|
138
|
+
* The description of the coupon to apply to the insert
|
|
139
|
+
* @type {string}
|
|
140
|
+
* @memberof CreateInsertRequestConfigCoupon
|
|
141
|
+
*/
|
|
142
|
+
'description': string;
|
|
69
143
|
}
|
|
144
|
+
|
|
145
|
+
export const CreateInsertRequestConfigCouponTypeEnum = {
|
|
146
|
+
Percentage: 'percentage',
|
|
147
|
+
Fixed: 'fixed',
|
|
148
|
+
Item: 'item'
|
|
149
|
+
} as const;
|
|
150
|
+
|
|
151
|
+
export type CreateInsertRequestConfigCouponTypeEnum = typeof CreateInsertRequestConfigCouponTypeEnum[keyof typeof CreateInsertRequestConfigCouponTypeEnum];
|
|
152
|
+
|
|
70
153
|
/**
|
|
71
154
|
*
|
|
72
155
|
* @export
|
|
@@ -97,6 +180,12 @@ export interface Insert {
|
|
|
97
180
|
* @memberof Insert
|
|
98
181
|
*/
|
|
99
182
|
'typeRef': string;
|
|
183
|
+
/**
|
|
184
|
+
*
|
|
185
|
+
* @type {InsertConfig}
|
|
186
|
+
* @memberof Insert
|
|
187
|
+
*/
|
|
188
|
+
'config': InsertConfig | null;
|
|
100
189
|
/**
|
|
101
190
|
* ISO 8601 Timestamp
|
|
102
191
|
* @type {string}
|
|
@@ -110,6 +199,83 @@ export interface Insert {
|
|
|
110
199
|
*/
|
|
111
200
|
'updatedAt': string | null;
|
|
112
201
|
}
|
|
202
|
+
/**
|
|
203
|
+
* The configuration of the insert
|
|
204
|
+
* @export
|
|
205
|
+
* @interface InsertConfig
|
|
206
|
+
*/
|
|
207
|
+
export interface InsertConfig {
|
|
208
|
+
/**
|
|
209
|
+
*
|
|
210
|
+
* @type {InsertConfigCoupon}
|
|
211
|
+
* @memberof InsertConfig
|
|
212
|
+
*/
|
|
213
|
+
'coupon'?: InsertConfigCoupon | null;
|
|
214
|
+
}
|
|
215
|
+
/**
|
|
216
|
+
*
|
|
217
|
+
* @export
|
|
218
|
+
* @interface InsertConfigCoupon
|
|
219
|
+
*/
|
|
220
|
+
export interface InsertConfigCoupon {
|
|
221
|
+
/**
|
|
222
|
+
* The prefix of the coupon code to apply to the insert
|
|
223
|
+
* @type {string}
|
|
224
|
+
* @memberof InsertConfigCoupon
|
|
225
|
+
*/
|
|
226
|
+
'prefix': string;
|
|
227
|
+
/**
|
|
228
|
+
* The type of coupon to apply to the insert
|
|
229
|
+
* @type {string}
|
|
230
|
+
* @memberof InsertConfigCoupon
|
|
231
|
+
*/
|
|
232
|
+
'type': InsertConfigCouponTypeEnum;
|
|
233
|
+
/**
|
|
234
|
+
* The number of hours after creation which the coupon will expire
|
|
235
|
+
* @type {number}
|
|
236
|
+
* @memberof InsertConfigCoupon
|
|
237
|
+
*/
|
|
238
|
+
'expiryHours': number;
|
|
239
|
+
/**
|
|
240
|
+
* The number of times the coupon can be used
|
|
241
|
+
* @type {number}
|
|
242
|
+
* @memberof InsertConfigCoupon
|
|
243
|
+
*/
|
|
244
|
+
'numberOfUses': number;
|
|
245
|
+
/**
|
|
246
|
+
* A list of delivery methods for the discount.
|
|
247
|
+
* @type {Array<string>}
|
|
248
|
+
* @memberof InsertConfigCoupon
|
|
249
|
+
*/
|
|
250
|
+
'freeDeliveryMethods'?: Array<string> | null;
|
|
251
|
+
/**
|
|
252
|
+
*
|
|
253
|
+
* @type {Value}
|
|
254
|
+
* @memberof InsertConfigCoupon
|
|
255
|
+
*/
|
|
256
|
+
'value': Value;
|
|
257
|
+
/**
|
|
258
|
+
* The minimum order value to apply the coupon to
|
|
259
|
+
* @type {number}
|
|
260
|
+
* @memberof InsertConfigCoupon
|
|
261
|
+
*/
|
|
262
|
+
'minimumOrderValue': number;
|
|
263
|
+
/**
|
|
264
|
+
*
|
|
265
|
+
* @type {string}
|
|
266
|
+
* @memberof InsertConfigCoupon
|
|
267
|
+
*/
|
|
268
|
+
'description': string;
|
|
269
|
+
}
|
|
270
|
+
|
|
271
|
+
export const InsertConfigCouponTypeEnum = {
|
|
272
|
+
Percentage: 'percentage',
|
|
273
|
+
Fixed: 'fixed',
|
|
274
|
+
Item: 'item'
|
|
275
|
+
} as const;
|
|
276
|
+
|
|
277
|
+
export type InsertConfigCouponTypeEnum = typeof InsertConfigCouponTypeEnum[keyof typeof InsertConfigCouponTypeEnum];
|
|
278
|
+
|
|
113
279
|
/**
|
|
114
280
|
*
|
|
115
281
|
* @export
|
|
@@ -203,8 +369,98 @@ export interface UpdateInsertRequest {
|
|
|
203
369
|
* @memberof UpdateInsertRequest
|
|
204
370
|
*/
|
|
205
371
|
'typeRef'?: string;
|
|
372
|
+
/**
|
|
373
|
+
*
|
|
374
|
+
* @type {UpdateInsertRequestConfig}
|
|
375
|
+
* @memberof UpdateInsertRequest
|
|
376
|
+
*/
|
|
377
|
+
'config'?: UpdateInsertRequestConfig | null;
|
|
378
|
+
}
|
|
379
|
+
/**
|
|
380
|
+
*
|
|
381
|
+
* @export
|
|
382
|
+
* @interface UpdateInsertRequestConfig
|
|
383
|
+
*/
|
|
384
|
+
export interface UpdateInsertRequestConfig {
|
|
385
|
+
/**
|
|
386
|
+
*
|
|
387
|
+
* @type {UpdateInsertRequestConfigCoupon}
|
|
388
|
+
* @memberof UpdateInsertRequestConfig
|
|
389
|
+
*/
|
|
390
|
+
'coupon'?: UpdateInsertRequestConfigCoupon;
|
|
391
|
+
}
|
|
392
|
+
/**
|
|
393
|
+
*
|
|
394
|
+
* @export
|
|
395
|
+
* @interface UpdateInsertRequestConfigCoupon
|
|
396
|
+
*/
|
|
397
|
+
export interface UpdateInsertRequestConfigCoupon {
|
|
398
|
+
/**
|
|
399
|
+
* The prefix of the coupon code to apply to the insert
|
|
400
|
+
* @type {string}
|
|
401
|
+
* @memberof UpdateInsertRequestConfigCoupon
|
|
402
|
+
*/
|
|
403
|
+
'prefix': string;
|
|
404
|
+
/**
|
|
405
|
+
* The number of times the coupon can be used
|
|
406
|
+
* @type {number}
|
|
407
|
+
* @memberof UpdateInsertRequestConfigCoupon
|
|
408
|
+
*/
|
|
409
|
+
'numberOfUses': number;
|
|
410
|
+
/**
|
|
411
|
+
* The number of hours after creation which the coupon will expire
|
|
412
|
+
* @type {number}
|
|
413
|
+
* @memberof UpdateInsertRequestConfigCoupon
|
|
414
|
+
*/
|
|
415
|
+
'expiryHours': number;
|
|
416
|
+
/**
|
|
417
|
+
* The type of coupon to apply to the insert
|
|
418
|
+
* @type {string}
|
|
419
|
+
* @memberof UpdateInsertRequestConfigCoupon
|
|
420
|
+
*/
|
|
421
|
+
'type': UpdateInsertRequestConfigCouponTypeEnum;
|
|
422
|
+
/**
|
|
423
|
+
*
|
|
424
|
+
* @type {Value}
|
|
425
|
+
* @memberof UpdateInsertRequestConfigCoupon
|
|
426
|
+
*/
|
|
427
|
+
'value': Value;
|
|
428
|
+
/**
|
|
429
|
+
* The minimum order value to apply the coupon to
|
|
430
|
+
* @type {number}
|
|
431
|
+
* @memberof UpdateInsertRequestConfigCoupon
|
|
432
|
+
*/
|
|
433
|
+
'minimumOrderValue': number;
|
|
434
|
+
/**
|
|
435
|
+
* A list of delivery methods that will be used for the discount. **Note:** Adding delivery methods requires the delivery integration to be installed on your project.
|
|
436
|
+
* @type {Array<string>}
|
|
437
|
+
* @memberof UpdateInsertRequestConfigCoupon
|
|
438
|
+
*/
|
|
439
|
+
'freeDeliveryMethods'?: Array<string> | null;
|
|
440
|
+
/**
|
|
441
|
+
* The description of the coupon to apply to the insert
|
|
442
|
+
* @type {string}
|
|
443
|
+
* @memberof UpdateInsertRequestConfigCoupon
|
|
444
|
+
*/
|
|
445
|
+
'description': string;
|
|
206
446
|
}
|
|
207
447
|
|
|
448
|
+
export const UpdateInsertRequestConfigCouponTypeEnum = {
|
|
449
|
+
Percentage: 'percentage',
|
|
450
|
+
Fixed: 'fixed',
|
|
451
|
+
Item: 'item'
|
|
452
|
+
} as const;
|
|
453
|
+
|
|
454
|
+
export type UpdateInsertRequestConfigCouponTypeEnum = typeof UpdateInsertRequestConfigCouponTypeEnum[keyof typeof UpdateInsertRequestConfigCouponTypeEnum];
|
|
455
|
+
|
|
456
|
+
/**
|
|
457
|
+
* @type Value
|
|
458
|
+
* The value of the discount. For percentage discounts, this is the percentage (0-100). For fixed discounts, this is the fixed amount. For item discounts, this is the product reference.
|
|
459
|
+
* @export
|
|
460
|
+
*/
|
|
461
|
+
export type Value = number | string;
|
|
462
|
+
|
|
463
|
+
|
|
208
464
|
/**
|
|
209
465
|
* InsertsApi - axios parameter creator
|
|
210
466
|
* @export
|
package/base.ts
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Inserts API
|
|
5
5
|
* An API for managing order inserts in PodOS that automatically adds a free item to a customer\'s order when specific conditions are met, such as a first-time purchase.
|
|
6
6
|
*
|
|
7
|
-
* The version of the OpenAPI document: 0.
|
|
7
|
+
* The version of the OpenAPI document: 0.4.0
|
|
8
8
|
*
|
|
9
9
|
*
|
|
10
10
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
package/common.ts
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Inserts API
|
|
5
5
|
* An API for managing order inserts in PodOS that automatically adds a free item to a customer\'s order when specific conditions are met, such as a first-time purchase.
|
|
6
6
|
*
|
|
7
|
-
* The version of the OpenAPI document: 0.
|
|
7
|
+
* The version of the OpenAPI document: 0.4.0
|
|
8
8
|
*
|
|
9
9
|
*
|
|
10
10
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
package/configuration.ts
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Inserts API
|
|
5
5
|
* An API for managing order inserts in PodOS that automatically adds a free item to a customer\'s order when specific conditions are met, such as a first-time purchase.
|
|
6
6
|
*
|
|
7
|
-
* The version of the OpenAPI document: 0.
|
|
7
|
+
* The version of the OpenAPI document: 0.4.0
|
|
8
8
|
*
|
|
9
9
|
*
|
|
10
10
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
package/dist/api.d.ts
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Inserts API
|
|
3
3
|
* An API for managing order inserts in PodOS that automatically adds a free item to a customer\'s order when specific conditions are met, such as a first-time purchase.
|
|
4
4
|
*
|
|
5
|
-
* The version of the OpenAPI document: 0.
|
|
5
|
+
* The version of the OpenAPI document: 0.4.0
|
|
6
6
|
*
|
|
7
7
|
*
|
|
8
8
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -56,7 +56,87 @@ export interface CreateInsertRequest {
|
|
|
56
56
|
* @memberof CreateInsertRequest
|
|
57
57
|
*/
|
|
58
58
|
'typeRef': string;
|
|
59
|
+
/**
|
|
60
|
+
*
|
|
61
|
+
* @type {CreateInsertRequestConfig}
|
|
62
|
+
* @memberof CreateInsertRequest
|
|
63
|
+
*/
|
|
64
|
+
'config'?: CreateInsertRequestConfig;
|
|
59
65
|
}
|
|
66
|
+
/**
|
|
67
|
+
*
|
|
68
|
+
* @export
|
|
69
|
+
* @interface CreateInsertRequestConfig
|
|
70
|
+
*/
|
|
71
|
+
export interface CreateInsertRequestConfig {
|
|
72
|
+
/**
|
|
73
|
+
*
|
|
74
|
+
* @type {CreateInsertRequestConfigCoupon}
|
|
75
|
+
* @memberof CreateInsertRequestConfig
|
|
76
|
+
*/
|
|
77
|
+
'coupon'?: CreateInsertRequestConfigCoupon;
|
|
78
|
+
}
|
|
79
|
+
/**
|
|
80
|
+
*
|
|
81
|
+
* @export
|
|
82
|
+
* @interface CreateInsertRequestConfigCoupon
|
|
83
|
+
*/
|
|
84
|
+
export interface CreateInsertRequestConfigCoupon {
|
|
85
|
+
/**
|
|
86
|
+
* The prefix of the coupon code to apply to the insert
|
|
87
|
+
* @type {string}
|
|
88
|
+
* @memberof CreateInsertRequestConfigCoupon
|
|
89
|
+
*/
|
|
90
|
+
'prefix': string;
|
|
91
|
+
/**
|
|
92
|
+
* The type of coupon to apply to the insert
|
|
93
|
+
* @type {string}
|
|
94
|
+
* @memberof CreateInsertRequestConfigCoupon
|
|
95
|
+
*/
|
|
96
|
+
'type': CreateInsertRequestConfigCouponTypeEnum;
|
|
97
|
+
/**
|
|
98
|
+
* The number of hours after creation which the coupon will expire
|
|
99
|
+
* @type {number}
|
|
100
|
+
* @memberof CreateInsertRequestConfigCoupon
|
|
101
|
+
*/
|
|
102
|
+
'expiryHours': number;
|
|
103
|
+
/**
|
|
104
|
+
* The number of times the coupon can be used
|
|
105
|
+
* @type {number}
|
|
106
|
+
* @memberof CreateInsertRequestConfigCoupon
|
|
107
|
+
*/
|
|
108
|
+
'numberOfUses': number;
|
|
109
|
+
/**
|
|
110
|
+
*
|
|
111
|
+
* @type {Value}
|
|
112
|
+
* @memberof CreateInsertRequestConfigCoupon
|
|
113
|
+
*/
|
|
114
|
+
'value': Value;
|
|
115
|
+
/**
|
|
116
|
+
* The minimum order value to apply the coupon to
|
|
117
|
+
* @type {number}
|
|
118
|
+
* @memberof CreateInsertRequestConfigCoupon
|
|
119
|
+
*/
|
|
120
|
+
'minimumOrderValue': number;
|
|
121
|
+
/**
|
|
122
|
+
* A list of delivery methods that will be used for the discount. **Note:** Adding delivery methods requires the delivery integration to be installed on your project.
|
|
123
|
+
* @type {Array<string>}
|
|
124
|
+
* @memberof CreateInsertRequestConfigCoupon
|
|
125
|
+
*/
|
|
126
|
+
'freeDeliveryMethods'?: Array<string>;
|
|
127
|
+
/**
|
|
128
|
+
* The description of the coupon to apply to the insert
|
|
129
|
+
* @type {string}
|
|
130
|
+
* @memberof CreateInsertRequestConfigCoupon
|
|
131
|
+
*/
|
|
132
|
+
'description': string;
|
|
133
|
+
}
|
|
134
|
+
export declare const CreateInsertRequestConfigCouponTypeEnum: {
|
|
135
|
+
readonly Percentage: "percentage";
|
|
136
|
+
readonly Fixed: "fixed";
|
|
137
|
+
readonly Item: "item";
|
|
138
|
+
};
|
|
139
|
+
export type CreateInsertRequestConfigCouponTypeEnum = typeof CreateInsertRequestConfigCouponTypeEnum[keyof typeof CreateInsertRequestConfigCouponTypeEnum];
|
|
60
140
|
/**
|
|
61
141
|
*
|
|
62
142
|
* @export
|
|
@@ -87,6 +167,12 @@ export interface Insert {
|
|
|
87
167
|
* @memberof Insert
|
|
88
168
|
*/
|
|
89
169
|
'typeRef': string;
|
|
170
|
+
/**
|
|
171
|
+
*
|
|
172
|
+
* @type {InsertConfig}
|
|
173
|
+
* @memberof Insert
|
|
174
|
+
*/
|
|
175
|
+
'config': InsertConfig | null;
|
|
90
176
|
/**
|
|
91
177
|
* ISO 8601 Timestamp
|
|
92
178
|
* @type {string}
|
|
@@ -100,6 +186,80 @@ export interface Insert {
|
|
|
100
186
|
*/
|
|
101
187
|
'updatedAt': string | null;
|
|
102
188
|
}
|
|
189
|
+
/**
|
|
190
|
+
* The configuration of the insert
|
|
191
|
+
* @export
|
|
192
|
+
* @interface InsertConfig
|
|
193
|
+
*/
|
|
194
|
+
export interface InsertConfig {
|
|
195
|
+
/**
|
|
196
|
+
*
|
|
197
|
+
* @type {InsertConfigCoupon}
|
|
198
|
+
* @memberof InsertConfig
|
|
199
|
+
*/
|
|
200
|
+
'coupon'?: InsertConfigCoupon | null;
|
|
201
|
+
}
|
|
202
|
+
/**
|
|
203
|
+
*
|
|
204
|
+
* @export
|
|
205
|
+
* @interface InsertConfigCoupon
|
|
206
|
+
*/
|
|
207
|
+
export interface InsertConfigCoupon {
|
|
208
|
+
/**
|
|
209
|
+
* The prefix of the coupon code to apply to the insert
|
|
210
|
+
* @type {string}
|
|
211
|
+
* @memberof InsertConfigCoupon
|
|
212
|
+
*/
|
|
213
|
+
'prefix': string;
|
|
214
|
+
/**
|
|
215
|
+
* The type of coupon to apply to the insert
|
|
216
|
+
* @type {string}
|
|
217
|
+
* @memberof InsertConfigCoupon
|
|
218
|
+
*/
|
|
219
|
+
'type': InsertConfigCouponTypeEnum;
|
|
220
|
+
/**
|
|
221
|
+
* The number of hours after creation which the coupon will expire
|
|
222
|
+
* @type {number}
|
|
223
|
+
* @memberof InsertConfigCoupon
|
|
224
|
+
*/
|
|
225
|
+
'expiryHours': number;
|
|
226
|
+
/**
|
|
227
|
+
* The number of times the coupon can be used
|
|
228
|
+
* @type {number}
|
|
229
|
+
* @memberof InsertConfigCoupon
|
|
230
|
+
*/
|
|
231
|
+
'numberOfUses': number;
|
|
232
|
+
/**
|
|
233
|
+
* A list of delivery methods for the discount.
|
|
234
|
+
* @type {Array<string>}
|
|
235
|
+
* @memberof InsertConfigCoupon
|
|
236
|
+
*/
|
|
237
|
+
'freeDeliveryMethods'?: Array<string> | null;
|
|
238
|
+
/**
|
|
239
|
+
*
|
|
240
|
+
* @type {Value}
|
|
241
|
+
* @memberof InsertConfigCoupon
|
|
242
|
+
*/
|
|
243
|
+
'value': Value;
|
|
244
|
+
/**
|
|
245
|
+
* The minimum order value to apply the coupon to
|
|
246
|
+
* @type {number}
|
|
247
|
+
* @memberof InsertConfigCoupon
|
|
248
|
+
*/
|
|
249
|
+
'minimumOrderValue': number;
|
|
250
|
+
/**
|
|
251
|
+
*
|
|
252
|
+
* @type {string}
|
|
253
|
+
* @memberof InsertConfigCoupon
|
|
254
|
+
*/
|
|
255
|
+
'description': string;
|
|
256
|
+
}
|
|
257
|
+
export declare const InsertConfigCouponTypeEnum: {
|
|
258
|
+
readonly Percentage: "percentage";
|
|
259
|
+
readonly Fixed: "fixed";
|
|
260
|
+
readonly Item: "item";
|
|
261
|
+
};
|
|
262
|
+
export type InsertConfigCouponTypeEnum = typeof InsertConfigCouponTypeEnum[keyof typeof InsertConfigCouponTypeEnum];
|
|
103
263
|
/**
|
|
104
264
|
*
|
|
105
265
|
* @export
|
|
@@ -193,7 +353,93 @@ export interface UpdateInsertRequest {
|
|
|
193
353
|
* @memberof UpdateInsertRequest
|
|
194
354
|
*/
|
|
195
355
|
'typeRef'?: string;
|
|
356
|
+
/**
|
|
357
|
+
*
|
|
358
|
+
* @type {UpdateInsertRequestConfig}
|
|
359
|
+
* @memberof UpdateInsertRequest
|
|
360
|
+
*/
|
|
361
|
+
'config'?: UpdateInsertRequestConfig | null;
|
|
362
|
+
}
|
|
363
|
+
/**
|
|
364
|
+
*
|
|
365
|
+
* @export
|
|
366
|
+
* @interface UpdateInsertRequestConfig
|
|
367
|
+
*/
|
|
368
|
+
export interface UpdateInsertRequestConfig {
|
|
369
|
+
/**
|
|
370
|
+
*
|
|
371
|
+
* @type {UpdateInsertRequestConfigCoupon}
|
|
372
|
+
* @memberof UpdateInsertRequestConfig
|
|
373
|
+
*/
|
|
374
|
+
'coupon'?: UpdateInsertRequestConfigCoupon;
|
|
375
|
+
}
|
|
376
|
+
/**
|
|
377
|
+
*
|
|
378
|
+
* @export
|
|
379
|
+
* @interface UpdateInsertRequestConfigCoupon
|
|
380
|
+
*/
|
|
381
|
+
export interface UpdateInsertRequestConfigCoupon {
|
|
382
|
+
/**
|
|
383
|
+
* The prefix of the coupon code to apply to the insert
|
|
384
|
+
* @type {string}
|
|
385
|
+
* @memberof UpdateInsertRequestConfigCoupon
|
|
386
|
+
*/
|
|
387
|
+
'prefix': string;
|
|
388
|
+
/**
|
|
389
|
+
* The number of times the coupon can be used
|
|
390
|
+
* @type {number}
|
|
391
|
+
* @memberof UpdateInsertRequestConfigCoupon
|
|
392
|
+
*/
|
|
393
|
+
'numberOfUses': number;
|
|
394
|
+
/**
|
|
395
|
+
* The number of hours after creation which the coupon will expire
|
|
396
|
+
* @type {number}
|
|
397
|
+
* @memberof UpdateInsertRequestConfigCoupon
|
|
398
|
+
*/
|
|
399
|
+
'expiryHours': number;
|
|
400
|
+
/**
|
|
401
|
+
* The type of coupon to apply to the insert
|
|
402
|
+
* @type {string}
|
|
403
|
+
* @memberof UpdateInsertRequestConfigCoupon
|
|
404
|
+
*/
|
|
405
|
+
'type': UpdateInsertRequestConfigCouponTypeEnum;
|
|
406
|
+
/**
|
|
407
|
+
*
|
|
408
|
+
* @type {Value}
|
|
409
|
+
* @memberof UpdateInsertRequestConfigCoupon
|
|
410
|
+
*/
|
|
411
|
+
'value': Value;
|
|
412
|
+
/**
|
|
413
|
+
* The minimum order value to apply the coupon to
|
|
414
|
+
* @type {number}
|
|
415
|
+
* @memberof UpdateInsertRequestConfigCoupon
|
|
416
|
+
*/
|
|
417
|
+
'minimumOrderValue': number;
|
|
418
|
+
/**
|
|
419
|
+
* A list of delivery methods that will be used for the discount. **Note:** Adding delivery methods requires the delivery integration to be installed on your project.
|
|
420
|
+
* @type {Array<string>}
|
|
421
|
+
* @memberof UpdateInsertRequestConfigCoupon
|
|
422
|
+
*/
|
|
423
|
+
'freeDeliveryMethods'?: Array<string> | null;
|
|
424
|
+
/**
|
|
425
|
+
* The description of the coupon to apply to the insert
|
|
426
|
+
* @type {string}
|
|
427
|
+
* @memberof UpdateInsertRequestConfigCoupon
|
|
428
|
+
*/
|
|
429
|
+
'description': string;
|
|
196
430
|
}
|
|
431
|
+
export declare const UpdateInsertRequestConfigCouponTypeEnum: {
|
|
432
|
+
readonly Percentage: "percentage";
|
|
433
|
+
readonly Fixed: "fixed";
|
|
434
|
+
readonly Item: "item";
|
|
435
|
+
};
|
|
436
|
+
export type UpdateInsertRequestConfigCouponTypeEnum = typeof UpdateInsertRequestConfigCouponTypeEnum[keyof typeof UpdateInsertRequestConfigCouponTypeEnum];
|
|
437
|
+
/**
|
|
438
|
+
* @type Value
|
|
439
|
+
* The value of the discount. For percentage discounts, this is the percentage (0-100). For fixed discounts, this is the fixed amount. For item discounts, this is the product reference.
|
|
440
|
+
* @export
|
|
441
|
+
*/
|
|
442
|
+
export type Value = number | string;
|
|
197
443
|
/**
|
|
198
444
|
* InsertsApi - axios parameter creator
|
|
199
445
|
* @export
|