@beorchid-llc/thrivo-contracts 0.5.5 → 0.6.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/dist/metrics.d.ts CHANGED
@@ -6,27 +6,115 @@ export declare const waterQuerySchema: z.ZodObject<{
6
6
  }, {
7
7
  date: string;
8
8
  }>;
9
+ export declare const waterEntrySchema: z.ZodObject<{
10
+ id: z.ZodString;
11
+ amountMl: z.ZodNumber;
12
+ day: z.ZodString;
13
+ recordedAt: z.ZodString;
14
+ }, "strip", z.ZodTypeAny, {
15
+ id: string;
16
+ day: string;
17
+ amountMl: number;
18
+ recordedAt: string;
19
+ }, {
20
+ id: string;
21
+ day: string;
22
+ amountMl: number;
23
+ recordedAt: string;
24
+ }>;
25
+ export type WaterEntry = z.infer<typeof waterEntrySchema>;
26
+ export declare const hydrationAlertSchema: z.ZodObject<{
27
+ title: z.ZodString;
28
+ message: z.ZodString;
29
+ severity: z.ZodEnum<["info", "warning"]>;
30
+ }, "strip", z.ZodTypeAny, {
31
+ message: string;
32
+ title: string;
33
+ severity: "info" | "warning";
34
+ }, {
35
+ message: string;
36
+ title: string;
37
+ severity: "info" | "warning";
38
+ }>;
39
+ export type HydrationAlert = z.infer<typeof hydrationAlertSchema>;
9
40
  export declare const waterSchema: z.ZodObject<{
10
41
  day: z.ZodString;
11
42
  totalMl: z.ZodNumber;
12
43
  targetMl: z.ZodNumber;
44
+ remainingMl: z.ZodNumber;
45
+ progressPercent: z.ZodNumber;
13
46
  glassMl: z.ZodNumber;
14
47
  glasses: z.ZodNumber;
15
48
  targetGlasses: z.ZodNumber;
49
+ entries: z.ZodArray<z.ZodObject<{
50
+ id: z.ZodString;
51
+ amountMl: z.ZodNumber;
52
+ day: z.ZodString;
53
+ recordedAt: z.ZodString;
54
+ }, "strip", z.ZodTypeAny, {
55
+ id: string;
56
+ day: string;
57
+ amountMl: number;
58
+ recordedAt: string;
59
+ }, {
60
+ id: string;
61
+ day: string;
62
+ amountMl: number;
63
+ recordedAt: string;
64
+ }>, "many">;
65
+ alert: z.ZodNullable<z.ZodObject<{
66
+ title: z.ZodString;
67
+ message: z.ZodString;
68
+ severity: z.ZodEnum<["info", "warning"]>;
69
+ }, "strip", z.ZodTypeAny, {
70
+ message: string;
71
+ title: string;
72
+ severity: "info" | "warning";
73
+ }, {
74
+ message: string;
75
+ title: string;
76
+ severity: "info" | "warning";
77
+ }>>;
16
78
  }, "strip", z.ZodTypeAny, {
79
+ entries: {
80
+ id: string;
81
+ day: string;
82
+ amountMl: number;
83
+ recordedAt: string;
84
+ }[];
17
85
  day: string;
18
86
  totalMl: number;
19
87
  targetMl: number;
88
+ remainingMl: number;
89
+ progressPercent: number;
20
90
  glassMl: number;
21
91
  glasses: number;
22
92
  targetGlasses: number;
93
+ alert: {
94
+ message: string;
95
+ title: string;
96
+ severity: "info" | "warning";
97
+ } | null;
23
98
  }, {
99
+ entries: {
100
+ id: string;
101
+ day: string;
102
+ amountMl: number;
103
+ recordedAt: string;
104
+ }[];
24
105
  day: string;
25
106
  totalMl: number;
26
107
  targetMl: number;
108
+ remainingMl: number;
109
+ progressPercent: number;
27
110
  glassMl: number;
28
111
  glasses: number;
29
112
  targetGlasses: number;
113
+ alert: {
114
+ message: string;
115
+ title: string;
116
+ severity: "info" | "warning";
117
+ } | null;
30
118
  }>;
31
119
  export type Water = z.infer<typeof waterSchema>;
32
120
  export declare const waterResponseSchema: z.ZodObject<{
@@ -36,41 +124,124 @@ export declare const waterResponseSchema: z.ZodObject<{
36
124
  day: z.ZodString;
37
125
  totalMl: z.ZodNumber;
38
126
  targetMl: z.ZodNumber;
127
+ remainingMl: z.ZodNumber;
128
+ progressPercent: z.ZodNumber;
39
129
  glassMl: z.ZodNumber;
40
130
  glasses: z.ZodNumber;
41
131
  targetGlasses: z.ZodNumber;
132
+ entries: z.ZodArray<z.ZodObject<{
133
+ id: z.ZodString;
134
+ amountMl: z.ZodNumber;
135
+ day: z.ZodString;
136
+ recordedAt: z.ZodString;
137
+ }, "strip", z.ZodTypeAny, {
138
+ id: string;
139
+ day: string;
140
+ amountMl: number;
141
+ recordedAt: string;
142
+ }, {
143
+ id: string;
144
+ day: string;
145
+ amountMl: number;
146
+ recordedAt: string;
147
+ }>, "many">;
148
+ alert: z.ZodNullable<z.ZodObject<{
149
+ title: z.ZodString;
150
+ message: z.ZodString;
151
+ severity: z.ZodEnum<["info", "warning"]>;
152
+ }, "strip", z.ZodTypeAny, {
153
+ message: string;
154
+ title: string;
155
+ severity: "info" | "warning";
156
+ }, {
157
+ message: string;
158
+ title: string;
159
+ severity: "info" | "warning";
160
+ }>>;
42
161
  }, "strip", z.ZodTypeAny, {
162
+ entries: {
163
+ id: string;
164
+ day: string;
165
+ amountMl: number;
166
+ recordedAt: string;
167
+ }[];
43
168
  day: string;
44
169
  totalMl: number;
45
170
  targetMl: number;
171
+ remainingMl: number;
172
+ progressPercent: number;
46
173
  glassMl: number;
47
174
  glasses: number;
48
175
  targetGlasses: number;
176
+ alert: {
177
+ message: string;
178
+ title: string;
179
+ severity: "info" | "warning";
180
+ } | null;
49
181
  }, {
182
+ entries: {
183
+ id: string;
184
+ day: string;
185
+ amountMl: number;
186
+ recordedAt: string;
187
+ }[];
50
188
  day: string;
51
189
  totalMl: number;
52
190
  targetMl: number;
191
+ remainingMl: number;
192
+ progressPercent: number;
53
193
  glassMl: number;
54
194
  glasses: number;
55
195
  targetGlasses: number;
196
+ alert: {
197
+ message: string;
198
+ title: string;
199
+ severity: "info" | "warning";
200
+ } | null;
56
201
  }>;
57
202
  }, "strip", z.ZodTypeAny, {
58
203
  water: {
204
+ entries: {
205
+ id: string;
206
+ day: string;
207
+ amountMl: number;
208
+ recordedAt: string;
209
+ }[];
59
210
  day: string;
60
211
  totalMl: number;
61
212
  targetMl: number;
213
+ remainingMl: number;
214
+ progressPercent: number;
62
215
  glassMl: number;
63
216
  glasses: number;
64
217
  targetGlasses: number;
218
+ alert: {
219
+ message: string;
220
+ title: string;
221
+ severity: "info" | "warning";
222
+ } | null;
65
223
  };
66
224
  }, {
67
225
  water: {
226
+ entries: {
227
+ id: string;
228
+ day: string;
229
+ amountMl: number;
230
+ recordedAt: string;
231
+ }[];
68
232
  day: string;
69
233
  totalMl: number;
70
234
  targetMl: number;
235
+ remainingMl: number;
236
+ progressPercent: number;
71
237
  glassMl: number;
72
238
  glasses: number;
73
239
  targetGlasses: number;
240
+ alert: {
241
+ message: string;
242
+ title: string;
243
+ severity: "info" | "warning";
244
+ } | null;
74
245
  };
75
246
  }>;
76
247
  responseCode: z.ZodNumber;
@@ -81,12 +252,25 @@ export declare const waterResponseSchema: z.ZodObject<{
81
252
  responseCode: number;
82
253
  data: {
83
254
  water: {
255
+ entries: {
256
+ id: string;
257
+ day: string;
258
+ amountMl: number;
259
+ recordedAt: string;
260
+ }[];
84
261
  day: string;
85
262
  totalMl: number;
86
263
  targetMl: number;
264
+ remainingMl: number;
265
+ progressPercent: number;
87
266
  glassMl: number;
88
267
  glasses: number;
89
268
  targetGlasses: number;
269
+ alert: {
270
+ message: string;
271
+ title: string;
272
+ severity: "info" | "warning";
273
+ } | null;
90
274
  };
91
275
  };
92
276
  }, {
@@ -95,12 +279,25 @@ export declare const waterResponseSchema: z.ZodObject<{
95
279
  responseCode: number;
96
280
  data: {
97
281
  water: {
282
+ entries: {
283
+ id: string;
284
+ day: string;
285
+ amountMl: number;
286
+ recordedAt: string;
287
+ }[];
98
288
  day: string;
99
289
  totalMl: number;
100
290
  targetMl: number;
291
+ remainingMl: number;
292
+ progressPercent: number;
101
293
  glassMl: number;
102
294
  glasses: number;
103
295
  targetGlasses: number;
296
+ alert: {
297
+ message: string;
298
+ title: string;
299
+ severity: "info" | "warning";
300
+ } | null;
104
301
  };
105
302
  };
106
303
  }>;
@@ -115,7 +312,718 @@ export declare const addWaterPayloadSchema: z.ZodObject<{
115
312
  amountMl: number;
116
313
  }>;
117
314
  export type AddWaterPayload = z.infer<typeof addWaterPayloadSchema>;
315
+ export declare const deleteWaterParamsSchema: z.ZodObject<{
316
+ id: z.ZodString;
317
+ }, "strip", z.ZodTypeAny, {
318
+ id: string;
319
+ }, {
320
+ id: string;
321
+ }>;
322
+ export declare const chartMetricSchema: z.ZodEnum<["calories", "water", "weight"]>;
323
+ export type ChartMetric = z.infer<typeof chartMetricSchema>;
324
+ export declare const chartPeriodSchema: z.ZodEnum<["7d", "14d", "1m", "1q", "6m", "1y", "all"]>;
325
+ export type ChartPeriod = z.infer<typeof chartPeriodSchema>;
326
+ export declare const progressQuerySchema: z.ZodObject<{
327
+ date: z.ZodString;
328
+ }, "strip", z.ZodTypeAny, {
329
+ date: string;
330
+ }, {
331
+ date: string;
332
+ }>;
333
+ export declare const chartQuerySchema: z.ZodObject<{
334
+ date: z.ZodString;
335
+ metric: z.ZodEnum<["calories", "water", "weight"]>;
336
+ period: z.ZodEnum<["7d", "14d", "1m", "1q", "6m", "1y", "all"]>;
337
+ }, "strip", z.ZodTypeAny, {
338
+ date: string;
339
+ metric: "weight" | "calories" | "water";
340
+ period: "7d" | "14d" | "1m" | "1q" | "6m" | "1y" | "all";
341
+ }, {
342
+ date: string;
343
+ metric: "weight" | "calories" | "water";
344
+ period: "7d" | "14d" | "1m" | "1q" | "6m" | "1y" | "all";
345
+ }>;
346
+ export declare const weightQuerySchema: z.ZodObject<{
347
+ date: z.ZodString;
348
+ }, "strip", z.ZodTypeAny, {
349
+ date: string;
350
+ }, {
351
+ date: string;
352
+ }>;
353
+ export declare const weightEntrySchema: z.ZodObject<{
354
+ id: z.ZodString;
355
+ weightKg: z.ZodNumber;
356
+ day: z.ZodString;
357
+ recordedAt: z.ZodString;
358
+ }, "strip", z.ZodTypeAny, {
359
+ id: string;
360
+ weightKg: number;
361
+ day: string;
362
+ recordedAt: string;
363
+ }, {
364
+ id: string;
365
+ weightKg: number;
366
+ day: string;
367
+ recordedAt: string;
368
+ }>;
369
+ export type WeightEntry = z.infer<typeof weightEntrySchema>;
370
+ export declare const addWeightPayloadSchema: z.ZodObject<{
371
+ day: z.ZodString;
372
+ weightKg: z.ZodNumber;
373
+ }, "strip", z.ZodTypeAny, {
374
+ weightKg: number;
375
+ day: string;
376
+ }, {
377
+ weightKg: number;
378
+ day: string;
379
+ }>;
380
+ export type AddWeightPayload = z.infer<typeof addWeightPayloadSchema>;
381
+ export declare const weightEntryResponseSchema: z.ZodObject<{
382
+ success: z.ZodLiteral<true>;
383
+ data: z.ZodObject<{
384
+ entry: z.ZodObject<{
385
+ id: z.ZodString;
386
+ weightKg: z.ZodNumber;
387
+ day: z.ZodString;
388
+ recordedAt: z.ZodString;
389
+ }, "strip", z.ZodTypeAny, {
390
+ id: string;
391
+ weightKg: number;
392
+ day: string;
393
+ recordedAt: string;
394
+ }, {
395
+ id: string;
396
+ weightKg: number;
397
+ day: string;
398
+ recordedAt: string;
399
+ }>;
400
+ }, "strip", z.ZodTypeAny, {
401
+ entry: {
402
+ id: string;
403
+ weightKg: number;
404
+ day: string;
405
+ recordedAt: string;
406
+ };
407
+ }, {
408
+ entry: {
409
+ id: string;
410
+ weightKg: number;
411
+ day: string;
412
+ recordedAt: string;
413
+ };
414
+ }>;
415
+ responseCode: z.ZodNumber;
416
+ message: z.ZodString;
417
+ }, "strip", z.ZodTypeAny, {
418
+ message: string;
419
+ success: true;
420
+ responseCode: number;
421
+ data: {
422
+ entry: {
423
+ id: string;
424
+ weightKg: number;
425
+ day: string;
426
+ recordedAt: string;
427
+ };
428
+ };
429
+ }, {
430
+ message: string;
431
+ success: true;
432
+ responseCode: number;
433
+ data: {
434
+ entry: {
435
+ id: string;
436
+ weightKg: number;
437
+ day: string;
438
+ recordedAt: string;
439
+ };
440
+ };
441
+ }>;
442
+ export declare const deleteWeightParamsSchema: z.ZodObject<{
443
+ id: z.ZodString;
444
+ }, "strip", z.ZodTypeAny, {
445
+ id: string;
446
+ }, {
447
+ id: string;
448
+ }>;
449
+ export declare const progressSummarySchema: z.ZodObject<{
450
+ currentWeightKg: z.ZodNullable<z.ZodNumber>;
451
+ targetWeightKg: z.ZodNullable<z.ZodNumber>;
452
+ goalGapKg: z.ZodNullable<z.ZodNumber>;
453
+ currentStreakDays: z.ZodNumber;
454
+ longestStreakDays: z.ZodNumber;
455
+ currentWeekAverageKcal: z.ZodNumber;
456
+ }, "strip", z.ZodTypeAny, {
457
+ targetWeightKg: number | null;
458
+ currentWeightKg: number | null;
459
+ currentStreakDays: number;
460
+ longestStreakDays: number;
461
+ goalGapKg: number | null;
462
+ currentWeekAverageKcal: number;
463
+ }, {
464
+ targetWeightKg: number | null;
465
+ currentWeightKg: number | null;
466
+ currentStreakDays: number;
467
+ longestStreakDays: number;
468
+ goalGapKg: number | null;
469
+ currentWeekAverageKcal: number;
470
+ }>;
471
+ export declare const goalProjectionSchema: z.ZodObject<{
472
+ projectedDate: z.ZodNullable<z.ZodString>;
473
+ projectedMonth: z.ZodNullable<z.ZodString>;
474
+ weeklyRateKg: z.ZodNullable<z.ZodNumber>;
475
+ status: z.ZodEnum<["on_track", "off_track", "maintaining", "not_enough_data"]>;
476
+ }, "strip", z.ZodTypeAny, {
477
+ status: "on_track" | "off_track" | "maintaining" | "not_enough_data";
478
+ projectedDate: string | null;
479
+ projectedMonth: string | null;
480
+ weeklyRateKg: number | null;
481
+ }, {
482
+ status: "on_track" | "off_track" | "maintaining" | "not_enough_data";
483
+ projectedDate: string | null;
484
+ projectedMonth: string | null;
485
+ weeklyRateKg: number | null;
486
+ }>;
487
+ export type GoalProjection = z.infer<typeof goalProjectionSchema>;
488
+ export declare const calendarDaySchema: z.ZodObject<{
489
+ day: z.ZodString;
490
+ dayOfMonth: z.ZodNumber;
491
+ logged: z.ZodBoolean;
492
+ today: z.ZodBoolean;
493
+ inMonth: z.ZodBoolean;
494
+ }, "strip", z.ZodTypeAny, {
495
+ day: string;
496
+ dayOfMonth: number;
497
+ logged: boolean;
498
+ today: boolean;
499
+ inMonth: boolean;
500
+ }, {
501
+ day: string;
502
+ dayOfMonth: number;
503
+ logged: boolean;
504
+ today: boolean;
505
+ inMonth: boolean;
506
+ }>;
507
+ export declare const progressResponseSchema: z.ZodObject<{
508
+ success: z.ZodLiteral<true>;
509
+ data: z.ZodObject<{
510
+ progress: z.ZodObject<{
511
+ day: z.ZodString;
512
+ summary: z.ZodObject<{
513
+ currentWeightKg: z.ZodNullable<z.ZodNumber>;
514
+ targetWeightKg: z.ZodNullable<z.ZodNumber>;
515
+ goalGapKg: z.ZodNullable<z.ZodNumber>;
516
+ currentStreakDays: z.ZodNumber;
517
+ longestStreakDays: z.ZodNumber;
518
+ currentWeekAverageKcal: z.ZodNumber;
519
+ }, "strip", z.ZodTypeAny, {
520
+ targetWeightKg: number | null;
521
+ currentWeightKg: number | null;
522
+ currentStreakDays: number;
523
+ longestStreakDays: number;
524
+ goalGapKg: number | null;
525
+ currentWeekAverageKcal: number;
526
+ }, {
527
+ targetWeightKg: number | null;
528
+ currentWeightKg: number | null;
529
+ currentStreakDays: number;
530
+ longestStreakDays: number;
531
+ goalGapKg: number | null;
532
+ currentWeekAverageKcal: number;
533
+ }>;
534
+ projection: z.ZodObject<{
535
+ projectedDate: z.ZodNullable<z.ZodString>;
536
+ projectedMonth: z.ZodNullable<z.ZodString>;
537
+ weeklyRateKg: z.ZodNullable<z.ZodNumber>;
538
+ status: z.ZodEnum<["on_track", "off_track", "maintaining", "not_enough_data"]>;
539
+ }, "strip", z.ZodTypeAny, {
540
+ status: "on_track" | "off_track" | "maintaining" | "not_enough_data";
541
+ projectedDate: string | null;
542
+ projectedMonth: string | null;
543
+ weeklyRateKg: number | null;
544
+ }, {
545
+ status: "on_track" | "off_track" | "maintaining" | "not_enough_data";
546
+ projectedDate: string | null;
547
+ projectedMonth: string | null;
548
+ weeklyRateKg: number | null;
549
+ }>;
550
+ calendar: z.ZodObject<{
551
+ month: z.ZodString;
552
+ days: z.ZodArray<z.ZodObject<{
553
+ day: z.ZodString;
554
+ dayOfMonth: z.ZodNumber;
555
+ logged: z.ZodBoolean;
556
+ today: z.ZodBoolean;
557
+ inMonth: z.ZodBoolean;
558
+ }, "strip", z.ZodTypeAny, {
559
+ day: string;
560
+ dayOfMonth: number;
561
+ logged: boolean;
562
+ today: boolean;
563
+ inMonth: boolean;
564
+ }, {
565
+ day: string;
566
+ dayOfMonth: number;
567
+ logged: boolean;
568
+ today: boolean;
569
+ inMonth: boolean;
570
+ }>, "many">;
571
+ }, "strip", z.ZodTypeAny, {
572
+ days: {
573
+ day: string;
574
+ dayOfMonth: number;
575
+ logged: boolean;
576
+ today: boolean;
577
+ inMonth: boolean;
578
+ }[];
579
+ month: string;
580
+ }, {
581
+ days: {
582
+ day: string;
583
+ dayOfMonth: number;
584
+ logged: boolean;
585
+ today: boolean;
586
+ inMonth: boolean;
587
+ }[];
588
+ month: string;
589
+ }>;
590
+ }, "strip", z.ZodTypeAny, {
591
+ day: string;
592
+ summary: {
593
+ targetWeightKg: number | null;
594
+ currentWeightKg: number | null;
595
+ currentStreakDays: number;
596
+ longestStreakDays: number;
597
+ goalGapKg: number | null;
598
+ currentWeekAverageKcal: number;
599
+ };
600
+ projection: {
601
+ status: "on_track" | "off_track" | "maintaining" | "not_enough_data";
602
+ projectedDate: string | null;
603
+ projectedMonth: string | null;
604
+ weeklyRateKg: number | null;
605
+ };
606
+ calendar: {
607
+ days: {
608
+ day: string;
609
+ dayOfMonth: number;
610
+ logged: boolean;
611
+ today: boolean;
612
+ inMonth: boolean;
613
+ }[];
614
+ month: string;
615
+ };
616
+ }, {
617
+ day: string;
618
+ summary: {
619
+ targetWeightKg: number | null;
620
+ currentWeightKg: number | null;
621
+ currentStreakDays: number;
622
+ longestStreakDays: number;
623
+ goalGapKg: number | null;
624
+ currentWeekAverageKcal: number;
625
+ };
626
+ projection: {
627
+ status: "on_track" | "off_track" | "maintaining" | "not_enough_data";
628
+ projectedDate: string | null;
629
+ projectedMonth: string | null;
630
+ weeklyRateKg: number | null;
631
+ };
632
+ calendar: {
633
+ days: {
634
+ day: string;
635
+ dayOfMonth: number;
636
+ logged: boolean;
637
+ today: boolean;
638
+ inMonth: boolean;
639
+ }[];
640
+ month: string;
641
+ };
642
+ }>;
643
+ }, "strip", z.ZodTypeAny, {
644
+ progress: {
645
+ day: string;
646
+ summary: {
647
+ targetWeightKg: number | null;
648
+ currentWeightKg: number | null;
649
+ currentStreakDays: number;
650
+ longestStreakDays: number;
651
+ goalGapKg: number | null;
652
+ currentWeekAverageKcal: number;
653
+ };
654
+ projection: {
655
+ status: "on_track" | "off_track" | "maintaining" | "not_enough_data";
656
+ projectedDate: string | null;
657
+ projectedMonth: string | null;
658
+ weeklyRateKg: number | null;
659
+ };
660
+ calendar: {
661
+ days: {
662
+ day: string;
663
+ dayOfMonth: number;
664
+ logged: boolean;
665
+ today: boolean;
666
+ inMonth: boolean;
667
+ }[];
668
+ month: string;
669
+ };
670
+ };
671
+ }, {
672
+ progress: {
673
+ day: string;
674
+ summary: {
675
+ targetWeightKg: number | null;
676
+ currentWeightKg: number | null;
677
+ currentStreakDays: number;
678
+ longestStreakDays: number;
679
+ goalGapKg: number | null;
680
+ currentWeekAverageKcal: number;
681
+ };
682
+ projection: {
683
+ status: "on_track" | "off_track" | "maintaining" | "not_enough_data";
684
+ projectedDate: string | null;
685
+ projectedMonth: string | null;
686
+ weeklyRateKg: number | null;
687
+ };
688
+ calendar: {
689
+ days: {
690
+ day: string;
691
+ dayOfMonth: number;
692
+ logged: boolean;
693
+ today: boolean;
694
+ inMonth: boolean;
695
+ }[];
696
+ month: string;
697
+ };
698
+ };
699
+ }>;
700
+ responseCode: z.ZodNumber;
701
+ message: z.ZodString;
702
+ }, "strip", z.ZodTypeAny, {
703
+ message: string;
704
+ success: true;
705
+ responseCode: number;
706
+ data: {
707
+ progress: {
708
+ day: string;
709
+ summary: {
710
+ targetWeightKg: number | null;
711
+ currentWeightKg: number | null;
712
+ currentStreakDays: number;
713
+ longestStreakDays: number;
714
+ goalGapKg: number | null;
715
+ currentWeekAverageKcal: number;
716
+ };
717
+ projection: {
718
+ status: "on_track" | "off_track" | "maintaining" | "not_enough_data";
719
+ projectedDate: string | null;
720
+ projectedMonth: string | null;
721
+ weeklyRateKg: number | null;
722
+ };
723
+ calendar: {
724
+ days: {
725
+ day: string;
726
+ dayOfMonth: number;
727
+ logged: boolean;
728
+ today: boolean;
729
+ inMonth: boolean;
730
+ }[];
731
+ month: string;
732
+ };
733
+ };
734
+ };
735
+ }, {
736
+ message: string;
737
+ success: true;
738
+ responseCode: number;
739
+ data: {
740
+ progress: {
741
+ day: string;
742
+ summary: {
743
+ targetWeightKg: number | null;
744
+ currentWeightKg: number | null;
745
+ currentStreakDays: number;
746
+ longestStreakDays: number;
747
+ goalGapKg: number | null;
748
+ currentWeekAverageKcal: number;
749
+ };
750
+ projection: {
751
+ status: "on_track" | "off_track" | "maintaining" | "not_enough_data";
752
+ projectedDate: string | null;
753
+ projectedMonth: string | null;
754
+ weeklyRateKg: number | null;
755
+ };
756
+ calendar: {
757
+ days: {
758
+ day: string;
759
+ dayOfMonth: number;
760
+ logged: boolean;
761
+ today: boolean;
762
+ inMonth: boolean;
763
+ }[];
764
+ month: string;
765
+ };
766
+ };
767
+ };
768
+ }>;
769
+ export declare const chartPointSchema: z.ZodObject<{
770
+ date: z.ZodString;
771
+ value: z.ZodNullable<z.ZodNumber>;
772
+ }, "strip", z.ZodTypeAny, {
773
+ value: number | null;
774
+ date: string;
775
+ }, {
776
+ value: number | null;
777
+ date: string;
778
+ }>;
779
+ export declare const chartResponseSchema: z.ZodObject<{
780
+ success: z.ZodLiteral<true>;
781
+ data: z.ZodObject<{
782
+ chart: z.ZodObject<{
783
+ metric: z.ZodEnum<["calories", "water", "weight"]>;
784
+ period: z.ZodEnum<["7d", "14d", "1m", "1q", "6m", "1y", "all"]>;
785
+ unit: z.ZodEnum<["kcal", "ml", "kg"]>;
786
+ from: z.ZodString;
787
+ to: z.ZodString;
788
+ points: z.ZodArray<z.ZodObject<{
789
+ date: z.ZodString;
790
+ value: z.ZodNullable<z.ZodNumber>;
791
+ }, "strip", z.ZodTypeAny, {
792
+ value: number | null;
793
+ date: string;
794
+ }, {
795
+ value: number | null;
796
+ date: string;
797
+ }>, "many">;
798
+ }, "strip", z.ZodTypeAny, {
799
+ metric: "weight" | "calories" | "water";
800
+ from: string;
801
+ to: string;
802
+ period: "7d" | "14d" | "1m" | "1q" | "6m" | "1y" | "all";
803
+ unit: "kcal" | "ml" | "kg";
804
+ points: {
805
+ value: number | null;
806
+ date: string;
807
+ }[];
808
+ }, {
809
+ metric: "weight" | "calories" | "water";
810
+ from: string;
811
+ to: string;
812
+ period: "7d" | "14d" | "1m" | "1q" | "6m" | "1y" | "all";
813
+ unit: "kcal" | "ml" | "kg";
814
+ points: {
815
+ value: number | null;
816
+ date: string;
817
+ }[];
818
+ }>;
819
+ }, "strip", z.ZodTypeAny, {
820
+ chart: {
821
+ metric: "weight" | "calories" | "water";
822
+ from: string;
823
+ to: string;
824
+ period: "7d" | "14d" | "1m" | "1q" | "6m" | "1y" | "all";
825
+ unit: "kcal" | "ml" | "kg";
826
+ points: {
827
+ value: number | null;
828
+ date: string;
829
+ }[];
830
+ };
831
+ }, {
832
+ chart: {
833
+ metric: "weight" | "calories" | "water";
834
+ from: string;
835
+ to: string;
836
+ period: "7d" | "14d" | "1m" | "1q" | "6m" | "1y" | "all";
837
+ unit: "kcal" | "ml" | "kg";
838
+ points: {
839
+ value: number | null;
840
+ date: string;
841
+ }[];
842
+ };
843
+ }>;
844
+ responseCode: z.ZodNumber;
845
+ message: z.ZodString;
846
+ }, "strip", z.ZodTypeAny, {
847
+ message: string;
848
+ success: true;
849
+ responseCode: number;
850
+ data: {
851
+ chart: {
852
+ metric: "weight" | "calories" | "water";
853
+ from: string;
854
+ to: string;
855
+ period: "7d" | "14d" | "1m" | "1q" | "6m" | "1y" | "all";
856
+ unit: "kcal" | "ml" | "kg";
857
+ points: {
858
+ value: number | null;
859
+ date: string;
860
+ }[];
861
+ };
862
+ };
863
+ }, {
864
+ message: string;
865
+ success: true;
866
+ responseCode: number;
867
+ data: {
868
+ chart: {
869
+ metric: "weight" | "calories" | "water";
870
+ from: string;
871
+ to: string;
872
+ period: "7d" | "14d" | "1m" | "1q" | "6m" | "1y" | "all";
873
+ unit: "kcal" | "ml" | "kg";
874
+ points: {
875
+ value: number | null;
876
+ date: string;
877
+ }[];
878
+ };
879
+ };
880
+ }>;
881
+ export declare const weightContextResponseSchema: z.ZodObject<{
882
+ success: z.ZodLiteral<true>;
883
+ data: z.ZodObject<{
884
+ context: z.ZodObject<{
885
+ day: z.ZodString;
886
+ currentWeightKg: z.ZodNullable<z.ZodNumber>;
887
+ yesterdayWeightKg: z.ZodNullable<z.ZodNumber>;
888
+ sevenDayAverageKg: z.ZodNullable<z.ZodNumber>;
889
+ targetWeightKg: z.ZodNullable<z.ZodNumber>;
890
+ projection: z.ZodObject<{
891
+ projectedDate: z.ZodNullable<z.ZodString>;
892
+ projectedMonth: z.ZodNullable<z.ZodString>;
893
+ weeklyRateKg: z.ZodNullable<z.ZodNumber>;
894
+ status: z.ZodEnum<["on_track", "off_track", "maintaining", "not_enough_data"]>;
895
+ }, "strip", z.ZodTypeAny, {
896
+ status: "on_track" | "off_track" | "maintaining" | "not_enough_data";
897
+ projectedDate: string | null;
898
+ projectedMonth: string | null;
899
+ weeklyRateKg: number | null;
900
+ }, {
901
+ status: "on_track" | "off_track" | "maintaining" | "not_enough_data";
902
+ projectedDate: string | null;
903
+ projectedMonth: string | null;
904
+ weeklyRateKg: number | null;
905
+ }>;
906
+ }, "strip", z.ZodTypeAny, {
907
+ targetWeightKg: number | null;
908
+ currentWeightKg: number | null;
909
+ day: string;
910
+ projection: {
911
+ status: "on_track" | "off_track" | "maintaining" | "not_enough_data";
912
+ projectedDate: string | null;
913
+ projectedMonth: string | null;
914
+ weeklyRateKg: number | null;
915
+ };
916
+ yesterdayWeightKg: number | null;
917
+ sevenDayAverageKg: number | null;
918
+ }, {
919
+ targetWeightKg: number | null;
920
+ currentWeightKg: number | null;
921
+ day: string;
922
+ projection: {
923
+ status: "on_track" | "off_track" | "maintaining" | "not_enough_data";
924
+ projectedDate: string | null;
925
+ projectedMonth: string | null;
926
+ weeklyRateKg: number | null;
927
+ };
928
+ yesterdayWeightKg: number | null;
929
+ sevenDayAverageKg: number | null;
930
+ }>;
931
+ }, "strip", z.ZodTypeAny, {
932
+ context: {
933
+ targetWeightKg: number | null;
934
+ currentWeightKg: number | null;
935
+ day: string;
936
+ projection: {
937
+ status: "on_track" | "off_track" | "maintaining" | "not_enough_data";
938
+ projectedDate: string | null;
939
+ projectedMonth: string | null;
940
+ weeklyRateKg: number | null;
941
+ };
942
+ yesterdayWeightKg: number | null;
943
+ sevenDayAverageKg: number | null;
944
+ };
945
+ }, {
946
+ context: {
947
+ targetWeightKg: number | null;
948
+ currentWeightKg: number | null;
949
+ day: string;
950
+ projection: {
951
+ status: "on_track" | "off_track" | "maintaining" | "not_enough_data";
952
+ projectedDate: string | null;
953
+ projectedMonth: string | null;
954
+ weeklyRateKg: number | null;
955
+ };
956
+ yesterdayWeightKg: number | null;
957
+ sevenDayAverageKg: number | null;
958
+ };
959
+ }>;
960
+ responseCode: z.ZodNumber;
961
+ message: z.ZodString;
962
+ }, "strip", z.ZodTypeAny, {
963
+ message: string;
964
+ success: true;
965
+ responseCode: number;
966
+ data: {
967
+ context: {
968
+ targetWeightKg: number | null;
969
+ currentWeightKg: number | null;
970
+ day: string;
971
+ projection: {
972
+ status: "on_track" | "off_track" | "maintaining" | "not_enough_data";
973
+ projectedDate: string | null;
974
+ projectedMonth: string | null;
975
+ weeklyRateKg: number | null;
976
+ };
977
+ yesterdayWeightKg: number | null;
978
+ sevenDayAverageKg: number | null;
979
+ };
980
+ };
981
+ }, {
982
+ message: string;
983
+ success: true;
984
+ responseCode: number;
985
+ data: {
986
+ context: {
987
+ targetWeightKg: number | null;
988
+ currentWeightKg: number | null;
989
+ day: string;
990
+ projection: {
991
+ status: "on_track" | "off_track" | "maintaining" | "not_enough_data";
992
+ projectedDate: string | null;
993
+ projectedMonth: string | null;
994
+ weeklyRateKg: number | null;
995
+ };
996
+ yesterdayWeightKg: number | null;
997
+ sevenDayAverageKg: number | null;
998
+ };
999
+ };
1000
+ }>;
118
1001
  export declare const metricRoutes: {
1002
+ progressGet: {
1003
+ method: "GET";
1004
+ path: "/api/v1/metrics/progress";
1005
+ auth: "user";
1006
+ };
1007
+ chartGet: {
1008
+ method: "GET";
1009
+ path: "/api/v1/metrics/chart";
1010
+ auth: "user";
1011
+ };
1012
+ weightContextGet: {
1013
+ method: "GET";
1014
+ path: "/api/v1/metrics/weight/context";
1015
+ auth: "user";
1016
+ };
1017
+ weightAdd: {
1018
+ method: "POST";
1019
+ path: "/api/v1/metrics/weight";
1020
+ auth: "user";
1021
+ };
1022
+ weightDelete: {
1023
+ method: "DELETE";
1024
+ path: "/api/v1/metrics/weight/:id";
1025
+ auth: "user";
1026
+ };
119
1027
  waterGet: {
120
1028
  method: "GET";
121
1029
  path: "/api/v1/metrics/water";
@@ -126,5 +1034,10 @@ export declare const metricRoutes: {
126
1034
  path: "/api/v1/metrics/water";
127
1035
  auth: "user";
128
1036
  };
1037
+ waterDelete: {
1038
+ method: "DELETE";
1039
+ path: "/api/v1/metrics/water/:id";
1040
+ auth: "user";
1041
+ };
129
1042
  };
130
1043
  //# sourceMappingURL=metrics.d.ts.map