@taphealth/kafka 1.2.57 → 1.2.58
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/events/activity-logged.d.ts +5 -1
- package/dist/events/diet-created.d.ts +5 -0
- package/dist/events/education-created.d.ts +4 -0
- package/dist/events/exercise-created.d.ts +5 -0
- package/dist/events/glucose-created.d.ts +5 -0
- package/dist/events/steps-logging.d.ts +13 -0
- package/dist/events/steps-logging.js +2 -0
- package/dist/index.d.ts +2 -1
- package/dist/index.js +2 -1
- package/dist/topics.d.ts +2 -1
- package/dist/topics.js +1 -0
- package/dist/types/activity.d.ts +6 -0
- package/dist/types/{reward.js → activity.js} +3 -3
- package/dist/types/exercise.d.ts +9 -0
- package/dist/types/exercise.js +14 -0
- package/dist/types/glucose.d.ts +6 -0
- package/dist/types/glucose.js +8 -1
- package/package.json +1 -1
- package/dist/types/reward.d.ts +0 -6
|
@@ -1,10 +1,14 @@
|
|
|
1
1
|
import { Topics } from "../topics";
|
|
2
|
-
import { ActivityType } from "../types/
|
|
2
|
+
import { ActivityType } from "../types/activity";
|
|
3
|
+
import { GlucoseRange } from "../types/glucose";
|
|
3
4
|
export interface ActivityLoggedEvent {
|
|
4
5
|
topic: Topics.ActivityLogged;
|
|
5
6
|
data: {
|
|
6
7
|
userId: string;
|
|
7
8
|
activityType: ActivityType;
|
|
8
9
|
loggedAt: Date;
|
|
10
|
+
mealType?: string;
|
|
11
|
+
hadHealthy?: boolean;
|
|
12
|
+
glucoseRange?: GlucoseRange;
|
|
9
13
|
};
|
|
10
14
|
}
|
|
@@ -1,8 +1,13 @@
|
|
|
1
1
|
import { Topics } from "../topics";
|
|
2
|
+
import { ExerciseDifficulty, ExerciseStatus } from "../types/exercise";
|
|
2
3
|
export interface ExerciseCreatedEvent {
|
|
3
4
|
topic: Topics.ExerciseCreated;
|
|
4
5
|
data: {
|
|
5
6
|
userId: string;
|
|
6
7
|
scheduledDate: string;
|
|
8
|
+
date: Date;
|
|
9
|
+
name: string;
|
|
10
|
+
status: ExerciseStatus;
|
|
11
|
+
difficulty: ExerciseDifficulty;
|
|
7
12
|
};
|
|
8
13
|
}
|
|
@@ -1,8 +1,13 @@
|
|
|
1
1
|
import { Topics } from "../topics";
|
|
2
|
+
import { GlucoseType } from "../types/glucose";
|
|
2
3
|
export interface GlucoseCreatedEvent {
|
|
3
4
|
topic: Topics.GlucoseCreated;
|
|
4
5
|
data: {
|
|
5
6
|
userId: string;
|
|
6
7
|
scheduledDate: string;
|
|
8
|
+
date: Date;
|
|
9
|
+
type: GlucoseType;
|
|
10
|
+
dueTime: string;
|
|
11
|
+
hasLogged: boolean;
|
|
7
12
|
};
|
|
8
13
|
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { Topics } from "../topics";
|
|
2
|
+
export interface StepsLoggingEvent {
|
|
3
|
+
topic: Topics.StepsLogging;
|
|
4
|
+
data: {
|
|
5
|
+
userId: string;
|
|
6
|
+
Date: Date;
|
|
7
|
+
cumulativeStepsCount: number;
|
|
8
|
+
targetStepsCount: number;
|
|
9
|
+
averageCumulativeStepsCount: number;
|
|
10
|
+
caloriesBurnt: number;
|
|
11
|
+
distanceWalked: number;
|
|
12
|
+
};
|
|
13
|
+
}
|
package/dist/index.d.ts
CHANGED
|
@@ -7,7 +7,7 @@ export * from "./types/refund";
|
|
|
7
7
|
export * from "./types/payment";
|
|
8
8
|
export * from "./types/profile";
|
|
9
9
|
export * from "./types/glucose";
|
|
10
|
-
export * from "./types/
|
|
10
|
+
export * from "./types/activity";
|
|
11
11
|
export * from "./events/payment-captured";
|
|
12
12
|
export * from "./events/payment-failed";
|
|
13
13
|
export * from "./events/appointment-created";
|
|
@@ -30,3 +30,4 @@ export * from "./events/glucose-created";
|
|
|
30
30
|
export * from "./events/glucose-generate";
|
|
31
31
|
export * from "./events/glucose-logging";
|
|
32
32
|
export * from "./events/activity-logged";
|
|
33
|
+
export * from "./events/steps-logging";
|
package/dist/index.js
CHANGED
|
@@ -23,7 +23,7 @@ __exportStar(require("./types/refund"), exports);
|
|
|
23
23
|
__exportStar(require("./types/payment"), exports);
|
|
24
24
|
__exportStar(require("./types/profile"), exports);
|
|
25
25
|
__exportStar(require("./types/glucose"), exports);
|
|
26
|
-
__exportStar(require("./types/
|
|
26
|
+
__exportStar(require("./types/activity"), exports);
|
|
27
27
|
__exportStar(require("./events/payment-captured"), exports);
|
|
28
28
|
__exportStar(require("./events/payment-failed"), exports);
|
|
29
29
|
__exportStar(require("./events/appointment-created"), exports);
|
|
@@ -46,3 +46,4 @@ __exportStar(require("./events/glucose-created"), exports);
|
|
|
46
46
|
__exportStar(require("./events/glucose-generate"), exports);
|
|
47
47
|
__exportStar(require("./events/glucose-logging"), exports);
|
|
48
48
|
__exportStar(require("./events/activity-logged"), exports);
|
|
49
|
+
__exportStar(require("./events/steps-logging"), exports);
|
package/dist/topics.d.ts
CHANGED
package/dist/topics.js
CHANGED
|
@@ -4,7 +4,7 @@ exports.ActivityType = void 0;
|
|
|
4
4
|
var ActivityType;
|
|
5
5
|
(function (ActivityType) {
|
|
6
6
|
ActivityType[ActivityType["MEAL_LOGGING"] = 0] = "MEAL_LOGGING";
|
|
7
|
-
ActivityType[ActivityType["
|
|
8
|
-
ActivityType[ActivityType["
|
|
9
|
-
ActivityType[ActivityType["
|
|
7
|
+
ActivityType[ActivityType["EXERCISE_LOGGING"] = 1] = "EXERCISE_LOGGING";
|
|
8
|
+
ActivityType[ActivityType["EDUCATIONAL_LOGGING"] = 2] = "EDUCATIONAL_LOGGING";
|
|
9
|
+
ActivityType[ActivityType["GLUCOSE_LOGGING"] = 3] = "GLUCOSE_LOGGING";
|
|
10
10
|
})(ActivityType || (exports.ActivityType = ActivityType = {}));
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ExerciseDifficulty = exports.ExerciseStatus = void 0;
|
|
4
|
+
var ExerciseStatus;
|
|
5
|
+
(function (ExerciseStatus) {
|
|
6
|
+
ExerciseStatus[ExerciseStatus["INCOMPLETE"] = 0] = "INCOMPLETE";
|
|
7
|
+
ExerciseStatus[ExerciseStatus["COMPLETE"] = 1] = "COMPLETE";
|
|
8
|
+
})(ExerciseStatus || (exports.ExerciseStatus = ExerciseStatus = {}));
|
|
9
|
+
var ExerciseDifficulty;
|
|
10
|
+
(function (ExerciseDifficulty) {
|
|
11
|
+
ExerciseDifficulty[ExerciseDifficulty["EASY"] = 0] = "EASY";
|
|
12
|
+
ExerciseDifficulty[ExerciseDifficulty["MODERATE"] = 1] = "MODERATE";
|
|
13
|
+
ExerciseDifficulty[ExerciseDifficulty["CHALLENGING"] = 2] = "CHALLENGING";
|
|
14
|
+
})(ExerciseDifficulty || (exports.ExerciseDifficulty = ExerciseDifficulty = {}));
|
package/dist/types/glucose.d.ts
CHANGED
package/dist/types/glucose.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.GlucoseType = void 0;
|
|
3
|
+
exports.GlucoseRange = exports.GlucoseType = void 0;
|
|
4
4
|
var GlucoseType;
|
|
5
5
|
(function (GlucoseType) {
|
|
6
6
|
GlucoseType[GlucoseType["Fasting"] = 0] = "Fasting";
|
|
@@ -8,3 +8,10 @@ var GlucoseType;
|
|
|
8
8
|
GlucoseType[GlucoseType["Bedtime"] = 2] = "Bedtime";
|
|
9
9
|
GlucoseType[GlucoseType["PostExercise"] = 3] = "PostExercise";
|
|
10
10
|
})(GlucoseType || (exports.GlucoseType = GlucoseType = {}));
|
|
11
|
+
var GlucoseRange;
|
|
12
|
+
(function (GlucoseRange) {
|
|
13
|
+
GlucoseRange[GlucoseRange["LOW"] = 0] = "LOW";
|
|
14
|
+
GlucoseRange[GlucoseRange["NORMAL"] = 1] = "NORMAL";
|
|
15
|
+
GlucoseRange[GlucoseRange["HIGH"] = 2] = "HIGH";
|
|
16
|
+
GlucoseRange[GlucoseRange["VERY_HIGH"] = 3] = "VERY_HIGH";
|
|
17
|
+
})(GlucoseRange || (exports.GlucoseRange = GlucoseRange = {}));
|
package/package.json
CHANGED