@compassdigital/sdk.typescript 4.108.0 → 4.109.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
@@ -296,8 +296,12 @@ import {
296
296
  GetPromoCompanyLocationGroupResponse,
297
297
  PostPromoValidateVoucherBody,
298
298
  PostPromoValidateVoucherResponse,
299
+ PostPromoValidateVouchersBody,
300
+ PostPromoValidateVouchersResponse,
299
301
  PostPromoRedeemVoucherBody,
300
302
  PostPromoRedeemVoucherResponse,
303
+ PostPromoRedeemVouchersBody,
304
+ PostPromoRedeemVouchersResponse,
301
305
  PostPromoVoucherBody,
302
306
  PostPromoVoucherResponse,
303
307
  PutPromoVoucherBody,
@@ -1054,19 +1058,6 @@ import {
1054
1058
  PostFrictionlessAmazonJwoConnectorV1OrderPurchasesResponse,
1055
1059
  } from './interface/frictionless';
1056
1060
 
1057
- import {
1058
- HealthCheckControllerExecuteQuery,
1059
- HealthCheckControllerExecuteResponse,
1060
- GetPaymentListByBrandQuery,
1061
- GetPaymentListByBrandResponse,
1062
- GetCustomerOrdersQuery,
1063
- GetCustomerOrdersResponse,
1064
- PostReviewOrderItemsBody,
1065
- PostReviewOrderItemsResponse,
1066
- PostHomePageBody,
1067
- PostHomePageResponse,
1068
- } from './interface/consumer';
1069
-
1070
1061
  import {
1071
1062
  PostAiLanguageGenerateBody,
1072
1063
  PostAiLanguageGenerateResponse,
@@ -1096,14 +1087,18 @@ import {
1096
1087
  GetSiteDevicesResponse,
1097
1088
  GetCentricosSitesQuery,
1098
1089
  GetCentricosSitesResponse,
1090
+ GetSitesFromPriceLevelQuery,
1091
+ GetSitesFromPriceLevelResponse,
1099
1092
  GetReviewOrderItemsQuery,
1100
1093
  GetReviewOrderItemsResponse,
1101
1094
  GetCentricosStationQuery,
1102
1095
  GetCentricosStationResponse,
1103
- PutDiscountVoucherifyBody,
1104
- PutDiscountVoucherifyResponse,
1105
- PutDiscountVoucherifyPublishBody,
1106
- PutDiscountVoucherifyPublishResponse,
1096
+ PutCentricosDiscountVoucherifyBody,
1097
+ PutCentricosDiscountVoucherifyResponse,
1098
+ PutCentricosDiscountVoucherifyPublishResponse,
1099
+ DeleteCentricosDiscountsVoucherifyResponse,
1100
+ GetCentricosDiscountQuery,
1101
+ GetCentricosDiscountResponse,
1107
1102
  } from './interface/centricos';
1108
1103
 
1109
1104
  import {
@@ -3708,6 +3703,26 @@ export class ServiceClient extends BaseServiceClient {
3708
3703
  );
3709
3704
  }
3710
3705
 
3706
+ /**
3707
+ * POST /promo/validate/vouchers - Validate multiple promo vouchers
3708
+ *
3709
+ * @param body
3710
+ * @param options - additional request options
3711
+ */
3712
+ post_promo_validate_vouchers(
3713
+ body: PostPromoValidateVouchersBody,
3714
+ options?: RequestOptions,
3715
+ ): ResponsePromise<PostPromoValidateVouchersResponse> {
3716
+ return this.request(
3717
+ 'promo',
3718
+ '/promo/validate/vouchers',
3719
+ 'post',
3720
+ `/promo/validate/vouchers`,
3721
+ body,
3722
+ options,
3723
+ );
3724
+ }
3725
+
3711
3726
  /**
3712
3727
  * POST /promo/redeem/voucher - Redeem a promo voucher
3713
3728
  *
@@ -3728,6 +3743,26 @@ export class ServiceClient extends BaseServiceClient {
3728
3743
  );
3729
3744
  }
3730
3745
 
3746
+ /**
3747
+ * POST /promo/redeem/vouchers - Redeem multiple promo vouchers
3748
+ *
3749
+ * @param body
3750
+ * @param options - additional request options
3751
+ */
3752
+ post_promo_redeem_vouchers(
3753
+ body: PostPromoRedeemVouchersBody,
3754
+ options?: RequestOptions,
3755
+ ): ResponsePromise<PostPromoRedeemVouchersResponse> {
3756
+ return this.request(
3757
+ 'promo',
3758
+ '/promo/redeem/vouchers',
3759
+ 'post',
3760
+ `/promo/redeem/vouchers`,
3761
+ body,
3762
+ options,
3763
+ );
3764
+ }
3765
+
3731
3766
  /**
3732
3767
  * POST /promo/voucher - Create new voucher
3733
3768
  *
@@ -11167,101 +11202,6 @@ export class ServiceClient extends BaseServiceClient {
11167
11202
  );
11168
11203
  }
11169
11204
 
11170
- /**
11171
- * GET /consumer/v1/health-check
11172
- *
11173
- * @param options - additional request options
11174
- */
11175
- HealthCheckController_execute(
11176
- options?: {
11177
- query?: HealthCheckControllerExecuteQuery;
11178
- } & RequestOptions,
11179
- ): ResponsePromise<HealthCheckControllerExecuteResponse> {
11180
- return this.request(
11181
- 'consumer',
11182
- '/consumer/v1/health-check',
11183
- 'get',
11184
- `/consumer/v1/health-check`,
11185
- null,
11186
- options,
11187
- );
11188
- }
11189
-
11190
- /**
11191
- * GET /consumer/v1/payment-methods - List payment methods available in a given brand
11192
- *
11193
- * @param options - additional request options
11194
- */
11195
- get_payment_list_by_brand(
11196
- options?: {
11197
- query?: GetPaymentListByBrandQuery;
11198
- } & RequestOptions,
11199
- ): ResponsePromise<GetPaymentListByBrandResponse> {
11200
- return this.request(
11201
- 'consumer',
11202
- '/consumer/v1/payment-methods',
11203
- 'get',
11204
- `/consumer/v1/payment-methods`,
11205
- null,
11206
- options,
11207
- );
11208
- }
11209
-
11210
- /**
11211
- * GET /consumer/customer-orders/{userId} - Get customer orders
11212
- *
11213
- * @param userId - a valid CDL user id
11214
- * @param options - additional request options
11215
- */
11216
- get_customer_orders(
11217
- userId: string,
11218
- options?: {
11219
- query?: GetCustomerOrdersQuery;
11220
- } & RequestOptions,
11221
- ): ResponsePromise<GetCustomerOrdersResponse> {
11222
- return this.request(
11223
- 'consumer',
11224
- '/consumer/customer-orders/{userId}',
11225
- 'get',
11226
- `/consumer/customer-orders/${userId}`,
11227
- null,
11228
- options,
11229
- );
11230
- }
11231
-
11232
- /**
11233
- * POST /consumer/review/order-items - Submit reviews for order items
11234
- *
11235
- * @param body
11236
- * @param options - additional request options
11237
- */
11238
- post_review_order_items(
11239
- body: PostReviewOrderItemsBody,
11240
- options?: RequestOptions,
11241
- ): ResponsePromise<PostReviewOrderItemsResponse> {
11242
- return this.request(
11243
- 'consumer',
11244
- '/consumer/review/order-items',
11245
- 'post',
11246
- `/consumer/review/order-items`,
11247
- body,
11248
- options,
11249
- );
11250
- }
11251
-
11252
- /**
11253
- * POST /consumer/home - Provide the front end all the data required to render the home page
11254
- *
11255
- * @param body
11256
- * @param options - additional request options
11257
- */
11258
- post_home_page(
11259
- body: PostHomePageBody,
11260
- options?: RequestOptions,
11261
- ): ResponsePromise<PostHomePageResponse> {
11262
- return this.request('consumer', '/consumer/home', 'post', `/consumer/home`, body, options);
11263
- }
11264
-
11265
11205
  /**
11266
11206
  * POST /ai/language/generate - Generate text from a given prompt
11267
11207
  *
@@ -11371,7 +11311,7 @@ export class ServiceClient extends BaseServiceClient {
11371
11311
  /**
11372
11312
  * GET /centricos/report/group/{location_group}/config - Get report configuration for a location group. Times are in site's local timezone.
11373
11313
  *
11374
- * @param location_group - TODO: add parameter to swagger.json
11314
+ * @param location_group - TODO: cannot use CompassLongID as path parameter
11375
11315
  * @param options - additional request options
11376
11316
  */
11377
11317
  get_centricos_report_group_config(
@@ -11393,7 +11333,7 @@ export class ServiceClient extends BaseServiceClient {
11393
11333
  /**
11394
11334
  * PUT /centricos/report/group/{location_group}/config - Update report configuration for a location group. Times are in site's local timezone.
11395
11335
  *
11396
- * @param location_group - TODO: add parameter to swagger.json
11336
+ * @param location_group - TODO: cannot use CompassLongID as path parameter
11397
11337
  * @param body
11398
11338
  * @param options - additional request options
11399
11339
  */
@@ -11415,7 +11355,7 @@ export class ServiceClient extends BaseServiceClient {
11415
11355
  /**
11416
11356
  * DELETE /centricos/report/group/{location_group}/config - Delete report configuration for a location group. Times are in site's local timezone.
11417
11357
  *
11418
- * @param location_group - TODO: add parameter to swagger.json
11358
+ * @param location_group - TODO: cannot use CompassLongID as path parameter
11419
11359
  * @param options - additional request options
11420
11360
  */
11421
11361
  delete_centricos_report_group_config(
@@ -11435,7 +11375,7 @@ export class ServiceClient extends BaseServiceClient {
11435
11375
  /**
11436
11376
  * GET /centricos/report/group/{location_group}/config/default - Get default report configuration. Times are in site's local timezone.
11437
11377
  *
11438
- * @param location_group - TODO: add parameter to swagger.json
11378
+ * @param location_group - TODO: cannot use CompassLongID as path parameter
11439
11379
  * @param options - additional request options
11440
11380
  */
11441
11381
  get_centricos_report_config_default(
@@ -11509,6 +11449,28 @@ export class ServiceClient extends BaseServiceClient {
11509
11449
  return this.request('centricos', '/centricos/sites', 'get', `/centricos/sites`, null, options);
11510
11450
  }
11511
11451
 
11452
+ /**
11453
+ * GET /centricos/sites/price-level/{price_level} - This returns specific properties from sites, locations, and stations connected to a menu price level. This does not support pagination, filtering, sorting, or searching.
11454
+ *
11455
+ * @param price_level - TODO: cannot use CompassLongID as path parameter
11456
+ * @param options - additional request options
11457
+ */
11458
+ get_sites_from_price_level(
11459
+ price_level: string,
11460
+ options?: {
11461
+ query?: GetSitesFromPriceLevelQuery;
11462
+ } & RequestOptions,
11463
+ ): ResponsePromise<GetSitesFromPriceLevelResponse> {
11464
+ return this.request(
11465
+ 'centricos',
11466
+ '/centricos/sites/price-level/{price_level}',
11467
+ 'get',
11468
+ `/centricos/sites/price-level/${price_level}`,
11469
+ null,
11470
+ options,
11471
+ );
11472
+ }
11473
+
11512
11474
  /**
11513
11475
  * GET /centricos/review/{orderId}/order-items - Get reviews for items in a given order in an array format
11514
11476
  *
@@ -11534,7 +11496,7 @@ export class ServiceClient extends BaseServiceClient {
11534
11496
  /**
11535
11497
  * GET /centricos/station/{station_id} - Get station details
11536
11498
  *
11537
- * @param station_id - TODO: add parameter to swagger.json
11499
+ * @param station_id - TODO: cannot use CompassLongID as path parameter
11538
11500
  * @param options - additional request options
11539
11501
  */
11540
11502
  get_centricos_station(
@@ -11559,10 +11521,10 @@ export class ServiceClient extends BaseServiceClient {
11559
11521
  * @param body
11560
11522
  * @param options - additional request options
11561
11523
  */
11562
- put_discount_voucherify(
11563
- body: PutDiscountVoucherifyBody,
11524
+ put_centricos_discount_voucherify(
11525
+ body: PutCentricosDiscountVoucherifyBody,
11564
11526
  options?: RequestOptions,
11565
- ): ResponsePromise<PutDiscountVoucherifyResponse> {
11527
+ ): ResponsePromise<PutCentricosDiscountVoucherifyResponse> {
11566
11528
  return this.request(
11567
11529
  'centricos',
11568
11530
  '/centricos/discount/voucherify',
@@ -11577,20 +11539,60 @@ export class ServiceClient extends BaseServiceClient {
11577
11539
  * PUT /centricos/discount/{id}/voucherify/publish - Update and publish a voucherify discount and assign it to multiple sites
11578
11540
  *
11579
11541
  * @param id - Discount ID
11580
- * @param body
11581
11542
  * @param options - additional request options
11582
11543
  */
11583
- put_discount_voucherify_publish(
11544
+ put_centricos_discount_voucherify_publish(
11584
11545
  id: string,
11585
- body: PutDiscountVoucherifyPublishBody,
11586
11546
  options?: RequestOptions,
11587
- ): ResponsePromise<PutDiscountVoucherifyPublishResponse> {
11547
+ ): ResponsePromise<PutCentricosDiscountVoucherifyPublishResponse> {
11588
11548
  return this.request(
11589
11549
  'centricos',
11590
11550
  '/centricos/discount/{id}/voucherify/publish',
11591
11551
  'put',
11592
11552
  `/centricos/discount/${id}/voucherify/publish`,
11593
- body,
11553
+ null,
11554
+ options,
11555
+ );
11556
+ }
11557
+
11558
+ /**
11559
+ * DELETE /centricos/discount/{id}/voucherify - Delete a discount from voucherify and all of its entity associations
11560
+ *
11561
+ * @param id - Discount ID
11562
+ * @param options - additional request options
11563
+ */
11564
+ delete_centricos_discounts_voucherify(
11565
+ id: string,
11566
+ options?: RequestOptions,
11567
+ ): ResponsePromise<DeleteCentricosDiscountsVoucherifyResponse> {
11568
+ return this.request(
11569
+ 'centricos',
11570
+ '/centricos/discount/{id}/voucherify',
11571
+ 'delete',
11572
+ `/centricos/discount/${id}/voucherify`,
11573
+ null,
11574
+ options,
11575
+ );
11576
+ }
11577
+
11578
+ /**
11579
+ * GET /centricos/discount/{id} - Get discount information by ID
11580
+ *
11581
+ * @param id - ID of the discount to retrieve
11582
+ * @param options - additional request options
11583
+ */
11584
+ get_centricos_discount(
11585
+ id: string,
11586
+ options?: {
11587
+ query?: GetCentricosDiscountQuery;
11588
+ } & RequestOptions,
11589
+ ): ResponsePromise<GetCentricosDiscountResponse> {
11590
+ return this.request(
11591
+ 'centricos',
11592
+ '/centricos/discount/{id}',
11593
+ 'get',
11594
+ `/centricos/discount/${id}`,
11595
+ null,
11594
11596
  options,
11595
11597
  );
11596
11598
  }
@@ -11809,7 +11811,7 @@ export class ServiceClient extends BaseServiceClient {
11809
11811
  /**
11810
11812
  * GET /discount/{id} - Get a discount
11811
11813
  *
11812
- * @param id
11814
+ * @param id - a discount id
11813
11815
  * @param options - additional request options
11814
11816
  */
11815
11817
  get_discount(
@@ -19,6 +19,12 @@ export interface SSOFlowResponseDTO {
19
19
  oidc?: OIDC;
20
20
  }
21
21
 
22
+ export interface UnauthorizedErrorDTO {
23
+ message: string;
24
+ code: number;
25
+ data: Record<string, any>;
26
+ }
27
+
22
28
  export interface SSOMapping {
23
29
  id: string;
24
30
  given_name: string;