@compassdigital/sdk.typescript 4.418.0 → 4.419.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.418.0",
3
+ "version": "4.419.0",
4
4
  "description": "Compass Digital Labs TypeScript SDK",
5
5
  "type": "commonjs",
6
6
  "main": "./lib/index.js",
@@ -58,7 +58,7 @@
58
58
  },
59
59
  "devDependencies": {
60
60
  "@compassdigital/review": "^7.6.3",
61
- "@compassdigital/sdk.typescript.cli": "^4.55.0",
61
+ "@compassdigital/sdk.typescript.cli": "^4.56.0",
62
62
  "@swc/core": "^1.4.1",
63
63
  "@swc/jest": "^0.2.36",
64
64
  "@types/jest": "^30.0.0",
package/pipeline.yml CHANGED
@@ -2,6 +2,7 @@ name: npm-typescript-sdk
2
2
 
3
3
  flags:
4
4
  - DEPENDABOT
5
+ - P4_V2_TOOLS
5
6
 
6
7
  test:
7
8
  commands:
package/src/base.ts CHANGED
@@ -15,6 +15,8 @@ export interface RequestOptions {
15
15
  retry?: number;
16
16
  // timeout in milliseconds
17
17
  timeout?: number;
18
+ // abort signal to cancel the request
19
+ signal?: AbortSignal;
18
20
  // make requests against this base url.
19
21
  // per-service base urls are configured as an object
20
22
  // eg. { order: 'http://localhost:3000', shoppingcart: 'http://localhost:4000' }
@@ -446,11 +448,10 @@ export abstract class BaseServiceClient {
446
448
  return options.intercept(req, this.fetch.bind(this));
447
449
  }
448
450
  try {
449
- let signal: AbortSignal | undefined;
451
+ let signal = options?.signal;
450
452
  if (options?.timeout) {
451
- const controller = new AbortController();
452
- setTimeout(() => controller.abort('timeout'), options.timeout);
453
- signal = controller.signal;
453
+ const timeoutSignal = AbortSignal.timeout(options.timeout);
454
+ signal = signal ? AbortSignal.any([signal, timeoutSignal]) : timeoutSignal;
454
455
  }
455
456
  const res = await fetch(req.url, {
456
457
  method: req.method,
package/src/index.ts CHANGED
@@ -4624,12 +4624,12 @@ export class ServiceClient extends BaseServiceClient {
4624
4624
  }
4625
4625
 
4626
4626
  /**
4627
- * GET /ping - Config Service liveness check
4627
+ * GET /config/ping - Config Service liveness check
4628
4628
  *
4629
4629
  * @param options - additional request options
4630
4630
  */
4631
4631
  get_config_ping(options?: RequestOptions): ResponsePromise<GetConfigPingResponse> {
4632
- return this.request('config', '/ping', 'GET', `/ping`, null, options);
4632
+ return this.request('config', '/config/ping', 'GET', `/config/ping`, null, options);
4633
4633
  }
4634
4634
 
4635
4635
  /**
@@ -300,7 +300,7 @@ export type DeleteConfigPublicResponse = Success;
300
300
 
301
301
  export interface DeleteConfigPublicRequest extends BaseRequest, DeleteConfigPublicPath {}
302
302
 
303
- // GET /ping - Config Service liveness check
303
+ // GET /config/ping - Config Service liveness check
304
304
 
305
305
  export type GetConfigPingResponse = PingResponse;
306
306
 
@@ -221,6 +221,9 @@ export interface Brand {
221
221
  agilysys_dod?: {
222
222
  enabled?: boolean;
223
223
  };
224
+ transact?: {
225
+ enabled?: boolean;
226
+ };
224
227
  };
225
228
  type_of_kds?: {
226
229
  cdl?: boolean;
@@ -54,6 +54,13 @@ export interface Menu {
54
54
  };
55
55
  [index: string]: any;
56
56
  };
57
+ image?: {
58
+ src?: string;
59
+ sizes?: {
60
+ original?: string;
61
+ thumbnail_80_80?: string;
62
+ };
63
+ };
57
64
  }
58
65
 
59
66
  export interface Nutrition {
@@ -169,6 +176,13 @@ export interface Item {
169
176
  smart_tags?: string[];
170
177
  // menuworks allergen tags
171
178
  allergen_tags?: string[];
179
+ // menuworks allergens with contains field
180
+ allergens?: {
181
+ // allergen name
182
+ name?: string;
183
+ // allergen contains status: 'Yes' or 'AtRisk'
184
+ contains?: 'Yes' | 'AtRisk';
185
+ }[];
172
186
  };
173
187
  // unique id of the entity
174
188
  unique_id?: number;
@@ -325,6 +339,13 @@ export interface Option {
325
339
  smart_tags?: string[];
326
340
  // menuworks allergen tags
327
341
  allergen_tags?: string[];
342
+ // menuworks allergens with contains field
343
+ allergens?: {
344
+ // allergen name
345
+ name?: string;
346
+ // allergen contains status: 'Yes' or 'AtRisk'
347
+ contains?: 'Yes' | 'AtRisk';
348
+ }[];
328
349
  };
329
350
  // unique id of the entity
330
351
  unique_id?: number;