@compassdigital/sdk.typescript 4.649.0 → 4.651.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.
@@ -2249,13 +2249,24 @@ export interface GetMenuItemNutritionValueConsumerV2 {
2249
2249
  display?: string;
2250
2250
  }
2251
2251
 
2252
+ export interface GetMenuItemNutrientConsumerV2 {
2253
+ // Nutrient key for FE localization (e.g. total_fat, added_sugars)
2254
+ key: string;
2255
+ // Unit of measurement
2256
+ unit?: string;
2257
+ // Formatted display value (e.g. "8 g")
2258
+ display?: string;
2259
+ // Indent level for FDA label layout (0 = primary, 1 = sub-nutrient, 2 = sub-sub-nutrient)
2260
+ indent: number;
2261
+ }
2262
+
2252
2263
  export interface GetMenuItemNutritionConsumerV2 {
2253
- // Deprecated calorie value in kcal
2254
- kcal?: number;
2255
- // Calories
2256
- calories?: GetMenuItemNutritionValueConsumerV2;
2257
2264
  // Serving size
2258
2265
  serving_size?: GetMenuItemNutritionValueConsumerV2;
2266
+ // Calories
2267
+ calories?: GetMenuItemNutritionValueConsumerV2;
2268
+ // Deprecated calorie value in kcal
2269
+ kcal?: number;
2259
2270
  // Total fat
2260
2271
  total_fat?: GetMenuItemNutritionValueConsumerV2;
2261
2272
  // Saturated fat
@@ -2270,10 +2281,12 @@ export interface GetMenuItemNutritionConsumerV2 {
2270
2281
  total_carbohydrate?: GetMenuItemNutritionValueConsumerV2;
2271
2282
  // Dietary fiber
2272
2283
  dietary_fiber?: GetMenuItemNutritionValueConsumerV2;
2273
- // Sugars
2274
- sugars?: GetMenuItemNutritionValueConsumerV2;
2275
2284
  // Total sugars
2276
2285
  total_sugars?: GetMenuItemNutritionValueConsumerV2;
2286
+ // Added sugars
2287
+ added_sugars?: GetMenuItemNutritionValueConsumerV2;
2288
+ // Sugars
2289
+ sugars?: GetMenuItemNutritionValueConsumerV2;
2277
2290
  // Protein
2278
2291
  protein?: GetMenuItemNutritionValueConsumerV2;
2279
2292
  // Well-being score
@@ -2589,8 +2602,10 @@ export interface GetMenuItemConsumerV2 {
2589
2602
  ingredients?: Record<string, any>[];
2590
2603
  // Amount off exclusion types
2591
2604
  amount_off_exclusions?: string[];
2592
- // Item nutrition
2605
+ // @deprecated
2593
2606
  nutrition?: GetMenuItemNutritionConsumerV2;
2607
+ // Ordered nutrition breakdown for display, following FDA Nutrition Facts label order and indentation
2608
+ ordered_nutrition?: GetMenuItemNutrientConsumerV2[];
2594
2609
  // Food certifications like vegan, organic, etc
2595
2610
  certified?: GetMenuItemCertifiedConsumerV2;
2596
2611
  // Item options/modifiers
@@ -311,6 +311,22 @@ export interface UserMeta {
311
311
  [index: string]: any;
312
312
  }
313
313
 
314
+ export interface UserLogEntry {
315
+ eventId?: string;
316
+ userId?: string;
317
+ actorId?: string;
318
+ actorType?: 'human' | 'internal' | 'external';
319
+ changedAt?: string;
320
+ message?: string;
321
+ meta?: Record<string, any>;
322
+ expiresAt?: number;
323
+ }
324
+
325
+ export interface GetUserLogsResponse {
326
+ logs?: UserLogEntry[];
327
+ meta?: Pagination;
328
+ }
329
+
314
330
  export interface Pagination {
315
331
  last_key?: string;
316
332
  count?: number;
@@ -544,6 +560,17 @@ export interface PostUserChangePasswordRequest extends BaseRequest, PostUserChan
544
560
  body: PostUserChangePasswordBody;
545
561
  }
546
562
 
563
+ // GET /user/logs - Get audit log entries (up to 1000 per page; use last_key cursor to paginate)
564
+
565
+ export interface GetUserLogsQuery {
566
+ // Cursor from the previous response's meta.last_key
567
+ last_key?: string;
568
+ }
569
+
570
+ export type GetUserLogsResponse$0 = GetUserLogsResponse;
571
+
572
+ export interface GetUserLogsRequest extends BaseRequest, RequestQuery<GetUserLogsQuery> {}
573
+
547
574
  // DELETE /user/logout - Logs out current user
548
575
 
549
576
  export type DeleteUserLogoutResponse = success;