@compassdigital/sdk.typescript 4.838.0 → 4.839.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/src/index.ts CHANGED
@@ -1288,12 +1288,6 @@ import {
1288
1288
  GetConsumerMenuV3Response,
1289
1289
  GetConsumerMenuItemsQuery,
1290
1290
  GetConsumerMenuItemsResponse$0,
1291
- PostConsumerLocationsMarketplaceTimeslotsQuery,
1292
- PostConsumerLocationsMarketplaceTimeslotsBody,
1293
- PostConsumerLocationsMarketplaceTimeslotsResponse,
1294
- PostConsumerLocationsMarketplaceTimeslotsDeliveryQuery,
1295
- PostConsumerLocationsMarketplaceTimeslotsDeliveryBody,
1296
- PostConsumerLocationsMarketplaceTimeslotsDeliveryResponse,
1297
1291
  DeleteConsumerUserQuery,
1298
1292
  DeleteConsumerUserResponse,
1299
1293
  PutConsumerUserBody,
@@ -1346,10 +1340,8 @@ import {
1346
1340
  GetConsumerConfigAppconfigResponse,
1347
1341
  PatchCheckinConsumerOrderResponse,
1348
1342
  GetConsumerAppThemeResponse,
1349
- GetConsumerBrandMenuTimeslotsQuery,
1350
- GetConsumerBrandMenuTimeslotsResponse,
1351
- GetConsumerBrandMenuDeliveryTimeslotsQuery,
1352
- GetConsumerBrandMenuDeliveryTimeslotsResponse,
1343
+ PostConsumerTimeslotsBody$0,
1344
+ PostConsumerTimeslotsResponse$0,
1353
1345
  GetConsumerConfigPublicResponse$0,
1354
1346
  PutConsumerShoppingcartPromoBody,
1355
1347
  PutConsumerShoppingcartPromoResponse,
@@ -15087,50 +15079,6 @@ export class ServiceClient extends BaseServiceClient {
15087
15079
  );
15088
15080
  }
15089
15081
 
15090
- /**
15091
- * POST /consumer/location/marketplace/timeslots - Get Marketplace timeslots
15092
- *
15093
- * @param body - Request body for marketplace timeslots
15094
- * @param options - additional request options
15095
- */
15096
- post_consumer_locations_marketplace_timeslots(
15097
- body: PostConsumerLocationsMarketplaceTimeslotsBody,
15098
- options?: {
15099
- query?: PostConsumerLocationsMarketplaceTimeslotsQuery;
15100
- } & RequestOptions,
15101
- ): ResponsePromise<PostConsumerLocationsMarketplaceTimeslotsResponse> {
15102
- return this.request(
15103
- 'consumer',
15104
- '/consumer/location/marketplace/timeslots',
15105
- 'POST',
15106
- `/consumer/location/marketplace/timeslots`,
15107
- body,
15108
- options,
15109
- );
15110
- }
15111
-
15112
- /**
15113
- * POST /consumer/location/marketplace/timeslots/delivery - Get Marketplace timeslots
15114
- *
15115
- * @param body - Request body for marketplace timeslots delivery
15116
- * @param options - additional request options
15117
- */
15118
- post_consumer_locations_marketplace_timeslots_delivery(
15119
- body: PostConsumerLocationsMarketplaceTimeslotsDeliveryBody,
15120
- options?: {
15121
- query?: PostConsumerLocationsMarketplaceTimeslotsDeliveryQuery;
15122
- } & RequestOptions,
15123
- ): ResponsePromise<PostConsumerLocationsMarketplaceTimeslotsDeliveryResponse> {
15124
- return this.request(
15125
- 'consumer',
15126
- '/consumer/location/marketplace/timeslots/delivery',
15127
- 'POST',
15128
- `/consumer/location/marketplace/timeslots/delivery`,
15129
- body,
15130
- options,
15131
- );
15132
- }
15133
-
15134
15082
  /**
15135
15083
  * DELETE /consumer/user/{id} - Delete user
15136
15084
  *
@@ -15782,49 +15730,21 @@ export class ServiceClient extends BaseServiceClient {
15782
15730
  }
15783
15731
 
15784
15732
  /**
15785
- * GET /consumer/location/brand/{brandId}/timeslots/menu/{menuId} - Get location brand menu timeslots
15733
+ * POST /consumer/location/timeslots - Get timeslots
15786
15734
  *
15787
- * @param brandId - Brand ID as Encoded CDL ID
15788
- * @param menuId - Menu ID as Encoded CDL ID
15735
+ * @param body - Which timeslots to fetch
15789
15736
  * @param options - additional request options
15790
15737
  */
15791
- get_consumer_brand_menu_timeslots(
15792
- brandId: string,
15793
- menuId: string,
15794
- options: {
15795
- query: GetConsumerBrandMenuTimeslotsQuery;
15796
- } & RequestOptions,
15797
- ): ResponsePromise<GetConsumerBrandMenuTimeslotsResponse> {
15798
- return this.request(
15799
- 'consumer',
15800
- '/consumer/location/brand/{brandId}/timeslots/menu/{menuId}',
15801
- 'GET',
15802
- `/consumer/location/brand/${brandId}/timeslots/menu/${menuId}`,
15803
- null,
15804
- options,
15805
- );
15806
- }
15807
-
15808
- /**
15809
- * GET /consumer/location/brand/{brandId}/timeslots/delivery/menu/{menuId} - Get location brand menu delivery timeslots
15810
- *
15811
- * @param brandId - Brand ID as Encoded CDL ID
15812
- * @param menuId - Menu ID as Encoded CDL ID
15813
- * @param options - additional request options
15814
- */
15815
- get_consumer_brand_menu_delivery_timeslots(
15816
- brandId: string,
15817
- menuId: string,
15818
- options: {
15819
- query: GetConsumerBrandMenuDeliveryTimeslotsQuery;
15820
- } & RequestOptions,
15821
- ): ResponsePromise<GetConsumerBrandMenuDeliveryTimeslotsResponse> {
15738
+ post_consumer_timeslots(
15739
+ body: PostConsumerTimeslotsBody$0,
15740
+ options?: RequestOptions,
15741
+ ): ResponsePromise<PostConsumerTimeslotsResponse$0> {
15822
15742
  return this.request(
15823
15743
  'consumer',
15824
- '/consumer/location/brand/{brandId}/timeslots/delivery/menu/{menuId}',
15825
- 'GET',
15826
- `/consumer/location/brand/${brandId}/timeslots/delivery/menu/${menuId}`,
15827
- null,
15744
+ '/consumer/location/timeslots',
15745
+ 'POST',
15746
+ `/consumer/location/timeslots`,
15747
+ body,
15828
15748
  options,
15829
15749
  );
15830
15750
  }
@@ -3015,12 +3015,19 @@ export interface PostConsumerLocationMarketplaceTimeslotsBody {
3015
3015
  }
3016
3016
 
3017
3017
  export interface ConsumerTimeslot {
3018
+ // Timeslot ID (start time as unix seconds)
3018
3019
  id?: number;
3020
+ // The CDL id representing the brand this timeslot belongs to
3019
3021
  brand_id?: string;
3022
+ // Start time of the timeslot as an ISO 8601 string
3020
3023
  start_time?: string;
3024
+ // Duration of the timeslot as HH:mm:ss
3021
3025
  duration?: string;
3026
+ // Whether the timeslot can still accept orders
3022
3027
  is_available?: boolean;
3028
+ // Number of orders already placed in the timeslot
3023
3029
  number_orders?: number;
3030
+ // Delivery destinations served by this timeslot (delivery only)
3024
3031
  delivery_destinations?: string[];
3025
3032
  }
3026
3033
 
@@ -4156,6 +4163,26 @@ export interface GetConsumerLocationBrandMenuDeliveryTimeslotsResponse {
4156
4163
  timeslots?: ConsumerTimeslot[];
4157
4164
  }
4158
4165
 
4166
+ export interface PostConsumerTimeslotsBody {
4167
+ // Fulfillment type of the timeslots. Defaults to pickup.
4168
+ fulfillment?: 'pickup' | 'delivery';
4169
+ // Brand ID as Encoded CDL ID. Use together with `menu` for a single (non-marketplace) brand.
4170
+ brand?: string;
4171
+ // Menu ID as Encoded CDL ID. Use together with `brand`.
4172
+ menu?: string;
4173
+ // Marketplace stations to merge timeslots across. Each station needs a brand. Mutually exclusive with `brand`/`menu`.
4174
+ stations?: ConsumerStation[];
4175
+ // Return timeslots on or after this date, in milliseconds since epoch.
4176
+ date?: number;
4177
+ // Maximum number of timeslots to return.
4178
+ limit?: number;
4179
+ }
4180
+
4181
+ export interface PostConsumerTimeslotsResponse {
4182
+ // Available timeslots
4183
+ timeslots: ConsumerTimeslot[];
4184
+ }
4185
+
4159
4186
  export interface ConsumerPublicMealplanConfig {
4160
4187
  // The mealplan id
4161
4188
  id?: string;
@@ -5227,36 +5254,6 @@ export interface GetConsumerMenuItemsQuery {
5227
5254
 
5228
5255
  export type GetConsumerMenuItemsResponse$0 = GetConsumerMenuItemsResponse;
5229
5256
 
5230
- // POST /consumer/location/marketplace/timeslots - Get Marketplace timeslots
5231
-
5232
- export interface PostConsumerLocationsMarketplaceTimeslotsQuery {
5233
- // Date of the timeslot
5234
- date?: number;
5235
- // Limit the number of timeslots returned
5236
- limit?: number;
5237
- }
5238
-
5239
- export type PostConsumerLocationsMarketplaceTimeslotsBody =
5240
- PostConsumerLocationMarketplaceTimeslotsBody;
5241
-
5242
- export type PostConsumerLocationsMarketplaceTimeslotsResponse =
5243
- PostConsumerLocationMarketplaceTimeslotsResponse;
5244
-
5245
- // POST /consumer/location/marketplace/timeslots/delivery - Get Marketplace timeslots
5246
-
5247
- export interface PostConsumerLocationsMarketplaceTimeslotsDeliveryQuery {
5248
- // Date of the timeslot
5249
- date?: number;
5250
- // Limit the number of timeslots returned
5251
- limit?: number;
5252
- }
5253
-
5254
- export type PostConsumerLocationsMarketplaceTimeslotsDeliveryBody =
5255
- PostConsumerLocationMarketplaceTimeslotsDeliveryBody;
5256
-
5257
- export type PostConsumerLocationsMarketplaceTimeslotsDeliveryResponse =
5258
- PostConsumerLocationMarketplaceTimeslotsDeliveryResponse;
5259
-
5260
5257
  // DELETE /consumer/user/{id} - Delete user
5261
5258
 
5262
5259
  export interface DeleteConsumerUserPath {
@@ -5561,38 +5558,11 @@ export interface GetConsumerAppThemePath {
5561
5558
 
5562
5559
  export type GetConsumerAppThemeResponse = GetAppThemeResponse;
5563
5560
 
5564
- // GET /consumer/location/brand/{brandId}/timeslots/menu/{menuId} - Get location brand menu timeslots
5565
-
5566
- export interface GetConsumerBrandMenuTimeslotsPath {
5567
- // Brand ID as Encoded CDL ID
5568
- brandId: string;
5569
- // Menu ID as Encoded CDL ID
5570
- menuId: string;
5571
- }
5572
-
5573
- export interface GetConsumerBrandMenuTimeslotsQuery {
5574
- // Date in milliseconds
5575
- date: number;
5576
- }
5577
-
5578
- export type GetConsumerBrandMenuTimeslotsResponse = GetConsumerLocationBrandMenuTimeslotsResponse;
5579
-
5580
- // GET /consumer/location/brand/{brandId}/timeslots/delivery/menu/{menuId} - Get location brand menu delivery timeslots
5581
-
5582
- export interface GetConsumerBrandMenuDeliveryTimeslotsPath {
5583
- // Brand ID as Encoded CDL ID
5584
- brandId: string;
5585
- // Menu ID as Encoded CDL ID
5586
- menuId: string;
5587
- }
5561
+ // POST /consumer/location/timeslots - Get timeslots
5588
5562
 
5589
- export interface GetConsumerBrandMenuDeliveryTimeslotsQuery {
5590
- // Date in milliseconds
5591
- date: number;
5592
- }
5563
+ export type PostConsumerTimeslotsBody$0 = PostConsumerTimeslotsBody;
5593
5564
 
5594
- export type GetConsumerBrandMenuDeliveryTimeslotsResponse =
5595
- GetConsumerLocationBrandMenuDeliveryTimeslotsResponse;
5565
+ export type PostConsumerTimeslotsResponse$0 = PostConsumerTimeslotsResponse;
5596
5566
 
5597
5567
  // GET /consumer/config/public/{id} - Get consumer public config
5598
5568