@compassdigital/sdk.typescript 4.192.0 → 4.194.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.192.0",
3
+ "version": "4.194.0",
4
4
  "description": "Compass Digital Labs TypeScript SDK",
5
5
  "type": "commonjs",
6
6
  "main": "./lib/index.js",
package/src/index.ts CHANGED
@@ -956,6 +956,8 @@ import {
956
956
  DeleteMenuV4ItemResponse,
957
957
  PatchMenuV4ItemsBulkUpdateBody,
958
958
  PatchMenuV4ItemsBulkUpdateResponse,
959
+ PatchMenuV4ItemsBulkPriceUpdateBody,
960
+ PatchMenuV4ItemsBulkPriceUpdateResponse,
959
961
  PostMenuV4ItemDuplicateBody,
960
962
  PostMenuV4ItemDuplicateResponse,
961
963
  DeleteMenuV4ItemModifierGroupsDetachBody,
@@ -1171,7 +1173,7 @@ import {
1171
1173
  GetConsumerActiveMenusQuery,
1172
1174
  GetConsumerActiveMenusResponse,
1173
1175
  GetConsumerMenuQuery,
1174
- GetConsumerMenuResponse$0,
1176
+ GetConsumerMenuResponse,
1175
1177
  GetConsumerMenuItemsQuery,
1176
1178
  GetConsumerMenuItemsResponse$0,
1177
1179
  PostConsumerLocationsMarketplaceTimeslotsQuery,
@@ -10484,6 +10486,26 @@ export class ServiceClient extends BaseServiceClient {
10484
10486
  );
10485
10487
  }
10486
10488
 
10489
+ /**
10490
+ * PATCH /menu/v4/items/bulk-price-update
10491
+ *
10492
+ * @param body
10493
+ * @param options - additional request options
10494
+ */
10495
+ patch_menu_v4_items_bulk_price_update(
10496
+ body: PatchMenuV4ItemsBulkPriceUpdateBody,
10497
+ options?: RequestOptions,
10498
+ ): ResponsePromise<PatchMenuV4ItemsBulkPriceUpdateResponse> {
10499
+ return this.request(
10500
+ 'menu',
10501
+ '/menu/v4/items/bulk-price-update',
10502
+ 'PATCH',
10503
+ `/menu/v4/items/bulk-price-update`,
10504
+ body,
10505
+ options,
10506
+ );
10507
+ }
10508
+
10487
10509
  /**
10488
10510
  * POST /menu/v4/item/{id}/duplicate
10489
10511
  *
@@ -12542,9 +12564,9 @@ export class ServiceClient extends BaseServiceClient {
12542
12564
  }
12543
12565
 
12544
12566
  /**
12545
- * GET /consumer/menu/{id} - Provide the front end all the data required to render the home page
12567
+ * GET /consumer/menu/{id} - Get full Menu by ID
12546
12568
  *
12547
- * @param id - Menu ID as Encoded CDL ID; TODO: mark parameter as required in swagger
12569
+ * @param id - Menu ID as Encoded CDL ID
12548
12570
  * @param options - additional request options
12549
12571
  */
12550
12572
  get_consumer_menu(
@@ -12552,7 +12574,7 @@ export class ServiceClient extends BaseServiceClient {
12552
12574
  options?: {
12553
12575
  query?: GetConsumerMenuQuery;
12554
12576
  } & RequestOptions,
12555
- ): ResponsePromise<GetConsumerMenuResponse$0> {
12577
+ ): ResponsePromise<GetConsumerMenuResponse> {
12556
12578
  return this.request(
12557
12579
  'consumer',
12558
12580
  '/consumer/menu/{id}',
@@ -1487,43 +1487,234 @@ export interface ConsumerGetActiveMenusResponse {
1487
1487
  menus: ConsumerMenuHours[];
1488
1488
  }
1489
1489
 
1490
- export interface GetConsumerMenuResponse {
1490
+ export interface GetMenuLabelConsumer {
1491
+ // English
1492
+ en?: string;
1493
+ }
1494
+
1495
+ export interface GetMenuGroupLabelConsumer {
1496
+ // English
1497
+ en?: string;
1498
+ // French
1499
+ fr?: string;
1500
+ }
1501
+
1502
+ export interface GetMenuItemLabelConsumer {
1503
+ // English
1504
+ en?: string;
1505
+ }
1506
+
1507
+ export interface GetMenuItemPriceConsumer {
1508
+ // Amount
1509
+ amount?: number;
1510
+ // Currency code
1511
+ currency?: string;
1512
+ }
1513
+
1514
+ export interface GetMenuItemCalorieConsumer {
1515
+ // Amount
1516
+ amount?: number;
1517
+ // Unit of measurement
1518
+ unit?: string;
1519
+ }
1520
+
1521
+ export interface GetMenuItemNutritionConsumer {
1522
+ // Calories
1523
+ calories?: GetMenuItemCalorieConsumer;
1524
+ }
1525
+
1526
+ export interface Certified {
1527
+ // Certified vegan
1528
+ vegan?: boolean;
1529
+ // Certified vegetarian
1530
+ vegetarian?: boolean;
1531
+ // Seafood Watch certified (sustainable seafood)
1532
+ seafood_watch?: boolean;
1533
+ // Certified for general wellbeing
1534
+ wellbeing?: boolean;
1535
+ // Farm to Fork certified (locally sourced)
1536
+ farm_to_fork?: boolean;
1537
+ // In Balance certified (nutritionally balanced)
1538
+ in_balance?: boolean;
1539
+ // Certified organic
1540
+ organic?: boolean;
1541
+ // No gluten ingredients present
1542
+ no_gluten_ingredients?: boolean;
1543
+ // Certified halal
1544
+ halal?: boolean;
1545
+ // Certified kosher
1546
+ kosher?: boolean;
1547
+ // Certified humane (animal welfare)
1548
+ humane?: boolean;
1549
+ // Locally crafted product
1550
+ locally_crafted?: boolean;
1551
+ // Contains nuts
1552
+ nuts?: boolean;
1553
+ // Oracle Garden Grown certified
1554
+ oracle_garden_grown?: boolean;
1555
+ // Oracle OYES certified
1556
+ oracle_oyes?: boolean;
1557
+ // Peanut free
1558
+ peanut_free?: boolean;
1559
+ // Tree nut free
1560
+ tree_nut_free?: boolean;
1561
+ // Wheat free
1562
+ wheat_free?: boolean;
1563
+ // Non-GMO certified
1564
+ non_gmo?: boolean;
1565
+ // Milk free
1566
+ milk_free?: boolean;
1567
+ // Egg free
1568
+ egg_free?: boolean;
1569
+ // Soy free
1570
+ soy_free?: boolean;
1571
+ // Fair Trade certified
1572
+ fair_trade?: boolean;
1573
+ // Rainforest Alliance certified
1574
+ rainforest_alliance?: boolean;
1575
+ // Salt free
1576
+ salt_free?: boolean;
1577
+ }
1578
+
1579
+ export interface GetMenuOptionNutritionConsumer {
1580
+ // Calories
1581
+ calories?: GetMenuItemCalorieConsumer;
1582
+ }
1583
+
1584
+ export interface GetMenuItemOptionSizingConsumer {
1585
+ // Sizing name
1586
+ name?: string;
1587
+ // POS ID for sizing
1588
+ posid?: string;
1589
+ // Price for this sizing
1590
+ price?: number;
1591
+ }
1592
+
1593
+ export interface GetMenuItemOptionMetaConsumer {
1594
+ // Available sizings
1595
+ sizing?: GetMenuItemOptionSizingConsumer[];
1596
+ }
1597
+
1598
+ export interface GetMenuItemOptionConsumer {
1599
+ // Menu Option ID
1600
+ id?: string;
1601
+ // Label for the option
1602
+ label?: GetMenuItemLabelConsumer;
1603
+ // Price
1604
+ price?: GetMenuItemPriceConsumer;
1605
+ // Nutrition
1606
+ nutrition?: GetMenuOptionNutritionConsumer;
1607
+ // Metadata for the option
1608
+ meta?: GetMenuItemOptionMetaConsumer;
1609
+ }
1610
+
1611
+ export interface GetMenuItemGroupIsConsumer {
1612
+ // Options group incremental?
1613
+ incremental?: boolean;
1614
+ }
1615
+
1616
+ export interface GetMenuItemGroupMetaConsumer {
1617
+ // Type of mod group
1618
+ order_type?: 'selection' | 'option' | 'quantity';
1619
+ }
1620
+
1621
+ export interface GetMenuItemOptionsGroupConsumer {
1622
+ // Menu Options Group ID
1623
+ id?: string;
1624
+ // Label for the options group
1625
+ label?: GetMenuItemLabelConsumer;
1626
+ // Options group items
1627
+ items?: GetMenuItemOptionConsumer[];
1628
+ // Minimum number of options
1629
+ min?: number;
1630
+ // Maximum number of options
1631
+ max?: number;
1632
+ // Object containing quick boolean details
1633
+ is?: GetMenuItemGroupIsConsumer;
1634
+ // Metadata for the options group
1635
+ meta?: GetMenuItemGroupMetaConsumer;
1636
+ }
1637
+
1638
+ export interface GetMenuItemRecipeConsumer {
1639
+ // Smart tags
1640
+ smart_tags?: string[];
1641
+ // Allergen tags
1642
+ allergen_tags?: string[];
1643
+ }
1644
+
1645
+ export interface GetMenuItemMetaConsumer {
1646
+ // Barcodes of the item
1647
+ barcodes?: string[];
1648
+ // Recipe meta
1649
+ recipe?: GetMenuItemRecipeConsumer;
1650
+ }
1651
+
1652
+ export interface GetMenuItemImageSizesConsumer {
1653
+ // Image URL
1654
+ original?: string;
1655
+ // 80x80 thumbnail image URL
1656
+ thumbnail_80_80?: string;
1657
+ }
1658
+
1659
+ export interface GetMenuItemImageConsumer {
1660
+ // Image source URL
1661
+ src?: string;
1662
+ // Image sizes
1663
+ sizes?: GetMenuItemImageSizesConsumer;
1664
+ }
1665
+
1666
+ export interface GetMenuItemIsConsumer {
1667
+ // Is the item out of stock?
1668
+ out_of_stock?: boolean;
1669
+ }
1670
+
1671
+ export interface GetMenuItemConsumer {
1672
+ // Menu Item ID
1673
+ id?: string;
1674
+ // Label for the menu item
1675
+ label?: GetMenuItemLabelConsumer;
1676
+ // Description of the item
1677
+ description?: GetMenuItemLabelConsumer;
1678
+ // Item price
1679
+ price?: GetMenuItemPriceConsumer;
1680
+ // Meal exchange value of the item
1681
+ meal_value?: number;
1682
+ // Sale price of the item
1683
+ sale_price?: GetMenuItemPriceConsumer;
1684
+ // Number of units for the item. For example, a dozen doughnuts should have a unit value of 12
1685
+ unit?: number;
1686
+ // Item nutrition
1687
+ nutrition?: GetMenuItemNutritionConsumer;
1688
+ // Food certifications like vegan, organic, etc
1689
+ certified?: Certified;
1690
+ // Item options/modifiers
1691
+ options?: GetMenuItemOptionsGroupConsumer[];
1692
+ // Metadata for the item
1693
+ meta?: GetMenuItemMetaConsumer;
1694
+ // Item image data
1695
+ image?: GetMenuItemImageConsumer;
1696
+ // Quick boolean details
1697
+ is?: GetMenuItemIsConsumer;
1698
+ }
1699
+
1700
+ export interface GetMenuGroupConsumer {
1701
+ // Menu Group ID
1702
+ id?: string;
1703
+ // Menu Group label
1704
+ label?: GetMenuGroupLabelConsumer;
1705
+ // Menu Items
1706
+ items?: GetMenuItemConsumer[];
1707
+ }
1708
+
1709
+ export interface GetMenuResponseConsumer {
1491
1710
  // menu id
1492
1711
  id: string;
1493
- date?: {
1494
- created?: string;
1495
- modified?: string;
1496
- published?: string;
1497
- };
1498
- label?: {
1499
- en?: string;
1500
- };
1712
+ // menu label
1713
+ label?: GetMenuLabelConsumer;
1501
1714
  // menu groups
1502
- groups: ConsumerGroup[];
1715
+ groups: GetMenuGroupConsumer[];
1503
1716
  // menu parent id
1504
1717
  parent_id: string;
1505
- // menu location brand
1506
- location_brand?: string;
1507
- // menu company
1508
- company?: string;
1509
- // menu sector
1510
- sector?: string;
1511
- is?: {
1512
- disabled?: boolean;
1513
- hidden?: boolean;
1514
- linked?: boolean;
1515
- promo_exemptions_enabled?: boolean;
1516
- plu_enabled?: boolean;
1517
- item_images_enabled?: boolean;
1518
- item_showcase_enabled?: boolean;
1519
- item_desc_edit_enabled?: boolean;
1520
- calories_edit_enabled?: boolean;
1521
- item_label_edit_enabled?: boolean;
1522
- frictionless?: boolean;
1523
- category_images_enabled?: boolean;
1524
- };
1525
- // menu meta
1526
- meta?: Record<string, any>;
1527
1718
  }
1528
1719
 
1529
1720
  export interface ConsumerOption {
@@ -2550,10 +2741,10 @@ export interface GetConsumerActiveMenusQuery {
2550
2741
 
2551
2742
  export type GetConsumerActiveMenusResponse = ConsumerGetActiveMenusResponse;
2552
2743
 
2553
- // GET /consumer/menu/{id} - Provide the front end all the data required to render the home page
2744
+ // GET /consumer/menu/{id} - Get full Menu by ID
2554
2745
 
2555
2746
  export interface GetConsumerMenuPath {
2556
- // Menu ID as Encoded CDL ID; TODO: mark parameter as required in swagger
2747
+ // Menu ID as Encoded CDL ID
2557
2748
  id: string;
2558
2749
  }
2559
2750
 
@@ -2562,7 +2753,7 @@ export interface GetConsumerMenuQuery {
2562
2753
  _query?: string;
2563
2754
  }
2564
2755
 
2565
- export type GetConsumerMenuResponse$0 = GetConsumerMenuResponse;
2756
+ export type GetConsumerMenuResponse = GetMenuResponseConsumer;
2566
2757
 
2567
2758
  // GET /consumer/menu/{id}/items - Provide the front end with menu items
2568
2759
 
@@ -8854,6 +8854,65 @@ export interface PatchMenuV4ItemsBulkUpdateRequest extends BaseRequest {
8854
8854
  body: PatchMenuV4ItemsBulkUpdateBody;
8855
8855
  }
8856
8856
 
8857
+ // PATCH /menu/v4/items/bulk-price-update
8858
+
8859
+ export interface PatchMenuV4ItemsBulkPriceUpdateBody {
8860
+ id_list: string[];
8861
+ price_flat_adjustment_amount?: number;
8862
+ price_percentage_adjustment?: number;
8863
+ is_published?: boolean;
8864
+ parent?: DraftItemDTO;
8865
+ children?: DraftItemDTO[];
8866
+ modifier_groups?: DraftItemToModifierGroupRelationshipDTO[];
8867
+ cpg_item?: UniversalItemDTO;
8868
+ stocks?: StockDTO[];
8869
+ id?: string;
8870
+ parent_id?: string;
8871
+ name?: string;
8872
+ name_on_receipt?: string;
8873
+ name_on_kds?: string;
8874
+ label?: string;
8875
+ description?: string;
8876
+ reporting?: ReportingMetadataDTO;
8877
+ price?: number;
8878
+ barcode?: string;
8879
+ calories?: number;
8880
+ meal_value?: number;
8881
+ is_active?: boolean;
8882
+ posid?: string;
8883
+ tax_tags?: string[];
8884
+ brand_id?: string;
8885
+ line_route?: string;
8886
+ posid_segment?: number;
8887
+ menu_works?: MenuWorksDTO;
8888
+ is_out_of_stock?: boolean;
8889
+ tax_tag_code?: string;
8890
+ tags?: string[];
8891
+ is_featured?: boolean;
8892
+ tax_jwo_code?: string;
8893
+ unique_id?: number;
8894
+ cpg_item_id?: string;
8895
+ price_levels?: Record<string, any>;
8896
+ translation?: Record<string, any>;
8897
+ applied_diff_snapshot?: Record<string, any>;
8898
+ brand?: DraftBrandDTO;
8899
+ categories?: DraftCategoryToItemRelationshipDTO[];
8900
+ changes?: ItemChangeDTO[];
8901
+ vendor_metadata?: VendorMetadataDTO[];
8902
+ attachments?: FileAttachmentsDTO;
8903
+ weight?: WeightDTO;
8904
+ permissions?: Record<string, any>;
8905
+ [index: string]: any;
8906
+ }
8907
+
8908
+ export interface PatchMenuV4ItemsBulkPriceUpdateResponse {
8909
+ results?: DraftItemEntityDTO[];
8910
+ }
8911
+
8912
+ export interface PatchMenuV4ItemsBulkPriceUpdateRequest extends BaseRequest {
8913
+ body: PatchMenuV4ItemsBulkPriceUpdateBody;
8914
+ }
8915
+
8857
8916
  // POST /menu/v4/item/{id}/duplicate
8858
8917
 
8859
8918
  export interface PostMenuV4ItemDuplicatePath {