@sunsteel/contracts 0.51.0 → 0.53.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/index.cjs +62 -0
- package/dist/index.d.cts +308 -1
- package/dist/index.d.ts +308 -1
- package/dist/index.js +48 -0
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -22,6 +22,15 @@ var index_exports = {};
|
|
|
22
22
|
__export(index_exports, {
|
|
23
23
|
ACHIEVEMENT_CATEGORIES: () => ACHIEVEMENT_CATEGORIES,
|
|
24
24
|
ACHIEVEMENT_DEFINITIONS: () => ACHIEVEMENT_DEFINITIONS,
|
|
25
|
+
ACTIVITY_CAPS: () => ACTIVITY_CAPS,
|
|
26
|
+
ACTIVITY_DEFAULT_AUDIENCE: () => ACTIVITY_DEFAULT_AUDIENCE,
|
|
27
|
+
ACTIVITY_ENTRY_ID_MAX_LENGTH: () => ACTIVITY_ENTRY_ID_MAX_LENGTH,
|
|
28
|
+
ACTIVITY_FEED_FOLLOWED_MAX: () => ACTIVITY_FEED_FOLLOWED_MAX,
|
|
29
|
+
ACTIVITY_PAGE_DEFAULT_LIMIT: () => ACTIVITY_PAGE_DEFAULT_LIMIT,
|
|
30
|
+
ACTIVITY_PAGE_MAX_LIMIT: () => ACTIVITY_PAGE_MAX_LIMIT,
|
|
31
|
+
ACTIVITY_PREVIEW_AUDIENCES: () => ACTIVITY_PREVIEW_AUDIENCES,
|
|
32
|
+
ACTIVITY_TYPES: () => ACTIVITY_TYPES,
|
|
33
|
+
ACTIVITY_TYPE_SECTIONS: () => ACTIVITY_TYPE_SECTIONS,
|
|
25
34
|
BLOCKED_MEMBERS_MAX: () => BLOCKED_MEMBERS_MAX,
|
|
26
35
|
CLONE_ROUTINE_REFUSALS: () => CLONE_ROUTINE_REFUSALS,
|
|
27
36
|
COMEBACK_MIN_INACTIVE_DAYS: () => COMEBACK_MIN_INACTIVE_DAYS,
|
|
@@ -80,6 +89,11 @@ __export(index_exports, {
|
|
|
80
89
|
REST_ALERT_REFUSALS: () => REST_ALERT_REFUSALS,
|
|
81
90
|
ROUTINE_DAYS_MAX: () => ROUTINE_DAYS_MAX,
|
|
82
91
|
ROUTINE_DAY_NAME_MAX: () => ROUTINE_DAY_NAME_MAX,
|
|
92
|
+
ROUTINE_DISCOVERY_DEFAULT_LIMIT: () => ROUTINE_DISCOVERY_DEFAULT_LIMIT,
|
|
93
|
+
ROUTINE_DISCOVERY_MAX_LIMIT: () => ROUTINE_DISCOVERY_MAX_LIMIT,
|
|
94
|
+
ROUTINE_DISCOVERY_SCAN_LIMIT: () => ROUTINE_DISCOVERY_SCAN_LIMIT,
|
|
95
|
+
ROUTINE_DURATION_BANDS: () => ROUTINE_DURATION_BANDS,
|
|
96
|
+
ROUTINE_DURATION_BAND_MAX_MINUTES: () => ROUTINE_DURATION_BAND_MAX_MINUTES,
|
|
83
97
|
ROUTINE_SCHEDULE_MODES: () => ROUTINE_SCHEDULE_MODES,
|
|
84
98
|
ROUTINE_SHARE_MAX_ACTIVE_LINKS: () => ROUTINE_SHARE_MAX_ACTIVE_LINKS,
|
|
85
99
|
ROUTINE_VERSIONS_MAX: () => ROUTINE_VERSIONS_MAX,
|
|
@@ -459,6 +473,40 @@ var CLONE_ROUTINE_REFUSALS = {
|
|
|
459
473
|
UNKNOWN_EXERCISE: "UNKNOWN_EXERCISE"
|
|
460
474
|
};
|
|
461
475
|
|
|
476
|
+
// src/routine-discovery.ts
|
|
477
|
+
var ROUTINE_DURATION_BANDS = ["SHORT", "MEDIUM", "LONG"];
|
|
478
|
+
var ROUTINE_DURATION_BAND_MAX_MINUTES = { SHORT: 45, MEDIUM: 75 };
|
|
479
|
+
var ROUTINE_DISCOVERY_DEFAULT_LIMIT = 20;
|
|
480
|
+
var ROUTINE_DISCOVERY_MAX_LIMIT = 50;
|
|
481
|
+
var ROUTINE_DISCOVERY_SCAN_LIMIT = 500;
|
|
482
|
+
|
|
483
|
+
// src/activity.ts
|
|
484
|
+
var ACTIVITY_TYPES = [
|
|
485
|
+
"SESSION_COMPLETED",
|
|
486
|
+
"PERSONAL_RECORD",
|
|
487
|
+
"PROGRESSION_CHANGED",
|
|
488
|
+
"ACHIEVEMENT_UNLOCKED",
|
|
489
|
+
"STREAK_MILESTONE",
|
|
490
|
+
"COMEBACK",
|
|
491
|
+
"ROUTINE_SHARED"
|
|
492
|
+
];
|
|
493
|
+
var ACTIVITY_TYPE_SECTIONS = {
|
|
494
|
+
SESSION_COMPLETED: "workoutHistory",
|
|
495
|
+
PERSONAL_RECORD: "records",
|
|
496
|
+
PROGRESSION_CHANGED: "workoutHistory",
|
|
497
|
+
ACHIEVEMENT_UNLOCKED: "achievements",
|
|
498
|
+
STREAK_MILESTONE: "achievements",
|
|
499
|
+
COMEBACK: "achievements",
|
|
500
|
+
ROUTINE_SHARED: "routines"
|
|
501
|
+
};
|
|
502
|
+
var ACTIVITY_DEFAULT_AUDIENCE = "PRIVATE";
|
|
503
|
+
var ACTIVITY_PAGE_DEFAULT_LIMIT = 20;
|
|
504
|
+
var ACTIVITY_PAGE_MAX_LIMIT = 50;
|
|
505
|
+
var ACTIVITY_FEED_FOLLOWED_MAX = 500;
|
|
506
|
+
var ACTIVITY_ENTRY_ID_MAX_LENGTH = 200;
|
|
507
|
+
var ACTIVITY_CAPS = ["SECTION", "ROUTINE"];
|
|
508
|
+
var ACTIVITY_PREVIEW_AUDIENCES = ["FOLLOWERS", "PUBLIC"];
|
|
509
|
+
|
|
462
510
|
// src/schedule.ts
|
|
463
511
|
var SCHEDULE_OVERRIDE_KINDS = ["MOVE", "SKIP"];
|
|
464
512
|
var SCHEDULE_MOVE_MAX_DAYS = 6;
|
|
@@ -551,6 +599,15 @@ var STREAK_MAX_GAP_DAYS = 3;
|
|
|
551
599
|
0 && (module.exports = {
|
|
552
600
|
ACHIEVEMENT_CATEGORIES,
|
|
553
601
|
ACHIEVEMENT_DEFINITIONS,
|
|
602
|
+
ACTIVITY_CAPS,
|
|
603
|
+
ACTIVITY_DEFAULT_AUDIENCE,
|
|
604
|
+
ACTIVITY_ENTRY_ID_MAX_LENGTH,
|
|
605
|
+
ACTIVITY_FEED_FOLLOWED_MAX,
|
|
606
|
+
ACTIVITY_PAGE_DEFAULT_LIMIT,
|
|
607
|
+
ACTIVITY_PAGE_MAX_LIMIT,
|
|
608
|
+
ACTIVITY_PREVIEW_AUDIENCES,
|
|
609
|
+
ACTIVITY_TYPES,
|
|
610
|
+
ACTIVITY_TYPE_SECTIONS,
|
|
554
611
|
BLOCKED_MEMBERS_MAX,
|
|
555
612
|
CLONE_ROUTINE_REFUSALS,
|
|
556
613
|
COMEBACK_MIN_INACTIVE_DAYS,
|
|
@@ -609,6 +666,11 @@ var STREAK_MAX_GAP_DAYS = 3;
|
|
|
609
666
|
REST_ALERT_REFUSALS,
|
|
610
667
|
ROUTINE_DAYS_MAX,
|
|
611
668
|
ROUTINE_DAY_NAME_MAX,
|
|
669
|
+
ROUTINE_DISCOVERY_DEFAULT_LIMIT,
|
|
670
|
+
ROUTINE_DISCOVERY_MAX_LIMIT,
|
|
671
|
+
ROUTINE_DISCOVERY_SCAN_LIMIT,
|
|
672
|
+
ROUTINE_DURATION_BANDS,
|
|
673
|
+
ROUTINE_DURATION_BAND_MAX_MINUTES,
|
|
612
674
|
ROUTINE_SCHEDULE_MODES,
|
|
613
675
|
ROUTINE_SHARE_MAX_ACTIVE_LINKS,
|
|
614
676
|
ROUTINE_VERSIONS_MAX,
|
package/dist/index.d.cts
CHANGED
|
@@ -974,6 +974,13 @@ interface Routine {
|
|
|
974
974
|
* this viewer is allowed to know about its source.
|
|
975
975
|
*/
|
|
976
976
|
lineage?: RoutineLineage | null;
|
|
977
|
+
/**
|
|
978
|
+
* ROUT-07: owner-declared, both optional. They are claims about the
|
|
979
|
+
* programme that only its author can make, which is why they are stored
|
|
980
|
+
* here rather than derived from the author's `PROF-05` training identity.
|
|
981
|
+
*/
|
|
982
|
+
goal?: TrainingGoal | null;
|
|
983
|
+
experienceLevel?: TrainingExperienceLevel | null;
|
|
977
984
|
days: RoutineDay[];
|
|
978
985
|
createdAt: IsoDateString;
|
|
979
986
|
updatedAt: IsoDateString;
|
|
@@ -981,6 +988,9 @@ interface Routine {
|
|
|
981
988
|
interface CreateRoutineRequest {
|
|
982
989
|
name: string;
|
|
983
990
|
description?: string;
|
|
991
|
+
/** ROUT-07; omitted means undeclared, which is not the same as a default. */
|
|
992
|
+
goal?: TrainingGoal | null;
|
|
993
|
+
experienceLevel?: TrainingExperienceLevel | null;
|
|
984
994
|
isPeriodized: boolean;
|
|
985
995
|
/** Defaults to WEEKLY. Changing it on update requires `days`. */
|
|
986
996
|
scheduleMode?: RoutineScheduleMode;
|
|
@@ -1555,6 +1565,303 @@ interface PersonalGoalsResponse {
|
|
|
1555
1565
|
goals: PersonalGoalProgress[];
|
|
1556
1566
|
}
|
|
1557
1567
|
|
|
1568
|
+
/** Owner-declared, both optional. Undeclared is not a default, it is unknown. */
|
|
1569
|
+
interface RoutineClassification {
|
|
1570
|
+
goal?: TrainingGoal | null;
|
|
1571
|
+
experienceLevel?: TrainingExperienceLevel | null;
|
|
1572
|
+
}
|
|
1573
|
+
/**
|
|
1574
|
+
* Derived from the routine's own exercises and the `EXER-09` catalog, never
|
|
1575
|
+
* stored: a stored facet drifts from the routine the moment an edit misses
|
|
1576
|
+
* its recompute.
|
|
1577
|
+
*/
|
|
1578
|
+
interface RoutineFacets {
|
|
1579
|
+
dayCount: number;
|
|
1580
|
+
exerciseCount: number;
|
|
1581
|
+
/** Muscles any day trains, primary or secondary, deduplicated. */
|
|
1582
|
+
muscles: MuscleGroup[];
|
|
1583
|
+
/** Everything the routine needs, from the catalog's closed vocabulary. */
|
|
1584
|
+
equipment: ExerciseEquipment[];
|
|
1585
|
+
/**
|
|
1586
|
+
* The longest day's estimate in minutes, by `ROUT-10`'s rule. It is an
|
|
1587
|
+
* estimate from set counts, reps and rest, and every surface that shows it
|
|
1588
|
+
* says so rather than presenting it as a measured time.
|
|
1589
|
+
*/
|
|
1590
|
+
longestDayMinutes: number;
|
|
1591
|
+
}
|
|
1592
|
+
/** One routine in a discovery result. It carries no training, as `ROUT-04`. */
|
|
1593
|
+
interface DiscoverableRoutine extends RoutineClassification, RoutineFacets {
|
|
1594
|
+
routineId: string;
|
|
1595
|
+
name: string;
|
|
1596
|
+
description: string | null;
|
|
1597
|
+
scheduleMode: RoutineScheduleMode;
|
|
1598
|
+
author: SharedRoutineOwner;
|
|
1599
|
+
updatedAt: IsoDateString;
|
|
1600
|
+
}
|
|
1601
|
+
/** Duration buckets, so a filter is a choice rather than a number entry. */
|
|
1602
|
+
declare const ROUTINE_DURATION_BANDS: readonly ["SHORT", "MEDIUM", "LONG"];
|
|
1603
|
+
type RoutineDurationBand = (typeof ROUTINE_DURATION_BANDS)[number];
|
|
1604
|
+
/** Upper bound of each band in minutes; `LONG` is anything above `MEDIUM`. */
|
|
1605
|
+
declare const ROUTINE_DURATION_BAND_MAX_MINUTES: Record<Exclude<RoutineDurationBand, 'LONG'>, number>;
|
|
1606
|
+
/** GET /routines/discover */
|
|
1607
|
+
interface RoutineDiscoveryQuery {
|
|
1608
|
+
/** Matches the routine name or description, case-insensitively. */
|
|
1609
|
+
q?: string;
|
|
1610
|
+
goal?: TrainingGoal;
|
|
1611
|
+
experienceLevel?: TrainingExperienceLevel;
|
|
1612
|
+
/** Exact number of training days a week. */
|
|
1613
|
+
days?: number;
|
|
1614
|
+
/** The routine must train this muscle, primary or secondary. */
|
|
1615
|
+
muscle?: MuscleGroup;
|
|
1616
|
+
/** The routine must need nothing outside what the viewer selects. */
|
|
1617
|
+
equipment?: ExerciseEquipment[];
|
|
1618
|
+
duration?: RoutineDurationBand;
|
|
1619
|
+
limit?: number;
|
|
1620
|
+
/** Opaque; from the previous page's `nextCursor`. */
|
|
1621
|
+
cursor?: string;
|
|
1622
|
+
}
|
|
1623
|
+
declare const ROUTINE_DISCOVERY_DEFAULT_LIMIT = 20;
|
|
1624
|
+
declare const ROUTINE_DISCOVERY_MAX_LIMIT = 50;
|
|
1625
|
+
/**
|
|
1626
|
+
* How many readable routines one request will consider before filtering.
|
|
1627
|
+
* The scan is bounded on purpose, and the response says when it ran out
|
|
1628
|
+
* rather than quietly returning a partial answer as a complete one.
|
|
1629
|
+
*/
|
|
1630
|
+
declare const ROUTINE_DISCOVERY_SCAN_LIMIT = 500;
|
|
1631
|
+
interface RoutineDiscoveryResponse {
|
|
1632
|
+
routines: DiscoverableRoutine[];
|
|
1633
|
+
nextCursor?: string;
|
|
1634
|
+
/**
|
|
1635
|
+
* True when the scan limit was reached, so results may be incomplete. The
|
|
1636
|
+
* UI says so; it never presents a truncated page as everything there is.
|
|
1637
|
+
*/
|
|
1638
|
+
scanTruncated: boolean;
|
|
1639
|
+
}
|
|
1640
|
+
|
|
1641
|
+
declare const ACTIVITY_TYPES: readonly ["SESSION_COMPLETED", "PERSONAL_RECORD", "PROGRESSION_CHANGED", "ACHIEVEMENT_UNLOCKED", "STREAK_MILESTONE", "COMEBACK", "ROUTINE_SHARED"];
|
|
1642
|
+
type ActivityType = (typeof ACTIVITY_TYPES)[number];
|
|
1643
|
+
/** The `PROF-06` sections activity can come from. */
|
|
1644
|
+
type ActivitySection = keyof Pick<ProfilePrivacySettings, 'workoutHistory' | 'records' | 'achievements' | 'routines'>;
|
|
1645
|
+
/**
|
|
1646
|
+
* The one section each type's data comes from. An entry can never be seen by
|
|
1647
|
+
* someone that section is hidden from.
|
|
1648
|
+
*/
|
|
1649
|
+
declare const ACTIVITY_TYPE_SECTIONS: Record<ActivityType, ActivitySection>;
|
|
1650
|
+
/** Who may see an entry: the `PROF-06` values, so there is one vocabulary. */
|
|
1651
|
+
type ActivityAudience = ProfileVisibility;
|
|
1652
|
+
/** Every type starts here until its owner chooses otherwise. */
|
|
1653
|
+
declare const ACTIVITY_DEFAULT_AUDIENCE: ActivityAudience;
|
|
1654
|
+
/**
|
|
1655
|
+
* Where the viewer may open the record an entry came from. The server decides
|
|
1656
|
+
* it, so the client never judges what a viewer may read; an entry whose
|
|
1657
|
+
* record has no such place for this viewer has `link: null` and still names
|
|
1658
|
+
* the record.
|
|
1659
|
+
*/
|
|
1660
|
+
type ActivityLink = {
|
|
1661
|
+
kind: 'OWN_SESSION';
|
|
1662
|
+
sessionId: string;
|
|
1663
|
+
} | {
|
|
1664
|
+
kind: 'OWN_EXERCISE';
|
|
1665
|
+
exerciseId: string;
|
|
1666
|
+
} | {
|
|
1667
|
+
kind: 'OWN_ACHIEVEMENTS';
|
|
1668
|
+
} | {
|
|
1669
|
+
kind: 'OWN_ROUTINE';
|
|
1670
|
+
routineId: string;
|
|
1671
|
+
} | {
|
|
1672
|
+
kind: 'MEMBER_RECORDS';
|
|
1673
|
+
username: string;
|
|
1674
|
+
} | {
|
|
1675
|
+
kind: 'MEMBER_ACHIEVEMENTS';
|
|
1676
|
+
username: string;
|
|
1677
|
+
} | {
|
|
1678
|
+
kind: 'MEMBER_ROUTINE';
|
|
1679
|
+
username: string;
|
|
1680
|
+
routineId: string;
|
|
1681
|
+
};
|
|
1682
|
+
interface ActivityEntryBase {
|
|
1683
|
+
/**
|
|
1684
|
+
* Stable across reads and opaque to clients. It is the key an override is
|
|
1685
|
+
* stored under, so it must be sent back unchanged.
|
|
1686
|
+
*/
|
|
1687
|
+
id: string;
|
|
1688
|
+
occurredAt: IsoDateString;
|
|
1689
|
+
author: SharedRoutineOwner;
|
|
1690
|
+
link: ActivityLink | null;
|
|
1691
|
+
/**
|
|
1692
|
+
* Shared by the facts of one workout, so a session and the records it set
|
|
1693
|
+
* can be shown together; null for a fact that belongs to no workout.
|
|
1694
|
+
*/
|
|
1695
|
+
groupKey: string | null;
|
|
1696
|
+
}
|
|
1697
|
+
interface SessionCompletedActivity extends ActivityEntryBase {
|
|
1698
|
+
type: 'SESSION_COMPLETED';
|
|
1699
|
+
session: {
|
|
1700
|
+
routineName: string;
|
|
1701
|
+
dayName: string | null;
|
|
1702
|
+
completedSets: number;
|
|
1703
|
+
/** External load × reps, canonical kilograms. */
|
|
1704
|
+
volumeKg: number;
|
|
1705
|
+
durationSec: number | null;
|
|
1706
|
+
};
|
|
1707
|
+
}
|
|
1708
|
+
interface PersonalRecordActivity extends ActivityEntryBase {
|
|
1709
|
+
type: 'PERSONAL_RECORD';
|
|
1710
|
+
record: {
|
|
1711
|
+
exerciseId: string;
|
|
1712
|
+
exerciseName: string;
|
|
1713
|
+
weightKg: number;
|
|
1714
|
+
reps: number;
|
|
1715
|
+
estimated1rmKg: number;
|
|
1716
|
+
};
|
|
1717
|
+
}
|
|
1718
|
+
interface ProgressionActivity extends ActivityEntryBase {
|
|
1719
|
+
type: 'PROGRESSION_CHANGED';
|
|
1720
|
+
progression: {
|
|
1721
|
+
exerciseId: string;
|
|
1722
|
+
exerciseName: string;
|
|
1723
|
+
sets: ProgressionSetChange[];
|
|
1724
|
+
};
|
|
1725
|
+
}
|
|
1726
|
+
interface AchievementActivity extends ActivityEntryBase {
|
|
1727
|
+
type: 'ACHIEVEMENT_UNLOCKED';
|
|
1728
|
+
achievement: {
|
|
1729
|
+
id: string;
|
|
1730
|
+
title: string;
|
|
1731
|
+
description: string;
|
|
1732
|
+
category: AchievementCategory;
|
|
1733
|
+
};
|
|
1734
|
+
}
|
|
1735
|
+
interface StreakMilestoneActivity extends ActivityEntryBase {
|
|
1736
|
+
type: 'STREAK_MILESTONE';
|
|
1737
|
+
streak: {
|
|
1738
|
+
achievementId: string;
|
|
1739
|
+
title: string;
|
|
1740
|
+
streakDays: number;
|
|
1741
|
+
};
|
|
1742
|
+
}
|
|
1743
|
+
interface ComebackActivity extends ActivityEntryBase {
|
|
1744
|
+
type: 'COMEBACK';
|
|
1745
|
+
comeback: {
|
|
1746
|
+
/** Full local-calendar days without a completed session before it. */
|
|
1747
|
+
inactiveDays: number;
|
|
1748
|
+
activeDays: number;
|
|
1749
|
+
windowDays: number;
|
|
1750
|
+
returnedAt: IsoDateString;
|
|
1751
|
+
};
|
|
1752
|
+
}
|
|
1753
|
+
interface RoutineSharedActivity extends ActivityEntryBase {
|
|
1754
|
+
type: 'ROUTINE_SHARED';
|
|
1755
|
+
routine: {
|
|
1756
|
+
routineId: string;
|
|
1757
|
+
name: string;
|
|
1758
|
+
dayCount: number;
|
|
1759
|
+
exerciseCount: number;
|
|
1760
|
+
};
|
|
1761
|
+
}
|
|
1762
|
+
type ActivityEntry = SessionCompletedActivity | PersonalRecordActivity | ProgressionActivity | AchievementActivity | StreakMilestoneActivity | ComebackActivity | RoutineSharedActivity;
|
|
1763
|
+
declare const ACTIVITY_PAGE_DEFAULT_LIMIT = 20;
|
|
1764
|
+
declare const ACTIVITY_PAGE_MAX_LIMIT = 50;
|
|
1765
|
+
/**
|
|
1766
|
+
* The feed considers at most this many followed members, and says so when it
|
|
1767
|
+
* reached the ceiling rather than presenting a partial feed as a whole one.
|
|
1768
|
+
*/
|
|
1769
|
+
declare const ACTIVITY_FEED_FOLLOWED_MAX = 500;
|
|
1770
|
+
/** Entry ids are opaque but bounded; anything longer is refused. */
|
|
1771
|
+
declare const ACTIVITY_ENTRY_ID_MAX_LENGTH = 200;
|
|
1772
|
+
interface ActivityPageQuery {
|
|
1773
|
+
limit?: number;
|
|
1774
|
+
/** Opaque; from the previous page's `nextCursor`. */
|
|
1775
|
+
cursor?: string;
|
|
1776
|
+
}
|
|
1777
|
+
interface ActivityPage<Entry = ActivityEntry> {
|
|
1778
|
+
entries: Entry[];
|
|
1779
|
+
nextCursor?: string;
|
|
1780
|
+
}
|
|
1781
|
+
/**
|
|
1782
|
+
* GET /activity/feed: activity of the members the viewer follows that each
|
|
1783
|
+
* member's audiences allow the viewer to see, newest first.
|
|
1784
|
+
*/
|
|
1785
|
+
interface ActivityFeedResponse extends ActivityPage {
|
|
1786
|
+
/**
|
|
1787
|
+
* How many members the viewer follows, so an empty feed can say whether
|
|
1788
|
+
* there is nobody to hear from or nothing they were allowed to see.
|
|
1789
|
+
*/
|
|
1790
|
+
followedCount: number;
|
|
1791
|
+
/** True when the viewer follows more than `ACTIVITY_FEED_FOLLOWED_MAX`. */
|
|
1792
|
+
followedTruncated: boolean;
|
|
1793
|
+
}
|
|
1794
|
+
/** GET /activity/members/:identifier — one member's activity, as this viewer may see it. */
|
|
1795
|
+
type MemberActivityResponse = ActivityPage;
|
|
1796
|
+
/** What narrowed an entry below the audience its owner chose. */
|
|
1797
|
+
declare const ACTIVITY_CAPS: readonly ["SECTION", "ROUTINE"];
|
|
1798
|
+
type ActivityCap = (typeof ACTIVITY_CAPS)[number];
|
|
1799
|
+
/** How one of the owner's own entries is shared. */
|
|
1800
|
+
interface ActivityEntrySharing {
|
|
1801
|
+
section: ActivitySection;
|
|
1802
|
+
/** The owner's current rule for that section. */
|
|
1803
|
+
sectionRule: ProfileVisibility;
|
|
1804
|
+
/** The type's default audience. */
|
|
1805
|
+
defaultAudience: ActivityAudience;
|
|
1806
|
+
/** This entry's own audience, or null when it follows the default. */
|
|
1807
|
+
override: ActivityAudience | null;
|
|
1808
|
+
/**
|
|
1809
|
+
* Who can actually see it: the narrowest of the section rule, the chosen
|
|
1810
|
+
* audience and, for a shared routine, the routine's own visibility.
|
|
1811
|
+
*/
|
|
1812
|
+
effectiveAudience: ActivityAudience;
|
|
1813
|
+
/** Set when the effective audience is narrower than the one chosen. */
|
|
1814
|
+
cappedBy: ActivityCap | null;
|
|
1815
|
+
}
|
|
1816
|
+
type OwnActivityEntry = ActivityEntry & {
|
|
1817
|
+
sharing: ActivityEntrySharing;
|
|
1818
|
+
};
|
|
1819
|
+
/** GET /activity/mine — every entry of the owner's, whoever may see it. */
|
|
1820
|
+
type OwnActivityResponse = ActivityPage<OwnActivityEntry>;
|
|
1821
|
+
/**
|
|
1822
|
+
* The audiences the owner can preview. `FOLLOWERS` is a member who follows
|
|
1823
|
+
* them; `PUBLIC` is any other signed-in member. Activity is never shown
|
|
1824
|
+
* signed out.
|
|
1825
|
+
*/
|
|
1826
|
+
declare const ACTIVITY_PREVIEW_AUDIENCES: readonly ["FOLLOWERS", "PUBLIC"];
|
|
1827
|
+
type ActivityPreviewAudience = (typeof ACTIVITY_PREVIEW_AUDIENCES)[number];
|
|
1828
|
+
/**
|
|
1829
|
+
* GET /activity/mine/preview — the owner's activity exactly as that audience
|
|
1830
|
+
* would receive it, through the same read, links included.
|
|
1831
|
+
*/
|
|
1832
|
+
interface ActivityPreviewQuery extends ActivityPageQuery {
|
|
1833
|
+
audience: ActivityPreviewAudience;
|
|
1834
|
+
}
|
|
1835
|
+
/** GET and PUT /activity/sharing */
|
|
1836
|
+
interface ActivitySharingSettings {
|
|
1837
|
+
/** The default audience of every type. */
|
|
1838
|
+
defaults: Record<ActivityType, ActivityAudience>;
|
|
1839
|
+
/** The section rules that cap them, so the UI can say when one does. */
|
|
1840
|
+
sections: Record<ActivitySection, ProfileVisibility>;
|
|
1841
|
+
}
|
|
1842
|
+
/**
|
|
1843
|
+
* PUT /activity/sharing. A partial write: an omitted type keeps its stored
|
|
1844
|
+
* default. A default applies to past entries of the type as well as future
|
|
1845
|
+
* ones, except those with their own audience.
|
|
1846
|
+
*/
|
|
1847
|
+
interface UpdateActivitySharingRequest {
|
|
1848
|
+
defaults: Partial<Record<ActivityType, ActivityAudience>>;
|
|
1849
|
+
}
|
|
1850
|
+
/**
|
|
1851
|
+
* PUT /activity/entries/audience. `null` returns the entry to its type's
|
|
1852
|
+
* default; `PRIVATE` withdraws it from everyone but its owner. Either way it
|
|
1853
|
+
* can never exceed its section.
|
|
1854
|
+
*/
|
|
1855
|
+
interface SetActivityEntryAudienceRequest {
|
|
1856
|
+
entryId: string;
|
|
1857
|
+
audience: ActivityAudience | null;
|
|
1858
|
+
}
|
|
1859
|
+
/** Stable successful response of PUT /activity/entries/audience. */
|
|
1860
|
+
interface SetActivityEntryAudienceResponse {
|
|
1861
|
+
entryId: string;
|
|
1862
|
+
sharing: ActivityEntrySharing;
|
|
1863
|
+
}
|
|
1864
|
+
|
|
1558
1865
|
/** A local calendar date, YYYY-MM-DD. */
|
|
1559
1866
|
type CalendarDate = string;
|
|
1560
1867
|
/**
|
|
@@ -1879,4 +2186,4 @@ interface PlannedReminder {
|
|
|
1879
2186
|
routineNames: string[];
|
|
1880
2187
|
}
|
|
1881
2188
|
|
|
1882
|
-
export { ACHIEVEMENT_CATEGORIES, ACHIEVEMENT_DEFINITIONS, type AchievementCategory, type AchievementCategoryProgress, type AchievementDefinition, type AchievementNotification, type AchievementUnlockedEventPayload, type AchievementsResponse, type AppNotification, BLOCKED_MEMBERS_MAX, type BlockedMember, type BlockedMembersResponse, type Brand, CLONE_ROUTINE_REFUSALS, COMEBACK_MIN_INACTIVE_DAYS, COMEBACK_RECOGNITION_LIMIT, COMEBACK_REQUIRED_ACTIVE_DAYS, COMEBACK_SESSION_LOOKBACK, COMEBACK_WINDOW_DAYS, type CalendarDate, type CloneRoutineRefusal, type CloneRoutineRequest, type ComebackRecognition, type ComebackRecognitionSummary, type CreateReportRequest, type CreateReportResponse, type CreateRoutineDayInput, type CreateRoutineExerciseInput, type CreateRoutineRequest, type CreateRoutineVersionRequest, type CreateSessionShareRequest, type DeletePushSubscriptionRequest, EXERCISE_EQUIPMENT, EXERCISE_MECHANICS, type EarnedAchievement, type EarnedPersonalRecord, type Exercise, type ExerciseEquipment, type ExerciseId, type ExerciseMechanic, type ExercisePerformanceHistoryQuery, type ExercisePerformanceHistoryResponse, type ExercisePerformancePrescription, type ExercisePerformancePrescriptionSet, type ExercisePerformanceSession, type ExercisePerformanceSet, type ExercisePerformanceSummary, type ExercisePlateau, type ExerciseStrengthSummary, type ExerciseStrengthTrendPoint, type ExerciseStrengthTrendQuery, type ExerciseStrengthTrendResponse, FEATURED_PROFILE_ITEMS_MAX, FEATURED_PROFILE_ITEM_KINDS, FEATURED_PROFILE_REFERENCE_MAX_LENGTH, FOLLOW_SUGGESTIONS_DEFAULT_LIMIT, FOLLOW_SUGGESTIONS_MAX_LIMIT, FOLLOW_SUGGESTION_REASONS, type FeaturedProfileAchievementItem, type FeaturedProfileItem, type FeaturedProfileItemKind, type FeaturedProfileRankItem, type FeaturedProfileRecordItem, type FeaturedProfileRoutineItem, type FeaturedProfileSelection, type FeaturedProfileSelectionInput, type FeaturedProfileSelectionsResponse, type FinishStatus, type FinishWorkoutRequest, type FinishWorkoutResponse, type FollowSuggestion, type FollowSuggestionReason, type FollowSuggestionsResponse, type IsoDateString, type ListSessionsParams, MEASURABLE_GOALS_MAX, MEASURABLE_GOAL_DIRECTIONS, MEASURABLE_GOAL_TYPES, MINUTES_IN_DAY, MOVEMENT_PATTERNS, MUSCLE_GROUPS, type MarkNotificationsReadRequest, type MarkNotificationsReadResponse, type MeasurableGoal, type MeasurableGoalDirection, type MeasurableGoalExercise, type MeasurableGoalInput, type MeasurableGoalType, type MemberModerationState, type MemberRoutinesResponse, type MoveOccurrenceRequest, type MovementPattern, type MuscleGroup, type MuscleGroupHeatmapQuery, type MuscleGroupHeatmapResponse, type MuscleGroupHeatmapValue, type MuscleGroupHeatmapWeek, type MuscleVolumeTrendSeries, NOTIFICATIONS_LIST_LIMIT, NOTIFICATIONS_LOOKBACK_DAYS, NOTIFICATIONS_RETENTION_DAYS, NOTIFICATION_CATEGORIES, NOTIFICATION_KINDS, type NewFollowerNotification, type NotificationCategory, type NotificationKind, type NotificationPreferences, type NotificationPreferencesResponse, type NotificationsResponse, PLATEAU_MIN_DAYS_SINCE_BEST, PLATEAU_MIN_SESSIONS, PLATEAU_MIN_SESSIONS_MAX, PLATEAU_MIN_SESSIONS_MIN, PLATEAU_RECENT_DAYS, PLATEAU_WINDOW_DAYS, PREFERRED_TRAINING_STYLE_VALUES, PROFILE_BIO_MAX_LENGTH, PROFILE_FAVORITE_EXERCISES_MAX, PROFILE_LOCATION_MAX_LENGTH, PROFILE_TRAINING_DISCIPLINES_MAX, PROFILE_TRAINING_GOALS_MAX, PROFILE_VISIBILITY_VALUES, PROGRESSION_SCHEMES, PROGRESS_TIMELINE_EVENT_TYPES, PUSH_PAYLOAD_KINDS, PUSH_SUBSCRIPTIONS_MAX, type PaginatedResponse, type PersonalGoalProgress, type PersonalGoalsResponse, type PersonalRecordEntry, type PersonalRecordKind, type PlannedReminder, type PlatePairInventory, type PlateauPreferences, type PlateauSet, type PlateausResponse, type PreferredTrainingStyle, type PreviousPerformanceResponse, type PreviousSessionRecap, type PreviousSetPerformance, type ProfileDiscoverySettings, type ProfileFavoriteExercise, type ProfilePrivacySettings, type ProfileViewerAccess, type ProfileVisibility, type ProgressTimelineEventType, type ProgressTimelineItem, type ProgressTimelinePersonalRecordItem, type ProgressTimelineProgressionItem, type ProgressTimelineQuery, type ProgressTimelineRecordPerformance, type ProgressTimelineRecordReason, type ProgressTimelineResponse, type ProgressTimelineSessionContext, type ProgressionChange, type ProgressionRule, type ProgressionScheme, type ProgressionSetChange, type PublicBodyMetrics, type PublicProfileAchievements, type PublicTrainingSummary, type PublicUserProfile, type PushPayload, type PushPayloadKind, type PushSubscriptionKeys, type PushSubscriptionSummary, type PushSubscriptionsResponse, type QuietHours, RELATIONSHIP_LIST_DEFAULT_LIMIT, RELATIONSHIP_LIST_KINDS, RELATIONSHIP_LIST_MAX_LIMIT, RENAISSANCE_RANK_DEFINITIONS, REPORTS_PER_DAY_MAX, REPORT_DETAILS_MAX_LENGTH, REPORT_REASONS, REPORT_SUBJECT_KINDS, REP_TYPES, RESERVED_USERNAMES, REST_ALERT_MAX_LEAD_SECONDS, REST_ALERT_MIN_LEAD_SECONDS, REST_ALERT_REFUSALS, ROUTINE_DAYS_MAX, ROUTINE_DAY_NAME_MAX, ROUTINE_SCHEDULE_MODES, ROUTINE_SHARE_MAX_ACTIVE_LINKS, ROUTINE_VERSIONS_MAX, ROUTINE_VERSION_KINDS, ROUTINE_VERSION_NAME_MAX, ROUTINE_VISIBILITY_VALUES, type RecentActivityEntry, type RegisterPushSubscriptionRequest, type RelationshipListKind, type RelationshipListQuery, type RelationshipListResponse, type RelationshipMember, type RenaissanceRankDefinition, type RenaissanceRankProgress, type RepType, type ReplaceFeaturedProfileItemsRequest, type ReplaceMeasurableGoalsRequest, type ReplaceTrainingLocationsRequest, type ReportReason, type ReportSubjectKind, type RestAlertPushPayload, type RestAlertRefusal, type RestoreRoutineVersionResponse, type Routine, type RoutineDay, type RoutineDayId, type RoutineExercise, type RoutineId, type RoutineLineage, type RoutineScheduleMode, type RoutineSet, type RoutineShare, type RoutineShareListResponse, type RoutineVersion, type RoutineVersionDay, type RoutineVersionExercise, type RoutineVersionKind, type RoutineVersionSetup, type RoutineVersionsResponse, type RoutineVisibility, SCHEDULE_MOVE_MAX_DAYS, SCHEDULE_OVERRIDES_MAX_RANGE_DAYS, SCHEDULE_OVERRIDE_KINDS, SCHEDULE_SKIP_PAST_DAYS, SESSION_SHARE_DEFAULT_FIELDS, SESSION_SHARE_FIELDS, SESSION_SHARE_MAX_ACTIVE_LINKS, SEXES, SHARED_ROUTINE_SOURCES, STARRED_EXERCISES_MAX, STREAK_MAX_GAP_DAYS, type ScheduleOverride, type ScheduleOverrideKind, type ScheduleOverridesQuery, type ScheduleOverridesResponse, type ScheduleRestAlertRequest, type ScheduleRestAlertResponse, type SessionComparisonExercise, type SessionComparisonQuery, type SessionComparisonResponse, type SessionComparisonRoutineDay, type SessionComparisonSession, type SessionComparisonSet, type SessionExerciseSubstitution, type SessionProgressNotification, type SessionRecapRecord, type SessionShare, type SessionShareField, type SessionShareListResponse, type SetAccountTimeZoneRequest, type SetLog, type Sex, type SharedRoutine, type SharedRoutineOwner, type SharedRoutineSource, type SharedRoutineSummary, type SharedSessionOwner, type SharedSessionRecap, type SkipOccurrenceRequest, type StarredExercise, type StarredExercisesResponse, type StartWorkoutRequest, type StartWorkoutResponse, type StreakAtRiskPushPayload, type StreakMilestoneEventPayload, type SubstituteSessionExerciseRequest, type SubstituteSessionExerciseResponse, type SupabaseAuthResponse, type SupabaseAuthUser, type SupabaseMigrationResponse, TRAINING_DISCIPLINE_VALUES, TRAINING_EVENT_TYPES, TRAINING_EXPERIENCE_LEVEL_VALUES, TRAINING_GOAL_VALUES, type TrainingDiscipline, type TrainingEventType, type TrainingExperienceLevel, type TrainingGoal, type TrainingIdentity, type TrainingLocationPreference, type TrainingLocationPreferenceInput, type TrainingReminderPreference, type TrainingReminderPushPayload, USERNAME_MAX_LENGTH, USERNAME_MIN_LENGTH, USERNAME_PATTERN_SOURCE, type UpdateNotificationPreferencesRequest, type UpdateProfileDiscoveryRequest, type UpdateProfilePrivacyRequest, type UpdateProfileRequest, type UpdateRoutineRequest, type UpdateRoutineVisibilityRequest, type UpsertSetLogRequest, type UpsertSetLogResponse, type UserId, type UserProfile, type UserSearchResponse, type VolumeTrendPoint, type VolumeTrendQuery, type VolumeTrendResponse, type VolumeTrendSeries, WEIGHT_UNITS, WORKOUT_SESSION_STATUSES, type WeightUnit, type WorkoutAnalyticsStatus, type WorkoutProgressQuery, type WorkoutProgressResponse, type WorkoutSession, type WorkoutSessionId, type WorkoutSessionListResponse, type WorkoutSessionRecap, type WorkoutSessionSnapshotV1, type WorkoutSessionStatus, type WorkoutSessionSummary, type WorkoutStatsQuery, type WorkoutStatsResponse, isWithinQuietHours, routineDayLabel };
|
|
2189
|
+
export { ACHIEVEMENT_CATEGORIES, ACHIEVEMENT_DEFINITIONS, ACTIVITY_CAPS, ACTIVITY_DEFAULT_AUDIENCE, ACTIVITY_ENTRY_ID_MAX_LENGTH, ACTIVITY_FEED_FOLLOWED_MAX, ACTIVITY_PAGE_DEFAULT_LIMIT, ACTIVITY_PAGE_MAX_LIMIT, ACTIVITY_PREVIEW_AUDIENCES, ACTIVITY_TYPES, ACTIVITY_TYPE_SECTIONS, type AchievementActivity, type AchievementCategory, type AchievementCategoryProgress, type AchievementDefinition, type AchievementNotification, type AchievementUnlockedEventPayload, type AchievementsResponse, type ActivityAudience, type ActivityCap, type ActivityEntry, type ActivityEntrySharing, type ActivityFeedResponse, type ActivityLink, type ActivityPage, type ActivityPageQuery, type ActivityPreviewAudience, type ActivityPreviewQuery, type ActivitySection, type ActivitySharingSettings, type ActivityType, type AppNotification, BLOCKED_MEMBERS_MAX, type BlockedMember, type BlockedMembersResponse, type Brand, CLONE_ROUTINE_REFUSALS, COMEBACK_MIN_INACTIVE_DAYS, COMEBACK_RECOGNITION_LIMIT, COMEBACK_REQUIRED_ACTIVE_DAYS, COMEBACK_SESSION_LOOKBACK, COMEBACK_WINDOW_DAYS, type CalendarDate, type CloneRoutineRefusal, type CloneRoutineRequest, type ComebackActivity, type ComebackRecognition, type ComebackRecognitionSummary, type CreateReportRequest, type CreateReportResponse, type CreateRoutineDayInput, type CreateRoutineExerciseInput, type CreateRoutineRequest, type CreateRoutineVersionRequest, type CreateSessionShareRequest, type DeletePushSubscriptionRequest, type DiscoverableRoutine, EXERCISE_EQUIPMENT, EXERCISE_MECHANICS, type EarnedAchievement, type EarnedPersonalRecord, type Exercise, type ExerciseEquipment, type ExerciseId, type ExerciseMechanic, type ExercisePerformanceHistoryQuery, type ExercisePerformanceHistoryResponse, type ExercisePerformancePrescription, type ExercisePerformancePrescriptionSet, type ExercisePerformanceSession, type ExercisePerformanceSet, type ExercisePerformanceSummary, type ExercisePlateau, type ExerciseStrengthSummary, type ExerciseStrengthTrendPoint, type ExerciseStrengthTrendQuery, type ExerciseStrengthTrendResponse, FEATURED_PROFILE_ITEMS_MAX, FEATURED_PROFILE_ITEM_KINDS, FEATURED_PROFILE_REFERENCE_MAX_LENGTH, FOLLOW_SUGGESTIONS_DEFAULT_LIMIT, FOLLOW_SUGGESTIONS_MAX_LIMIT, FOLLOW_SUGGESTION_REASONS, type FeaturedProfileAchievementItem, type FeaturedProfileItem, type FeaturedProfileItemKind, type FeaturedProfileRankItem, type FeaturedProfileRecordItem, type FeaturedProfileRoutineItem, type FeaturedProfileSelection, type FeaturedProfileSelectionInput, type FeaturedProfileSelectionsResponse, type FinishStatus, type FinishWorkoutRequest, type FinishWorkoutResponse, type FollowSuggestion, type FollowSuggestionReason, type FollowSuggestionsResponse, type IsoDateString, type ListSessionsParams, MEASURABLE_GOALS_MAX, MEASURABLE_GOAL_DIRECTIONS, MEASURABLE_GOAL_TYPES, MINUTES_IN_DAY, MOVEMENT_PATTERNS, MUSCLE_GROUPS, type MarkNotificationsReadRequest, type MarkNotificationsReadResponse, type MeasurableGoal, type MeasurableGoalDirection, type MeasurableGoalExercise, type MeasurableGoalInput, type MeasurableGoalType, type MemberActivityResponse, type MemberModerationState, type MemberRoutinesResponse, type MoveOccurrenceRequest, type MovementPattern, type MuscleGroup, type MuscleGroupHeatmapQuery, type MuscleGroupHeatmapResponse, type MuscleGroupHeatmapValue, type MuscleGroupHeatmapWeek, type MuscleVolumeTrendSeries, NOTIFICATIONS_LIST_LIMIT, NOTIFICATIONS_LOOKBACK_DAYS, NOTIFICATIONS_RETENTION_DAYS, NOTIFICATION_CATEGORIES, NOTIFICATION_KINDS, type NewFollowerNotification, type NotificationCategory, type NotificationKind, type NotificationPreferences, type NotificationPreferencesResponse, type NotificationsResponse, type OwnActivityEntry, type OwnActivityResponse, PLATEAU_MIN_DAYS_SINCE_BEST, PLATEAU_MIN_SESSIONS, PLATEAU_MIN_SESSIONS_MAX, PLATEAU_MIN_SESSIONS_MIN, PLATEAU_RECENT_DAYS, PLATEAU_WINDOW_DAYS, PREFERRED_TRAINING_STYLE_VALUES, PROFILE_BIO_MAX_LENGTH, PROFILE_FAVORITE_EXERCISES_MAX, PROFILE_LOCATION_MAX_LENGTH, PROFILE_TRAINING_DISCIPLINES_MAX, PROFILE_TRAINING_GOALS_MAX, PROFILE_VISIBILITY_VALUES, PROGRESSION_SCHEMES, PROGRESS_TIMELINE_EVENT_TYPES, PUSH_PAYLOAD_KINDS, PUSH_SUBSCRIPTIONS_MAX, type PaginatedResponse, type PersonalGoalProgress, type PersonalGoalsResponse, type PersonalRecordActivity, type PersonalRecordEntry, type PersonalRecordKind, type PlannedReminder, type PlatePairInventory, type PlateauPreferences, type PlateauSet, type PlateausResponse, type PreferredTrainingStyle, type PreviousPerformanceResponse, type PreviousSessionRecap, type PreviousSetPerformance, type ProfileDiscoverySettings, type ProfileFavoriteExercise, type ProfilePrivacySettings, type ProfileViewerAccess, type ProfileVisibility, type ProgressTimelineEventType, type ProgressTimelineItem, type ProgressTimelinePersonalRecordItem, type ProgressTimelineProgressionItem, type ProgressTimelineQuery, type ProgressTimelineRecordPerformance, type ProgressTimelineRecordReason, type ProgressTimelineResponse, type ProgressTimelineSessionContext, type ProgressionActivity, type ProgressionChange, type ProgressionRule, type ProgressionScheme, type ProgressionSetChange, type PublicBodyMetrics, type PublicProfileAchievements, type PublicTrainingSummary, type PublicUserProfile, type PushPayload, type PushPayloadKind, type PushSubscriptionKeys, type PushSubscriptionSummary, type PushSubscriptionsResponse, type QuietHours, RELATIONSHIP_LIST_DEFAULT_LIMIT, RELATIONSHIP_LIST_KINDS, RELATIONSHIP_LIST_MAX_LIMIT, RENAISSANCE_RANK_DEFINITIONS, REPORTS_PER_DAY_MAX, REPORT_DETAILS_MAX_LENGTH, REPORT_REASONS, REPORT_SUBJECT_KINDS, REP_TYPES, RESERVED_USERNAMES, REST_ALERT_MAX_LEAD_SECONDS, REST_ALERT_MIN_LEAD_SECONDS, REST_ALERT_REFUSALS, ROUTINE_DAYS_MAX, ROUTINE_DAY_NAME_MAX, ROUTINE_DISCOVERY_DEFAULT_LIMIT, ROUTINE_DISCOVERY_MAX_LIMIT, ROUTINE_DISCOVERY_SCAN_LIMIT, ROUTINE_DURATION_BANDS, ROUTINE_DURATION_BAND_MAX_MINUTES, ROUTINE_SCHEDULE_MODES, ROUTINE_SHARE_MAX_ACTIVE_LINKS, ROUTINE_VERSIONS_MAX, ROUTINE_VERSION_KINDS, ROUTINE_VERSION_NAME_MAX, ROUTINE_VISIBILITY_VALUES, type RecentActivityEntry, type RegisterPushSubscriptionRequest, type RelationshipListKind, type RelationshipListQuery, type RelationshipListResponse, type RelationshipMember, type RenaissanceRankDefinition, type RenaissanceRankProgress, type RepType, type ReplaceFeaturedProfileItemsRequest, type ReplaceMeasurableGoalsRequest, type ReplaceTrainingLocationsRequest, type ReportReason, type ReportSubjectKind, type RestAlertPushPayload, type RestAlertRefusal, type RestoreRoutineVersionResponse, type Routine, type RoutineClassification, type RoutineDay, type RoutineDayId, type RoutineDiscoveryQuery, type RoutineDiscoveryResponse, type RoutineDurationBand, type RoutineExercise, type RoutineFacets, type RoutineId, type RoutineLineage, type RoutineScheduleMode, type RoutineSet, type RoutineShare, type RoutineShareListResponse, type RoutineSharedActivity, type RoutineVersion, type RoutineVersionDay, type RoutineVersionExercise, type RoutineVersionKind, type RoutineVersionSetup, type RoutineVersionsResponse, type RoutineVisibility, SCHEDULE_MOVE_MAX_DAYS, SCHEDULE_OVERRIDES_MAX_RANGE_DAYS, SCHEDULE_OVERRIDE_KINDS, SCHEDULE_SKIP_PAST_DAYS, SESSION_SHARE_DEFAULT_FIELDS, SESSION_SHARE_FIELDS, SESSION_SHARE_MAX_ACTIVE_LINKS, SEXES, SHARED_ROUTINE_SOURCES, STARRED_EXERCISES_MAX, STREAK_MAX_GAP_DAYS, type ScheduleOverride, type ScheduleOverrideKind, type ScheduleOverridesQuery, type ScheduleOverridesResponse, type ScheduleRestAlertRequest, type ScheduleRestAlertResponse, type SessionComparisonExercise, type SessionComparisonQuery, type SessionComparisonResponse, type SessionComparisonRoutineDay, type SessionComparisonSession, type SessionComparisonSet, type SessionCompletedActivity, type SessionExerciseSubstitution, type SessionProgressNotification, type SessionRecapRecord, type SessionShare, type SessionShareField, type SessionShareListResponse, type SetAccountTimeZoneRequest, type SetActivityEntryAudienceRequest, type SetActivityEntryAudienceResponse, type SetLog, type Sex, type SharedRoutine, type SharedRoutineOwner, type SharedRoutineSource, type SharedRoutineSummary, type SharedSessionOwner, type SharedSessionRecap, type SkipOccurrenceRequest, type StarredExercise, type StarredExercisesResponse, type StartWorkoutRequest, type StartWorkoutResponse, type StreakAtRiskPushPayload, type StreakMilestoneActivity, type StreakMilestoneEventPayload, type SubstituteSessionExerciseRequest, type SubstituteSessionExerciseResponse, type SupabaseAuthResponse, type SupabaseAuthUser, type SupabaseMigrationResponse, TRAINING_DISCIPLINE_VALUES, TRAINING_EVENT_TYPES, TRAINING_EXPERIENCE_LEVEL_VALUES, TRAINING_GOAL_VALUES, type TrainingDiscipline, type TrainingEventType, type TrainingExperienceLevel, type TrainingGoal, type TrainingIdentity, type TrainingLocationPreference, type TrainingLocationPreferenceInput, type TrainingReminderPreference, type TrainingReminderPushPayload, USERNAME_MAX_LENGTH, USERNAME_MIN_LENGTH, USERNAME_PATTERN_SOURCE, type UpdateActivitySharingRequest, type UpdateNotificationPreferencesRequest, type UpdateProfileDiscoveryRequest, type UpdateProfilePrivacyRequest, type UpdateProfileRequest, type UpdateRoutineRequest, type UpdateRoutineVisibilityRequest, type UpsertSetLogRequest, type UpsertSetLogResponse, type UserId, type UserProfile, type UserSearchResponse, type VolumeTrendPoint, type VolumeTrendQuery, type VolumeTrendResponse, type VolumeTrendSeries, WEIGHT_UNITS, WORKOUT_SESSION_STATUSES, type WeightUnit, type WorkoutAnalyticsStatus, type WorkoutProgressQuery, type WorkoutProgressResponse, type WorkoutSession, type WorkoutSessionId, type WorkoutSessionListResponse, type WorkoutSessionRecap, type WorkoutSessionSnapshotV1, type WorkoutSessionStatus, type WorkoutSessionSummary, type WorkoutStatsQuery, type WorkoutStatsResponse, isWithinQuietHours, routineDayLabel };
|
package/dist/index.d.ts
CHANGED
|
@@ -974,6 +974,13 @@ interface Routine {
|
|
|
974
974
|
* this viewer is allowed to know about its source.
|
|
975
975
|
*/
|
|
976
976
|
lineage?: RoutineLineage | null;
|
|
977
|
+
/**
|
|
978
|
+
* ROUT-07: owner-declared, both optional. They are claims about the
|
|
979
|
+
* programme that only its author can make, which is why they are stored
|
|
980
|
+
* here rather than derived from the author's `PROF-05` training identity.
|
|
981
|
+
*/
|
|
982
|
+
goal?: TrainingGoal | null;
|
|
983
|
+
experienceLevel?: TrainingExperienceLevel | null;
|
|
977
984
|
days: RoutineDay[];
|
|
978
985
|
createdAt: IsoDateString;
|
|
979
986
|
updatedAt: IsoDateString;
|
|
@@ -981,6 +988,9 @@ interface Routine {
|
|
|
981
988
|
interface CreateRoutineRequest {
|
|
982
989
|
name: string;
|
|
983
990
|
description?: string;
|
|
991
|
+
/** ROUT-07; omitted means undeclared, which is not the same as a default. */
|
|
992
|
+
goal?: TrainingGoal | null;
|
|
993
|
+
experienceLevel?: TrainingExperienceLevel | null;
|
|
984
994
|
isPeriodized: boolean;
|
|
985
995
|
/** Defaults to WEEKLY. Changing it on update requires `days`. */
|
|
986
996
|
scheduleMode?: RoutineScheduleMode;
|
|
@@ -1555,6 +1565,303 @@ interface PersonalGoalsResponse {
|
|
|
1555
1565
|
goals: PersonalGoalProgress[];
|
|
1556
1566
|
}
|
|
1557
1567
|
|
|
1568
|
+
/** Owner-declared, both optional. Undeclared is not a default, it is unknown. */
|
|
1569
|
+
interface RoutineClassification {
|
|
1570
|
+
goal?: TrainingGoal | null;
|
|
1571
|
+
experienceLevel?: TrainingExperienceLevel | null;
|
|
1572
|
+
}
|
|
1573
|
+
/**
|
|
1574
|
+
* Derived from the routine's own exercises and the `EXER-09` catalog, never
|
|
1575
|
+
* stored: a stored facet drifts from the routine the moment an edit misses
|
|
1576
|
+
* its recompute.
|
|
1577
|
+
*/
|
|
1578
|
+
interface RoutineFacets {
|
|
1579
|
+
dayCount: number;
|
|
1580
|
+
exerciseCount: number;
|
|
1581
|
+
/** Muscles any day trains, primary or secondary, deduplicated. */
|
|
1582
|
+
muscles: MuscleGroup[];
|
|
1583
|
+
/** Everything the routine needs, from the catalog's closed vocabulary. */
|
|
1584
|
+
equipment: ExerciseEquipment[];
|
|
1585
|
+
/**
|
|
1586
|
+
* The longest day's estimate in minutes, by `ROUT-10`'s rule. It is an
|
|
1587
|
+
* estimate from set counts, reps and rest, and every surface that shows it
|
|
1588
|
+
* says so rather than presenting it as a measured time.
|
|
1589
|
+
*/
|
|
1590
|
+
longestDayMinutes: number;
|
|
1591
|
+
}
|
|
1592
|
+
/** One routine in a discovery result. It carries no training, as `ROUT-04`. */
|
|
1593
|
+
interface DiscoverableRoutine extends RoutineClassification, RoutineFacets {
|
|
1594
|
+
routineId: string;
|
|
1595
|
+
name: string;
|
|
1596
|
+
description: string | null;
|
|
1597
|
+
scheduleMode: RoutineScheduleMode;
|
|
1598
|
+
author: SharedRoutineOwner;
|
|
1599
|
+
updatedAt: IsoDateString;
|
|
1600
|
+
}
|
|
1601
|
+
/** Duration buckets, so a filter is a choice rather than a number entry. */
|
|
1602
|
+
declare const ROUTINE_DURATION_BANDS: readonly ["SHORT", "MEDIUM", "LONG"];
|
|
1603
|
+
type RoutineDurationBand = (typeof ROUTINE_DURATION_BANDS)[number];
|
|
1604
|
+
/** Upper bound of each band in minutes; `LONG` is anything above `MEDIUM`. */
|
|
1605
|
+
declare const ROUTINE_DURATION_BAND_MAX_MINUTES: Record<Exclude<RoutineDurationBand, 'LONG'>, number>;
|
|
1606
|
+
/** GET /routines/discover */
|
|
1607
|
+
interface RoutineDiscoveryQuery {
|
|
1608
|
+
/** Matches the routine name or description, case-insensitively. */
|
|
1609
|
+
q?: string;
|
|
1610
|
+
goal?: TrainingGoal;
|
|
1611
|
+
experienceLevel?: TrainingExperienceLevel;
|
|
1612
|
+
/** Exact number of training days a week. */
|
|
1613
|
+
days?: number;
|
|
1614
|
+
/** The routine must train this muscle, primary or secondary. */
|
|
1615
|
+
muscle?: MuscleGroup;
|
|
1616
|
+
/** The routine must need nothing outside what the viewer selects. */
|
|
1617
|
+
equipment?: ExerciseEquipment[];
|
|
1618
|
+
duration?: RoutineDurationBand;
|
|
1619
|
+
limit?: number;
|
|
1620
|
+
/** Opaque; from the previous page's `nextCursor`. */
|
|
1621
|
+
cursor?: string;
|
|
1622
|
+
}
|
|
1623
|
+
declare const ROUTINE_DISCOVERY_DEFAULT_LIMIT = 20;
|
|
1624
|
+
declare const ROUTINE_DISCOVERY_MAX_LIMIT = 50;
|
|
1625
|
+
/**
|
|
1626
|
+
* How many readable routines one request will consider before filtering.
|
|
1627
|
+
* The scan is bounded on purpose, and the response says when it ran out
|
|
1628
|
+
* rather than quietly returning a partial answer as a complete one.
|
|
1629
|
+
*/
|
|
1630
|
+
declare const ROUTINE_DISCOVERY_SCAN_LIMIT = 500;
|
|
1631
|
+
interface RoutineDiscoveryResponse {
|
|
1632
|
+
routines: DiscoverableRoutine[];
|
|
1633
|
+
nextCursor?: string;
|
|
1634
|
+
/**
|
|
1635
|
+
* True when the scan limit was reached, so results may be incomplete. The
|
|
1636
|
+
* UI says so; it never presents a truncated page as everything there is.
|
|
1637
|
+
*/
|
|
1638
|
+
scanTruncated: boolean;
|
|
1639
|
+
}
|
|
1640
|
+
|
|
1641
|
+
declare const ACTIVITY_TYPES: readonly ["SESSION_COMPLETED", "PERSONAL_RECORD", "PROGRESSION_CHANGED", "ACHIEVEMENT_UNLOCKED", "STREAK_MILESTONE", "COMEBACK", "ROUTINE_SHARED"];
|
|
1642
|
+
type ActivityType = (typeof ACTIVITY_TYPES)[number];
|
|
1643
|
+
/** The `PROF-06` sections activity can come from. */
|
|
1644
|
+
type ActivitySection = keyof Pick<ProfilePrivacySettings, 'workoutHistory' | 'records' | 'achievements' | 'routines'>;
|
|
1645
|
+
/**
|
|
1646
|
+
* The one section each type's data comes from. An entry can never be seen by
|
|
1647
|
+
* someone that section is hidden from.
|
|
1648
|
+
*/
|
|
1649
|
+
declare const ACTIVITY_TYPE_SECTIONS: Record<ActivityType, ActivitySection>;
|
|
1650
|
+
/** Who may see an entry: the `PROF-06` values, so there is one vocabulary. */
|
|
1651
|
+
type ActivityAudience = ProfileVisibility;
|
|
1652
|
+
/** Every type starts here until its owner chooses otherwise. */
|
|
1653
|
+
declare const ACTIVITY_DEFAULT_AUDIENCE: ActivityAudience;
|
|
1654
|
+
/**
|
|
1655
|
+
* Where the viewer may open the record an entry came from. The server decides
|
|
1656
|
+
* it, so the client never judges what a viewer may read; an entry whose
|
|
1657
|
+
* record has no such place for this viewer has `link: null` and still names
|
|
1658
|
+
* the record.
|
|
1659
|
+
*/
|
|
1660
|
+
type ActivityLink = {
|
|
1661
|
+
kind: 'OWN_SESSION';
|
|
1662
|
+
sessionId: string;
|
|
1663
|
+
} | {
|
|
1664
|
+
kind: 'OWN_EXERCISE';
|
|
1665
|
+
exerciseId: string;
|
|
1666
|
+
} | {
|
|
1667
|
+
kind: 'OWN_ACHIEVEMENTS';
|
|
1668
|
+
} | {
|
|
1669
|
+
kind: 'OWN_ROUTINE';
|
|
1670
|
+
routineId: string;
|
|
1671
|
+
} | {
|
|
1672
|
+
kind: 'MEMBER_RECORDS';
|
|
1673
|
+
username: string;
|
|
1674
|
+
} | {
|
|
1675
|
+
kind: 'MEMBER_ACHIEVEMENTS';
|
|
1676
|
+
username: string;
|
|
1677
|
+
} | {
|
|
1678
|
+
kind: 'MEMBER_ROUTINE';
|
|
1679
|
+
username: string;
|
|
1680
|
+
routineId: string;
|
|
1681
|
+
};
|
|
1682
|
+
interface ActivityEntryBase {
|
|
1683
|
+
/**
|
|
1684
|
+
* Stable across reads and opaque to clients. It is the key an override is
|
|
1685
|
+
* stored under, so it must be sent back unchanged.
|
|
1686
|
+
*/
|
|
1687
|
+
id: string;
|
|
1688
|
+
occurredAt: IsoDateString;
|
|
1689
|
+
author: SharedRoutineOwner;
|
|
1690
|
+
link: ActivityLink | null;
|
|
1691
|
+
/**
|
|
1692
|
+
* Shared by the facts of one workout, so a session and the records it set
|
|
1693
|
+
* can be shown together; null for a fact that belongs to no workout.
|
|
1694
|
+
*/
|
|
1695
|
+
groupKey: string | null;
|
|
1696
|
+
}
|
|
1697
|
+
interface SessionCompletedActivity extends ActivityEntryBase {
|
|
1698
|
+
type: 'SESSION_COMPLETED';
|
|
1699
|
+
session: {
|
|
1700
|
+
routineName: string;
|
|
1701
|
+
dayName: string | null;
|
|
1702
|
+
completedSets: number;
|
|
1703
|
+
/** External load × reps, canonical kilograms. */
|
|
1704
|
+
volumeKg: number;
|
|
1705
|
+
durationSec: number | null;
|
|
1706
|
+
};
|
|
1707
|
+
}
|
|
1708
|
+
interface PersonalRecordActivity extends ActivityEntryBase {
|
|
1709
|
+
type: 'PERSONAL_RECORD';
|
|
1710
|
+
record: {
|
|
1711
|
+
exerciseId: string;
|
|
1712
|
+
exerciseName: string;
|
|
1713
|
+
weightKg: number;
|
|
1714
|
+
reps: number;
|
|
1715
|
+
estimated1rmKg: number;
|
|
1716
|
+
};
|
|
1717
|
+
}
|
|
1718
|
+
interface ProgressionActivity extends ActivityEntryBase {
|
|
1719
|
+
type: 'PROGRESSION_CHANGED';
|
|
1720
|
+
progression: {
|
|
1721
|
+
exerciseId: string;
|
|
1722
|
+
exerciseName: string;
|
|
1723
|
+
sets: ProgressionSetChange[];
|
|
1724
|
+
};
|
|
1725
|
+
}
|
|
1726
|
+
interface AchievementActivity extends ActivityEntryBase {
|
|
1727
|
+
type: 'ACHIEVEMENT_UNLOCKED';
|
|
1728
|
+
achievement: {
|
|
1729
|
+
id: string;
|
|
1730
|
+
title: string;
|
|
1731
|
+
description: string;
|
|
1732
|
+
category: AchievementCategory;
|
|
1733
|
+
};
|
|
1734
|
+
}
|
|
1735
|
+
interface StreakMilestoneActivity extends ActivityEntryBase {
|
|
1736
|
+
type: 'STREAK_MILESTONE';
|
|
1737
|
+
streak: {
|
|
1738
|
+
achievementId: string;
|
|
1739
|
+
title: string;
|
|
1740
|
+
streakDays: number;
|
|
1741
|
+
};
|
|
1742
|
+
}
|
|
1743
|
+
interface ComebackActivity extends ActivityEntryBase {
|
|
1744
|
+
type: 'COMEBACK';
|
|
1745
|
+
comeback: {
|
|
1746
|
+
/** Full local-calendar days without a completed session before it. */
|
|
1747
|
+
inactiveDays: number;
|
|
1748
|
+
activeDays: number;
|
|
1749
|
+
windowDays: number;
|
|
1750
|
+
returnedAt: IsoDateString;
|
|
1751
|
+
};
|
|
1752
|
+
}
|
|
1753
|
+
interface RoutineSharedActivity extends ActivityEntryBase {
|
|
1754
|
+
type: 'ROUTINE_SHARED';
|
|
1755
|
+
routine: {
|
|
1756
|
+
routineId: string;
|
|
1757
|
+
name: string;
|
|
1758
|
+
dayCount: number;
|
|
1759
|
+
exerciseCount: number;
|
|
1760
|
+
};
|
|
1761
|
+
}
|
|
1762
|
+
type ActivityEntry = SessionCompletedActivity | PersonalRecordActivity | ProgressionActivity | AchievementActivity | StreakMilestoneActivity | ComebackActivity | RoutineSharedActivity;
|
|
1763
|
+
declare const ACTIVITY_PAGE_DEFAULT_LIMIT = 20;
|
|
1764
|
+
declare const ACTIVITY_PAGE_MAX_LIMIT = 50;
|
|
1765
|
+
/**
|
|
1766
|
+
* The feed considers at most this many followed members, and says so when it
|
|
1767
|
+
* reached the ceiling rather than presenting a partial feed as a whole one.
|
|
1768
|
+
*/
|
|
1769
|
+
declare const ACTIVITY_FEED_FOLLOWED_MAX = 500;
|
|
1770
|
+
/** Entry ids are opaque but bounded; anything longer is refused. */
|
|
1771
|
+
declare const ACTIVITY_ENTRY_ID_MAX_LENGTH = 200;
|
|
1772
|
+
interface ActivityPageQuery {
|
|
1773
|
+
limit?: number;
|
|
1774
|
+
/** Opaque; from the previous page's `nextCursor`. */
|
|
1775
|
+
cursor?: string;
|
|
1776
|
+
}
|
|
1777
|
+
interface ActivityPage<Entry = ActivityEntry> {
|
|
1778
|
+
entries: Entry[];
|
|
1779
|
+
nextCursor?: string;
|
|
1780
|
+
}
|
|
1781
|
+
/**
|
|
1782
|
+
* GET /activity/feed: activity of the members the viewer follows that each
|
|
1783
|
+
* member's audiences allow the viewer to see, newest first.
|
|
1784
|
+
*/
|
|
1785
|
+
interface ActivityFeedResponse extends ActivityPage {
|
|
1786
|
+
/**
|
|
1787
|
+
* How many members the viewer follows, so an empty feed can say whether
|
|
1788
|
+
* there is nobody to hear from or nothing they were allowed to see.
|
|
1789
|
+
*/
|
|
1790
|
+
followedCount: number;
|
|
1791
|
+
/** True when the viewer follows more than `ACTIVITY_FEED_FOLLOWED_MAX`. */
|
|
1792
|
+
followedTruncated: boolean;
|
|
1793
|
+
}
|
|
1794
|
+
/** GET /activity/members/:identifier — one member's activity, as this viewer may see it. */
|
|
1795
|
+
type MemberActivityResponse = ActivityPage;
|
|
1796
|
+
/** What narrowed an entry below the audience its owner chose. */
|
|
1797
|
+
declare const ACTIVITY_CAPS: readonly ["SECTION", "ROUTINE"];
|
|
1798
|
+
type ActivityCap = (typeof ACTIVITY_CAPS)[number];
|
|
1799
|
+
/** How one of the owner's own entries is shared. */
|
|
1800
|
+
interface ActivityEntrySharing {
|
|
1801
|
+
section: ActivitySection;
|
|
1802
|
+
/** The owner's current rule for that section. */
|
|
1803
|
+
sectionRule: ProfileVisibility;
|
|
1804
|
+
/** The type's default audience. */
|
|
1805
|
+
defaultAudience: ActivityAudience;
|
|
1806
|
+
/** This entry's own audience, or null when it follows the default. */
|
|
1807
|
+
override: ActivityAudience | null;
|
|
1808
|
+
/**
|
|
1809
|
+
* Who can actually see it: the narrowest of the section rule, the chosen
|
|
1810
|
+
* audience and, for a shared routine, the routine's own visibility.
|
|
1811
|
+
*/
|
|
1812
|
+
effectiveAudience: ActivityAudience;
|
|
1813
|
+
/** Set when the effective audience is narrower than the one chosen. */
|
|
1814
|
+
cappedBy: ActivityCap | null;
|
|
1815
|
+
}
|
|
1816
|
+
type OwnActivityEntry = ActivityEntry & {
|
|
1817
|
+
sharing: ActivityEntrySharing;
|
|
1818
|
+
};
|
|
1819
|
+
/** GET /activity/mine — every entry of the owner's, whoever may see it. */
|
|
1820
|
+
type OwnActivityResponse = ActivityPage<OwnActivityEntry>;
|
|
1821
|
+
/**
|
|
1822
|
+
* The audiences the owner can preview. `FOLLOWERS` is a member who follows
|
|
1823
|
+
* them; `PUBLIC` is any other signed-in member. Activity is never shown
|
|
1824
|
+
* signed out.
|
|
1825
|
+
*/
|
|
1826
|
+
declare const ACTIVITY_PREVIEW_AUDIENCES: readonly ["FOLLOWERS", "PUBLIC"];
|
|
1827
|
+
type ActivityPreviewAudience = (typeof ACTIVITY_PREVIEW_AUDIENCES)[number];
|
|
1828
|
+
/**
|
|
1829
|
+
* GET /activity/mine/preview — the owner's activity exactly as that audience
|
|
1830
|
+
* would receive it, through the same read, links included.
|
|
1831
|
+
*/
|
|
1832
|
+
interface ActivityPreviewQuery extends ActivityPageQuery {
|
|
1833
|
+
audience: ActivityPreviewAudience;
|
|
1834
|
+
}
|
|
1835
|
+
/** GET and PUT /activity/sharing */
|
|
1836
|
+
interface ActivitySharingSettings {
|
|
1837
|
+
/** The default audience of every type. */
|
|
1838
|
+
defaults: Record<ActivityType, ActivityAudience>;
|
|
1839
|
+
/** The section rules that cap them, so the UI can say when one does. */
|
|
1840
|
+
sections: Record<ActivitySection, ProfileVisibility>;
|
|
1841
|
+
}
|
|
1842
|
+
/**
|
|
1843
|
+
* PUT /activity/sharing. A partial write: an omitted type keeps its stored
|
|
1844
|
+
* default. A default applies to past entries of the type as well as future
|
|
1845
|
+
* ones, except those with their own audience.
|
|
1846
|
+
*/
|
|
1847
|
+
interface UpdateActivitySharingRequest {
|
|
1848
|
+
defaults: Partial<Record<ActivityType, ActivityAudience>>;
|
|
1849
|
+
}
|
|
1850
|
+
/**
|
|
1851
|
+
* PUT /activity/entries/audience. `null` returns the entry to its type's
|
|
1852
|
+
* default; `PRIVATE` withdraws it from everyone but its owner. Either way it
|
|
1853
|
+
* can never exceed its section.
|
|
1854
|
+
*/
|
|
1855
|
+
interface SetActivityEntryAudienceRequest {
|
|
1856
|
+
entryId: string;
|
|
1857
|
+
audience: ActivityAudience | null;
|
|
1858
|
+
}
|
|
1859
|
+
/** Stable successful response of PUT /activity/entries/audience. */
|
|
1860
|
+
interface SetActivityEntryAudienceResponse {
|
|
1861
|
+
entryId: string;
|
|
1862
|
+
sharing: ActivityEntrySharing;
|
|
1863
|
+
}
|
|
1864
|
+
|
|
1558
1865
|
/** A local calendar date, YYYY-MM-DD. */
|
|
1559
1866
|
type CalendarDate = string;
|
|
1560
1867
|
/**
|
|
@@ -1879,4 +2186,4 @@ interface PlannedReminder {
|
|
|
1879
2186
|
routineNames: string[];
|
|
1880
2187
|
}
|
|
1881
2188
|
|
|
1882
|
-
export { ACHIEVEMENT_CATEGORIES, ACHIEVEMENT_DEFINITIONS, type AchievementCategory, type AchievementCategoryProgress, type AchievementDefinition, type AchievementNotification, type AchievementUnlockedEventPayload, type AchievementsResponse, type AppNotification, BLOCKED_MEMBERS_MAX, type BlockedMember, type BlockedMembersResponse, type Brand, CLONE_ROUTINE_REFUSALS, COMEBACK_MIN_INACTIVE_DAYS, COMEBACK_RECOGNITION_LIMIT, COMEBACK_REQUIRED_ACTIVE_DAYS, COMEBACK_SESSION_LOOKBACK, COMEBACK_WINDOW_DAYS, type CalendarDate, type CloneRoutineRefusal, type CloneRoutineRequest, type ComebackRecognition, type ComebackRecognitionSummary, type CreateReportRequest, type CreateReportResponse, type CreateRoutineDayInput, type CreateRoutineExerciseInput, type CreateRoutineRequest, type CreateRoutineVersionRequest, type CreateSessionShareRequest, type DeletePushSubscriptionRequest, EXERCISE_EQUIPMENT, EXERCISE_MECHANICS, type EarnedAchievement, type EarnedPersonalRecord, type Exercise, type ExerciseEquipment, type ExerciseId, type ExerciseMechanic, type ExercisePerformanceHistoryQuery, type ExercisePerformanceHistoryResponse, type ExercisePerformancePrescription, type ExercisePerformancePrescriptionSet, type ExercisePerformanceSession, type ExercisePerformanceSet, type ExercisePerformanceSummary, type ExercisePlateau, type ExerciseStrengthSummary, type ExerciseStrengthTrendPoint, type ExerciseStrengthTrendQuery, type ExerciseStrengthTrendResponse, FEATURED_PROFILE_ITEMS_MAX, FEATURED_PROFILE_ITEM_KINDS, FEATURED_PROFILE_REFERENCE_MAX_LENGTH, FOLLOW_SUGGESTIONS_DEFAULT_LIMIT, FOLLOW_SUGGESTIONS_MAX_LIMIT, FOLLOW_SUGGESTION_REASONS, type FeaturedProfileAchievementItem, type FeaturedProfileItem, type FeaturedProfileItemKind, type FeaturedProfileRankItem, type FeaturedProfileRecordItem, type FeaturedProfileRoutineItem, type FeaturedProfileSelection, type FeaturedProfileSelectionInput, type FeaturedProfileSelectionsResponse, type FinishStatus, type FinishWorkoutRequest, type FinishWorkoutResponse, type FollowSuggestion, type FollowSuggestionReason, type FollowSuggestionsResponse, type IsoDateString, type ListSessionsParams, MEASURABLE_GOALS_MAX, MEASURABLE_GOAL_DIRECTIONS, MEASURABLE_GOAL_TYPES, MINUTES_IN_DAY, MOVEMENT_PATTERNS, MUSCLE_GROUPS, type MarkNotificationsReadRequest, type MarkNotificationsReadResponse, type MeasurableGoal, type MeasurableGoalDirection, type MeasurableGoalExercise, type MeasurableGoalInput, type MeasurableGoalType, type MemberModerationState, type MemberRoutinesResponse, type MoveOccurrenceRequest, type MovementPattern, type MuscleGroup, type MuscleGroupHeatmapQuery, type MuscleGroupHeatmapResponse, type MuscleGroupHeatmapValue, type MuscleGroupHeatmapWeek, type MuscleVolumeTrendSeries, NOTIFICATIONS_LIST_LIMIT, NOTIFICATIONS_LOOKBACK_DAYS, NOTIFICATIONS_RETENTION_DAYS, NOTIFICATION_CATEGORIES, NOTIFICATION_KINDS, type NewFollowerNotification, type NotificationCategory, type NotificationKind, type NotificationPreferences, type NotificationPreferencesResponse, type NotificationsResponse, PLATEAU_MIN_DAYS_SINCE_BEST, PLATEAU_MIN_SESSIONS, PLATEAU_MIN_SESSIONS_MAX, PLATEAU_MIN_SESSIONS_MIN, PLATEAU_RECENT_DAYS, PLATEAU_WINDOW_DAYS, PREFERRED_TRAINING_STYLE_VALUES, PROFILE_BIO_MAX_LENGTH, PROFILE_FAVORITE_EXERCISES_MAX, PROFILE_LOCATION_MAX_LENGTH, PROFILE_TRAINING_DISCIPLINES_MAX, PROFILE_TRAINING_GOALS_MAX, PROFILE_VISIBILITY_VALUES, PROGRESSION_SCHEMES, PROGRESS_TIMELINE_EVENT_TYPES, PUSH_PAYLOAD_KINDS, PUSH_SUBSCRIPTIONS_MAX, type PaginatedResponse, type PersonalGoalProgress, type PersonalGoalsResponse, type PersonalRecordEntry, type PersonalRecordKind, type PlannedReminder, type PlatePairInventory, type PlateauPreferences, type PlateauSet, type PlateausResponse, type PreferredTrainingStyle, type PreviousPerformanceResponse, type PreviousSessionRecap, type PreviousSetPerformance, type ProfileDiscoverySettings, type ProfileFavoriteExercise, type ProfilePrivacySettings, type ProfileViewerAccess, type ProfileVisibility, type ProgressTimelineEventType, type ProgressTimelineItem, type ProgressTimelinePersonalRecordItem, type ProgressTimelineProgressionItem, type ProgressTimelineQuery, type ProgressTimelineRecordPerformance, type ProgressTimelineRecordReason, type ProgressTimelineResponse, type ProgressTimelineSessionContext, type ProgressionChange, type ProgressionRule, type ProgressionScheme, type ProgressionSetChange, type PublicBodyMetrics, type PublicProfileAchievements, type PublicTrainingSummary, type PublicUserProfile, type PushPayload, type PushPayloadKind, type PushSubscriptionKeys, type PushSubscriptionSummary, type PushSubscriptionsResponse, type QuietHours, RELATIONSHIP_LIST_DEFAULT_LIMIT, RELATIONSHIP_LIST_KINDS, RELATIONSHIP_LIST_MAX_LIMIT, RENAISSANCE_RANK_DEFINITIONS, REPORTS_PER_DAY_MAX, REPORT_DETAILS_MAX_LENGTH, REPORT_REASONS, REPORT_SUBJECT_KINDS, REP_TYPES, RESERVED_USERNAMES, REST_ALERT_MAX_LEAD_SECONDS, REST_ALERT_MIN_LEAD_SECONDS, REST_ALERT_REFUSALS, ROUTINE_DAYS_MAX, ROUTINE_DAY_NAME_MAX, ROUTINE_SCHEDULE_MODES, ROUTINE_SHARE_MAX_ACTIVE_LINKS, ROUTINE_VERSIONS_MAX, ROUTINE_VERSION_KINDS, ROUTINE_VERSION_NAME_MAX, ROUTINE_VISIBILITY_VALUES, type RecentActivityEntry, type RegisterPushSubscriptionRequest, type RelationshipListKind, type RelationshipListQuery, type RelationshipListResponse, type RelationshipMember, type RenaissanceRankDefinition, type RenaissanceRankProgress, type RepType, type ReplaceFeaturedProfileItemsRequest, type ReplaceMeasurableGoalsRequest, type ReplaceTrainingLocationsRequest, type ReportReason, type ReportSubjectKind, type RestAlertPushPayload, type RestAlertRefusal, type RestoreRoutineVersionResponse, type Routine, type RoutineDay, type RoutineDayId, type RoutineExercise, type RoutineId, type RoutineLineage, type RoutineScheduleMode, type RoutineSet, type RoutineShare, type RoutineShareListResponse, type RoutineVersion, type RoutineVersionDay, type RoutineVersionExercise, type RoutineVersionKind, type RoutineVersionSetup, type RoutineVersionsResponse, type RoutineVisibility, SCHEDULE_MOVE_MAX_DAYS, SCHEDULE_OVERRIDES_MAX_RANGE_DAYS, SCHEDULE_OVERRIDE_KINDS, SCHEDULE_SKIP_PAST_DAYS, SESSION_SHARE_DEFAULT_FIELDS, SESSION_SHARE_FIELDS, SESSION_SHARE_MAX_ACTIVE_LINKS, SEXES, SHARED_ROUTINE_SOURCES, STARRED_EXERCISES_MAX, STREAK_MAX_GAP_DAYS, type ScheduleOverride, type ScheduleOverrideKind, type ScheduleOverridesQuery, type ScheduleOverridesResponse, type ScheduleRestAlertRequest, type ScheduleRestAlertResponse, type SessionComparisonExercise, type SessionComparisonQuery, type SessionComparisonResponse, type SessionComparisonRoutineDay, type SessionComparisonSession, type SessionComparisonSet, type SessionExerciseSubstitution, type SessionProgressNotification, type SessionRecapRecord, type SessionShare, type SessionShareField, type SessionShareListResponse, type SetAccountTimeZoneRequest, type SetLog, type Sex, type SharedRoutine, type SharedRoutineOwner, type SharedRoutineSource, type SharedRoutineSummary, type SharedSessionOwner, type SharedSessionRecap, type SkipOccurrenceRequest, type StarredExercise, type StarredExercisesResponse, type StartWorkoutRequest, type StartWorkoutResponse, type StreakAtRiskPushPayload, type StreakMilestoneEventPayload, type SubstituteSessionExerciseRequest, type SubstituteSessionExerciseResponse, type SupabaseAuthResponse, type SupabaseAuthUser, type SupabaseMigrationResponse, TRAINING_DISCIPLINE_VALUES, TRAINING_EVENT_TYPES, TRAINING_EXPERIENCE_LEVEL_VALUES, TRAINING_GOAL_VALUES, type TrainingDiscipline, type TrainingEventType, type TrainingExperienceLevel, type TrainingGoal, type TrainingIdentity, type TrainingLocationPreference, type TrainingLocationPreferenceInput, type TrainingReminderPreference, type TrainingReminderPushPayload, USERNAME_MAX_LENGTH, USERNAME_MIN_LENGTH, USERNAME_PATTERN_SOURCE, type UpdateNotificationPreferencesRequest, type UpdateProfileDiscoveryRequest, type UpdateProfilePrivacyRequest, type UpdateProfileRequest, type UpdateRoutineRequest, type UpdateRoutineVisibilityRequest, type UpsertSetLogRequest, type UpsertSetLogResponse, type UserId, type UserProfile, type UserSearchResponse, type VolumeTrendPoint, type VolumeTrendQuery, type VolumeTrendResponse, type VolumeTrendSeries, WEIGHT_UNITS, WORKOUT_SESSION_STATUSES, type WeightUnit, type WorkoutAnalyticsStatus, type WorkoutProgressQuery, type WorkoutProgressResponse, type WorkoutSession, type WorkoutSessionId, type WorkoutSessionListResponse, type WorkoutSessionRecap, type WorkoutSessionSnapshotV1, type WorkoutSessionStatus, type WorkoutSessionSummary, type WorkoutStatsQuery, type WorkoutStatsResponse, isWithinQuietHours, routineDayLabel };
|
|
2189
|
+
export { ACHIEVEMENT_CATEGORIES, ACHIEVEMENT_DEFINITIONS, ACTIVITY_CAPS, ACTIVITY_DEFAULT_AUDIENCE, ACTIVITY_ENTRY_ID_MAX_LENGTH, ACTIVITY_FEED_FOLLOWED_MAX, ACTIVITY_PAGE_DEFAULT_LIMIT, ACTIVITY_PAGE_MAX_LIMIT, ACTIVITY_PREVIEW_AUDIENCES, ACTIVITY_TYPES, ACTIVITY_TYPE_SECTIONS, type AchievementActivity, type AchievementCategory, type AchievementCategoryProgress, type AchievementDefinition, type AchievementNotification, type AchievementUnlockedEventPayload, type AchievementsResponse, type ActivityAudience, type ActivityCap, type ActivityEntry, type ActivityEntrySharing, type ActivityFeedResponse, type ActivityLink, type ActivityPage, type ActivityPageQuery, type ActivityPreviewAudience, type ActivityPreviewQuery, type ActivitySection, type ActivitySharingSettings, type ActivityType, type AppNotification, BLOCKED_MEMBERS_MAX, type BlockedMember, type BlockedMembersResponse, type Brand, CLONE_ROUTINE_REFUSALS, COMEBACK_MIN_INACTIVE_DAYS, COMEBACK_RECOGNITION_LIMIT, COMEBACK_REQUIRED_ACTIVE_DAYS, COMEBACK_SESSION_LOOKBACK, COMEBACK_WINDOW_DAYS, type CalendarDate, type CloneRoutineRefusal, type CloneRoutineRequest, type ComebackActivity, type ComebackRecognition, type ComebackRecognitionSummary, type CreateReportRequest, type CreateReportResponse, type CreateRoutineDayInput, type CreateRoutineExerciseInput, type CreateRoutineRequest, type CreateRoutineVersionRequest, type CreateSessionShareRequest, type DeletePushSubscriptionRequest, type DiscoverableRoutine, EXERCISE_EQUIPMENT, EXERCISE_MECHANICS, type EarnedAchievement, type EarnedPersonalRecord, type Exercise, type ExerciseEquipment, type ExerciseId, type ExerciseMechanic, type ExercisePerformanceHistoryQuery, type ExercisePerformanceHistoryResponse, type ExercisePerformancePrescription, type ExercisePerformancePrescriptionSet, type ExercisePerformanceSession, type ExercisePerformanceSet, type ExercisePerformanceSummary, type ExercisePlateau, type ExerciseStrengthSummary, type ExerciseStrengthTrendPoint, type ExerciseStrengthTrendQuery, type ExerciseStrengthTrendResponse, FEATURED_PROFILE_ITEMS_MAX, FEATURED_PROFILE_ITEM_KINDS, FEATURED_PROFILE_REFERENCE_MAX_LENGTH, FOLLOW_SUGGESTIONS_DEFAULT_LIMIT, FOLLOW_SUGGESTIONS_MAX_LIMIT, FOLLOW_SUGGESTION_REASONS, type FeaturedProfileAchievementItem, type FeaturedProfileItem, type FeaturedProfileItemKind, type FeaturedProfileRankItem, type FeaturedProfileRecordItem, type FeaturedProfileRoutineItem, type FeaturedProfileSelection, type FeaturedProfileSelectionInput, type FeaturedProfileSelectionsResponse, type FinishStatus, type FinishWorkoutRequest, type FinishWorkoutResponse, type FollowSuggestion, type FollowSuggestionReason, type FollowSuggestionsResponse, type IsoDateString, type ListSessionsParams, MEASURABLE_GOALS_MAX, MEASURABLE_GOAL_DIRECTIONS, MEASURABLE_GOAL_TYPES, MINUTES_IN_DAY, MOVEMENT_PATTERNS, MUSCLE_GROUPS, type MarkNotificationsReadRequest, type MarkNotificationsReadResponse, type MeasurableGoal, type MeasurableGoalDirection, type MeasurableGoalExercise, type MeasurableGoalInput, type MeasurableGoalType, type MemberActivityResponse, type MemberModerationState, type MemberRoutinesResponse, type MoveOccurrenceRequest, type MovementPattern, type MuscleGroup, type MuscleGroupHeatmapQuery, type MuscleGroupHeatmapResponse, type MuscleGroupHeatmapValue, type MuscleGroupHeatmapWeek, type MuscleVolumeTrendSeries, NOTIFICATIONS_LIST_LIMIT, NOTIFICATIONS_LOOKBACK_DAYS, NOTIFICATIONS_RETENTION_DAYS, NOTIFICATION_CATEGORIES, NOTIFICATION_KINDS, type NewFollowerNotification, type NotificationCategory, type NotificationKind, type NotificationPreferences, type NotificationPreferencesResponse, type NotificationsResponse, type OwnActivityEntry, type OwnActivityResponse, PLATEAU_MIN_DAYS_SINCE_BEST, PLATEAU_MIN_SESSIONS, PLATEAU_MIN_SESSIONS_MAX, PLATEAU_MIN_SESSIONS_MIN, PLATEAU_RECENT_DAYS, PLATEAU_WINDOW_DAYS, PREFERRED_TRAINING_STYLE_VALUES, PROFILE_BIO_MAX_LENGTH, PROFILE_FAVORITE_EXERCISES_MAX, PROFILE_LOCATION_MAX_LENGTH, PROFILE_TRAINING_DISCIPLINES_MAX, PROFILE_TRAINING_GOALS_MAX, PROFILE_VISIBILITY_VALUES, PROGRESSION_SCHEMES, PROGRESS_TIMELINE_EVENT_TYPES, PUSH_PAYLOAD_KINDS, PUSH_SUBSCRIPTIONS_MAX, type PaginatedResponse, type PersonalGoalProgress, type PersonalGoalsResponse, type PersonalRecordActivity, type PersonalRecordEntry, type PersonalRecordKind, type PlannedReminder, type PlatePairInventory, type PlateauPreferences, type PlateauSet, type PlateausResponse, type PreferredTrainingStyle, type PreviousPerformanceResponse, type PreviousSessionRecap, type PreviousSetPerformance, type ProfileDiscoverySettings, type ProfileFavoriteExercise, type ProfilePrivacySettings, type ProfileViewerAccess, type ProfileVisibility, type ProgressTimelineEventType, type ProgressTimelineItem, type ProgressTimelinePersonalRecordItem, type ProgressTimelineProgressionItem, type ProgressTimelineQuery, type ProgressTimelineRecordPerformance, type ProgressTimelineRecordReason, type ProgressTimelineResponse, type ProgressTimelineSessionContext, type ProgressionActivity, type ProgressionChange, type ProgressionRule, type ProgressionScheme, type ProgressionSetChange, type PublicBodyMetrics, type PublicProfileAchievements, type PublicTrainingSummary, type PublicUserProfile, type PushPayload, type PushPayloadKind, type PushSubscriptionKeys, type PushSubscriptionSummary, type PushSubscriptionsResponse, type QuietHours, RELATIONSHIP_LIST_DEFAULT_LIMIT, RELATIONSHIP_LIST_KINDS, RELATIONSHIP_LIST_MAX_LIMIT, RENAISSANCE_RANK_DEFINITIONS, REPORTS_PER_DAY_MAX, REPORT_DETAILS_MAX_LENGTH, REPORT_REASONS, REPORT_SUBJECT_KINDS, REP_TYPES, RESERVED_USERNAMES, REST_ALERT_MAX_LEAD_SECONDS, REST_ALERT_MIN_LEAD_SECONDS, REST_ALERT_REFUSALS, ROUTINE_DAYS_MAX, ROUTINE_DAY_NAME_MAX, ROUTINE_DISCOVERY_DEFAULT_LIMIT, ROUTINE_DISCOVERY_MAX_LIMIT, ROUTINE_DISCOVERY_SCAN_LIMIT, ROUTINE_DURATION_BANDS, ROUTINE_DURATION_BAND_MAX_MINUTES, ROUTINE_SCHEDULE_MODES, ROUTINE_SHARE_MAX_ACTIVE_LINKS, ROUTINE_VERSIONS_MAX, ROUTINE_VERSION_KINDS, ROUTINE_VERSION_NAME_MAX, ROUTINE_VISIBILITY_VALUES, type RecentActivityEntry, type RegisterPushSubscriptionRequest, type RelationshipListKind, type RelationshipListQuery, type RelationshipListResponse, type RelationshipMember, type RenaissanceRankDefinition, type RenaissanceRankProgress, type RepType, type ReplaceFeaturedProfileItemsRequest, type ReplaceMeasurableGoalsRequest, type ReplaceTrainingLocationsRequest, type ReportReason, type ReportSubjectKind, type RestAlertPushPayload, type RestAlertRefusal, type RestoreRoutineVersionResponse, type Routine, type RoutineClassification, type RoutineDay, type RoutineDayId, type RoutineDiscoveryQuery, type RoutineDiscoveryResponse, type RoutineDurationBand, type RoutineExercise, type RoutineFacets, type RoutineId, type RoutineLineage, type RoutineScheduleMode, type RoutineSet, type RoutineShare, type RoutineShareListResponse, type RoutineSharedActivity, type RoutineVersion, type RoutineVersionDay, type RoutineVersionExercise, type RoutineVersionKind, type RoutineVersionSetup, type RoutineVersionsResponse, type RoutineVisibility, SCHEDULE_MOVE_MAX_DAYS, SCHEDULE_OVERRIDES_MAX_RANGE_DAYS, SCHEDULE_OVERRIDE_KINDS, SCHEDULE_SKIP_PAST_DAYS, SESSION_SHARE_DEFAULT_FIELDS, SESSION_SHARE_FIELDS, SESSION_SHARE_MAX_ACTIVE_LINKS, SEXES, SHARED_ROUTINE_SOURCES, STARRED_EXERCISES_MAX, STREAK_MAX_GAP_DAYS, type ScheduleOverride, type ScheduleOverrideKind, type ScheduleOverridesQuery, type ScheduleOverridesResponse, type ScheduleRestAlertRequest, type ScheduleRestAlertResponse, type SessionComparisonExercise, type SessionComparisonQuery, type SessionComparisonResponse, type SessionComparisonRoutineDay, type SessionComparisonSession, type SessionComparisonSet, type SessionCompletedActivity, type SessionExerciseSubstitution, type SessionProgressNotification, type SessionRecapRecord, type SessionShare, type SessionShareField, type SessionShareListResponse, type SetAccountTimeZoneRequest, type SetActivityEntryAudienceRequest, type SetActivityEntryAudienceResponse, type SetLog, type Sex, type SharedRoutine, type SharedRoutineOwner, type SharedRoutineSource, type SharedRoutineSummary, type SharedSessionOwner, type SharedSessionRecap, type SkipOccurrenceRequest, type StarredExercise, type StarredExercisesResponse, type StartWorkoutRequest, type StartWorkoutResponse, type StreakAtRiskPushPayload, type StreakMilestoneActivity, type StreakMilestoneEventPayload, type SubstituteSessionExerciseRequest, type SubstituteSessionExerciseResponse, type SupabaseAuthResponse, type SupabaseAuthUser, type SupabaseMigrationResponse, TRAINING_DISCIPLINE_VALUES, TRAINING_EVENT_TYPES, TRAINING_EXPERIENCE_LEVEL_VALUES, TRAINING_GOAL_VALUES, type TrainingDiscipline, type TrainingEventType, type TrainingExperienceLevel, type TrainingGoal, type TrainingIdentity, type TrainingLocationPreference, type TrainingLocationPreferenceInput, type TrainingReminderPreference, type TrainingReminderPushPayload, USERNAME_MAX_LENGTH, USERNAME_MIN_LENGTH, USERNAME_PATTERN_SOURCE, type UpdateActivitySharingRequest, type UpdateNotificationPreferencesRequest, type UpdateProfileDiscoveryRequest, type UpdateProfilePrivacyRequest, type UpdateProfileRequest, type UpdateRoutineRequest, type UpdateRoutineVisibilityRequest, type UpsertSetLogRequest, type UpsertSetLogResponse, type UserId, type UserProfile, type UserSearchResponse, type VolumeTrendPoint, type VolumeTrendQuery, type VolumeTrendResponse, type VolumeTrendSeries, WEIGHT_UNITS, WORKOUT_SESSION_STATUSES, type WeightUnit, type WorkoutAnalyticsStatus, type WorkoutProgressQuery, type WorkoutProgressResponse, type WorkoutSession, type WorkoutSessionId, type WorkoutSessionListResponse, type WorkoutSessionRecap, type WorkoutSessionSnapshotV1, type WorkoutSessionStatus, type WorkoutSessionSummary, type WorkoutStatsQuery, type WorkoutStatsResponse, isWithinQuietHours, routineDayLabel };
|
package/dist/index.js
CHANGED
|
@@ -346,6 +346,40 @@ var CLONE_ROUTINE_REFUSALS = {
|
|
|
346
346
|
UNKNOWN_EXERCISE: "UNKNOWN_EXERCISE"
|
|
347
347
|
};
|
|
348
348
|
|
|
349
|
+
// src/routine-discovery.ts
|
|
350
|
+
var ROUTINE_DURATION_BANDS = ["SHORT", "MEDIUM", "LONG"];
|
|
351
|
+
var ROUTINE_DURATION_BAND_MAX_MINUTES = { SHORT: 45, MEDIUM: 75 };
|
|
352
|
+
var ROUTINE_DISCOVERY_DEFAULT_LIMIT = 20;
|
|
353
|
+
var ROUTINE_DISCOVERY_MAX_LIMIT = 50;
|
|
354
|
+
var ROUTINE_DISCOVERY_SCAN_LIMIT = 500;
|
|
355
|
+
|
|
356
|
+
// src/activity.ts
|
|
357
|
+
var ACTIVITY_TYPES = [
|
|
358
|
+
"SESSION_COMPLETED",
|
|
359
|
+
"PERSONAL_RECORD",
|
|
360
|
+
"PROGRESSION_CHANGED",
|
|
361
|
+
"ACHIEVEMENT_UNLOCKED",
|
|
362
|
+
"STREAK_MILESTONE",
|
|
363
|
+
"COMEBACK",
|
|
364
|
+
"ROUTINE_SHARED"
|
|
365
|
+
];
|
|
366
|
+
var ACTIVITY_TYPE_SECTIONS = {
|
|
367
|
+
SESSION_COMPLETED: "workoutHistory",
|
|
368
|
+
PERSONAL_RECORD: "records",
|
|
369
|
+
PROGRESSION_CHANGED: "workoutHistory",
|
|
370
|
+
ACHIEVEMENT_UNLOCKED: "achievements",
|
|
371
|
+
STREAK_MILESTONE: "achievements",
|
|
372
|
+
COMEBACK: "achievements",
|
|
373
|
+
ROUTINE_SHARED: "routines"
|
|
374
|
+
};
|
|
375
|
+
var ACTIVITY_DEFAULT_AUDIENCE = "PRIVATE";
|
|
376
|
+
var ACTIVITY_PAGE_DEFAULT_LIMIT = 20;
|
|
377
|
+
var ACTIVITY_PAGE_MAX_LIMIT = 50;
|
|
378
|
+
var ACTIVITY_FEED_FOLLOWED_MAX = 500;
|
|
379
|
+
var ACTIVITY_ENTRY_ID_MAX_LENGTH = 200;
|
|
380
|
+
var ACTIVITY_CAPS = ["SECTION", "ROUTINE"];
|
|
381
|
+
var ACTIVITY_PREVIEW_AUDIENCES = ["FOLLOWERS", "PUBLIC"];
|
|
382
|
+
|
|
349
383
|
// src/schedule.ts
|
|
350
384
|
var SCHEDULE_OVERRIDE_KINDS = ["MOVE", "SKIP"];
|
|
351
385
|
var SCHEDULE_MOVE_MAX_DAYS = 6;
|
|
@@ -437,6 +471,15 @@ var STREAK_MAX_GAP_DAYS = 3;
|
|
|
437
471
|
export {
|
|
438
472
|
ACHIEVEMENT_CATEGORIES,
|
|
439
473
|
ACHIEVEMENT_DEFINITIONS,
|
|
474
|
+
ACTIVITY_CAPS,
|
|
475
|
+
ACTIVITY_DEFAULT_AUDIENCE,
|
|
476
|
+
ACTIVITY_ENTRY_ID_MAX_LENGTH,
|
|
477
|
+
ACTIVITY_FEED_FOLLOWED_MAX,
|
|
478
|
+
ACTIVITY_PAGE_DEFAULT_LIMIT,
|
|
479
|
+
ACTIVITY_PAGE_MAX_LIMIT,
|
|
480
|
+
ACTIVITY_PREVIEW_AUDIENCES,
|
|
481
|
+
ACTIVITY_TYPES,
|
|
482
|
+
ACTIVITY_TYPE_SECTIONS,
|
|
440
483
|
BLOCKED_MEMBERS_MAX,
|
|
441
484
|
CLONE_ROUTINE_REFUSALS,
|
|
442
485
|
COMEBACK_MIN_INACTIVE_DAYS,
|
|
@@ -495,6 +538,11 @@ export {
|
|
|
495
538
|
REST_ALERT_REFUSALS,
|
|
496
539
|
ROUTINE_DAYS_MAX,
|
|
497
540
|
ROUTINE_DAY_NAME_MAX,
|
|
541
|
+
ROUTINE_DISCOVERY_DEFAULT_LIMIT,
|
|
542
|
+
ROUTINE_DISCOVERY_MAX_LIMIT,
|
|
543
|
+
ROUTINE_DISCOVERY_SCAN_LIMIT,
|
|
544
|
+
ROUTINE_DURATION_BANDS,
|
|
545
|
+
ROUTINE_DURATION_BAND_MAX_MINUTES,
|
|
498
546
|
ROUTINE_SCHEDULE_MODES,
|
|
499
547
|
ROUTINE_SHARE_MAX_ACTIVE_LINKS,
|
|
500
548
|
ROUTINE_VERSIONS_MAX,
|