@compassdigital/sdk.typescript 4.50.0 → 4.52.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.
@@ -137,6 +137,7 @@ export interface Item {
137
137
  barcodes?: string[];
138
138
  tax?: {
139
139
  tax_tag_code?: string;
140
+ tax_jwo_code?: string;
140
141
  };
141
142
  [index: string]: any;
142
143
  };
@@ -257,7 +258,6 @@ export interface Option {
257
258
  sort_number?: number;
258
259
  // menu sort order
259
260
  menu_sort_number?: number;
260
- plu?: string;
261
261
  sizing?: {
262
262
  name?: string;
263
263
  posid?: string;
@@ -384,7 +384,7 @@ export interface DraftBrandDTO {
384
384
  global_menu_group_id?: string;
385
385
  posid_segment?: string;
386
386
  is_simplified_view?: boolean;
387
- frictionless_partner?: "AWS";
387
+ frictionless_partner?: string;
388
388
  applied_diff_snapshot?: Record<string, any>;
389
389
  permissions?: Record<string, any>;
390
390
  [index: string]: any;
@@ -401,7 +401,7 @@ export interface PublishedBrandDTO {
401
401
  global_menu_group_id?: string;
402
402
  posid_segment?: string;
403
403
  is_simplified_view?: boolean;
404
- frictionless_partner?: "AWS";
404
+ frictionless_partner?: string;
405
405
  permissions?: Record<string, any>;
406
406
  [index: string]: any;
407
407
  }
@@ -619,6 +619,7 @@ export interface DraftItemDTO {
619
619
  tax_tag_code?: string;
620
620
  tags?: string[];
621
621
  is_featured?: boolean;
622
+ tax_jwo_code?: string;
622
623
  applied_diff_snapshot?: Record<string, any>;
623
624
  brand?: DraftBrandDTO;
624
625
  categories?: Record<string, any>[];
@@ -855,6 +856,19 @@ export interface BrandStatusDTO {
855
856
  [index: string]: any;
856
857
  }
857
858
 
859
+ export interface AuditDTO {
860
+ process_id?: string;
861
+ brand_id?: string;
862
+ status_type?: string;
863
+ status?: string;
864
+ message?: string;
865
+ id?: string;
866
+ data?: Record<string, any>;
867
+ brand?: DraftBrandDTO;
868
+ permissions?: Record<string, any>;
869
+ [index: string]: any;
870
+ }
871
+
858
872
  export interface SiteGroupWithMenuGroupNameResponseDTO {
859
873
  site_id: string;
860
874
  local_menu_group_id: string;
@@ -872,6 +886,23 @@ export interface SiteGroupDTO {
872
886
  [index: string]: any;
873
887
  }
874
888
 
889
+ export interface AuditListDraftItemDTO {
890
+ process_id: string;
891
+ brand_id: string;
892
+ status_type: string;
893
+ status: string;
894
+ message: string;
895
+ id: string;
896
+ created_at?: string;
897
+ updated_at?: string;
898
+ deleted_at?: string;
899
+ data?: Record<string, any>;
900
+ version?: number;
901
+ brand?: DraftBrandDTO;
902
+ permissions?: Record<string, any>;
903
+ [index: string]: any;
904
+ }
905
+
875
906
  export interface ReportingCategorySuggestion {
876
907
  category?: string;
877
908
  occurrences?: number;
@@ -990,6 +1021,7 @@ export interface PublishedItemDTO {
990
1021
  tax_tag_code?: string;
991
1022
  tags?: string[];
992
1023
  is_featured?: boolean;
1024
+ tax_jwo_code?: string;
993
1025
  permissions?: Record<string, any>;
994
1026
  [index: string]: any;
995
1027
  }
@@ -1338,6 +1370,7 @@ export interface DraftItemEntityDTO {
1338
1370
  tax_tag_code?: string;
1339
1371
  tags?: string[];
1340
1372
  is_featured?: boolean;
1373
+ tax_jwo_code?: string;
1341
1374
  applied_diff_snapshot?: Record<string, any>;
1342
1375
  version?: number;
1343
1376
  brand?: DraftBrandDTO;
@@ -1613,6 +1646,25 @@ export interface GetMenuItemsRequest
1613
1646
  RequestQuery<GetMenuItemsQuery>,
1614
1647
  GetMenuItemsPath {}
1615
1648
 
1649
+ // POST /menu/{id}/recommended - get recommended items
1650
+
1651
+ export interface PostMenuRecommendedPath {
1652
+ // menu
1653
+ id: string;
1654
+ }
1655
+
1656
+ export interface PostMenuRecommendedBody {
1657
+ excluded_items?: string[];
1658
+ }
1659
+
1660
+ export interface PostMenuRecommendedResponse {
1661
+ items?: Item[];
1662
+ }
1663
+
1664
+ export interface PostMenuRecommendedRequest extends BaseRequest, PostMenuRecommendedPath {
1665
+ body: PostMenuRecommendedBody;
1666
+ }
1667
+
1616
1668
  // POST /menu/items/import/{location} - trigger import items
1617
1669
 
1618
1670
  export interface ImportItemsCanteenPath {
@@ -2609,6 +2661,7 @@ export interface PostMenuV3DraftBrandBody {
2609
2661
  modifier_group_to_modifier_relationships?: DraftModifierGroupToModifierRelationshipDTO[];
2610
2662
  modifiers?: DraftModifierDTO[];
2611
2663
  statuses?: BrandStatusDTO[];
2664
+ audit_logs?: AuditDTO[];
2612
2665
  name: string;
2613
2666
  description?: string;
2614
2667
  is_active?: boolean;
@@ -2618,7 +2671,7 @@ export interface PostMenuV3DraftBrandBody {
2618
2671
  global_menu_group_id?: string;
2619
2672
  posid_segment?: string;
2620
2673
  is_simplified_view?: boolean;
2621
- frictionless_partner?: "AWS";
2674
+ frictionless_partner?: string;
2622
2675
  applied_diff_snapshot?: Record<string, any>;
2623
2676
  changes?: BrandChangeDTO[];
2624
2677
  local_menu_group?: LocalMenuGroupDTO;
@@ -2675,6 +2728,7 @@ export interface PatchMenuV3DraftBrandBody {
2675
2728
  modifier_group_to_modifier_relationships?: DraftModifierGroupToModifierRelationshipDTO[];
2676
2729
  modifiers?: DraftModifierDTO[];
2677
2730
  statuses?: BrandStatusDTO[];
2731
+ audit_logs?: AuditDTO[];
2678
2732
  id?: string;
2679
2733
  name?: string;
2680
2734
  description?: string;
@@ -2685,7 +2739,7 @@ export interface PatchMenuV3DraftBrandBody {
2685
2739
  global_menu_group_id?: string;
2686
2740
  posid_segment?: string;
2687
2741
  is_simplified_view?: boolean;
2688
- frictionless_partner?: "AWS";
2742
+ frictionless_partner?: string;
2689
2743
  applied_diff_snapshot?: Record<string, any>;
2690
2744
  version?: number;
2691
2745
  changes?: BrandChangeDTO[];
@@ -2765,6 +2819,7 @@ export type PostMenuV3DraftBrandsBody = {
2765
2819
  modifier_group_to_modifier_relationships?: DraftModifierGroupToModifierRelationshipDTO[];
2766
2820
  modifiers?: DraftModifierDTO[];
2767
2821
  statuses?: BrandStatusDTO[];
2822
+ audit_logs?: AuditDTO[];
2768
2823
  name: string;
2769
2824
  description?: string;
2770
2825
  is_active?: boolean;
@@ -2774,7 +2829,7 @@ export type PostMenuV3DraftBrandsBody = {
2774
2829
  global_menu_group_id?: string;
2775
2830
  posid_segment?: string;
2776
2831
  is_simplified_view?: boolean;
2777
- frictionless_partner?: "AWS";
2832
+ frictionless_partner?: string;
2778
2833
  applied_diff_snapshot?: Record<string, any>;
2779
2834
  changes?: BrandChangeDTO[];
2780
2835
  local_menu_group?: LocalMenuGroupDTO;
@@ -2813,6 +2868,41 @@ export interface GetMenuV3DraftBrandsCountRequest
2813
2868
  extends BaseRequest,
2814
2869
  RequestQuery<GetMenuV3DraftBrandsCountQuery> {}
2815
2870
 
2871
+ // GET /menu/v3/draft/brand/{id}/audits
2872
+
2873
+ export interface GetMenuV3DraftBrandAuditsPath {
2874
+ id: string;
2875
+ }
2876
+
2877
+ export interface GetMenuV3DraftBrandAuditsQuery {
2878
+ // If specified, only the selected fields will be returned
2879
+ select?: string[];
2880
+ // List of relationships to load alongside this entity. Can load nested relationships using the pattern 'children.grand_children.foo'
2881
+ relationships?: string[];
2882
+ filter?: string;
2883
+ // Number of records to load per page
2884
+ limit?: number;
2885
+ page?: number;
2886
+ // A field to sort the results based on
2887
+ sort_by?: string;
2888
+ sort_order?: "DESC" | "ASC";
2889
+ // How soft deleted records should be shown in the list
2890
+ soft_deleted?: "include" | "exclude" | "only";
2891
+ // Graphql query string
2892
+ _query?: string;
2893
+ }
2894
+
2895
+ export interface GetMenuV3DraftBrandAuditsResponse {
2896
+ results: AuditListDraftItemDTO[];
2897
+ meta?: ListResponseMetadataDTO;
2898
+ [index: string]: any;
2899
+ }
2900
+
2901
+ export interface GetMenuV3DraftBrandAuditsRequest
2902
+ extends BaseRequest,
2903
+ RequestQuery<GetMenuV3DraftBrandAuditsQuery>,
2904
+ GetMenuV3DraftBrandAuditsPath {}
2905
+
2816
2906
  // GET /menu/v3/draft/brand/{id}/menus
2817
2907
 
2818
2908
  export interface GetMenuV3DraftBrandMenusPath {
@@ -3167,7 +3257,7 @@ export interface PostMenuV3BrandBody {
3167
3257
  global_menu_group_id?: string;
3168
3258
  posid_segment?: string;
3169
3259
  is_simplified_view?: boolean;
3170
- frictionless_partner?: "AWS";
3260
+ frictionless_partner?: string;
3171
3261
  local_menu_group?: LocalMenuGroupDTO;
3172
3262
  global_menu_group?: GlobalMenuGroupDTO;
3173
3263
  attachments?: FileAttachmentsDTO;
@@ -3235,7 +3325,7 @@ export interface PatchMenuV3BrandBody {
3235
3325
  global_menu_group_id?: string;
3236
3326
  posid_segment?: string;
3237
3327
  is_simplified_view?: boolean;
3238
- frictionless_partner?: "AWS";
3328
+ frictionless_partner?: string;
3239
3329
  version?: number;
3240
3330
  local_menu_group?: LocalMenuGroupDTO;
3241
3331
  global_menu_group?: GlobalMenuGroupDTO;
@@ -3327,7 +3417,7 @@ export type PostMenuV3BrandsBody = {
3327
3417
  global_menu_group_id?: string;
3328
3418
  posid_segment?: string;
3329
3419
  is_simplified_view?: boolean;
3330
- frictionless_partner?: "AWS";
3420
+ frictionless_partner?: string;
3331
3421
  local_menu_group?: LocalMenuGroupDTO;
3332
3422
  global_menu_group?: GlobalMenuGroupDTO;
3333
3423
  attachments?: FileAttachmentsDTO;
@@ -4363,6 +4453,7 @@ export interface PostMenuV3DraftItemBody {
4363
4453
  tax_tag_code?: string;
4364
4454
  tags?: string[];
4365
4455
  is_featured?: boolean;
4456
+ tax_jwo_code?: string;
4366
4457
  applied_diff_snapshot?: Record<string, any>;
4367
4458
  brand?: DraftBrandDTO;
4368
4459
  categories?: DraftCategoryToItemRelationshipDTO[];
@@ -4435,6 +4526,7 @@ export interface PatchMenuV3DraftItemBody {
4435
4526
  tax_tag_code?: string;
4436
4527
  tags?: string[];
4437
4528
  is_featured?: boolean;
4529
+ tax_jwo_code?: string;
4438
4530
  applied_diff_snapshot?: Record<string, any>;
4439
4531
  version?: number;
4440
4532
  brand?: DraftBrandDTO;
@@ -4529,6 +4621,7 @@ export type PostMenuV3DraftItemsBody = {
4529
4621
  tax_tag_code?: string;
4530
4622
  tags?: string[];
4531
4623
  is_featured?: boolean;
4624
+ tax_jwo_code?: string;
4532
4625
  applied_diff_snapshot?: Record<string, any>;
4533
4626
  brand?: DraftBrandDTO;
4534
4627
  categories?: DraftCategoryToItemRelationshipDTO[];
@@ -4619,6 +4712,7 @@ export interface PatchMenuV3DraftItemsBulkUpdateBody {
4619
4712
  tax_tag_code?: string;
4620
4713
  tags?: string[];
4621
4714
  is_featured?: boolean;
4715
+ tax_jwo_code?: string;
4622
4716
  applied_diff_snapshot?: Record<string, any>;
4623
4717
  brand?: DraftBrandDTO;
4624
4718
  categories?: DraftCategoryToItemRelationshipDTO[];
@@ -64,6 +64,9 @@ export interface ItemResponse {
64
64
  brand?: string;
65
65
  brand_label?: Label;
66
66
  taxes?: string[];
67
+ tax?: {
68
+ tax_tag_code?: string;
69
+ };
67
70
  menu_tax_tags?: string[];
68
71
  orderable?: boolean;
69
72
  volante_id?: string;
@@ -83,6 +86,12 @@ export interface ItemResponse {
83
86
  menu_label?: Label;
84
87
  tax_rate?: MonetaryValue;
85
88
  label?: Label;
89
+ reporting?: {
90
+ category?: {
91
+ primary?: string;
92
+ secondary?: string;
93
+ };
94
+ };
86
95
  }
87
96
 
88
97
  export interface ModifierGroupRequest {
@@ -241,6 +250,8 @@ export interface ShoppingCartRequest {
241
250
  email_tax_exempt?: boolean;
242
251
  // Indicates to clients that a tax recalculation is required
243
252
  tax_calculation_required?: boolean;
253
+ // Indicates that the shopping cart is a system 365 shopping cart
254
+ system365?: boolean;
244
255
  };
245
256
  meta?: {
246
257
  // Raw request from any vendor integrated with CDL
@@ -272,6 +283,7 @@ export interface ShoppingCartResponse {
272
283
  app?: string;
273
284
  discount?: Record<string, any>;
274
285
  provider_data?: FPValidationData;
286
+ order?: PromoOrder;
275
287
  };
276
288
  //@deprecated
277
289
  loyalty?: {
@@ -331,6 +343,8 @@ export interface ShoppingCartResponse {
331
343
  email_tax_exempt?: boolean;
332
344
  // Indicates to clients that a tax recalculation is required
333
345
  tax_calculation_required?: boolean;
346
+ // Indicates that the shopping cart is a system 365 shopping cart
347
+ system365?: boolean;
334
348
  };
335
349
  meta?: {
336
350
  // Raw request from any vendor integrated with CDL
@@ -435,6 +449,26 @@ export interface FPValidationData {
435
449
 
436
450
  export type AmountOffExclusion = "discount" | "promo";
437
451
 
452
+ export interface PromoOrder {
453
+ items_applied_discount_amount?: number;
454
+ amount?: number;
455
+ items_discount_amount?: number;
456
+ total_amount?: number;
457
+ total_applied_discount_amount?: number;
458
+ total_discount_amount?: number;
459
+ items?: PromoItem[];
460
+ }
461
+
462
+ export interface PromoItem {
463
+ applied_discount_amount?: number;
464
+ amount?: number;
465
+ discount_amount?: number;
466
+ price?: number;
467
+ quantity?: number;
468
+ source_id?: string;
469
+ subtotal_amount?: number;
470
+ }
471
+
438
472
  // POST /shoppingcart - Create a new ShoppingCart
439
473
 
440
474
  export type PostShoppingcartCartBody = ShoppingCartRequest;
@@ -348,13 +348,13 @@ export interface PostUserAuthRequest extends BaseRequest {
348
348
 
349
349
  export interface PostUserOauthBody {
350
350
  // OMS code from commpass sso
351
- code?: string;
351
+ code: string;
352
352
  // the oms url for compass
353
- oms_url?: string;
353
+ oms_url: string;
354
354
  // the return uri for compassconnect
355
- callback_uri?: string;
355
+ callback_uri: string;
356
356
  // the id of the application for compassconnect
357
- client_id?: string;
357
+ client_id: string;
358
358
  }
359
359
 
360
360
  export type PostUserOauthResponse = omsauth;