@taphealth/kafka 1.4.3 → 1.4.5
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/notification.d.ts +17 -0
- package/dist/events/notification.js +2 -0
- package/dist/events/subscription-cancelled.d.ts +8 -0
- package/dist/events/subscription-cancelled.js +2 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.js +3 -0
- package/dist/topics.d.ts +3 -1
- package/dist/topics.js +2 -0
- package/dist/types/notification.d.ts +12 -0
- package/dist/types/notification.js +8 -0
- package/package.json +1 -1
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { Topics } from "../topics";
|
|
2
|
+
import { NotificationChannel, NotificationType } from "../types/notification";
|
|
3
|
+
export interface NotificationEvent {
|
|
4
|
+
topic: Topics.Notification;
|
|
5
|
+
data: {
|
|
6
|
+
module: string;
|
|
7
|
+
type: NotificationType;
|
|
8
|
+
userId: string;
|
|
9
|
+
content: string;
|
|
10
|
+
channel: NotificationChannel;
|
|
11
|
+
dueTime: Date;
|
|
12
|
+
priority: number;
|
|
13
|
+
metadata?: {
|
|
14
|
+
[key: string]: any;
|
|
15
|
+
};
|
|
16
|
+
};
|
|
17
|
+
}
|
package/dist/index.d.ts
CHANGED
|
@@ -10,6 +10,7 @@ export * from "./types/glucose";
|
|
|
10
10
|
export * from "./types/activity";
|
|
11
11
|
export * from "./types/exercise";
|
|
12
12
|
export * from "./types/proactive";
|
|
13
|
+
export * from "./types/notification";
|
|
13
14
|
export * from "./events/payment-captured";
|
|
14
15
|
export * from "./events/payment-failed";
|
|
15
16
|
export * from "./events/appointment-created";
|
|
@@ -36,3 +37,5 @@ export * from "./events/proactive-check-in";
|
|
|
36
37
|
export * from "./events/subscription-status";
|
|
37
38
|
export * from "./events/subscription-created";
|
|
38
39
|
export * from "./events/subscription-expired";
|
|
40
|
+
export * from "./events/subscription-cancelled";
|
|
41
|
+
export * from "./events/notification";
|
package/dist/index.js
CHANGED
|
@@ -26,6 +26,7 @@ __exportStar(require("./types/glucose"), exports);
|
|
|
26
26
|
__exportStar(require("./types/activity"), exports);
|
|
27
27
|
__exportStar(require("./types/exercise"), exports);
|
|
28
28
|
__exportStar(require("./types/proactive"), exports);
|
|
29
|
+
__exportStar(require("./types/notification"), exports);
|
|
29
30
|
__exportStar(require("./events/payment-captured"), exports);
|
|
30
31
|
__exportStar(require("./events/payment-failed"), exports);
|
|
31
32
|
__exportStar(require("./events/appointment-created"), exports);
|
|
@@ -52,3 +53,5 @@ __exportStar(require("./events/proactive-check-in"), exports);
|
|
|
52
53
|
__exportStar(require("./events/subscription-status"), exports);
|
|
53
54
|
__exportStar(require("./events/subscription-created"), exports);
|
|
54
55
|
__exportStar(require("./events/subscription-expired"), exports);
|
|
56
|
+
__exportStar(require("./events/subscription-cancelled"), exports);
|
|
57
|
+
__exportStar(require("./events/notification"), exports);
|
package/dist/topics.d.ts
CHANGED
|
@@ -26,5 +26,7 @@ export declare enum Topics {
|
|
|
26
26
|
ProactiveCheckIn = "proactive-check-in",
|
|
27
27
|
SubscriptionStatus = "subscription-status",
|
|
28
28
|
SubscriptionCreated = "subscription-created",
|
|
29
|
-
SubscriptionExpired = "subscription-expired"
|
|
29
|
+
SubscriptionExpired = "subscription-expired",
|
|
30
|
+
SubscriptionDowngrade = "subscription-cancelled",
|
|
31
|
+
Notification = "notification"
|
|
30
32
|
}
|
package/dist/topics.js
CHANGED
|
@@ -31,4 +31,6 @@ var Topics;
|
|
|
31
31
|
Topics["SubscriptionStatus"] = "subscription-status";
|
|
32
32
|
Topics["SubscriptionCreated"] = "subscription-created";
|
|
33
33
|
Topics["SubscriptionExpired"] = "subscription-expired";
|
|
34
|
+
Topics["SubscriptionDowngrade"] = "subscription-cancelled";
|
|
35
|
+
Topics["Notification"] = "notification";
|
|
34
36
|
})(Topics || (exports.Topics = Topics = {}));
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export declare enum NotificationType {
|
|
2
|
+
AdminNotification = "AdminNotification",
|
|
3
|
+
AICoachNotification = "AICoachNotification"
|
|
4
|
+
}
|
|
5
|
+
export interface NotificationChannel {
|
|
6
|
+
name: string;
|
|
7
|
+
trigger?: string;
|
|
8
|
+
expiry?: string;
|
|
9
|
+
message: string;
|
|
10
|
+
recurrence?: string;
|
|
11
|
+
redirect?: string;
|
|
12
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.NotificationType = void 0;
|
|
4
|
+
var NotificationType;
|
|
5
|
+
(function (NotificationType) {
|
|
6
|
+
NotificationType["AdminNotification"] = "AdminNotification";
|
|
7
|
+
NotificationType["AICoachNotification"] = "AICoachNotification";
|
|
8
|
+
})(NotificationType || (exports.NotificationType = NotificationType = {}));
|