@demind-inc/core 1.4.30 → 1.4.32

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.
@@ -11,6 +11,7 @@ export declare const DB_COLLECTION: {
11
11
  EXERCISE: string;
12
12
  MEAL: string;
13
13
  HEART_RATE: string;
14
+ STRESS: string;
14
15
  RECOMMENDED_TASKS: string;
15
16
  EMAS: string;
16
17
  EMA_DATES: string;
package/dist/constants.js CHANGED
@@ -12,6 +12,7 @@ exports.DB_COLLECTION = {
12
12
  EXERCISE: "exercise",
13
13
  MEAL: "meal",
14
14
  HEART_RATE: "heartRate",
15
+ STRESS: "stress",
15
16
  RECOMMENDED_TASKS: "recommendedTasks",
16
17
  EMAS: "emas",
17
18
  EMA_DATES: "emaDates",
@@ -90,6 +90,11 @@ export interface ActivityFrom {
90
90
  export interface CalendarEventMetrics {
91
91
  energy?: EnergyFeedbackType;
92
92
  stress?: number;
93
+ heartRate?: CalendarEventHRMetrics;
94
+ }
95
+ export interface CalendarEventHRMetrics {
96
+ startHRbpm: number;
97
+ endHRbpm: number;
93
98
  }
94
99
  export type EnergyFeedbackType = "low" | "mild" | "medium" | "strong" | "high";
95
100
  export interface EventCategorySet {
@@ -6,6 +6,7 @@ export interface Metrics {
6
6
  exercise?: MetricExercise[];
7
7
  meal?: MetricMeal[];
8
8
  heartRate?: MetricHeartRate[];
9
+ stress?: MetricStress[];
9
10
  basicTimezone?: string;
10
11
  targetUserId?: string;
11
12
  }
@@ -52,6 +53,22 @@ export interface MetricHeartRate {
52
53
  hrvSdnn?: MetricHRValueSet[];
53
54
  summary?: MetricHRSummary;
54
55
  }
56
+ export interface MetricStress {
57
+ metricStressId: string;
58
+ date: string;
59
+ stress?: MetricStressValueSet[];
60
+ avgStress?: number;
61
+ maxStress?: number;
62
+ highStressDurationSeconds?: number;
63
+ lowStressDurationSeconds?: number;
64
+ mediumStressDurationSeconds?: number;
65
+ stressDurationSeconds?: number;
66
+ activityStressDurationSeconds?: number;
67
+ }
68
+ export interface MetricStressValueSet {
69
+ timestamp: string;
70
+ value: number;
71
+ }
55
72
  export interface MetricHRValueSet {
56
73
  timestamp: string;
57
74
  value: number;
package/lib/constants.ts CHANGED
@@ -12,6 +12,7 @@ export const DB_COLLECTION = {
12
12
  EXERCISE: "exercise",
13
13
  MEAL: "meal",
14
14
  HEART_RATE: "heartRate",
15
+ STRESS: "stress",
15
16
  RECOMMENDED_TASKS: "recommendedTasks",
16
17
  EMAS: "emas",
17
18
  EMA_DATES: "emaDates",
@@ -124,6 +124,12 @@ export interface ActivityFrom {
124
124
  export interface CalendarEventMetrics {
125
125
  energy?: EnergyFeedbackType;
126
126
  stress?: number;
127
+ heartRate?: CalendarEventHRMetrics;
128
+ }
129
+
130
+ export interface CalendarEventHRMetrics {
131
+ startHRbpm: number;
132
+ endHRbpm: number;
127
133
  }
128
134
 
129
135
  export type EnergyFeedbackType = "low" | "mild" | "medium" | "strong" | "high";
@@ -7,6 +7,7 @@ export interface Metrics {
7
7
  exercise?: MetricExercise[];
8
8
  meal?: MetricMeal[];
9
9
  heartRate?: MetricHeartRate[];
10
+ stress?: MetricStress[];
10
11
  basicTimezone?: string;
11
12
  targetUserId?: string;
12
13
  }
@@ -60,6 +61,24 @@ export interface MetricHeartRate {
60
61
  summary?: MetricHRSummary;
61
62
  }
62
63
 
64
+ export interface MetricStress {
65
+ metricStressId: string;
66
+ date: string;
67
+ stress?: MetricStressValueSet[];
68
+ avgStress?: number;
69
+ maxStress?: number;
70
+ highStressDurationSeconds?: number;
71
+ lowStressDurationSeconds?: number;
72
+ mediumStressDurationSeconds?: number;
73
+ stressDurationSeconds?: number;
74
+ activityStressDurationSeconds?: number;
75
+ }
76
+
77
+ export interface MetricStressValueSet {
78
+ timestamp: string;
79
+ value: number;
80
+ }
81
+
63
82
  export interface MetricHRValueSet {
64
83
  timestamp: string;
65
84
  value: number;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@demind-inc/core",
3
- "version": "1.4.30",
3
+ "version": "1.4.32",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "scripts": {