@trainheroic-unofficial/dto 0.6.2 → 0.6.4

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.
Files changed (2) hide show
  1. package/dist/index.d.mts +67 -1
  2. package/package.json +1 -1
package/dist/index.d.mts CHANGED
@@ -276,6 +276,72 @@ type AthleteWorkoutView = {
276
276
  logged: boolean;
277
277
  blocks: AthleteWorkoutBlock[];
278
278
  };
279
+ /**
280
+ * A compact per-workout header with no block/exercise detail. Produced by the summary
281
+ * projection so an overview question ("what's on my schedule this week", "what have I been
282
+ * training lately") returns one small row per session instead of the full prescribed/performed
283
+ * sets — a dense multi-program week of `AthleteWorkoutView`s can run tens of KB and force a
284
+ * follow-up drill-in.
285
+ */
286
+ type AthleteWorkoutSummary = {
287
+ id: number | null;
288
+ date: string;
289
+ title: string;
290
+ program: string | null;
291
+ team: string | null; /** True when the athlete logged at least one set on this workout. */
292
+ logged: boolean; /** Total prescribed exercises across all blocks. */
293
+ exerciseCount: number;
294
+ /**
295
+ * How many of those exercises have at least one logged set. Read it against exerciseCount
296
+ * (e.g. 1 of 12), not in isolation — a low number means the session was mostly unlogged, not
297
+ * that only one exercise was prescribed.
298
+ */
299
+ performedCount: number;
300
+ };
301
+ /** One exercise inside a coach-viewed athlete session (from the calendar summary). */
302
+ type CoachAthleteExercise = {
303
+ exerciseId: number | null;
304
+ title: string; /** The set summary the API returns, e.g. "5 x 2 @ 205 lb" or "3 x 5 @ 24 in". */
305
+ summary: string | null;
306
+ completed: boolean;
307
+ };
308
+ /** One session in a coach's view of a roster athlete's training month. */
309
+ type CoachAthleteSession = {
310
+ workoutId: number | null;
311
+ savedWorkoutId: number | null;
312
+ title: string; /** True when the athlete logged this session (the reliable did-they-train signal). */
313
+ logged: boolean;
314
+ completed: boolean;
315
+ rpe: number | null;
316
+ durationMin: number | null;
317
+ notes: string | null;
318
+ exercises: CoachAthleteExercise[];
319
+ };
320
+ /**
321
+ * A coach's month view of a roster athlete's training, presented from
322
+ * `/2.0/coach/athlete/calendar/summary`. Sessions are in calendar order within the month; the
323
+ * API carries no per-session date, so the month comes from year/month.
324
+ */
325
+ type CoachAthleteTraining = {
326
+ athleteId: number | null;
327
+ athleteName: string | null;
328
+ year: number;
329
+ month: number;
330
+ sessions: CoachAthleteSession[];
331
+ };
332
+ /**
333
+ * One athlete's all-time training snapshot in a coach's roster-activity ranking. `lastLoggedDate`
334
+ * is the real training-recency signal (null means the athlete has never logged a session),
335
+ * distinct from `list_athletes`'s `daysSinceLastLogin`, which is app-login recency.
336
+ */
337
+ type RosterActivityRow = {
338
+ athleteId: number;
339
+ sessionsCount: number | null;
340
+ firstLoggedDate: string | null;
341
+ lastLoggedDate: string | null;
342
+ totalReps: number | null;
343
+ totalVolume: number | null;
344
+ };
279
345
  /** One performed session in a presented exercise history. */
280
346
  type PresentedExerciseSession = {
281
347
  date: string;
@@ -495,4 +561,4 @@ type ReadResult = {
495
561
  blocks: ReadBlock[];
496
562
  };
497
563
  //#endregion
498
- export { Advisory, AthletePrefs, AthleteProfileSummary, AthleteUser, AthleteWorkingMax, AthleteWorkoutBlock, AthleteWorkoutExercise, AthleteWorkoutRangeArgs, AthleteWorkoutView, BlockSpec, CommentDraft, ExerciseCreate, ExerciseHistoryDetail, ExerciseHistoryListItem, ExerciseRow, ExerciseSpec, ExerciseStats, ExerciseView, Id, LeaderboardSpec, LogSetArgs, PersonalRecord, PresentedExerciseHistory, PresentedExerciseSession, ProgramWorkout, ReadBlock, ReadExercise, ReadResult, ResolveResult, UserSimple, WorkoutDate, WorkoutSpec, athletePrefsSchema, athleteProfileSummarySchema, athleteUserSchema, athleteWorkingMaxListSchema, athleteWorkingMaxSchema, athleteWorkoutRangeArgsSchema, blockSpecSchema, commentDraftSchema, dateString, exerciseCreateSchema, exerciseHistoryDetailSchema, exerciseHistoryListItemSchema, exerciseHistoryListSchema, exerciseLibraryResponseSchema, exerciseResponseSchema, exerciseSpecSchema, exerciseStatsSchema, historyEntrySchema, historySetSchema, idArgSchema, idSchema, leaderboardSpecSchema, liftPRSchema, logSetArgsSchema, parseWorkoutDate, personalRecordListSchema, personalRecordSchema, programWorkoutListSchema, programWorkoutResponseSchema, programWorkoutSchema, programsEditResponseSchema, repMaxSchema, sessionCreateResponseSchema, userSimpleSchema, workoutSpecSchema };
564
+ export { Advisory, AthletePrefs, AthleteProfileSummary, AthleteUser, AthleteWorkingMax, AthleteWorkoutBlock, AthleteWorkoutExercise, AthleteWorkoutRangeArgs, AthleteWorkoutSummary, AthleteWorkoutView, BlockSpec, CoachAthleteExercise, CoachAthleteSession, CoachAthleteTraining, CommentDraft, ExerciseCreate, ExerciseHistoryDetail, ExerciseHistoryListItem, ExerciseRow, ExerciseSpec, ExerciseStats, ExerciseView, Id, LeaderboardSpec, LogSetArgs, PersonalRecord, PresentedExerciseHistory, PresentedExerciseSession, ProgramWorkout, ReadBlock, ReadExercise, ReadResult, ResolveResult, RosterActivityRow, UserSimple, WorkoutDate, WorkoutSpec, athletePrefsSchema, athleteProfileSummarySchema, athleteUserSchema, athleteWorkingMaxListSchema, athleteWorkingMaxSchema, athleteWorkoutRangeArgsSchema, blockSpecSchema, commentDraftSchema, dateString, exerciseCreateSchema, exerciseHistoryDetailSchema, exerciseHistoryListItemSchema, exerciseHistoryListSchema, exerciseLibraryResponseSchema, exerciseResponseSchema, exerciseSpecSchema, exerciseStatsSchema, historyEntrySchema, historySetSchema, idArgSchema, idSchema, leaderboardSpecSchema, liftPRSchema, logSetArgsSchema, parseWorkoutDate, personalRecordListSchema, personalRecordSchema, programWorkoutListSchema, programWorkoutResponseSchema, programWorkoutSchema, programsEditResponseSchema, repMaxSchema, sessionCreateResponseSchema, userSimpleSchema, workoutSpecSchema };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@trainheroic-unofficial/dto",
3
- "version": "0.6.2",
3
+ "version": "0.6.4",
4
4
  "license": "MIT",
5
5
  "repository": {
6
6
  "type": "git",