@compassdigital/sdk.typescript 4.431.0 → 4.433.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@compassdigital/sdk.typescript",
3
- "version": "4.431.0",
3
+ "version": "4.433.0",
4
4
  "description": "Compass Digital Labs TypeScript SDK",
5
5
  "type": "commonjs",
6
6
  "main": "./lib/index.js",
@@ -99,6 +99,55 @@ export interface DiscountChannelConfig {
99
99
  agilysys: boolean;
100
100
  }
101
101
 
102
+ export interface Item {
103
+ id: string;
104
+ name: string;
105
+ }
106
+
107
+ export interface Category {
108
+ id: string;
109
+ name: string;
110
+ items: Item[];
111
+ }
112
+
113
+ export interface Menu {
114
+ id: string;
115
+ name: string;
116
+ categories: Category[];
117
+ }
118
+
119
+ export interface Station {
120
+ id: string;
121
+ name: string;
122
+ menus?: Menu[];
123
+ }
124
+
125
+ export interface Site {
126
+ id: string;
127
+ name: string;
128
+ stations: Station[];
129
+ }
130
+
131
+ export interface MenuBrand {
132
+ id: string;
133
+ name: string;
134
+ menus: Menu[];
135
+ }
136
+
137
+ export interface ItemLevelConfigDetails {
138
+ bundleGroupName?: string;
139
+ minimum: number;
140
+ sites?: Site[];
141
+ menuBrands?: MenuBrand[];
142
+ }
143
+
144
+ export interface ItemLevelConfig {
145
+ globalMenuGroupId?: string;
146
+ globalMenuGroupName?: string;
147
+ sectorName?: string;
148
+ details: ItemLevelConfigDetails[];
149
+ }
150
+
102
151
  export interface DiscountWithEntities {
103
152
  // discount id
104
153
  id: string;
@@ -108,6 +157,8 @@ export interface DiscountWithEntities {
108
157
  updatedBy: string;
109
158
  // What the discount applies to
110
159
  appliesTo: 'order' | 'items';
160
+ // What the discount type is
161
+ type: 'Total Order' | 'Single Items' | 'Bundle';
111
162
  sites?: string[];
112
163
  brands?: string[];
113
164
  createdAt: string;
@@ -118,6 +169,9 @@ export interface DiscountWithEntities {
118
169
  meta?: DiscountMeta;
119
170
  schedule?: DiscountSchedule;
120
171
  channelConfig: DiscountChannelConfig;
172
+ itemLevelConfig?: ItemLevelConfig;
173
+ siteCount: number;
174
+ brandCount: number;
121
175
  }
122
176
 
123
177
  export interface GetAllDiscountsResponseDTO {
@@ -133,6 +187,8 @@ export interface GetDiscountResponseDTO {
133
187
  updatedBy: string;
134
188
  // What the discount applies to
135
189
  appliesTo: 'order' | 'items';
190
+ // What the discount type is
191
+ type: 'Total Order' | 'Single Items' | 'Bundle';
136
192
  sites?: string[];
137
193
  brands?: string[];
138
194
  createdAt: string;
@@ -143,6 +199,9 @@ export interface GetDiscountResponseDTO {
143
199
  meta?: DiscountMeta;
144
200
  schedule?: DiscountSchedule;
145
201
  channelConfig: DiscountChannelConfig;
202
+ itemLevelConfig?: ItemLevelConfig;
203
+ siteCount: number;
204
+ brandCount: number;
146
205
  }
147
206
 
148
207
  export interface DiscountDTO {
@@ -154,6 +213,8 @@ export interface DiscountDTO {
154
213
  updatedBy: string;
155
214
  // What the discount applies to
156
215
  appliesTo: 'order' | 'items';
216
+ // What the discount type is
217
+ type: 'Total Order' | 'Single Items' | 'Bundle';
157
218
  createdAt: string;
158
219
  updatedAt: string;
159
220
  name: string;
@@ -162,6 +223,9 @@ export interface DiscountDTO {
162
223
  meta?: DiscountMeta;
163
224
  schedule?: DiscountSchedule;
164
225
  channelConfig: DiscountChannelConfig;
226
+ itemLevelConfig?: ItemLevelConfig;
227
+ siteCount: number;
228
+ brandCount: number;
165
229
  }
166
230
 
167
231
  export interface GetDiscountsResponseDTO {
@@ -171,6 +235,8 @@ export interface GetDiscountsResponseDTO {
171
235
  export interface PatchDiscountRequestDTO {
172
236
  // What the discount applies to
173
237
  appliesTo?: 'order' | 'items';
238
+ // What the discount type is
239
+ type?: 'Total Order' | 'Single Items' | 'Bundle';
174
240
  updatedBy: string;
175
241
  status?: DiscountStatus;
176
242
  name?: string;
@@ -178,6 +244,9 @@ export interface PatchDiscountRequestDTO {
178
244
  meta?: DiscountMeta;
179
245
  schedule?: DiscountSchedule;
180
246
  channelConfig?: DiscountChannelConfig;
247
+ itemLevelConfig?: ItemLevelConfig;
248
+ siteCount?: number;
249
+ brandCount?: number;
181
250
  }
182
251
 
183
252
  export interface PatchDiscountResponseDTO {
@@ -189,6 +258,8 @@ export interface PatchDiscountResponseDTO {
189
258
  updatedBy: string;
190
259
  // What the discount applies to
191
260
  appliesTo: 'order' | 'items';
261
+ // What the discount type is
262
+ type: 'Total Order' | 'Single Items' | 'Bundle';
192
263
  createdAt: string;
193
264
  updatedAt: string;
194
265
  name: string;
@@ -197,6 +268,9 @@ export interface PatchDiscountResponseDTO {
197
268
  meta?: DiscountMeta;
198
269
  schedule?: DiscountSchedule;
199
270
  channelConfig: DiscountChannelConfig;
271
+ itemLevelConfig?: ItemLevelConfig;
272
+ siteCount: number;
273
+ brandCount: number;
200
274
  }
201
275
 
202
276
  export interface DiscountTaxonomy {
@@ -207,12 +281,17 @@ export interface DiscountTaxonomy {
207
281
  export interface PostDiscountRequestDTO {
208
282
  // What the discount applies to
209
283
  appliesTo: 'order' | 'items';
284
+ // What the discount type is
285
+ type: 'Total Order' | 'Single Items' | 'Bundle';
210
286
  createdBy: string;
211
287
  name: string;
212
288
  is?: DiscountIs;
213
289
  meta?: DiscountMeta;
214
290
  schedule?: DiscountSchedule;
215
291
  channelConfig: DiscountChannelConfig;
292
+ itemLevelConfig?: ItemLevelConfig;
293
+ siteCount: number;
294
+ brandCount: number;
216
295
  taxonomy?: DiscountTaxonomy;
217
296
  status?: DiscountStatus;
218
297
  }
@@ -226,6 +305,8 @@ export interface PostDiscountResponseDTO {
226
305
  updatedBy: string;
227
306
  // What the discount applies to
228
307
  appliesTo: 'order' | 'items';
308
+ // What the discount type is
309
+ type: 'Total Order' | 'Single Items' | 'Bundle';
229
310
  createdAt: string;
230
311
  updatedAt: string;
231
312
  name: string;
@@ -234,6 +315,9 @@ export interface PostDiscountResponseDTO {
234
315
  meta?: DiscountMeta;
235
316
  schedule?: DiscountSchedule;
236
317
  channelConfig: DiscountChannelConfig;
318
+ itemLevelConfig?: ItemLevelConfig;
319
+ siteCount: number;
320
+ brandCount: number;
237
321
  }
238
322
 
239
323
  export interface PostDiscountEventRequestDTO {
@@ -342,6 +426,8 @@ export interface PostRewardsResponseDTO {
342
426
  export interface PutDiscountRequestDTO {
343
427
  // What the discount applies to
344
428
  appliesTo: 'order' | 'items';
429
+ // What the discount type is
430
+ type: 'Total Order' | 'Single Items' | 'Bundle';
345
431
  updatedBy: string;
346
432
  taxonomy?: DiscountTaxonomy;
347
433
  status?: DiscountStatus;
@@ -350,6 +436,9 @@ export interface PutDiscountRequestDTO {
350
436
  meta?: DiscountMeta;
351
437
  schedule?: DiscountSchedule;
352
438
  channelConfig: DiscountChannelConfig;
439
+ itemLevelConfig?: ItemLevelConfig;
440
+ siteCount: number;
441
+ brandCount: number;
353
442
  }
354
443
 
355
444
  export interface PutDiscountResponseDTO {
@@ -361,6 +450,8 @@ export interface PutDiscountResponseDTO {
361
450
  updatedBy: string;
362
451
  // What the discount applies to
363
452
  appliesTo: 'order' | 'items';
453
+ // What the discount type is
454
+ type: 'Total Order' | 'Single Items' | 'Bundle';
364
455
  createdAt: string;
365
456
  updatedAt: string;
366
457
  name: string;
@@ -369,6 +460,9 @@ export interface PutDiscountResponseDTO {
369
460
  meta?: DiscountMeta;
370
461
  schedule?: DiscountSchedule;
371
462
  channelConfig: DiscountChannelConfig;
463
+ itemLevelConfig?: ItemLevelConfig;
464
+ siteCount: number;
465
+ brandCount: number;
372
466
  }
373
467
 
374
468
  export interface PutDiscountPublishRequestDTO {
@@ -383,6 +477,8 @@ export interface PutDiscountPublishResponseDTO {
383
477
  createdBy: string;
384
478
  // user id of most recent update
385
479
  updatedBy: string;
480
+ // What the discount type is
481
+ type: 'Total Order' | 'Single Items' | 'Bundle';
386
482
  // What the discount applies to
387
483
  appliesTo: 'order' | 'items';
388
484
  is: DiscountIs;
@@ -393,6 +489,9 @@ export interface PutDiscountPublishResponseDTO {
393
489
  updatedAt: string;
394
490
  name: string;
395
491
  status: DiscountStatus;
492
+ itemLevelConfig?: ItemLevelConfig;
493
+ siteCount: number;
494
+ brandCount: number;
396
495
  }
397
496
 
398
497
  // DELETE /discount/{id} - Delete a discount
@@ -1065,6 +1065,9 @@ export interface NutritionDTO {
1065
1065
  protein?: Record<string, any>;
1066
1066
  dietary_fiber?: Record<string, any>;
1067
1067
  sodium?: Record<string, any>;
1068
+ trans_fat?: Record<string, any>;
1069
+ cholesterol?: Record<string, any>;
1070
+ added_sugars?: Record<string, any>;
1068
1071
  [index: string]: any;
1069
1072
  }
1070
1073