@voyantjs/notifications 0.8.0 → 0.10.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/routes.d.ts +12 -12
- package/dist/schema.d.ts +2 -2
- package/dist/service-templates.d.ts +13 -13
- package/dist/validation.d.ts +11 -11
- package/package.json +7 -7
package/dist/routes.d.ts
CHANGED
|
@@ -36,7 +36,7 @@ export declare function createNotificationsRoutes(options?: NotificationsRoutesO
|
|
|
36
36
|
name: string;
|
|
37
37
|
channel: "email" | "sms";
|
|
38
38
|
provider: string | null;
|
|
39
|
-
status: "
|
|
39
|
+
status: "active" | "draft" | "archived";
|
|
40
40
|
subjectTemplate: string | null;
|
|
41
41
|
htmlTemplate: string | null;
|
|
42
42
|
textTemplate: string | null;
|
|
@@ -70,9 +70,9 @@ export declare function createNotificationsRoutes(options?: NotificationsRoutesO
|
|
|
70
70
|
createdAt: string;
|
|
71
71
|
updatedAt: string;
|
|
72
72
|
slug: string;
|
|
73
|
-
status: "
|
|
74
|
-
channel: "email" | "sms";
|
|
73
|
+
status: "active" | "draft" | "archived";
|
|
75
74
|
provider: string | null;
|
|
75
|
+
channel: "email" | "sms";
|
|
76
76
|
subjectTemplate: string | null;
|
|
77
77
|
htmlTemplate: string | null;
|
|
78
78
|
textTemplate: string | null;
|
|
@@ -110,7 +110,7 @@ export declare function createNotificationsRoutes(options?: NotificationsRoutesO
|
|
|
110
110
|
name: string;
|
|
111
111
|
channel: "email" | "sms";
|
|
112
112
|
provider: string | null;
|
|
113
|
-
status: "
|
|
113
|
+
status: "active" | "draft" | "archived";
|
|
114
114
|
subjectTemplate: string | null;
|
|
115
115
|
htmlTemplate: string | null;
|
|
116
116
|
textTemplate: string | null;
|
|
@@ -153,7 +153,7 @@ export declare function createNotificationsRoutes(options?: NotificationsRoutesO
|
|
|
153
153
|
name: string;
|
|
154
154
|
channel: "email" | "sms";
|
|
155
155
|
provider: string | null;
|
|
156
|
-
status: "
|
|
156
|
+
status: "active" | "draft" | "archived";
|
|
157
157
|
subjectTemplate: string | null;
|
|
158
158
|
htmlTemplate: string | null;
|
|
159
159
|
textTemplate: string | null;
|
|
@@ -301,7 +301,7 @@ export declare function createNotificationsRoutes(options?: NotificationsRoutesO
|
|
|
301
301
|
id: string;
|
|
302
302
|
slug: string;
|
|
303
303
|
name: string;
|
|
304
|
-
status: "
|
|
304
|
+
status: "active" | "draft" | "archived";
|
|
305
305
|
targetType: "invoice" | "booking_payment_schedule";
|
|
306
306
|
channel: "email" | "sms";
|
|
307
307
|
provider: string | null;
|
|
@@ -337,9 +337,9 @@ export declare function createNotificationsRoutes(options?: NotificationsRoutesO
|
|
|
337
337
|
createdAt: string;
|
|
338
338
|
updatedAt: string;
|
|
339
339
|
slug: string;
|
|
340
|
-
status: "
|
|
341
|
-
channel: "email" | "sms";
|
|
340
|
+
status: "active" | "draft" | "archived";
|
|
342
341
|
provider: string | null;
|
|
342
|
+
channel: "email" | "sms";
|
|
343
343
|
targetType: "invoice" | "booking_payment_schedule";
|
|
344
344
|
templateId: string | null;
|
|
345
345
|
isSystem: boolean;
|
|
@@ -375,7 +375,7 @@ export declare function createNotificationsRoutes(options?: NotificationsRoutesO
|
|
|
375
375
|
id: string;
|
|
376
376
|
slug: string;
|
|
377
377
|
name: string;
|
|
378
|
-
status: "
|
|
378
|
+
status: "active" | "draft" | "archived";
|
|
379
379
|
targetType: "invoice" | "booking_payment_schedule";
|
|
380
380
|
channel: "email" | "sms";
|
|
381
381
|
provider: string | null;
|
|
@@ -418,7 +418,7 @@ export declare function createNotificationsRoutes(options?: NotificationsRoutesO
|
|
|
418
418
|
id: string;
|
|
419
419
|
slug: string;
|
|
420
420
|
name: string;
|
|
421
|
-
status: "
|
|
421
|
+
status: "active" | "draft" | "archived";
|
|
422
422
|
targetType: "invoice" | "booking_payment_schedule";
|
|
423
423
|
channel: "email" | "sms";
|
|
424
424
|
provider: string | null;
|
|
@@ -471,7 +471,7 @@ export declare function createNotificationsRoutes(options?: NotificationsRoutesO
|
|
|
471
471
|
id: string;
|
|
472
472
|
slug: string;
|
|
473
473
|
name: string;
|
|
474
|
-
status: "
|
|
474
|
+
status: "active" | "draft" | "archived";
|
|
475
475
|
targetType: "invoice" | "booking_payment_schedule";
|
|
476
476
|
channel: "email" | "sms";
|
|
477
477
|
provider: string | null;
|
|
@@ -548,7 +548,7 @@ export declare function createNotificationsRoutes(options?: NotificationsRoutesO
|
|
|
548
548
|
id: string;
|
|
549
549
|
slug: string;
|
|
550
550
|
name: string;
|
|
551
|
-
status: "
|
|
551
|
+
status: "active" | "draft" | "archived";
|
|
552
552
|
targetType: "invoice" | "booking_payment_schedule";
|
|
553
553
|
channel: "email" | "sms";
|
|
554
554
|
provider: string | null;
|
package/dist/schema.d.ts
CHANGED
|
@@ -101,7 +101,7 @@ export declare const notificationTemplates: import("drizzle-orm/pg-core").PgTabl
|
|
|
101
101
|
tableName: "notification_templates";
|
|
102
102
|
dataType: "string";
|
|
103
103
|
columnType: "PgEnumColumn";
|
|
104
|
-
data: "
|
|
104
|
+
data: "active" | "draft" | "archived";
|
|
105
105
|
driverParam: string;
|
|
106
106
|
notNull: true;
|
|
107
107
|
hasDefault: true;
|
|
@@ -788,7 +788,7 @@ export declare const notificationReminderRules: import("drizzle-orm/pg-core").Pg
|
|
|
788
788
|
tableName: "notification_reminder_rules";
|
|
789
789
|
dataType: "string";
|
|
790
790
|
columnType: "PgEnumColumn";
|
|
791
|
-
data: "
|
|
791
|
+
data: "active" | "draft" | "archived";
|
|
792
792
|
driverParam: string;
|
|
793
793
|
notNull: true;
|
|
794
794
|
hasDefault: true;
|
|
@@ -7,7 +7,7 @@ export declare function listTemplates(db: PostgresJsDatabase, query: Notificatio
|
|
|
7
7
|
name: string;
|
|
8
8
|
channel: "email" | "sms";
|
|
9
9
|
provider: string | null;
|
|
10
|
-
status: "
|
|
10
|
+
status: "active" | "draft" | "archived";
|
|
11
11
|
subjectTemplate: string | null;
|
|
12
12
|
htmlTemplate: string | null;
|
|
13
13
|
textTemplate: string | null;
|
|
@@ -27,7 +27,7 @@ export declare function getTemplateById(db: PostgresJsDatabase, id: string): Pro
|
|
|
27
27
|
name: string;
|
|
28
28
|
channel: "email" | "sms";
|
|
29
29
|
provider: string | null;
|
|
30
|
-
status: "
|
|
30
|
+
status: "active" | "draft" | "archived";
|
|
31
31
|
subjectTemplate: string | null;
|
|
32
32
|
htmlTemplate: string | null;
|
|
33
33
|
textTemplate: string | null;
|
|
@@ -43,7 +43,7 @@ export declare function getTemplateBySlug(db: PostgresJsDatabase, slug: string):
|
|
|
43
43
|
name: string;
|
|
44
44
|
channel: "email" | "sms";
|
|
45
45
|
provider: string | null;
|
|
46
|
-
status: "
|
|
46
|
+
status: "active" | "draft" | "archived";
|
|
47
47
|
subjectTemplate: string | null;
|
|
48
48
|
htmlTemplate: string | null;
|
|
49
49
|
textTemplate: string | null;
|
|
@@ -60,9 +60,9 @@ export declare function createTemplate(db: PostgresJsDatabase, data: CreateNotif
|
|
|
60
60
|
createdAt: Date;
|
|
61
61
|
updatedAt: Date;
|
|
62
62
|
slug: string;
|
|
63
|
-
status: "
|
|
64
|
-
channel: "email" | "sms";
|
|
63
|
+
status: "active" | "draft" | "archived";
|
|
65
64
|
provider: string | null;
|
|
65
|
+
channel: "email" | "sms";
|
|
66
66
|
subjectTemplate: string | null;
|
|
67
67
|
htmlTemplate: string | null;
|
|
68
68
|
textTemplate: string | null;
|
|
@@ -75,7 +75,7 @@ export declare function updateTemplate(db: PostgresJsDatabase, id: string, data:
|
|
|
75
75
|
name: string;
|
|
76
76
|
channel: "email" | "sms";
|
|
77
77
|
provider: string | null;
|
|
78
|
-
status: "
|
|
78
|
+
status: "active" | "draft" | "archived";
|
|
79
79
|
subjectTemplate: string | null;
|
|
80
80
|
htmlTemplate: string | null;
|
|
81
81
|
textTemplate: string | null;
|
|
@@ -90,7 +90,7 @@ export declare function listReminderRules(db: PostgresJsDatabase, query: Notific
|
|
|
90
90
|
id: string;
|
|
91
91
|
slug: string;
|
|
92
92
|
name: string;
|
|
93
|
-
status: "
|
|
93
|
+
status: "active" | "draft" | "archived";
|
|
94
94
|
targetType: "invoice" | "booking_payment_schedule";
|
|
95
95
|
channel: "email" | "sms";
|
|
96
96
|
provider: string | null;
|
|
@@ -110,7 +110,7 @@ export declare function getReminderRuleById(db: PostgresJsDatabase, id: string):
|
|
|
110
110
|
id: string;
|
|
111
111
|
slug: string;
|
|
112
112
|
name: string;
|
|
113
|
-
status: "
|
|
113
|
+
status: "active" | "draft" | "archived";
|
|
114
114
|
targetType: "invoice" | "booking_payment_schedule";
|
|
115
115
|
channel: "email" | "sms";
|
|
116
116
|
provider: string | null;
|
|
@@ -129,9 +129,9 @@ export declare function createReminderRule(db: PostgresJsDatabase, data: CreateN
|
|
|
129
129
|
createdAt: Date;
|
|
130
130
|
updatedAt: Date;
|
|
131
131
|
slug: string;
|
|
132
|
-
status: "
|
|
133
|
-
channel: "email" | "sms";
|
|
132
|
+
status: "active" | "draft" | "archived";
|
|
134
133
|
provider: string | null;
|
|
134
|
+
channel: "email" | "sms";
|
|
135
135
|
targetType: "invoice" | "booking_payment_schedule";
|
|
136
136
|
templateId: string | null;
|
|
137
137
|
isSystem: boolean;
|
|
@@ -142,7 +142,7 @@ export declare function updateReminderRule(db: PostgresJsDatabase, id: string, d
|
|
|
142
142
|
id: string;
|
|
143
143
|
slug: string;
|
|
144
144
|
name: string;
|
|
145
|
-
status: "
|
|
145
|
+
status: "active" | "draft" | "archived";
|
|
146
146
|
targetType: "invoice" | "booking_payment_schedule";
|
|
147
147
|
channel: "email" | "sms";
|
|
148
148
|
provider: string | null;
|
|
@@ -182,7 +182,7 @@ export declare function listReminderRuns(db: PostgresJsDatabase, query: Notifica
|
|
|
182
182
|
id: string;
|
|
183
183
|
slug: string;
|
|
184
184
|
name: string;
|
|
185
|
-
status: "
|
|
185
|
+
status: "active" | "draft" | "archived";
|
|
186
186
|
targetType: "invoice" | "booking_payment_schedule";
|
|
187
187
|
channel: "email" | "sms";
|
|
188
188
|
provider: string | null;
|
|
@@ -233,7 +233,7 @@ export declare function getReminderRunById(db: PostgresJsDatabase, id: string):
|
|
|
233
233
|
id: string;
|
|
234
234
|
slug: string;
|
|
235
235
|
name: string;
|
|
236
|
-
status: "
|
|
236
|
+
status: "active" | "draft" | "archived";
|
|
237
237
|
targetType: "invoice" | "booking_payment_schedule";
|
|
238
238
|
channel: "email" | "sms";
|
|
239
239
|
provider: string | null;
|
package/dist/validation.d.ts
CHANGED
|
@@ -4,8 +4,8 @@ export declare const notificationChannelSchema: z.ZodEnum<{
|
|
|
4
4
|
sms: "sms";
|
|
5
5
|
}>;
|
|
6
6
|
export declare const notificationTemplateStatusSchema: z.ZodEnum<{
|
|
7
|
-
draft: "draft";
|
|
8
7
|
active: "active";
|
|
8
|
+
draft: "draft";
|
|
9
9
|
archived: "archived";
|
|
10
10
|
}>;
|
|
11
11
|
export declare const notificationDeliveryStatusSchema: z.ZodEnum<{
|
|
@@ -25,8 +25,8 @@ export declare const notificationTargetTypeSchema: z.ZodEnum<{
|
|
|
25
25
|
payment_session: "payment_session";
|
|
26
26
|
}>;
|
|
27
27
|
export declare const notificationReminderStatusSchema: z.ZodEnum<{
|
|
28
|
-
draft: "draft";
|
|
29
28
|
active: "active";
|
|
29
|
+
draft: "draft";
|
|
30
30
|
archived: "archived";
|
|
31
31
|
}>;
|
|
32
32
|
export declare const notificationReminderTargetTypeSchema: z.ZodEnum<{
|
|
@@ -69,8 +69,8 @@ export declare const insertNotificationTemplateSchema: z.ZodObject<{
|
|
|
69
69
|
}>;
|
|
70
70
|
provider: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
71
71
|
status: z.ZodDefault<z.ZodEnum<{
|
|
72
|
-
draft: "draft";
|
|
73
72
|
active: "active";
|
|
73
|
+
draft: "draft";
|
|
74
74
|
archived: "archived";
|
|
75
75
|
}>>;
|
|
76
76
|
subjectTemplate: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
@@ -89,8 +89,8 @@ export declare const updateNotificationTemplateSchema: z.ZodObject<{
|
|
|
89
89
|
}>>;
|
|
90
90
|
provider: z.ZodOptional<z.ZodNullable<z.ZodOptional<z.ZodString>>>;
|
|
91
91
|
status: z.ZodOptional<z.ZodDefault<z.ZodEnum<{
|
|
92
|
-
draft: "draft";
|
|
93
92
|
active: "active";
|
|
93
|
+
draft: "draft";
|
|
94
94
|
archived: "archived";
|
|
95
95
|
}>>>;
|
|
96
96
|
subjectTemplate: z.ZodOptional<z.ZodNullable<z.ZodOptional<z.ZodString>>>;
|
|
@@ -109,8 +109,8 @@ export declare const notificationTemplateListQuerySchema: z.ZodObject<{
|
|
|
109
109
|
}>>;
|
|
110
110
|
provider: z.ZodOptional<z.ZodString>;
|
|
111
111
|
status: z.ZodOptional<z.ZodEnum<{
|
|
112
|
-
draft: "draft";
|
|
113
112
|
active: "active";
|
|
113
|
+
draft: "draft";
|
|
114
114
|
archived: "archived";
|
|
115
115
|
}>>;
|
|
116
116
|
search: z.ZodOptional<z.ZodString>;
|
|
@@ -151,8 +151,8 @@ export declare const insertNotificationReminderRuleSchema: z.ZodObject<{
|
|
|
151
151
|
slug: z.ZodString;
|
|
152
152
|
name: z.ZodString;
|
|
153
153
|
status: z.ZodDefault<z.ZodEnum<{
|
|
154
|
-
draft: "draft";
|
|
155
154
|
active: "active";
|
|
155
|
+
draft: "draft";
|
|
156
156
|
archived: "archived";
|
|
157
157
|
}>>;
|
|
158
158
|
targetType: z.ZodEnum<{
|
|
@@ -174,8 +174,8 @@ export declare const updateNotificationReminderRuleSchema: z.ZodObject<{
|
|
|
174
174
|
slug: z.ZodOptional<z.ZodString>;
|
|
175
175
|
name: z.ZodOptional<z.ZodString>;
|
|
176
176
|
status: z.ZodOptional<z.ZodDefault<z.ZodEnum<{
|
|
177
|
-
draft: "draft";
|
|
178
177
|
active: "active";
|
|
178
|
+
draft: "draft";
|
|
179
179
|
archived: "archived";
|
|
180
180
|
}>>>;
|
|
181
181
|
targetType: z.ZodOptional<z.ZodEnum<{
|
|
@@ -197,8 +197,8 @@ export declare const notificationReminderRuleListQuerySchema: z.ZodObject<{
|
|
|
197
197
|
limit: z.ZodDefault<z.ZodCoercedNumber<unknown>>;
|
|
198
198
|
offset: z.ZodDefault<z.ZodCoercedNumber<unknown>>;
|
|
199
199
|
status: z.ZodOptional<z.ZodEnum<{
|
|
200
|
-
draft: "draft";
|
|
201
200
|
active: "active";
|
|
201
|
+
draft: "draft";
|
|
202
202
|
archived: "archived";
|
|
203
203
|
}>>;
|
|
204
204
|
targetType: z.ZodOptional<z.ZodEnum<{
|
|
@@ -241,8 +241,8 @@ export declare const notificationReminderRunRuleSummarySchema: z.ZodObject<{
|
|
|
241
241
|
slug: z.ZodString;
|
|
242
242
|
name: z.ZodString;
|
|
243
243
|
status: z.ZodEnum<{
|
|
244
|
-
draft: "draft";
|
|
245
244
|
active: "active";
|
|
245
|
+
draft: "draft";
|
|
246
246
|
archived: "archived";
|
|
247
247
|
}>;
|
|
248
248
|
targetType: z.ZodEnum<{
|
|
@@ -323,8 +323,8 @@ export declare const notificationReminderRunRecordSchema: z.ZodObject<{
|
|
|
323
323
|
slug: z.ZodString;
|
|
324
324
|
name: z.ZodString;
|
|
325
325
|
status: z.ZodEnum<{
|
|
326
|
-
draft: "draft";
|
|
327
326
|
active: "active";
|
|
327
|
+
draft: "draft";
|
|
328
328
|
archived: "archived";
|
|
329
329
|
}>;
|
|
330
330
|
targetType: z.ZodEnum<{
|
|
@@ -398,8 +398,8 @@ export declare const notificationReminderRunListResponseSchema: z.ZodObject<{
|
|
|
398
398
|
slug: z.ZodString;
|
|
399
399
|
name: z.ZodString;
|
|
400
400
|
status: z.ZodEnum<{
|
|
401
|
-
draft: "draft";
|
|
402
401
|
active: "active";
|
|
402
|
+
draft: "draft";
|
|
403
403
|
archived: "archived";
|
|
404
404
|
}>;
|
|
405
405
|
targetType: z.ZodEnum<{
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@voyantjs/notifications",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.10.0",
|
|
4
4
|
"license": "FSL-1.1-Apache-2.0",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"exports": {
|
|
@@ -50,12 +50,12 @@
|
|
|
50
50
|
"hono": "^4.12.10",
|
|
51
51
|
"liquidjs": "^10.24.0",
|
|
52
52
|
"zod": "^4.3.6",
|
|
53
|
-
"@voyantjs/bookings": "0.
|
|
54
|
-
"@voyantjs/core": "0.
|
|
55
|
-
"@voyantjs/db": "0.
|
|
56
|
-
"@voyantjs/finance": "0.
|
|
57
|
-
"@voyantjs/hono": "0.
|
|
58
|
-
"@voyantjs/legal": "0.
|
|
53
|
+
"@voyantjs/bookings": "0.10.0",
|
|
54
|
+
"@voyantjs/core": "0.10.0",
|
|
55
|
+
"@voyantjs/db": "0.10.0",
|
|
56
|
+
"@voyantjs/finance": "0.10.0",
|
|
57
|
+
"@voyantjs/hono": "0.10.0",
|
|
58
|
+
"@voyantjs/legal": "0.10.0"
|
|
59
59
|
},
|
|
60
60
|
"devDependencies": {
|
|
61
61
|
"typescript": "^6.0.2",
|