@compassdigital/sdk.typescript 3.67.0 → 3.69.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.
Files changed (50) hide show
  1. package/.editorconfig +4 -0
  2. package/.eslintignore +4 -0
  3. package/.eslintrc.js +71 -0
  4. package/lib/base.d.ts +36 -35
  5. package/lib/base.d.ts.map +1 -1
  6. package/lib/base.js +68 -66
  7. package/lib/base.js.map +1 -1
  8. package/lib/index.d.ts +23 -1
  9. package/lib/index.d.ts.map +1 -1
  10. package/lib/index.js +26 -0
  11. package/lib/index.js.map +1 -1
  12. package/lib/interface/calendar.js +1 -1
  13. package/lib/interface/calendar.js.map +1 -1
  14. package/lib/interface/compassconnect.js +1 -1
  15. package/lib/interface/compassconnect.js.map +1 -1
  16. package/lib/interface/delivery.js +1 -1
  17. package/lib/interface/delivery.js.map +1 -1
  18. package/lib/interface/file.js +1 -1
  19. package/lib/interface/file.js.map +1 -1
  20. package/lib/interface/menu.d.ts +171 -39
  21. package/lib/interface/menu.d.ts.map +1 -1
  22. package/lib/interface/menu.js +1 -1
  23. package/lib/interface/menu.js.map +1 -1
  24. package/lib/interface/notification.js +1 -1
  25. package/lib/interface/notification.js.map +1 -1
  26. package/lib/interface/promo.d.ts +8 -10
  27. package/lib/interface/promo.d.ts.map +1 -1
  28. package/lib/interface/shoppingcart.d.ts +7 -0
  29. package/lib/interface/shoppingcart.d.ts.map +1 -1
  30. package/lib/interface/user.d.ts +10 -1
  31. package/lib/interface/user.d.ts.map +1 -1
  32. package/lib/interface/user.js +1 -1
  33. package/lib/interface/user.js.map +1 -1
  34. package/lib/interface/vendor.js +1 -1
  35. package/lib/interface/vendor.js.map +1 -1
  36. package/package.json +56 -52
  37. package/prettier.config.js +10 -0
  38. package/src/base.ts +425 -410
  39. package/src/index.ts +66 -0
  40. package/src/interface/calendar.ts +1 -1
  41. package/src/interface/compassconnect.ts +1 -1
  42. package/src/interface/delivery.ts +1 -1
  43. package/src/interface/file.ts +1 -1
  44. package/src/interface/menu.ts +196 -41
  45. package/src/interface/notification.ts +1 -1
  46. package/src/interface/promo.ts +9 -10
  47. package/src/interface/shoppingcart.ts +8 -0
  48. package/src/interface/user.ts +12 -2
  49. package/src/interface/vendor.ts +1 -1
  50. package/test/client.test.ts +223 -226
@@ -429,7 +429,7 @@ export interface BrandChangeDTO {
429
429
  [index: string]: any;
430
430
  }
431
431
  export interface POSIDSegmentDTO {
432
- value?: string;
432
+ value?: FilterFieldDTO;
433
433
  modifier_id?: string;
434
434
  published_modifier?: PublishedModifierDTO;
435
435
  draft_modifier?: DraftModifierDTO;
@@ -460,9 +460,9 @@ export interface PublishedModifierDTO {
460
460
  tax_tags?: FilterFieldDTO[];
461
461
  is_active?: boolean;
462
462
  posid?: FilterFieldDTO;
463
+ reporting?: any;
463
464
  brand_id?: string;
464
465
  brand?: PublishedBrandDTO;
465
- reporting?: any;
466
466
  weight?: any;
467
467
  permissions?: FilterFieldDTO;
468
468
  [index: string]: any;
@@ -524,6 +524,7 @@ export interface PublishedItemDTO {
524
524
  name?: string;
525
525
  label?: string;
526
526
  description?: string;
527
+ reporting?: ReportingMetadataDTO;
527
528
  price?: number;
528
529
  barcode?: string;
529
530
  calories?: number;
@@ -531,9 +532,9 @@ export interface PublishedItemDTO {
531
532
  posid?: FilterFieldDTO;
532
533
  tax_tags?: FilterFieldDTO[];
533
534
  brand_id?: string;
535
+ line_route?: FilterFieldDTO;
534
536
  brand?: PublishedBrandDTO;
535
537
  categories?: PublishedCategoryToItemRelationshipDTO[];
536
- reporting?: ReportingMetadataDTO;
537
538
  attachments?: FileAttachmentsDTO;
538
539
  weight?: WeightDTO;
539
540
  permissions?: FilterFieldDTO;
@@ -620,11 +621,11 @@ export interface DraftModifierDTO {
620
621
  tax_tags?: FilterFieldDTO[];
621
622
  is_active?: boolean;
622
623
  posid?: FilterFieldDTO;
624
+ reporting?: any;
623
625
  brand_id?: string;
624
626
  brand?: any;
625
627
  changes?: ModifierChangeDTO[];
626
628
  vendor_metadata?: VendorMetadataDTO[];
627
- reporting?: any;
628
629
  weight?: any;
629
630
  permissions?: FilterFieldDTO;
630
631
  [index: string]: any;
@@ -692,6 +693,7 @@ export interface DraftItemDTO {
692
693
  name?: string;
693
694
  label?: string;
694
695
  description?: string;
696
+ reporting?: any;
695
697
  price?: number;
696
698
  barcode?: string;
697
699
  calories?: number;
@@ -699,11 +701,11 @@ export interface DraftItemDTO {
699
701
  posid?: FilterFieldDTO;
700
702
  tax_tags?: FilterFieldDTO[];
701
703
  brand_id?: string;
704
+ line_route?: FilterFieldDTO;
702
705
  brand?: any;
703
706
  categories?: DraftCategoryToItemRelationshipDTO[];
704
707
  changes?: ItemChangeDTO[];
705
708
  vendor_metadata?: VendorMetadataDTO[];
706
- reporting?: any;
707
709
  attachments?: any;
708
710
  weight?: any;
709
711
  permissions?: FilterFieldDTO;
@@ -921,6 +923,7 @@ export interface DraftItemDraftItemDTO {
921
923
  posid?: FilterFieldDTO;
922
924
  tax_tags?: FilterFieldDTO[];
923
925
  brand_id?: FilterFieldDTO;
926
+ line_route?: FilterFieldDTO;
924
927
  id?: FilterFieldDTO;
925
928
  version?: FilterFieldDTO;
926
929
  created_at?: FilterFieldDTO;
@@ -944,43 +947,43 @@ export interface ReportingCategorySuggestion {
944
947
  category?: string;
945
948
  occurrences?: number;
946
949
  }
947
- export interface DiffDTO {
948
- action: string;
949
- id?: string;
950
- created_at?: string;
951
- updated_at?: string;
952
- deleted_at?: string;
953
- child_nodes?: any[];
954
- name?: string;
955
- entity_type?: string;
956
- local_id?: string;
957
- changes?: any;
958
- local_snapshot?: any;
959
- global_id?: string;
960
- global_snapshot?: any;
961
- brand_id?: string;
962
- version?: number;
963
- depends_on?: GlobalDiffDependencyDTO[];
964
- is_depended_by?: any[];
965
- brand?: DraftBrandDTO;
966
- permissions?: any;
967
- [index: string]: any;
968
- }
969
950
  export interface GlobalDiffDependencyDTO {
970
951
  depends_on_id?: string;
971
952
  is_depended_by_id?: string;
972
953
  id?: string;
973
- depends_on?: GlobalDiffDTO;
954
+ depends_on?: GlobalDiffGlobalDiffDTO;
974
955
  is_depended_by?: any;
975
- permissions?: any;
956
+ permissions?: FilterFieldDTO;
976
957
  [index: string]: any;
977
958
  }
978
- export interface GlobalDiffDTO {
959
+ export interface GlobalDiffGlobalDiffDTO {
960
+ action?: FilterFieldDTO;
961
+ entity_type?: FilterFieldDTO;
962
+ local_id?: FilterFieldDTO;
963
+ changes?: FilterFieldDTO;
964
+ local_snapshot?: FilterFieldDTO;
965
+ global_id?: FilterFieldDTO;
966
+ global_snapshot?: FilterFieldDTO;
967
+ brand_id?: FilterFieldDTO;
968
+ id?: FilterFieldDTO;
969
+ version?: FilterFieldDTO;
970
+ created_at?: FilterFieldDTO;
971
+ updated_at?: FilterFieldDTO;
972
+ deleted_at?: FilterFieldDTO;
973
+ depends_on?: any[];
974
+ is_depended_by?: any[];
975
+ brand?: DraftBrandDTO;
976
+ permissions?: FilterFieldDTO;
977
+ [index: string]: any;
978
+ }
979
+ export interface DiffDTO {
979
980
  action: string;
980
981
  id?: string;
981
982
  created_at?: string;
982
983
  updated_at?: string;
983
984
  deleted_at?: string;
985
+ child_nodes?: any[];
986
+ name?: string;
984
987
  entity_type?: string;
985
988
  local_id?: string;
986
989
  changes?: any;
@@ -989,8 +992,8 @@ export interface GlobalDiffDTO {
989
992
  global_snapshot?: any;
990
993
  brand_id?: string;
991
994
  version?: number;
992
- depends_on?: any[];
993
- is_depended_by?: any[];
995
+ depends_on?: GlobalDiffDependencyDTO[];
996
+ is_depended_by?: GlobalDiffDependencyDTO[];
994
997
  brand?: DraftBrandDTO;
995
998
  permissions?: any;
996
999
  [index: string]: any;
@@ -1137,6 +1140,7 @@ export interface PublishedItemPublishedItemDTO {
1137
1140
  posid?: FilterFieldDTO;
1138
1141
  tax_tags?: FilterFieldDTO[];
1139
1142
  brand_id?: FilterFieldDTO;
1143
+ line_route?: FilterFieldDTO;
1140
1144
  id?: FilterFieldDTO;
1141
1145
  version?: FilterFieldDTO;
1142
1146
  created_at?: FilterFieldDTO;
@@ -1281,6 +1285,26 @@ export interface PublishedModifierPublishedModifierDTO {
1281
1285
  permissions?: FilterFieldDTO;
1282
1286
  [index: string]: any;
1283
1287
  }
1288
+ export interface GlobalDiffDTO {
1289
+ action: string;
1290
+ id?: string;
1291
+ created_at?: string;
1292
+ updated_at?: string;
1293
+ deleted_at?: string;
1294
+ entity_type?: string;
1295
+ local_id?: string;
1296
+ changes?: any;
1297
+ local_snapshot?: any;
1298
+ global_id?: string;
1299
+ global_snapshot?: any;
1300
+ brand_id?: string;
1301
+ version?: number;
1302
+ depends_on?: GlobalDiffDependencyDTO[];
1303
+ is_depended_by?: GlobalDiffDependencyDTO[];
1304
+ brand?: DraftBrandDTO;
1305
+ permissions?: any;
1306
+ [index: string]: any;
1307
+ }
1284
1308
  export interface GetMenuClientPath {
1285
1309
  client_id: string;
1286
1310
  }
@@ -2214,6 +2238,14 @@ export interface GetMenuV3DraftBrandDiffsPath {
2214
2238
  id: string;
2215
2239
  }
2216
2240
  export interface GetMenuV3DraftBrandDiffsQuery {
2241
+ select?: string[];
2242
+ relationships?: string[];
2243
+ filter?: any;
2244
+ limit?: number;
2245
+ page?: number;
2246
+ sort_by?: string;
2247
+ sort_order?: string;
2248
+ soft_deleted?: string;
2217
2249
  _query?: string;
2218
2250
  }
2219
2251
  export interface GetMenuV3DraftBrandDiffsResponse {
@@ -3021,6 +3053,7 @@ export interface PostMenuV3DraftItemBody {
3021
3053
  name: string;
3022
3054
  label?: string;
3023
3055
  description?: string;
3056
+ reporting: ReportingMetadataDTO;
3024
3057
  price: number;
3025
3058
  barcode?: string;
3026
3059
  calories?: number;
@@ -3028,12 +3061,12 @@ export interface PostMenuV3DraftItemBody {
3028
3061
  posid?: string;
3029
3062
  tax_tags?: any[];
3030
3063
  brand_id: string;
3064
+ line_route?: string;
3031
3065
  id?: any;
3032
3066
  brand?: DraftBrandDTO;
3033
3067
  categories?: DraftCategoryToItemRelationshipDTO[];
3034
3068
  changes?: ItemChangeDTO[];
3035
3069
  vendor_metadata?: VendorMetadataDTO[];
3036
- reporting?: ReportingMetadataDTO;
3037
3070
  attachments?: FileAttachmentsDTO;
3038
3071
  weight?: WeightDTO;
3039
3072
  permissions?: any;
@@ -3067,6 +3100,7 @@ export interface PatchMenuV3DraftItemBody {
3067
3100
  name?: string;
3068
3101
  label?: string;
3069
3102
  description?: string;
3103
+ reporting?: ReportingMetadataDTO;
3070
3104
  price?: number;
3071
3105
  barcode?: string;
3072
3106
  calories?: number;
@@ -3074,11 +3108,11 @@ export interface PatchMenuV3DraftItemBody {
3074
3108
  posid?: string;
3075
3109
  tax_tags?: any[];
3076
3110
  brand_id?: string;
3111
+ line_route?: string;
3077
3112
  brand?: DraftBrandDTO;
3078
3113
  categories?: DraftCategoryToItemRelationshipDTO[];
3079
3114
  changes?: ItemChangeDTO[];
3080
3115
  vendor_metadata?: VendorMetadataDTO[];
3081
- reporting?: ReportingMetadataDTO;
3082
3116
  attachments?: FileAttachmentsDTO;
3083
3117
  weight?: WeightDTO;
3084
3118
  permissions?: any;
@@ -3121,6 +3155,7 @@ export type PostMenuV3DraftItemsBody = {
3121
3155
  name: string;
3122
3156
  label?: string;
3123
3157
  description?: string;
3158
+ reporting: ReportingMetadataDTO;
3124
3159
  price: number;
3125
3160
  barcode?: string;
3126
3161
  calories?: number;
@@ -3128,12 +3163,12 @@ export type PostMenuV3DraftItemsBody = {
3128
3163
  posid?: string;
3129
3164
  tax_tags?: any[];
3130
3165
  brand_id: string;
3166
+ line_route?: string;
3131
3167
  id?: any;
3132
3168
  brand?: DraftBrandDTO;
3133
3169
  categories?: DraftCategoryToItemRelationshipDTO[];
3134
3170
  changes?: ItemChangeDTO[];
3135
3171
  vendor_metadata?: VendorMetadataDTO[];
3136
- reporting?: ReportingMetadataDTO;
3137
3172
  attachments?: FileAttachmentsDTO;
3138
3173
  weight?: WeightDTO;
3139
3174
  permissions?: any;
@@ -3157,6 +3192,42 @@ export interface GetMenuV3DraftItemsCountResponse {
3157
3192
  }
3158
3193
  export interface GetMenuV3DraftItemsCountRequest extends BaseRequest, RequestQuery<GetMenuV3DraftItemsCountQuery> {
3159
3194
  }
3195
+ export interface PatchMenuV3DraftItemsBulkUpdateBody {
3196
+ id_list: any[];
3197
+ parent?: DraftItemDTO;
3198
+ children?: DraftItemDTO[];
3199
+ posid_segment?: POSIDSegmentDTO;
3200
+ modifier_groups?: DraftItemToModifierGroupRelationshipDTO[];
3201
+ id?: string;
3202
+ parent_id?: string;
3203
+ name?: string;
3204
+ label?: string;
3205
+ description?: string;
3206
+ reporting?: ReportingMetadataDTO;
3207
+ price?: number;
3208
+ barcode?: string;
3209
+ calories?: number;
3210
+ is_active?: boolean;
3211
+ posid?: string;
3212
+ tax_tags?: any[];
3213
+ brand_id?: string;
3214
+ line_route?: string;
3215
+ brand?: DraftBrandDTO;
3216
+ categories?: DraftCategoryToItemRelationshipDTO[];
3217
+ changes?: ItemChangeDTO[];
3218
+ vendor_metadata?: VendorMetadataDTO[];
3219
+ attachments?: FileAttachmentsDTO;
3220
+ weight?: WeightDTO;
3221
+ permissions?: any;
3222
+ [index: string]: any;
3223
+ }
3224
+ export interface PatchMenuV3DraftItemsBulkUpdateResponse {
3225
+ results: any[];
3226
+ [index: string]: any;
3227
+ }
3228
+ export interface PatchMenuV3DraftItemsBulkUpdateRequest extends BaseRequest {
3229
+ body: PatchMenuV3DraftItemsBulkUpdateBody;
3230
+ }
3160
3231
  export interface PostMenuV3ItemAttachmentPath {
3161
3232
  id: string;
3162
3233
  name: string;
@@ -3169,6 +3240,16 @@ export interface PostMenuV3ItemAttachmentResponse {
3169
3240
  }
3170
3241
  export interface PostMenuV3ItemAttachmentRequest extends BaseRequest, RequestQuery<PostMenuV3ItemAttachmentQuery>, PostMenuV3ItemAttachmentPath {
3171
3242
  }
3243
+ export interface PostMenuV3ItemsImportQuery {
3244
+ "body.brand_id"?: string;
3245
+ "body.data"?: string;
3246
+ }
3247
+ export interface PostMenuV3ItemsImportResponse {
3248
+ results: any[];
3249
+ [index: string]: any;
3250
+ }
3251
+ export interface PostMenuV3ItemsImportRequest extends BaseRequest, RequestQuery<PostMenuV3ItemsImportQuery> {
3252
+ }
3172
3253
  export interface GetMenuV3ItemPath {
3173
3254
  id: string;
3174
3255
  }
@@ -3702,12 +3783,12 @@ export interface PostMenuV3DraftModifierBody {
3702
3783
  tax_tags?: any[];
3703
3784
  is_active?: boolean;
3704
3785
  posid?: string;
3786
+ reporting: ReportingMetadataDTO;
3705
3787
  brand_id: string;
3706
3788
  id?: any;
3707
3789
  brand?: DraftBrandDTO;
3708
3790
  changes?: ModifierChangeDTO[];
3709
3791
  vendor_metadata?: VendorMetadataDTO[];
3710
- reporting?: ReportingMetadataDTO;
3711
3792
  weight?: WeightDTO;
3712
3793
  permissions?: any;
3713
3794
  [index: string]: any;
@@ -3745,11 +3826,11 @@ export interface PatchMenuV3DraftModifierBody {
3745
3826
  tax_tags?: any[];
3746
3827
  is_active?: boolean;
3747
3828
  posid?: string;
3829
+ reporting?: ReportingMetadataDTO;
3748
3830
  brand_id?: string;
3749
3831
  brand?: DraftBrandDTO;
3750
3832
  changes?: ModifierChangeDTO[];
3751
3833
  vendor_metadata?: VendorMetadataDTO[];
3752
- reporting?: ReportingMetadataDTO;
3753
3834
  weight?: WeightDTO;
3754
3835
  permissions?: any;
3755
3836
  [index: string]: any;
@@ -3796,12 +3877,12 @@ export type PostMenuV3DraftModifiersBody = {
3796
3877
  tax_tags?: any[];
3797
3878
  is_active?: boolean;
3798
3879
  posid?: string;
3880
+ reporting: ReportingMetadataDTO;
3799
3881
  brand_id: string;
3800
3882
  id?: any;
3801
3883
  brand?: DraftBrandDTO;
3802
3884
  changes?: ModifierChangeDTO[];
3803
3885
  vendor_metadata?: VendorMetadataDTO[];
3804
- reporting?: ReportingMetadataDTO;
3805
3886
  weight?: WeightDTO;
3806
3887
  permissions?: any;
3807
3888
  [index: string]: any;
@@ -3824,6 +3905,38 @@ export interface GetMenuV3DraftModifiersCountResponse {
3824
3905
  }
3825
3906
  export interface GetMenuV3DraftModifiersCountRequest extends BaseRequest, RequestQuery<GetMenuV3DraftModifiersCountQuery> {
3826
3907
  }
3908
+ export interface PatchMenuV3DraftModifiersBulkUpdateBody {
3909
+ id_list: any[];
3910
+ parent?: DraftModifierDTO;
3911
+ children?: DraftModifierDTO[];
3912
+ posid_segment?: POSIDSegmentDTO;
3913
+ modifier_groups?: DraftModifierGroupToModifierRelationshipDTO[];
3914
+ id?: string;
3915
+ parent_id?: string;
3916
+ name?: string;
3917
+ label?: string;
3918
+ description?: string;
3919
+ price?: number;
3920
+ calories?: number;
3921
+ tax_tags?: any[];
3922
+ is_active?: boolean;
3923
+ posid?: string;
3924
+ reporting?: ReportingMetadataDTO;
3925
+ brand_id?: string;
3926
+ brand?: DraftBrandDTO;
3927
+ changes?: ModifierChangeDTO[];
3928
+ vendor_metadata?: VendorMetadataDTO[];
3929
+ weight?: WeightDTO;
3930
+ permissions?: any;
3931
+ [index: string]: any;
3932
+ }
3933
+ export interface PatchMenuV3DraftModifiersBulkUpdateResponse {
3934
+ results: any[];
3935
+ [index: string]: any;
3936
+ }
3937
+ export interface PatchMenuV3DraftModifiersBulkUpdateRequest extends BaseRequest {
3938
+ body: PatchMenuV3DraftModifiersBulkUpdateBody;
3939
+ }
3827
3940
  export interface GetMenuV3ModifierPath {
3828
3941
  id: string;
3829
3942
  }
@@ -3883,7 +3996,26 @@ export interface GetMenuV3GlobalDiffQuery {
3883
3996
  relationships?: string[];
3884
3997
  _query?: string;
3885
3998
  }
3886
- export type GetMenuV3GlobalDiffResponse = GlobalDiffDTO;
3999
+ export interface GetMenuV3GlobalDiffResponse {
4000
+ action: string;
4001
+ id?: string;
4002
+ created_at?: string;
4003
+ updated_at?: string;
4004
+ deleted_at?: string;
4005
+ entity_type?: string;
4006
+ local_id?: string;
4007
+ changes?: any;
4008
+ local_snapshot?: any;
4009
+ global_id?: string;
4010
+ global_snapshot?: any;
4011
+ brand_id?: string;
4012
+ version?: number;
4013
+ depends_on?: GlobalDiffDependencyDTO[];
4014
+ is_depended_by?: GlobalDiffDependencyDTO[];
4015
+ brand?: DraftBrandDTO;
4016
+ permissions?: any;
4017
+ [index: string]: any;
4018
+ }
3887
4019
  export interface GetMenuV3GlobalDiffRequest extends BaseRequest, RequestQuery<GetMenuV3GlobalDiffQuery>, GetMenuV3GlobalDiffPath {
3888
4020
  }
3889
4021
  export interface GetMenuV3GlobalDiffsQuery {