notifkit 0.1.3 → 0.1.4
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/README.md +95 -79
- package/dist/index.d.mts +199 -135
- package/dist/index.d.mts.map +1 -1
- package/dist/index.mjs +1 -1
- package/dist/index.mjs.map +1 -1
- package/dist/{main-DtHWhueo.mjs → main-40zwq6b0.mjs} +28 -3
- package/dist/{main-DtHWhueo.mjs.map → main-40zwq6b0.mjs.map} +1 -1
- package/dist/{main-DyfbnJc3.mjs → main-BFre2-HQ.mjs} +2 -2
- package/dist/{main-DyfbnJc3.mjs.map → main-BFre2-HQ.mjs.map} +1 -1
- package/dist/{main-CAH0_Q6d.mjs → main-BNJtzY61.mjs} +3 -3
- package/dist/main-BNJtzY61.mjs.map +1 -0
- package/dist/{main-B561M1d3.mjs → main-BOPMYqsW.mjs} +2 -2
- package/dist/{main-B561M1d3.mjs.map → main-BOPMYqsW.mjs.map} +1 -1
- package/dist/{main-CCfc45ev.mjs → main-CiigNpsP.mjs} +7 -4
- package/dist/main-CiigNpsP.mjs.map +1 -0
- package/dist/{main-Ce9dcrsg.mjs → main-DeNFQ-UL.mjs} +6 -3
- package/dist/{main-Ce9dcrsg.mjs.map → main-DeNFQ-UL.mjs.map} +1 -1
- package/dist/{main-B-jwm8ED.mjs → main-DmCPcxOc.mjs} +2 -2
- package/dist/{main-B-jwm8ED.mjs.map → main-DmCPcxOc.mjs.map} +1 -1
- package/dist/{main-C45e7grq.mjs → main-DvgJSm11.mjs} +2 -2
- package/dist/{main-C45e7grq.mjs.map → main-DvgJSm11.mjs.map} +1 -1
- package/dist/{src-C-PfEDMY.mjs → src-vG79L-8m.mjs} +57 -26
- package/dist/src-vG79L-8m.mjs.map +1 -0
- package/drizzle/0002_wide_colleen_wing.sql +2 -0
- package/drizzle/0003_skinny_daimon_hellstrom.sql +1 -0
- package/drizzle/0004_pretty_bruce_banner.sql +1 -0
- package/drizzle/meta/0002_snapshot.json +1460 -0
- package/drizzle/meta/0003_snapshot.json +1460 -0
- package/drizzle/meta/0004_snapshot.json +1470 -0
- package/drizzle/meta/_journal.json +21 -0
- package/package.json +2 -1
- package/src/client.ts +412 -0
- package/src/config/index.ts +107 -0
- package/src/contracts/common.ts +28 -0
- package/src/contracts/envelope.ts +31 -0
- package/src/contracts/events/notification-ai-pending.ts +18 -0
- package/src/contracts/events/notification-canceled.ts +7 -0
- package/src/contracts/events/notification-created.ts +14 -0
- package/src/contracts/events/notification-delivered.ts +17 -0
- package/src/contracts/events/notification-dispatched.ts +45 -0
- package/src/contracts/events/notification-enriched.ts +46 -0
- package/src/contracts/events/notification-failed.ts +19 -0
- package/src/contracts/events/notification-requested.ts +36 -0
- package/src/contracts/events/notification-scheduled.ts +9 -0
- package/src/contracts/events/notification-skipped.ts +9 -0
- package/src/contracts/helpers.ts +21 -0
- package/src/contracts/index.ts +46 -0
- package/src/contracts/metadata.ts +10 -0
- package/src/contracts/registry.ts +88 -0
- package/src/contracts/sdk.ts +242 -0
- package/src/contracts/streams.ts +62 -0
- package/src/db/index.ts +69 -0
- package/src/db/schema.ts +412 -0
- package/src/idempotency/index.ts +50 -0
- package/src/index.ts +19 -0
- package/src/logger/index.ts +60 -0
- package/src/metrics/index.ts +53 -0
- package/src/queue/index.ts +501 -0
- package/src/rate-limiter/index.ts +210 -0
- package/src/redis/index.ts +89 -0
- package/src/repositories/index.ts +1246 -0
- package/src/server.ts +277 -0
- package/src/services/ai/main.ts +404 -0
- package/src/services/api/handlers.ts +1734 -0
- package/src/services/api/http.ts +64 -0
- package/src/services/api/main.ts +693 -0
- package/src/services/api/router.ts +82 -0
- package/src/services/delivery/main.ts +842 -0
- package/src/services/delivery/throttle.ts +71 -0
- package/src/services/engine/main.ts +827 -0
- package/src/services/enricher/main.ts +594 -0
- package/src/services/events/main.ts +365 -0
- package/src/services/scheduler/main.ts +319 -0
- package/src/services/workflow/main.ts +627 -0
- package/src/shared/batch-processor.ts +67 -0
- package/src/shared/cache.ts +47 -0
- package/src/shared/circuit-breaker.ts +74 -0
- package/src/shared/dataloader.ts +41 -0
- package/src/shared/events.ts +3 -0
- package/src/shared/index.ts +39 -0
- package/src/shared/semaphore.ts +33 -0
- package/src/shared/utils.ts +64 -0
- package/src/templates/cache.ts +32 -0
- package/src/templates/index.ts +69 -0
- package/src/templates/render.ts +128 -0
- package/src/transport/index.ts +96 -0
- package/src/unsubscribe/index.ts +127 -0
- package/src/workers/health.ts +31 -0
- package/src/workers/index.ts +266 -0
- package/src/workflows/index.ts +2 -0
- package/src/workflows/registry.ts +21 -0
- package/src/workflows/sdk.ts +106 -0
- package/dist/main-CAH0_Q6d.mjs.map +0 -1
- package/dist/main-CCfc45ev.mjs.map +0 -1
- package/dist/src-C-PfEDMY.mjs.map +0 -1
package/dist/index.d.mts
CHANGED
|
@@ -94,7 +94,7 @@ declare function setAiConfig(config: AiConfig): void;
|
|
|
94
94
|
declare function getAiConfig(): AiConfig;
|
|
95
95
|
//#endregion
|
|
96
96
|
//#region src/contracts/common.d.ts
|
|
97
|
-
declare const NotificationChannelSchema: z.ZodEnum<["email", "sms", "push", "webhook", "in-app"]>;
|
|
97
|
+
declare const NotificationChannelSchema: z.ZodEnum<["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"]>;
|
|
98
98
|
type NotificationChannel = z.infer<typeof NotificationChannelSchema>;
|
|
99
99
|
declare const NotificationPrioritySchema: z.ZodEnum<["low", "normal", "high", "critical"]>;
|
|
100
100
|
type NotificationPriority = z.infer<typeof NotificationPrioritySchema>;
|
|
@@ -193,7 +193,7 @@ declare const NotificationRequestedPayloadSchema: z.ZodObject<{
|
|
|
193
193
|
}>]>;
|
|
194
194
|
templateId: z.ZodString;
|
|
195
195
|
priority: z.ZodDefault<z.ZodEnum<["low", "normal", "high", "critical"]>>;
|
|
196
|
-
channels: z.ZodOptional<z.ZodArray<z.ZodEnum<["email", "sms", "push", "webhook", "in-app"]>, "atleastone">>;
|
|
196
|
+
channels: z.ZodOptional<z.ZodArray<z.ZodEnum<["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"]>, "atleastone">>;
|
|
197
197
|
data: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
198
198
|
fallback: z.ZodDefault<z.ZodBoolean>;
|
|
199
199
|
aiPrompts: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
@@ -220,7 +220,7 @@ declare const NotificationRequestedPayloadSchema: z.ZodObject<{
|
|
|
220
220
|
fallback: boolean;
|
|
221
221
|
projectId: string;
|
|
222
222
|
templateId: string;
|
|
223
|
-
channels?: ["push" | "email" | "sms" | "webhook" | "in-app", ...("push" | "email" | "sms" | "webhook" | "in-app")[]] | undefined;
|
|
223
|
+
channels?: ["push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app", ...("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[]] | undefined;
|
|
224
224
|
aiPrompts?: Record<string, string> | undefined;
|
|
225
225
|
campaignId?: string | undefined;
|
|
226
226
|
scheduledAt?: string | undefined;
|
|
@@ -239,7 +239,7 @@ declare const NotificationRequestedPayloadSchema: z.ZodObject<{
|
|
|
239
239
|
projectId: string;
|
|
240
240
|
templateId: string;
|
|
241
241
|
priority?: "low" | "normal" | "high" | "critical" | undefined;
|
|
242
|
-
channels?: ["push" | "email" | "sms" | "webhook" | "in-app", ...("push" | "email" | "sms" | "webhook" | "in-app")[]] | undefined;
|
|
242
|
+
channels?: ["push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app", ...("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[]] | undefined;
|
|
243
243
|
aiPrompts?: Record<string, string> | undefined;
|
|
244
244
|
data?: Record<string, unknown> | undefined;
|
|
245
245
|
fallback?: boolean | undefined;
|
|
@@ -253,14 +253,14 @@ type NotificationRequestedPayload = z.infer<typeof NotificationRequestedPayloadS
|
|
|
253
253
|
declare const NotificationCreatedPayloadSchema: z.ZodObject<{
|
|
254
254
|
projectId: z.ZodString;
|
|
255
255
|
recipientId: z.ZodString;
|
|
256
|
-
channel: z.ZodEnum<["email", "sms", "push", "webhook", "in-app"]>;
|
|
256
|
+
channel: z.ZodEnum<["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"]>;
|
|
257
257
|
priority: z.ZodDefault<z.ZodEnum<["low", "normal", "high", "critical"]>>;
|
|
258
258
|
templateId: z.ZodOptional<z.ZodString>;
|
|
259
259
|
payload: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
260
260
|
scheduledAt: z.ZodOptional<z.ZodString>;
|
|
261
261
|
idempotencyKey: z.ZodOptional<z.ZodString>;
|
|
262
262
|
}, "strip", z.ZodTypeAny, {
|
|
263
|
-
channel: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
263
|
+
channel: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
264
264
|
priority: "low" | "normal" | "high" | "critical";
|
|
265
265
|
payload: Record<string, unknown>;
|
|
266
266
|
projectId: string;
|
|
@@ -269,7 +269,7 @@ declare const NotificationCreatedPayloadSchema: z.ZodObject<{
|
|
|
269
269
|
scheduledAt?: string | undefined;
|
|
270
270
|
idempotencyKey?: string | undefined;
|
|
271
271
|
}, {
|
|
272
|
-
channel: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
272
|
+
channel: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
273
273
|
payload: Record<string, unknown>;
|
|
274
274
|
projectId: string;
|
|
275
275
|
recipientId: string;
|
|
@@ -288,11 +288,14 @@ declare const RecipientProfileSchema: z.ZodObject<{
|
|
|
288
288
|
webhook: z.ZodOptional<z.ZodString>;
|
|
289
289
|
pushTokens: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
290
290
|
pushToken: z.ZodOptional<z.ZodString>;
|
|
291
|
+
telegram: z.ZodOptional<z.ZodString>;
|
|
292
|
+
discord: z.ZodOptional<z.ZodString>;
|
|
293
|
+
slack: z.ZodOptional<z.ZodString>;
|
|
291
294
|
locale: z.ZodDefault<z.ZodString>;
|
|
292
295
|
timezone: z.ZodDefault<z.ZodString>;
|
|
293
296
|
preferences: z.ZodObject<{
|
|
294
297
|
optedOut: z.ZodDefault<z.ZodBoolean>;
|
|
295
|
-
channels: z.ZodDefault<z.ZodArray<z.ZodEnum<["email", "sms", "push", "webhook", "in-app"]>, "many">>;
|
|
298
|
+
channels: z.ZodDefault<z.ZodArray<z.ZodEnum<["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"]>, "many">>;
|
|
296
299
|
quietHours: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
297
300
|
start: z.ZodString;
|
|
298
301
|
end: z.ZodString;
|
|
@@ -304,14 +307,14 @@ declare const RecipientProfileSchema: z.ZodObject<{
|
|
|
304
307
|
end: string;
|
|
305
308
|
}>, "many">>;
|
|
306
309
|
}, "strip", z.ZodTypeAny, {
|
|
307
|
-
channels: ("push" | "email" | "sms" | "webhook" | "in-app")[];
|
|
310
|
+
channels: ("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[];
|
|
308
311
|
optedOut: boolean;
|
|
309
312
|
quietHours?: {
|
|
310
313
|
start: string;
|
|
311
314
|
end: string;
|
|
312
315
|
}[] | undefined;
|
|
313
316
|
}, {
|
|
314
|
-
channels?: ("push" | "email" | "sms" | "webhook" | "in-app")[] | undefined;
|
|
317
|
+
channels?: ("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[] | undefined;
|
|
315
318
|
quietHours?: {
|
|
316
319
|
start: string;
|
|
317
320
|
end: string;
|
|
@@ -322,7 +325,7 @@ declare const RecipientProfileSchema: z.ZodObject<{
|
|
|
322
325
|
id: string;
|
|
323
326
|
timezone: string;
|
|
324
327
|
preferences: {
|
|
325
|
-
channels: ("push" | "email" | "sms" | "webhook" | "in-app")[];
|
|
328
|
+
channels: ("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[];
|
|
326
329
|
optedOut: boolean;
|
|
327
330
|
quietHours?: {
|
|
328
331
|
start: string;
|
|
@@ -332,13 +335,16 @@ declare const RecipientProfileSchema: z.ZodObject<{
|
|
|
332
335
|
locale: string;
|
|
333
336
|
email?: string | undefined;
|
|
334
337
|
webhook?: string | undefined;
|
|
338
|
+
telegram?: string | undefined;
|
|
339
|
+
discord?: string | undefined;
|
|
340
|
+
slack?: string | undefined;
|
|
335
341
|
phone?: string | undefined;
|
|
336
342
|
pushToken?: string | undefined;
|
|
337
343
|
pushTokens?: string[] | undefined;
|
|
338
344
|
}, {
|
|
339
345
|
id: string;
|
|
340
346
|
preferences: {
|
|
341
|
-
channels?: ("push" | "email" | "sms" | "webhook" | "in-app")[] | undefined;
|
|
347
|
+
channels?: ("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[] | undefined;
|
|
342
348
|
quietHours?: {
|
|
343
349
|
start: string;
|
|
344
350
|
end: string;
|
|
@@ -347,6 +353,9 @@ declare const RecipientProfileSchema: z.ZodObject<{
|
|
|
347
353
|
};
|
|
348
354
|
email?: string | undefined;
|
|
349
355
|
webhook?: string | undefined;
|
|
356
|
+
telegram?: string | undefined;
|
|
357
|
+
discord?: string | undefined;
|
|
358
|
+
slack?: string | undefined;
|
|
350
359
|
timezone?: string | undefined;
|
|
351
360
|
phone?: string | undefined;
|
|
352
361
|
pushToken?: string | undefined;
|
|
@@ -358,7 +367,7 @@ declare const NotificationEnrichedPayloadSchema: z.ZodObject<{
|
|
|
358
367
|
projectId: z.ZodString;
|
|
359
368
|
rawEventId: z.ZodString;
|
|
360
369
|
recipientId: z.ZodString;
|
|
361
|
-
channel: z.ZodEnum<["email", "sms", "push", "webhook", "in-app"]>;
|
|
370
|
+
channel: z.ZodEnum<["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"]>;
|
|
362
371
|
priority: z.ZodEnum<["low", "normal", "high", "critical"]>;
|
|
363
372
|
templateId: z.ZodOptional<z.ZodString>;
|
|
364
373
|
templateVariables: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
@@ -369,11 +378,14 @@ declare const NotificationEnrichedPayloadSchema: z.ZodObject<{
|
|
|
369
378
|
webhook: z.ZodOptional<z.ZodString>;
|
|
370
379
|
pushTokens: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
371
380
|
pushToken: z.ZodOptional<z.ZodString>;
|
|
381
|
+
telegram: z.ZodOptional<z.ZodString>;
|
|
382
|
+
discord: z.ZodOptional<z.ZodString>;
|
|
383
|
+
slack: z.ZodOptional<z.ZodString>;
|
|
372
384
|
locale: z.ZodDefault<z.ZodString>;
|
|
373
385
|
timezone: z.ZodDefault<z.ZodString>;
|
|
374
386
|
preferences: z.ZodObject<{
|
|
375
387
|
optedOut: z.ZodDefault<z.ZodBoolean>;
|
|
376
|
-
channels: z.ZodDefault<z.ZodArray<z.ZodEnum<["email", "sms", "push", "webhook", "in-app"]>, "many">>;
|
|
388
|
+
channels: z.ZodDefault<z.ZodArray<z.ZodEnum<["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"]>, "many">>;
|
|
377
389
|
quietHours: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
378
390
|
start: z.ZodString;
|
|
379
391
|
end: z.ZodString;
|
|
@@ -385,14 +397,14 @@ declare const NotificationEnrichedPayloadSchema: z.ZodObject<{
|
|
|
385
397
|
end: string;
|
|
386
398
|
}>, "many">>;
|
|
387
399
|
}, "strip", z.ZodTypeAny, {
|
|
388
|
-
channels: ("push" | "email" | "sms" | "webhook" | "in-app")[];
|
|
400
|
+
channels: ("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[];
|
|
389
401
|
optedOut: boolean;
|
|
390
402
|
quietHours?: {
|
|
391
403
|
start: string;
|
|
392
404
|
end: string;
|
|
393
405
|
}[] | undefined;
|
|
394
406
|
}, {
|
|
395
|
-
channels?: ("push" | "email" | "sms" | "webhook" | "in-app")[] | undefined;
|
|
407
|
+
channels?: ("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[] | undefined;
|
|
396
408
|
quietHours?: {
|
|
397
409
|
start: string;
|
|
398
410
|
end: string;
|
|
@@ -403,7 +415,7 @@ declare const NotificationEnrichedPayloadSchema: z.ZodObject<{
|
|
|
403
415
|
id: string;
|
|
404
416
|
timezone: string;
|
|
405
417
|
preferences: {
|
|
406
|
-
channels: ("push" | "email" | "sms" | "webhook" | "in-app")[];
|
|
418
|
+
channels: ("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[];
|
|
407
419
|
optedOut: boolean;
|
|
408
420
|
quietHours?: {
|
|
409
421
|
start: string;
|
|
@@ -413,13 +425,16 @@ declare const NotificationEnrichedPayloadSchema: z.ZodObject<{
|
|
|
413
425
|
locale: string;
|
|
414
426
|
email?: string | undefined;
|
|
415
427
|
webhook?: string | undefined;
|
|
428
|
+
telegram?: string | undefined;
|
|
429
|
+
discord?: string | undefined;
|
|
430
|
+
slack?: string | undefined;
|
|
416
431
|
phone?: string | undefined;
|
|
417
432
|
pushToken?: string | undefined;
|
|
418
433
|
pushTokens?: string[] | undefined;
|
|
419
434
|
}, {
|
|
420
435
|
id: string;
|
|
421
436
|
preferences: {
|
|
422
|
-
channels?: ("push" | "email" | "sms" | "webhook" | "in-app")[] | undefined;
|
|
437
|
+
channels?: ("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[] | undefined;
|
|
423
438
|
quietHours?: {
|
|
424
439
|
start: string;
|
|
425
440
|
end: string;
|
|
@@ -428,6 +443,9 @@ declare const NotificationEnrichedPayloadSchema: z.ZodObject<{
|
|
|
428
443
|
};
|
|
429
444
|
email?: string | undefined;
|
|
430
445
|
webhook?: string | undefined;
|
|
446
|
+
telegram?: string | undefined;
|
|
447
|
+
discord?: string | undefined;
|
|
448
|
+
slack?: string | undefined;
|
|
431
449
|
timezone?: string | undefined;
|
|
432
450
|
phone?: string | undefined;
|
|
433
451
|
pushToken?: string | undefined;
|
|
@@ -436,20 +454,21 @@ declare const NotificationEnrichedPayloadSchema: z.ZodObject<{
|
|
|
436
454
|
}>;
|
|
437
455
|
aiPrompts: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
438
456
|
scheduledAt: z.ZodOptional<z.ZodString>;
|
|
439
|
-
fallbackChain: z.ZodOptional<z.ZodArray<z.ZodEnum<["email", "sms", "push", "webhook", "in-app"]>, "many">>;
|
|
457
|
+
fallbackChain: z.ZodOptional<z.ZodArray<z.ZodEnum<["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"]>, "many">>;
|
|
440
458
|
/** Campaign this message belongs to, carried from the originating request. */
|
|
441
459
|
campaignId: z.ZodOptional<z.ZodString>;
|
|
442
460
|
}, "strip", z.ZodTypeAny, {
|
|
443
|
-
channel: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
461
|
+
channel: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
444
462
|
priority: "low" | "normal" | "high" | "critical";
|
|
445
463
|
projectId: string;
|
|
446
464
|
recipientId: string;
|
|
465
|
+
rawEventId: string;
|
|
447
466
|
templateVariables: Record<string, unknown>;
|
|
448
467
|
recipient: {
|
|
449
468
|
id: string;
|
|
450
469
|
timezone: string;
|
|
451
470
|
preferences: {
|
|
452
|
-
channels: ("push" | "email" | "sms" | "webhook" | "in-app")[];
|
|
471
|
+
channels: ("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[];
|
|
453
472
|
optedOut: boolean;
|
|
454
473
|
quietHours?: {
|
|
455
474
|
start: string;
|
|
@@ -459,26 +478,29 @@ declare const NotificationEnrichedPayloadSchema: z.ZodObject<{
|
|
|
459
478
|
locale: string;
|
|
460
479
|
email?: string | undefined;
|
|
461
480
|
webhook?: string | undefined;
|
|
481
|
+
telegram?: string | undefined;
|
|
482
|
+
discord?: string | undefined;
|
|
483
|
+
slack?: string | undefined;
|
|
462
484
|
phone?: string | undefined;
|
|
463
485
|
pushToken?: string | undefined;
|
|
464
486
|
pushTokens?: string[] | undefined;
|
|
465
487
|
};
|
|
466
|
-
rawEventId: string;
|
|
467
488
|
aiPrompts?: Record<string, string> | undefined;
|
|
468
489
|
templateId?: string | undefined;
|
|
469
490
|
campaignId?: string | undefined;
|
|
470
491
|
scheduledAt?: string | undefined;
|
|
471
|
-
fallbackChain?: ("push" | "email" | "sms" | "webhook" | "in-app")[] | undefined;
|
|
492
|
+
fallbackChain?: ("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[] | undefined;
|
|
472
493
|
}, {
|
|
473
|
-
channel: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
494
|
+
channel: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
474
495
|
priority: "low" | "normal" | "high" | "critical";
|
|
475
496
|
projectId: string;
|
|
476
497
|
recipientId: string;
|
|
498
|
+
rawEventId: string;
|
|
477
499
|
templateVariables: Record<string, unknown>;
|
|
478
500
|
recipient: {
|
|
479
501
|
id: string;
|
|
480
502
|
preferences: {
|
|
481
|
-
channels?: ("push" | "email" | "sms" | "webhook" | "in-app")[] | undefined;
|
|
503
|
+
channels?: ("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[] | undefined;
|
|
482
504
|
quietHours?: {
|
|
483
505
|
start: string;
|
|
484
506
|
end: string;
|
|
@@ -487,18 +509,20 @@ declare const NotificationEnrichedPayloadSchema: z.ZodObject<{
|
|
|
487
509
|
};
|
|
488
510
|
email?: string | undefined;
|
|
489
511
|
webhook?: string | undefined;
|
|
512
|
+
telegram?: string | undefined;
|
|
513
|
+
discord?: string | undefined;
|
|
514
|
+
slack?: string | undefined;
|
|
490
515
|
timezone?: string | undefined;
|
|
491
516
|
phone?: string | undefined;
|
|
492
517
|
pushToken?: string | undefined;
|
|
493
518
|
pushTokens?: string[] | undefined;
|
|
494
519
|
locale?: string | undefined;
|
|
495
520
|
};
|
|
496
|
-
rawEventId: string;
|
|
497
521
|
aiPrompts?: Record<string, string> | undefined;
|
|
498
522
|
templateId?: string | undefined;
|
|
499
523
|
campaignId?: string | undefined;
|
|
500
524
|
scheduledAt?: string | undefined;
|
|
501
|
-
fallbackChain?: ("push" | "email" | "sms" | "webhook" | "in-app")[] | undefined;
|
|
525
|
+
fallbackChain?: ("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[] | undefined;
|
|
502
526
|
}>;
|
|
503
527
|
type NotificationEnrichedPayload = z.infer<typeof NotificationEnrichedPayloadSchema>;
|
|
504
528
|
//#endregion
|
|
@@ -572,7 +596,7 @@ declare const NotificationDispatchedPayloadSchema: z.ZodObject<{
|
|
|
572
596
|
taskId: z.ZodString;
|
|
573
597
|
enrichedEventId: z.ZodString;
|
|
574
598
|
recipientId: z.ZodString;
|
|
575
|
-
channel: z.ZodEnum<["email", "sms", "push", "webhook", "in-app"]>;
|
|
599
|
+
channel: z.ZodEnum<["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"]>;
|
|
576
600
|
priority: z.ZodEnum<["low", "normal", "high", "critical"]>;
|
|
577
601
|
templateId: z.ZodOptional<z.ZodString>;
|
|
578
602
|
templateVariables: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
@@ -584,11 +608,14 @@ declare const NotificationDispatchedPayloadSchema: z.ZodObject<{
|
|
|
584
608
|
webhook: z.ZodOptional<z.ZodString>;
|
|
585
609
|
pushTokens: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
586
610
|
pushToken: z.ZodOptional<z.ZodString>;
|
|
611
|
+
telegram: z.ZodOptional<z.ZodString>;
|
|
612
|
+
discord: z.ZodOptional<z.ZodString>;
|
|
613
|
+
slack: z.ZodOptional<z.ZodString>;
|
|
587
614
|
locale: z.ZodDefault<z.ZodString>;
|
|
588
615
|
timezone: z.ZodDefault<z.ZodString>;
|
|
589
616
|
preferences: z.ZodObject<{
|
|
590
617
|
optedOut: z.ZodDefault<z.ZodBoolean>;
|
|
591
|
-
channels: z.ZodDefault<z.ZodArray<z.ZodEnum<["email", "sms", "push", "webhook", "in-app"]>, "many">>;
|
|
618
|
+
channels: z.ZodDefault<z.ZodArray<z.ZodEnum<["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"]>, "many">>;
|
|
592
619
|
quietHours: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
593
620
|
start: z.ZodString;
|
|
594
621
|
end: z.ZodString;
|
|
@@ -600,14 +627,14 @@ declare const NotificationDispatchedPayloadSchema: z.ZodObject<{
|
|
|
600
627
|
end: string;
|
|
601
628
|
}>, "many">>;
|
|
602
629
|
}, "strip", z.ZodTypeAny, {
|
|
603
|
-
channels: ("push" | "email" | "sms" | "webhook" | "in-app")[];
|
|
630
|
+
channels: ("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[];
|
|
604
631
|
optedOut: boolean;
|
|
605
632
|
quietHours?: {
|
|
606
633
|
start: string;
|
|
607
634
|
end: string;
|
|
608
635
|
}[] | undefined;
|
|
609
636
|
}, {
|
|
610
|
-
channels?: ("push" | "email" | "sms" | "webhook" | "in-app")[] | undefined;
|
|
637
|
+
channels?: ("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[] | undefined;
|
|
611
638
|
quietHours?: {
|
|
612
639
|
start: string;
|
|
613
640
|
end: string;
|
|
@@ -618,7 +645,7 @@ declare const NotificationDispatchedPayloadSchema: z.ZodObject<{
|
|
|
618
645
|
id: string;
|
|
619
646
|
timezone: string;
|
|
620
647
|
preferences: {
|
|
621
|
-
channels: ("push" | "email" | "sms" | "webhook" | "in-app")[];
|
|
648
|
+
channels: ("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[];
|
|
622
649
|
optedOut: boolean;
|
|
623
650
|
quietHours?: {
|
|
624
651
|
start: string;
|
|
@@ -628,13 +655,16 @@ declare const NotificationDispatchedPayloadSchema: z.ZodObject<{
|
|
|
628
655
|
locale: string;
|
|
629
656
|
email?: string | undefined;
|
|
630
657
|
webhook?: string | undefined;
|
|
658
|
+
telegram?: string | undefined;
|
|
659
|
+
discord?: string | undefined;
|
|
660
|
+
slack?: string | undefined;
|
|
631
661
|
phone?: string | undefined;
|
|
632
662
|
pushToken?: string | undefined;
|
|
633
663
|
pushTokens?: string[] | undefined;
|
|
634
664
|
}, {
|
|
635
665
|
id: string;
|
|
636
666
|
preferences: {
|
|
637
|
-
channels?: ("push" | "email" | "sms" | "webhook" | "in-app")[] | undefined;
|
|
667
|
+
channels?: ("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[] | undefined;
|
|
638
668
|
quietHours?: {
|
|
639
669
|
start: string;
|
|
640
670
|
end: string;
|
|
@@ -643,6 +673,9 @@ declare const NotificationDispatchedPayloadSchema: z.ZodObject<{
|
|
|
643
673
|
};
|
|
644
674
|
email?: string | undefined;
|
|
645
675
|
webhook?: string | undefined;
|
|
676
|
+
telegram?: string | undefined;
|
|
677
|
+
discord?: string | undefined;
|
|
678
|
+
slack?: string | undefined;
|
|
646
679
|
timezone?: string | undefined;
|
|
647
680
|
phone?: string | undefined;
|
|
648
681
|
pushToken?: string | undefined;
|
|
@@ -693,17 +726,17 @@ declare const NotificationDispatchedPayloadSchema: z.ZodObject<{
|
|
|
693
726
|
timeoutMs?: number | undefined;
|
|
694
727
|
headers?: Record<string, string> | undefined;
|
|
695
728
|
}>;
|
|
696
|
-
fallbackChain: z.ZodOptional<z.ZodArray<z.ZodEnum<["email", "sms", "push", "webhook", "in-app"]>, "many">>;
|
|
729
|
+
fallbackChain: z.ZodOptional<z.ZodArray<z.ZodEnum<["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"]>, "many">>;
|
|
697
730
|
throttleAttemptCount: z.ZodOptional<z.ZodNumber>;
|
|
698
731
|
/** Campaign this message belongs to, carried from the originating request. */
|
|
699
732
|
campaignId: z.ZodOptional<z.ZodString>;
|
|
700
733
|
}, "strip", z.ZodTypeAny, {
|
|
701
|
-
channel: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
734
|
+
channel: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
702
735
|
priority: "low" | "normal" | "high" | "critical";
|
|
703
736
|
projectId: string;
|
|
704
737
|
taskId: string;
|
|
705
|
-
enrichedEventId: string;
|
|
706
738
|
recipientId: string;
|
|
739
|
+
enrichedEventId: string;
|
|
707
740
|
templateVariables: Record<string, unknown>;
|
|
708
741
|
renderedContent: {
|
|
709
742
|
content: Record<string, unknown>;
|
|
@@ -726,7 +759,7 @@ declare const NotificationDispatchedPayloadSchema: z.ZodObject<{
|
|
|
726
759
|
id: string;
|
|
727
760
|
timezone: string;
|
|
728
761
|
preferences: {
|
|
729
|
-
channels: ("push" | "email" | "sms" | "webhook" | "in-app")[];
|
|
762
|
+
channels: ("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[];
|
|
730
763
|
optedOut: boolean;
|
|
731
764
|
quietHours?: {
|
|
732
765
|
start: string;
|
|
@@ -736,19 +769,22 @@ declare const NotificationDispatchedPayloadSchema: z.ZodObject<{
|
|
|
736
769
|
locale: string;
|
|
737
770
|
email?: string | undefined;
|
|
738
771
|
webhook?: string | undefined;
|
|
772
|
+
telegram?: string | undefined;
|
|
773
|
+
discord?: string | undefined;
|
|
774
|
+
slack?: string | undefined;
|
|
739
775
|
phone?: string | undefined;
|
|
740
776
|
pushToken?: string | undefined;
|
|
741
777
|
pushTokens?: string[] | undefined;
|
|
742
778
|
} | undefined;
|
|
743
|
-
fallbackChain?: ("push" | "email" | "sms" | "webhook" | "in-app")[] | undefined;
|
|
779
|
+
fallbackChain?: ("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[] | undefined;
|
|
744
780
|
throttleAttemptCount?: number | undefined;
|
|
745
781
|
}, {
|
|
746
|
-
channel: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
782
|
+
channel: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
747
783
|
priority: "low" | "normal" | "high" | "critical";
|
|
748
784
|
projectId: string;
|
|
749
785
|
taskId: string;
|
|
750
|
-
enrichedEventId: string;
|
|
751
786
|
recipientId: string;
|
|
787
|
+
enrichedEventId: string;
|
|
752
788
|
renderedContent: {
|
|
753
789
|
content: Record<string, unknown>;
|
|
754
790
|
attachments?: {
|
|
@@ -770,7 +806,7 @@ declare const NotificationDispatchedPayloadSchema: z.ZodObject<{
|
|
|
770
806
|
recipient?: {
|
|
771
807
|
id: string;
|
|
772
808
|
preferences: {
|
|
773
|
-
channels?: ("push" | "email" | "sms" | "webhook" | "in-app")[] | undefined;
|
|
809
|
+
channels?: ("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[] | undefined;
|
|
774
810
|
quietHours?: {
|
|
775
811
|
start: string;
|
|
776
812
|
end: string;
|
|
@@ -779,13 +815,16 @@ declare const NotificationDispatchedPayloadSchema: z.ZodObject<{
|
|
|
779
815
|
};
|
|
780
816
|
email?: string | undefined;
|
|
781
817
|
webhook?: string | undefined;
|
|
818
|
+
telegram?: string | undefined;
|
|
819
|
+
discord?: string | undefined;
|
|
820
|
+
slack?: string | undefined;
|
|
782
821
|
timezone?: string | undefined;
|
|
783
822
|
phone?: string | undefined;
|
|
784
823
|
pushToken?: string | undefined;
|
|
785
824
|
pushTokens?: string[] | undefined;
|
|
786
825
|
locale?: string | undefined;
|
|
787
826
|
} | undefined;
|
|
788
|
-
fallbackChain?: ("push" | "email" | "sms" | "webhook" | "in-app")[] | undefined;
|
|
827
|
+
fallbackChain?: ("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[] | undefined;
|
|
789
828
|
throttleAttemptCount?: number | undefined;
|
|
790
829
|
}>;
|
|
791
830
|
type NotificationDispatchedPayload = z.infer<typeof NotificationDispatchedPayloadSchema>;
|
|
@@ -795,7 +834,7 @@ declare const NotificationDeliveredPayloadSchema: z.ZodObject<{
|
|
|
795
834
|
projectId: z.ZodString;
|
|
796
835
|
taskId: z.ZodString;
|
|
797
836
|
enrichedEventId: z.ZodString;
|
|
798
|
-
channel: z.ZodEnum<["email", "sms", "push", "webhook", "in-app"]>;
|
|
837
|
+
channel: z.ZodEnum<["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"]>;
|
|
799
838
|
deliveredAt: z.ZodString;
|
|
800
839
|
providerMessageId: z.ZodOptional<z.ZodString>;
|
|
801
840
|
providerResponse: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
@@ -804,7 +843,7 @@ declare const NotificationDeliveredPayloadSchema: z.ZodObject<{
|
|
|
804
843
|
/** Campaign this message belongs to, carried from the originating request. */
|
|
805
844
|
campaignId: z.ZodOptional<z.ZodString>;
|
|
806
845
|
}, "strip", z.ZodTypeAny, {
|
|
807
|
-
channel: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
846
|
+
channel: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
808
847
|
projectId: string;
|
|
809
848
|
taskId: string;
|
|
810
849
|
enrichedEventId: string;
|
|
@@ -815,7 +854,7 @@ declare const NotificationDeliveredPayloadSchema: z.ZodObject<{
|
|
|
815
854
|
campaignId?: string | undefined;
|
|
816
855
|
providerResponse?: Record<string, unknown> | undefined;
|
|
817
856
|
}, {
|
|
818
|
-
channel: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
857
|
+
channel: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
819
858
|
projectId: string;
|
|
820
859
|
taskId: string;
|
|
821
860
|
enrichedEventId: string;
|
|
@@ -833,7 +872,7 @@ declare const NotificationFailedPayloadSchema: z.ZodObject<{
|
|
|
833
872
|
projectId: z.ZodString;
|
|
834
873
|
taskId: z.ZodString;
|
|
835
874
|
enrichedEventId: z.ZodString;
|
|
836
|
-
channel: z.ZodEnum<["email", "sms", "push", "webhook", "in-app"]>;
|
|
875
|
+
channel: z.ZodEnum<["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"]>;
|
|
837
876
|
failureReason: z.ZodString;
|
|
838
877
|
failureCode: z.ZodString;
|
|
839
878
|
retryable: z.ZodBoolean;
|
|
@@ -844,7 +883,7 @@ declare const NotificationFailedPayloadSchema: z.ZodObject<{
|
|
|
844
883
|
/** Campaign this message belongs to, carried from the originating request. */
|
|
845
884
|
campaignId: z.ZodOptional<z.ZodString>;
|
|
846
885
|
}, "strip", z.ZodTypeAny, {
|
|
847
|
-
channel: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
886
|
+
channel: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
848
887
|
projectId: string;
|
|
849
888
|
taskId: string;
|
|
850
889
|
attempt: number;
|
|
@@ -857,7 +896,7 @@ declare const NotificationFailedPayloadSchema: z.ZodObject<{
|
|
|
857
896
|
campaignId?: string | undefined;
|
|
858
897
|
providerResponse?: Record<string, unknown> | undefined;
|
|
859
898
|
}, {
|
|
860
|
-
channel: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
899
|
+
channel: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
861
900
|
projectId: string;
|
|
862
901
|
taskId: string;
|
|
863
902
|
attempt: number;
|
|
@@ -909,7 +948,7 @@ declare const NotificationAiPendingPayloadSchema: z.ZodObject<{
|
|
|
909
948
|
projectId: z.ZodString;
|
|
910
949
|
enrichedEventId: z.ZodString;
|
|
911
950
|
recipientId: z.ZodString;
|
|
912
|
-
channel: z.ZodEnum<["email", "sms", "push", "webhook", "in-app"]>;
|
|
951
|
+
channel: z.ZodEnum<["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"]>;
|
|
913
952
|
priority: z.ZodEnum<["low", "normal", "high", "critical"]>;
|
|
914
953
|
templateId: z.ZodOptional<z.ZodString>;
|
|
915
954
|
templateVariables: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
@@ -920,11 +959,14 @@ declare const NotificationAiPendingPayloadSchema: z.ZodObject<{
|
|
|
920
959
|
webhook: z.ZodOptional<z.ZodString>;
|
|
921
960
|
pushTokens: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
922
961
|
pushToken: z.ZodOptional<z.ZodString>;
|
|
962
|
+
telegram: z.ZodOptional<z.ZodString>;
|
|
963
|
+
discord: z.ZodOptional<z.ZodString>;
|
|
964
|
+
slack: z.ZodOptional<z.ZodString>;
|
|
923
965
|
locale: z.ZodDefault<z.ZodString>;
|
|
924
966
|
timezone: z.ZodDefault<z.ZodString>;
|
|
925
967
|
preferences: z.ZodObject<{
|
|
926
968
|
optedOut: z.ZodDefault<z.ZodBoolean>;
|
|
927
|
-
channels: z.ZodDefault<z.ZodArray<z.ZodEnum<["email", "sms", "push", "webhook", "in-app"]>, "many">>;
|
|
969
|
+
channels: z.ZodDefault<z.ZodArray<z.ZodEnum<["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"]>, "many">>;
|
|
928
970
|
quietHours: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
929
971
|
start: z.ZodString;
|
|
930
972
|
end: z.ZodString;
|
|
@@ -936,14 +978,14 @@ declare const NotificationAiPendingPayloadSchema: z.ZodObject<{
|
|
|
936
978
|
end: string;
|
|
937
979
|
}>, "many">>;
|
|
938
980
|
}, "strip", z.ZodTypeAny, {
|
|
939
|
-
channels: ("push" | "email" | "sms" | "webhook" | "in-app")[];
|
|
981
|
+
channels: ("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[];
|
|
940
982
|
optedOut: boolean;
|
|
941
983
|
quietHours?: {
|
|
942
984
|
start: string;
|
|
943
985
|
end: string;
|
|
944
986
|
}[] | undefined;
|
|
945
987
|
}, {
|
|
946
|
-
channels?: ("push" | "email" | "sms" | "webhook" | "in-app")[] | undefined;
|
|
988
|
+
channels?: ("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[] | undefined;
|
|
947
989
|
quietHours?: {
|
|
948
990
|
start: string;
|
|
949
991
|
end: string;
|
|
@@ -954,7 +996,7 @@ declare const NotificationAiPendingPayloadSchema: z.ZodObject<{
|
|
|
954
996
|
id: string;
|
|
955
997
|
timezone: string;
|
|
956
998
|
preferences: {
|
|
957
|
-
channels: ("push" | "email" | "sms" | "webhook" | "in-app")[];
|
|
999
|
+
channels: ("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[];
|
|
958
1000
|
optedOut: boolean;
|
|
959
1001
|
quietHours?: {
|
|
960
1002
|
start: string;
|
|
@@ -964,13 +1006,16 @@ declare const NotificationAiPendingPayloadSchema: z.ZodObject<{
|
|
|
964
1006
|
locale: string;
|
|
965
1007
|
email?: string | undefined;
|
|
966
1008
|
webhook?: string | undefined;
|
|
1009
|
+
telegram?: string | undefined;
|
|
1010
|
+
discord?: string | undefined;
|
|
1011
|
+
slack?: string | undefined;
|
|
967
1012
|
phone?: string | undefined;
|
|
968
1013
|
pushToken?: string | undefined;
|
|
969
1014
|
pushTokens?: string[] | undefined;
|
|
970
1015
|
}, {
|
|
971
1016
|
id: string;
|
|
972
1017
|
preferences: {
|
|
973
|
-
channels?: ("push" | "email" | "sms" | "webhook" | "in-app")[] | undefined;
|
|
1018
|
+
channels?: ("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[] | undefined;
|
|
974
1019
|
quietHours?: {
|
|
975
1020
|
start: string;
|
|
976
1021
|
end: string;
|
|
@@ -979,6 +1024,9 @@ declare const NotificationAiPendingPayloadSchema: z.ZodObject<{
|
|
|
979
1024
|
};
|
|
980
1025
|
email?: string | undefined;
|
|
981
1026
|
webhook?: string | undefined;
|
|
1027
|
+
telegram?: string | undefined;
|
|
1028
|
+
discord?: string | undefined;
|
|
1029
|
+
slack?: string | undefined;
|
|
982
1030
|
timezone?: string | undefined;
|
|
983
1031
|
phone?: string | undefined;
|
|
984
1032
|
pushToken?: string | undefined;
|
|
@@ -987,20 +1035,20 @@ declare const NotificationAiPendingPayloadSchema: z.ZodObject<{
|
|
|
987
1035
|
}>;
|
|
988
1036
|
aiPrompts: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
989
1037
|
scheduledAt: z.ZodOptional<z.ZodString>;
|
|
990
|
-
fallbackChain: z.ZodOptional<z.ZodArray<z.ZodEnum<["email", "sms", "push", "webhook", "in-app"]>, "many">>;
|
|
1038
|
+
fallbackChain: z.ZodOptional<z.ZodArray<z.ZodEnum<["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"]>, "many">>;
|
|
991
1039
|
}, "strip", z.ZodTypeAny, {
|
|
992
|
-
channel: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
1040
|
+
channel: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
993
1041
|
priority: "low" | "normal" | "high" | "critical";
|
|
994
1042
|
aiPrompts: Record<string, string>;
|
|
995
1043
|
projectId: string;
|
|
996
|
-
enrichedEventId: string;
|
|
997
1044
|
recipientId: string;
|
|
1045
|
+
enrichedEventId: string;
|
|
998
1046
|
templateVariables: Record<string, unknown>;
|
|
999
1047
|
recipient: {
|
|
1000
1048
|
id: string;
|
|
1001
1049
|
timezone: string;
|
|
1002
1050
|
preferences: {
|
|
1003
|
-
channels: ("push" | "email" | "sms" | "webhook" | "in-app")[];
|
|
1051
|
+
channels: ("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[];
|
|
1004
1052
|
optedOut: boolean;
|
|
1005
1053
|
quietHours?: {
|
|
1006
1054
|
start: string;
|
|
@@ -1010,25 +1058,28 @@ declare const NotificationAiPendingPayloadSchema: z.ZodObject<{
|
|
|
1010
1058
|
locale: string;
|
|
1011
1059
|
email?: string | undefined;
|
|
1012
1060
|
webhook?: string | undefined;
|
|
1061
|
+
telegram?: string | undefined;
|
|
1062
|
+
discord?: string | undefined;
|
|
1063
|
+
slack?: string | undefined;
|
|
1013
1064
|
phone?: string | undefined;
|
|
1014
1065
|
pushToken?: string | undefined;
|
|
1015
1066
|
pushTokens?: string[] | undefined;
|
|
1016
1067
|
};
|
|
1017
1068
|
templateId?: string | undefined;
|
|
1018
1069
|
scheduledAt?: string | undefined;
|
|
1019
|
-
fallbackChain?: ("push" | "email" | "sms" | "webhook" | "in-app")[] | undefined;
|
|
1070
|
+
fallbackChain?: ("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[] | undefined;
|
|
1020
1071
|
}, {
|
|
1021
|
-
channel: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
1072
|
+
channel: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
1022
1073
|
priority: "low" | "normal" | "high" | "critical";
|
|
1023
1074
|
aiPrompts: Record<string, string>;
|
|
1024
1075
|
projectId: string;
|
|
1025
|
-
enrichedEventId: string;
|
|
1026
1076
|
recipientId: string;
|
|
1077
|
+
enrichedEventId: string;
|
|
1027
1078
|
templateVariables: Record<string, unknown>;
|
|
1028
1079
|
recipient: {
|
|
1029
1080
|
id: string;
|
|
1030
1081
|
preferences: {
|
|
1031
|
-
channels?: ("push" | "email" | "sms" | "webhook" | "in-app")[] | undefined;
|
|
1082
|
+
channels?: ("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[] | undefined;
|
|
1032
1083
|
quietHours?: {
|
|
1033
1084
|
start: string;
|
|
1034
1085
|
end: string;
|
|
@@ -1037,6 +1088,9 @@ declare const NotificationAiPendingPayloadSchema: z.ZodObject<{
|
|
|
1037
1088
|
};
|
|
1038
1089
|
email?: string | undefined;
|
|
1039
1090
|
webhook?: string | undefined;
|
|
1091
|
+
telegram?: string | undefined;
|
|
1092
|
+
discord?: string | undefined;
|
|
1093
|
+
slack?: string | undefined;
|
|
1040
1094
|
timezone?: string | undefined;
|
|
1041
1095
|
phone?: string | undefined;
|
|
1042
1096
|
pushToken?: string | undefined;
|
|
@@ -1045,7 +1099,7 @@ declare const NotificationAiPendingPayloadSchema: z.ZodObject<{
|
|
|
1045
1099
|
};
|
|
1046
1100
|
templateId?: string | undefined;
|
|
1047
1101
|
scheduledAt?: string | undefined;
|
|
1048
|
-
fallbackChain?: ("push" | "email" | "sms" | "webhook" | "in-app")[] | undefined;
|
|
1102
|
+
fallbackChain?: ("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[] | undefined;
|
|
1049
1103
|
}>;
|
|
1050
1104
|
type NotificationAiPendingPayload = z.infer<typeof NotificationAiPendingPayloadSchema>;
|
|
1051
1105
|
//#endregion
|
|
@@ -1315,8 +1369,8 @@ declare const PreferencesSchema: z.ZodObject<{
|
|
|
1315
1369
|
}[] | undefined;
|
|
1316
1370
|
}>;
|
|
1317
1371
|
type Preferences = z.infer<typeof PreferencesSchema>;
|
|
1318
|
-
/** Channels that carry an addressable target (email address, phone, push token, url). */
|
|
1319
|
-
declare const ContactChannelSchema: z.ZodEnum<["email", "sms", "push", "webhook"]>;
|
|
1372
|
+
/** Channels that carry an addressable target (email address, phone, push token, url, chat id). */
|
|
1373
|
+
declare const ContactChannelSchema: z.ZodEnum<["email", "sms", "push", "webhook", "telegram", "discord", "whatsapp", "slack"]>;
|
|
1320
1374
|
type ContactChannel = z.infer<typeof ContactChannelSchema>;
|
|
1321
1375
|
/**
|
|
1322
1376
|
* addUser({ id, email, phone, pushToken, segments, preferences })
|
|
@@ -1462,7 +1516,7 @@ declare const UpdateUserSchema: z.ZodObject<{
|
|
|
1462
1516
|
type UpdateUserInput = z.input<typeof UpdateUserSchema>;
|
|
1463
1517
|
/** addUserContact(userId, channel, { target, preferences }) — channel carried in body. */
|
|
1464
1518
|
declare const AddContactSchema: z.ZodObject<{
|
|
1465
|
-
channel: z.ZodEnum<["email", "sms", "push", "webhook"]>;
|
|
1519
|
+
channel: z.ZodEnum<["email", "sms", "push", "webhook", "telegram", "discord", "whatsapp", "slack"]>;
|
|
1466
1520
|
target: z.ZodString;
|
|
1467
1521
|
preferences: z.ZodOptional<z.ZodObject<{
|
|
1468
1522
|
channels: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
|
|
@@ -1493,7 +1547,7 @@ declare const AddContactSchema: z.ZodObject<{
|
|
|
1493
1547
|
}[] | undefined;
|
|
1494
1548
|
}>>;
|
|
1495
1549
|
}, "strip", z.ZodTypeAny, {
|
|
1496
|
-
channel: "push" | "email" | "sms" | "webhook";
|
|
1550
|
+
channel: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack";
|
|
1497
1551
|
target: string;
|
|
1498
1552
|
preferences?: {
|
|
1499
1553
|
channels?: Record<string, boolean> | undefined;
|
|
@@ -1504,7 +1558,7 @@ declare const AddContactSchema: z.ZodObject<{
|
|
|
1504
1558
|
}[] | undefined;
|
|
1505
1559
|
} | undefined;
|
|
1506
1560
|
}, {
|
|
1507
|
-
channel: "push" | "email" | "sms" | "webhook";
|
|
1561
|
+
channel: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack";
|
|
1508
1562
|
target: string;
|
|
1509
1563
|
preferences?: {
|
|
1510
1564
|
channels?: Record<string, boolean> | undefined;
|
|
@@ -1518,18 +1572,18 @@ declare const AddContactSchema: z.ZodObject<{
|
|
|
1518
1572
|
type AddContactInput = z.infer<typeof AddContactSchema>;
|
|
1519
1573
|
declare const TemplateSchema: z.ZodObject<{
|
|
1520
1574
|
id: z.ZodString;
|
|
1521
|
-
channel: z.ZodEnum<["email", "sms", "push", "webhook", "in-app"]>;
|
|
1575
|
+
channel: z.ZodEnum<["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"]>;
|
|
1522
1576
|
topic: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodArray<z.ZodString, "many">]>, string[], string | string[]>>;
|
|
1523
1577
|
content: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
1524
1578
|
aiPrompts: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
1525
1579
|
}, "strip", z.ZodTypeAny, {
|
|
1526
|
-
channel: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
1580
|
+
channel: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
1527
1581
|
id: string;
|
|
1528
1582
|
content: Record<string, unknown>;
|
|
1529
1583
|
topic?: string[] | undefined;
|
|
1530
1584
|
aiPrompts?: Record<string, string> | undefined;
|
|
1531
1585
|
}, {
|
|
1532
|
-
channel: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
1586
|
+
channel: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
1533
1587
|
id: string;
|
|
1534
1588
|
content: Record<string, unknown>;
|
|
1535
1589
|
topic?: string | string[] | undefined;
|
|
@@ -1539,18 +1593,18 @@ type TemplateInput = z.infer<typeof TemplateSchema>;
|
|
|
1539
1593
|
declare const SyncTemplatesSchema: z.ZodObject<{
|
|
1540
1594
|
templates: z.ZodArray<z.ZodObject<{
|
|
1541
1595
|
id: z.ZodString;
|
|
1542
|
-
channel: z.ZodEnum<["email", "sms", "push", "webhook", "in-app"]>;
|
|
1596
|
+
channel: z.ZodEnum<["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"]>;
|
|
1543
1597
|
topic: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodArray<z.ZodString, "many">]>, string[], string | string[]>>;
|
|
1544
1598
|
content: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
1545
1599
|
aiPrompts: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
1546
1600
|
}, "strip", z.ZodTypeAny, {
|
|
1547
|
-
channel: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
1601
|
+
channel: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
1548
1602
|
id: string;
|
|
1549
1603
|
content: Record<string, unknown>;
|
|
1550
1604
|
topic?: string[] | undefined;
|
|
1551
1605
|
aiPrompts?: Record<string, string> | undefined;
|
|
1552
1606
|
}, {
|
|
1553
|
-
channel: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
1607
|
+
channel: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
1554
1608
|
id: string;
|
|
1555
1609
|
content: Record<string, unknown>;
|
|
1556
1610
|
topic?: string | string[] | undefined;
|
|
@@ -1558,7 +1612,7 @@ declare const SyncTemplatesSchema: z.ZodObject<{
|
|
|
1558
1612
|
}>, "many">;
|
|
1559
1613
|
}, "strip", z.ZodTypeAny, {
|
|
1560
1614
|
templates: {
|
|
1561
|
-
channel: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
1615
|
+
channel: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
1562
1616
|
id: string;
|
|
1563
1617
|
content: Record<string, unknown>;
|
|
1564
1618
|
topic?: string[] | undefined;
|
|
@@ -1566,7 +1620,7 @@ declare const SyncTemplatesSchema: z.ZodObject<{
|
|
|
1566
1620
|
}[];
|
|
1567
1621
|
}, {
|
|
1568
1622
|
templates: {
|
|
1569
|
-
channel: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
1623
|
+
channel: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
1570
1624
|
id: string;
|
|
1571
1625
|
content: Record<string, unknown>;
|
|
1572
1626
|
topic?: string | string[] | undefined;
|
|
@@ -1789,7 +1843,7 @@ declare const NotifyRequestSchema: z.ZodEffects<z.ZodObject<{
|
|
|
1789
1843
|
data: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
1790
1844
|
aiPrompts: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
1791
1845
|
priority: z.ZodOptional<z.ZodEnum<["low", "normal", "high", "critical"]>>;
|
|
1792
|
-
channels: z.ZodOptional<z.ZodArray<z.ZodEnum<["email", "sms", "push", "webhook", "in-app"]>, "atleastone">>;
|
|
1846
|
+
channels: z.ZodOptional<z.ZodArray<z.ZodEnum<["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"]>, "atleastone">>;
|
|
1793
1847
|
fallback: z.ZodOptional<z.ZodBoolean>;
|
|
1794
1848
|
sendAt: z.ZodOptional<z.ZodString>;
|
|
1795
1849
|
/**
|
|
@@ -1802,7 +1856,7 @@ declare const NotifyRequestSchema: z.ZodEffects<z.ZodObject<{
|
|
|
1802
1856
|
}, "strip", z.ZodTypeAny, {
|
|
1803
1857
|
template: string;
|
|
1804
1858
|
priority?: "low" | "normal" | "high" | "critical" | undefined;
|
|
1805
|
-
channels?: ["push" | "email" | "sms" | "webhook" | "in-app", ...("push" | "email" | "sms" | "webhook" | "in-app")[]] | undefined;
|
|
1859
|
+
channels?: ["push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app", ...("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[]] | undefined;
|
|
1806
1860
|
topic?: string | undefined;
|
|
1807
1861
|
aiPrompts?: Record<string, string> | undefined;
|
|
1808
1862
|
user?: string | {
|
|
@@ -1862,7 +1916,7 @@ declare const NotifyRequestSchema: z.ZodEffects<z.ZodObject<{
|
|
|
1862
1916
|
}, {
|
|
1863
1917
|
template: string;
|
|
1864
1918
|
priority?: "low" | "normal" | "high" | "critical" | undefined;
|
|
1865
|
-
channels?: ["push" | "email" | "sms" | "webhook" | "in-app", ...("push" | "email" | "sms" | "webhook" | "in-app")[]] | undefined;
|
|
1919
|
+
channels?: ["push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app", ...("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[]] | undefined;
|
|
1866
1920
|
topic?: string | undefined;
|
|
1867
1921
|
aiPrompts?: Record<string, string> | undefined;
|
|
1868
1922
|
user?: string | {
|
|
@@ -1922,7 +1976,7 @@ declare const NotifyRequestSchema: z.ZodEffects<z.ZodObject<{
|
|
|
1922
1976
|
}>, {
|
|
1923
1977
|
template: string;
|
|
1924
1978
|
priority?: "low" | "normal" | "high" | "critical" | undefined;
|
|
1925
|
-
channels?: ["push" | "email" | "sms" | "webhook" | "in-app", ...("push" | "email" | "sms" | "webhook" | "in-app")[]] | undefined;
|
|
1979
|
+
channels?: ["push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app", ...("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[]] | undefined;
|
|
1926
1980
|
topic?: string | undefined;
|
|
1927
1981
|
aiPrompts?: Record<string, string> | undefined;
|
|
1928
1982
|
user?: string | {
|
|
@@ -1982,7 +2036,7 @@ declare const NotifyRequestSchema: z.ZodEffects<z.ZodObject<{
|
|
|
1982
2036
|
}, {
|
|
1983
2037
|
template: string;
|
|
1984
2038
|
priority?: "low" | "normal" | "high" | "critical" | undefined;
|
|
1985
|
-
channels?: ["push" | "email" | "sms" | "webhook" | "in-app", ...("push" | "email" | "sms" | "webhook" | "in-app")[]] | undefined;
|
|
2039
|
+
channels?: ["push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app", ...("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[]] | undefined;
|
|
1986
2040
|
topic?: string | undefined;
|
|
1987
2041
|
aiPrompts?: Record<string, string> | undefined;
|
|
1988
2042
|
user?: string | {
|
|
@@ -2192,7 +2246,7 @@ declare const WorkflowNotifyPayloadSchema: z.ZodEffects<z.ZodObject<{
|
|
|
2192
2246
|
data: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
2193
2247
|
aiPrompts: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
2194
2248
|
priority: z.ZodOptional<z.ZodEnum<["low", "normal", "high", "critical"]>>;
|
|
2195
|
-
channels: z.ZodOptional<z.ZodArray<z.ZodEnum<["email", "sms", "push", "webhook", "in-app"]>, "atleastone">>;
|
|
2249
|
+
channels: z.ZodOptional<z.ZodArray<z.ZodEnum<["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"]>, "atleastone">>;
|
|
2196
2250
|
fallback: z.ZodOptional<z.ZodBoolean>;
|
|
2197
2251
|
sendAt: z.ZodOptional<z.ZodString>;
|
|
2198
2252
|
/**
|
|
@@ -2205,7 +2259,7 @@ declare const WorkflowNotifyPayloadSchema: z.ZodEffects<z.ZodObject<{
|
|
|
2205
2259
|
}, "strip", z.ZodTypeAny, {
|
|
2206
2260
|
template: string;
|
|
2207
2261
|
priority?: "low" | "normal" | "high" | "critical" | undefined;
|
|
2208
|
-
channels?: ["push" | "email" | "sms" | "webhook" | "in-app", ...("push" | "email" | "sms" | "webhook" | "in-app")[]] | undefined;
|
|
2262
|
+
channels?: ["push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app", ...("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[]] | undefined;
|
|
2209
2263
|
topic?: string | undefined;
|
|
2210
2264
|
aiPrompts?: Record<string, string> | undefined;
|
|
2211
2265
|
user?: string | {
|
|
@@ -2265,7 +2319,7 @@ declare const WorkflowNotifyPayloadSchema: z.ZodEffects<z.ZodObject<{
|
|
|
2265
2319
|
}, {
|
|
2266
2320
|
template: string;
|
|
2267
2321
|
priority?: "low" | "normal" | "high" | "critical" | undefined;
|
|
2268
|
-
channels?: ["push" | "email" | "sms" | "webhook" | "in-app", ...("push" | "email" | "sms" | "webhook" | "in-app")[]] | undefined;
|
|
2322
|
+
channels?: ["push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app", ...("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[]] | undefined;
|
|
2269
2323
|
topic?: string | undefined;
|
|
2270
2324
|
aiPrompts?: Record<string, string> | undefined;
|
|
2271
2325
|
user?: string | {
|
|
@@ -2325,7 +2379,7 @@ declare const WorkflowNotifyPayloadSchema: z.ZodEffects<z.ZodObject<{
|
|
|
2325
2379
|
}>, {
|
|
2326
2380
|
template: string;
|
|
2327
2381
|
priority?: "low" | "normal" | "high" | "critical" | undefined;
|
|
2328
|
-
channels?: ["push" | "email" | "sms" | "webhook" | "in-app", ...("push" | "email" | "sms" | "webhook" | "in-app")[]] | undefined;
|
|
2382
|
+
channels?: ["push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app", ...("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[]] | undefined;
|
|
2329
2383
|
topic?: string | undefined;
|
|
2330
2384
|
aiPrompts?: Record<string, string> | undefined;
|
|
2331
2385
|
user?: string | {
|
|
@@ -2385,7 +2439,7 @@ declare const WorkflowNotifyPayloadSchema: z.ZodEffects<z.ZodObject<{
|
|
|
2385
2439
|
}, {
|
|
2386
2440
|
template: string;
|
|
2387
2441
|
priority?: "low" | "normal" | "high" | "critical" | undefined;
|
|
2388
|
-
channels?: ["push" | "email" | "sms" | "webhook" | "in-app", ...("push" | "email" | "sms" | "webhook" | "in-app")[]] | undefined;
|
|
2442
|
+
channels?: ["push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app", ...("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[]] | undefined;
|
|
2389
2443
|
topic?: string | undefined;
|
|
2390
2444
|
aiPrompts?: Record<string, string> | undefined;
|
|
2391
2445
|
user?: string | {
|
|
@@ -2715,7 +2769,7 @@ declare const WorkflowStepSchema: z.ZodDiscriminatedUnion<"action", [z.ZodObject
|
|
|
2715
2769
|
data: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
2716
2770
|
aiPrompts: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
2717
2771
|
priority: z.ZodOptional<z.ZodEnum<["low", "normal", "high", "critical"]>>;
|
|
2718
|
-
channels: z.ZodOptional<z.ZodArray<z.ZodEnum<["email", "sms", "push", "webhook", "in-app"]>, "atleastone">>;
|
|
2772
|
+
channels: z.ZodOptional<z.ZodArray<z.ZodEnum<["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"]>, "atleastone">>;
|
|
2719
2773
|
fallback: z.ZodOptional<z.ZodBoolean>;
|
|
2720
2774
|
sendAt: z.ZodOptional<z.ZodString>;
|
|
2721
2775
|
/**
|
|
@@ -2728,7 +2782,7 @@ declare const WorkflowStepSchema: z.ZodDiscriminatedUnion<"action", [z.ZodObject
|
|
|
2728
2782
|
}, "strip", z.ZodTypeAny, {
|
|
2729
2783
|
template: string;
|
|
2730
2784
|
priority?: "low" | "normal" | "high" | "critical" | undefined;
|
|
2731
|
-
channels?: ["push" | "email" | "sms" | "webhook" | "in-app", ...("push" | "email" | "sms" | "webhook" | "in-app")[]] | undefined;
|
|
2785
|
+
channels?: ["push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app", ...("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[]] | undefined;
|
|
2732
2786
|
topic?: string | undefined;
|
|
2733
2787
|
aiPrompts?: Record<string, string> | undefined;
|
|
2734
2788
|
user?: string | {
|
|
@@ -2788,7 +2842,7 @@ declare const WorkflowStepSchema: z.ZodDiscriminatedUnion<"action", [z.ZodObject
|
|
|
2788
2842
|
}, {
|
|
2789
2843
|
template: string;
|
|
2790
2844
|
priority?: "low" | "normal" | "high" | "critical" | undefined;
|
|
2791
|
-
channels?: ["push" | "email" | "sms" | "webhook" | "in-app", ...("push" | "email" | "sms" | "webhook" | "in-app")[]] | undefined;
|
|
2845
|
+
channels?: ["push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app", ...("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[]] | undefined;
|
|
2792
2846
|
topic?: string | undefined;
|
|
2793
2847
|
aiPrompts?: Record<string, string> | undefined;
|
|
2794
2848
|
user?: string | {
|
|
@@ -2848,7 +2902,7 @@ declare const WorkflowStepSchema: z.ZodDiscriminatedUnion<"action", [z.ZodObject
|
|
|
2848
2902
|
}>, {
|
|
2849
2903
|
template: string;
|
|
2850
2904
|
priority?: "low" | "normal" | "high" | "critical" | undefined;
|
|
2851
|
-
channels?: ["push" | "email" | "sms" | "webhook" | "in-app", ...("push" | "email" | "sms" | "webhook" | "in-app")[]] | undefined;
|
|
2905
|
+
channels?: ["push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app", ...("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[]] | undefined;
|
|
2852
2906
|
topic?: string | undefined;
|
|
2853
2907
|
aiPrompts?: Record<string, string> | undefined;
|
|
2854
2908
|
user?: string | {
|
|
@@ -2908,7 +2962,7 @@ declare const WorkflowStepSchema: z.ZodDiscriminatedUnion<"action", [z.ZodObject
|
|
|
2908
2962
|
}, {
|
|
2909
2963
|
template: string;
|
|
2910
2964
|
priority?: "low" | "normal" | "high" | "critical" | undefined;
|
|
2911
|
-
channels?: ["push" | "email" | "sms" | "webhook" | "in-app", ...("push" | "email" | "sms" | "webhook" | "in-app")[]] | undefined;
|
|
2965
|
+
channels?: ["push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app", ...("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[]] | undefined;
|
|
2912
2966
|
topic?: string | undefined;
|
|
2913
2967
|
aiPrompts?: Record<string, string> | undefined;
|
|
2914
2968
|
user?: string | {
|
|
@@ -2971,7 +3025,7 @@ declare const WorkflowStepSchema: z.ZodDiscriminatedUnion<"action", [z.ZodObject
|
|
|
2971
3025
|
payload: {
|
|
2972
3026
|
template: string;
|
|
2973
3027
|
priority?: "low" | "normal" | "high" | "critical" | undefined;
|
|
2974
|
-
channels?: ["push" | "email" | "sms" | "webhook" | "in-app", ...("push" | "email" | "sms" | "webhook" | "in-app")[]] | undefined;
|
|
3028
|
+
channels?: ["push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app", ...("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[]] | undefined;
|
|
2975
3029
|
topic?: string | undefined;
|
|
2976
3030
|
aiPrompts?: Record<string, string> | undefined;
|
|
2977
3031
|
user?: string | {
|
|
@@ -3034,7 +3088,7 @@ declare const WorkflowStepSchema: z.ZodDiscriminatedUnion<"action", [z.ZodObject
|
|
|
3034
3088
|
payload: {
|
|
3035
3089
|
template: string;
|
|
3036
3090
|
priority?: "low" | "normal" | "high" | "critical" | undefined;
|
|
3037
|
-
channels?: ["push" | "email" | "sms" | "webhook" | "in-app", ...("push" | "email" | "sms" | "webhook" | "in-app")[]] | undefined;
|
|
3091
|
+
channels?: ["push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app", ...("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[]] | undefined;
|
|
3038
3092
|
topic?: string | undefined;
|
|
3039
3093
|
aiPrompts?: Record<string, string> | undefined;
|
|
3040
3094
|
user?: string | {
|
|
@@ -3273,7 +3327,7 @@ declare const CreateWorkflowSchema: z.ZodObject<{
|
|
|
3273
3327
|
data: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
3274
3328
|
aiPrompts: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
3275
3329
|
priority: z.ZodOptional<z.ZodEnum<["low", "normal", "high", "critical"]>>;
|
|
3276
|
-
channels: z.ZodOptional<z.ZodArray<z.ZodEnum<["email", "sms", "push", "webhook", "in-app"]>, "atleastone">>;
|
|
3330
|
+
channels: z.ZodOptional<z.ZodArray<z.ZodEnum<["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"]>, "atleastone">>;
|
|
3277
3331
|
fallback: z.ZodOptional<z.ZodBoolean>;
|
|
3278
3332
|
sendAt: z.ZodOptional<z.ZodString>;
|
|
3279
3333
|
/**
|
|
@@ -3286,7 +3340,7 @@ declare const CreateWorkflowSchema: z.ZodObject<{
|
|
|
3286
3340
|
}, "strip", z.ZodTypeAny, {
|
|
3287
3341
|
template: string;
|
|
3288
3342
|
priority?: "low" | "normal" | "high" | "critical" | undefined;
|
|
3289
|
-
channels?: ["push" | "email" | "sms" | "webhook" | "in-app", ...("push" | "email" | "sms" | "webhook" | "in-app")[]] | undefined;
|
|
3343
|
+
channels?: ["push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app", ...("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[]] | undefined;
|
|
3290
3344
|
topic?: string | undefined;
|
|
3291
3345
|
aiPrompts?: Record<string, string> | undefined;
|
|
3292
3346
|
user?: string | {
|
|
@@ -3346,7 +3400,7 @@ declare const CreateWorkflowSchema: z.ZodObject<{
|
|
|
3346
3400
|
}, {
|
|
3347
3401
|
template: string;
|
|
3348
3402
|
priority?: "low" | "normal" | "high" | "critical" | undefined;
|
|
3349
|
-
channels?: ["push" | "email" | "sms" | "webhook" | "in-app", ...("push" | "email" | "sms" | "webhook" | "in-app")[]] | undefined;
|
|
3403
|
+
channels?: ["push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app", ...("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[]] | undefined;
|
|
3350
3404
|
topic?: string | undefined;
|
|
3351
3405
|
aiPrompts?: Record<string, string> | undefined;
|
|
3352
3406
|
user?: string | {
|
|
@@ -3406,7 +3460,7 @@ declare const CreateWorkflowSchema: z.ZodObject<{
|
|
|
3406
3460
|
}>, {
|
|
3407
3461
|
template: string;
|
|
3408
3462
|
priority?: "low" | "normal" | "high" | "critical" | undefined;
|
|
3409
|
-
channels?: ["push" | "email" | "sms" | "webhook" | "in-app", ...("push" | "email" | "sms" | "webhook" | "in-app")[]] | undefined;
|
|
3463
|
+
channels?: ["push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app", ...("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[]] | undefined;
|
|
3410
3464
|
topic?: string | undefined;
|
|
3411
3465
|
aiPrompts?: Record<string, string> | undefined;
|
|
3412
3466
|
user?: string | {
|
|
@@ -3466,7 +3520,7 @@ declare const CreateWorkflowSchema: z.ZodObject<{
|
|
|
3466
3520
|
}, {
|
|
3467
3521
|
template: string;
|
|
3468
3522
|
priority?: "low" | "normal" | "high" | "critical" | undefined;
|
|
3469
|
-
channels?: ["push" | "email" | "sms" | "webhook" | "in-app", ...("push" | "email" | "sms" | "webhook" | "in-app")[]] | undefined;
|
|
3523
|
+
channels?: ["push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app", ...("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[]] | undefined;
|
|
3470
3524
|
topic?: string | undefined;
|
|
3471
3525
|
aiPrompts?: Record<string, string> | undefined;
|
|
3472
3526
|
user?: string | {
|
|
@@ -3529,7 +3583,7 @@ declare const CreateWorkflowSchema: z.ZodObject<{
|
|
|
3529
3583
|
payload: {
|
|
3530
3584
|
template: string;
|
|
3531
3585
|
priority?: "low" | "normal" | "high" | "critical" | undefined;
|
|
3532
|
-
channels?: ["push" | "email" | "sms" | "webhook" | "in-app", ...("push" | "email" | "sms" | "webhook" | "in-app")[]] | undefined;
|
|
3586
|
+
channels?: ["push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app", ...("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[]] | undefined;
|
|
3533
3587
|
topic?: string | undefined;
|
|
3534
3588
|
aiPrompts?: Record<string, string> | undefined;
|
|
3535
3589
|
user?: string | {
|
|
@@ -3592,7 +3646,7 @@ declare const CreateWorkflowSchema: z.ZodObject<{
|
|
|
3592
3646
|
payload: {
|
|
3593
3647
|
template: string;
|
|
3594
3648
|
priority?: "low" | "normal" | "high" | "critical" | undefined;
|
|
3595
|
-
channels?: ["push" | "email" | "sms" | "webhook" | "in-app", ...("push" | "email" | "sms" | "webhook" | "in-app")[]] | undefined;
|
|
3649
|
+
channels?: ["push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app", ...("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[]] | undefined;
|
|
3596
3650
|
topic?: string | undefined;
|
|
3597
3651
|
aiPrompts?: Record<string, string> | undefined;
|
|
3598
3652
|
user?: string | {
|
|
@@ -3689,7 +3743,7 @@ declare const CreateWorkflowSchema: z.ZodObject<{
|
|
|
3689
3743
|
payload: {
|
|
3690
3744
|
template: string;
|
|
3691
3745
|
priority?: "low" | "normal" | "high" | "critical" | undefined;
|
|
3692
|
-
channels?: ["push" | "email" | "sms" | "webhook" | "in-app", ...("push" | "email" | "sms" | "webhook" | "in-app")[]] | undefined;
|
|
3746
|
+
channels?: ["push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app", ...("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[]] | undefined;
|
|
3693
3747
|
topic?: string | undefined;
|
|
3694
3748
|
aiPrompts?: Record<string, string> | undefined;
|
|
3695
3749
|
user?: string | {
|
|
@@ -3764,7 +3818,7 @@ declare const CreateWorkflowSchema: z.ZodObject<{
|
|
|
3764
3818
|
payload: {
|
|
3765
3819
|
template: string;
|
|
3766
3820
|
priority?: "low" | "normal" | "high" | "critical" | undefined;
|
|
3767
|
-
channels?: ["push" | "email" | "sms" | "webhook" | "in-app", ...("push" | "email" | "sms" | "webhook" | "in-app")[]] | undefined;
|
|
3821
|
+
channels?: ["push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app", ...("push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app")[]] | undefined;
|
|
3768
3822
|
topic?: string | undefined;
|
|
3769
3823
|
aiPrompts?: Record<string, string> | undefined;
|
|
3770
3824
|
user?: string | {
|
|
@@ -3851,7 +3905,7 @@ type UpdateProjectInput = z.infer<typeof UpdateProjectSchema>;
|
|
|
3851
3905
|
declare namespace schema_d_exports {
|
|
3852
3906
|
export { apiKeyRoleEnum, channelEnum, contactTopicPreferences, deliveryOutbox, insertDeliveryOutboxSchema, insertMessageLogSchema, insertProjectApiKeySchema, insertProjectSchema, insertScheduledPayloadSchema, insertSuppressionSchema, insertUserChannelPreferenceSchema, insertUserContactSchema, insertUserSchema, insertUserSegmentSchema, insertUserTopicPreferenceSchema, insertWorkflowInstanceSchema, insertWorkflowStepSchema, insertWorkflowWaiterSchema, messageLogs, projectApiKeys, projects, quietHours, scheduledPayloads, selectDeliveryOutboxSchema, selectMessageLogSchema, selectProjectApiKeySchema, selectProjectSchema, selectScheduledPayloadSchema, selectSuppressionSchema, selectUserChannelPreferenceSchema, selectUserContactSchema, selectUserSchema, selectUserSegmentSchema, selectUserTopicPreferenceSchema, selectWorkflowInstanceSchema, selectWorkflowStepSchema, selectWorkflowWaiterSchema, suppressions, templates, userChannelPreferences, userContacts, userSegments, userTopicPreferences, users, workflowDefinitions, workflowInstances, workflowStatusEnum, workflowSteps, workflowWaiters };
|
|
3853
3907
|
}
|
|
3854
|
-
declare const channelEnum: import("drizzle-orm/pg-core").PgEnum<["email", "sms", "push", "webhook", "in-app"]>;
|
|
3908
|
+
declare const channelEnum: import("drizzle-orm/pg-core").PgEnum<["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"]>;
|
|
3855
3909
|
declare const projects: import("drizzle-orm/pg-core").PgTableWithColumns<{
|
|
3856
3910
|
name: "projects";
|
|
3857
3911
|
schema: undefined;
|
|
@@ -4270,14 +4324,14 @@ declare const userContacts: import("drizzle-orm/pg-core").PgTableWithColumns<{
|
|
|
4270
4324
|
tableName: "user_contacts";
|
|
4271
4325
|
dataType: "string";
|
|
4272
4326
|
columnType: "PgEnumColumn";
|
|
4273
|
-
data: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
4327
|
+
data: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
4274
4328
|
driverParam: string;
|
|
4275
4329
|
notNull: true;
|
|
4276
4330
|
hasDefault: false;
|
|
4277
4331
|
isPrimaryKey: false;
|
|
4278
4332
|
isAutoincrement: false;
|
|
4279
4333
|
hasRuntimeDefault: false;
|
|
4280
|
-
enumValues: ["email", "sms", "push", "webhook", "in-app"];
|
|
4334
|
+
enumValues: ["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"];
|
|
4281
4335
|
baseColumn: never;
|
|
4282
4336
|
identity: undefined;
|
|
4283
4337
|
generated: undefined;
|
|
@@ -4396,14 +4450,14 @@ declare const userChannelPreferences: import("drizzle-orm/pg-core").PgTableWithC
|
|
|
4396
4450
|
tableName: "user_channel_preferences";
|
|
4397
4451
|
dataType: "string";
|
|
4398
4452
|
columnType: "PgEnumColumn";
|
|
4399
|
-
data: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
4453
|
+
data: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
4400
4454
|
driverParam: string;
|
|
4401
4455
|
notNull: true;
|
|
4402
4456
|
hasDefault: false;
|
|
4403
4457
|
isPrimaryKey: false;
|
|
4404
4458
|
isAutoincrement: false;
|
|
4405
4459
|
hasRuntimeDefault: false;
|
|
4406
|
-
enumValues: ["email", "sms", "push", "webhook", "in-app"];
|
|
4460
|
+
enumValues: ["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"];
|
|
4407
4461
|
baseColumn: never;
|
|
4408
4462
|
identity: undefined;
|
|
4409
4463
|
generated: undefined;
|
|
@@ -4719,14 +4773,14 @@ declare const templates: import("drizzle-orm/pg-core").PgTableWithColumns<{
|
|
|
4719
4773
|
tableName: "templates";
|
|
4720
4774
|
dataType: "string";
|
|
4721
4775
|
columnType: "PgEnumColumn";
|
|
4722
|
-
data: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
4776
|
+
data: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
4723
4777
|
driverParam: string;
|
|
4724
4778
|
notNull: true;
|
|
4725
4779
|
hasDefault: false;
|
|
4726
4780
|
isPrimaryKey: false;
|
|
4727
4781
|
isAutoincrement: false;
|
|
4728
4782
|
hasRuntimeDefault: false;
|
|
4729
|
-
enumValues: ["email", "sms", "push", "webhook", "in-app"];
|
|
4783
|
+
enumValues: ["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"];
|
|
4730
4784
|
baseColumn: never;
|
|
4731
4785
|
identity: undefined;
|
|
4732
4786
|
generated: undefined;
|
|
@@ -4945,14 +4999,14 @@ declare const messageLogs: import("drizzle-orm/pg-core").PgTableWithColumns<{
|
|
|
4945
4999
|
tableName: "message_logs";
|
|
4946
5000
|
dataType: "string";
|
|
4947
5001
|
columnType: "PgEnumColumn";
|
|
4948
|
-
data: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
5002
|
+
data: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
4949
5003
|
driverParam: string;
|
|
4950
5004
|
notNull: true;
|
|
4951
5005
|
hasDefault: false;
|
|
4952
5006
|
isPrimaryKey: false;
|
|
4953
5007
|
isAutoincrement: false;
|
|
4954
5008
|
hasRuntimeDefault: false;
|
|
4955
|
-
enumValues: ["email", "sms", "push", "webhook", "in-app"];
|
|
5009
|
+
enumValues: ["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"];
|
|
4956
5010
|
baseColumn: never;
|
|
4957
5011
|
identity: undefined;
|
|
4958
5012
|
generated: undefined;
|
|
@@ -5120,14 +5174,14 @@ declare const suppressions: import("drizzle-orm/pg-core").PgTableWithColumns<{
|
|
|
5120
5174
|
tableName: "suppressions";
|
|
5121
5175
|
dataType: "string";
|
|
5122
5176
|
columnType: "PgEnumColumn";
|
|
5123
|
-
data: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
5177
|
+
data: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
5124
5178
|
driverParam: string;
|
|
5125
5179
|
notNull: true;
|
|
5126
5180
|
hasDefault: false;
|
|
5127
5181
|
isPrimaryKey: false;
|
|
5128
5182
|
isAutoincrement: false;
|
|
5129
5183
|
hasRuntimeDefault: false;
|
|
5130
|
-
enumValues: ["email", "sms", "push", "webhook", "in-app"];
|
|
5184
|
+
enumValues: ["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"];
|
|
5131
5185
|
baseColumn: never;
|
|
5132
5186
|
identity: undefined;
|
|
5133
5187
|
generated: undefined;
|
|
@@ -5754,14 +5808,14 @@ declare const deliveryOutbox: import("drizzle-orm/pg-core").PgTableWithColumns<{
|
|
|
5754
5808
|
tableName: "delivery_outbox";
|
|
5755
5809
|
dataType: "string";
|
|
5756
5810
|
columnType: "PgEnumColumn";
|
|
5757
|
-
data: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
5811
|
+
data: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
5758
5812
|
driverParam: string;
|
|
5759
5813
|
notNull: true;
|
|
5760
5814
|
hasDefault: false;
|
|
5761
5815
|
isPrimaryKey: false;
|
|
5762
5816
|
isAutoincrement: false;
|
|
5763
5817
|
hasRuntimeDefault: false;
|
|
5764
|
-
enumValues: ["email", "sms", "push", "webhook", "in-app"];
|
|
5818
|
+
enumValues: ["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"];
|
|
5765
5819
|
baseColumn: never;
|
|
5766
5820
|
identity: undefined;
|
|
5767
5821
|
generated: undefined;
|
|
@@ -6630,14 +6684,14 @@ declare const insertUserContactSchema: import("drizzle-zod").BuildSchema<"insert
|
|
|
6630
6684
|
tableName: "user_contacts";
|
|
6631
6685
|
dataType: "string";
|
|
6632
6686
|
columnType: "PgEnumColumn";
|
|
6633
|
-
data: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
6687
|
+
data: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
6634
6688
|
driverParam: string;
|
|
6635
6689
|
notNull: true;
|
|
6636
6690
|
hasDefault: false;
|
|
6637
6691
|
isPrimaryKey: false;
|
|
6638
6692
|
isAutoincrement: false;
|
|
6639
6693
|
hasRuntimeDefault: false;
|
|
6640
|
-
enumValues: ["email", "sms", "push", "webhook", "in-app"];
|
|
6694
|
+
enumValues: ["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"];
|
|
6641
6695
|
baseColumn: never;
|
|
6642
6696
|
identity: undefined;
|
|
6643
6697
|
generated: undefined;
|
|
@@ -6768,14 +6822,14 @@ declare const selectUserContactSchema: import("drizzle-zod").BuildSchema<"select
|
|
|
6768
6822
|
tableName: "user_contacts";
|
|
6769
6823
|
dataType: "string";
|
|
6770
6824
|
columnType: "PgEnumColumn";
|
|
6771
|
-
data: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
6825
|
+
data: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
6772
6826
|
driverParam: string;
|
|
6773
6827
|
notNull: true;
|
|
6774
6828
|
hasDefault: false;
|
|
6775
6829
|
isPrimaryKey: false;
|
|
6776
6830
|
isAutoincrement: false;
|
|
6777
6831
|
hasRuntimeDefault: false;
|
|
6778
|
-
enumValues: ["email", "sms", "push", "webhook", "in-app"];
|
|
6832
|
+
enumValues: ["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"];
|
|
6779
6833
|
baseColumn: never;
|
|
6780
6834
|
identity: undefined;
|
|
6781
6835
|
generated: undefined;
|
|
@@ -6889,14 +6943,14 @@ declare const insertUserChannelPreferenceSchema: import("drizzle-zod").BuildSche
|
|
|
6889
6943
|
tableName: "user_channel_preferences";
|
|
6890
6944
|
dataType: "string";
|
|
6891
6945
|
columnType: "PgEnumColumn";
|
|
6892
|
-
data: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
6946
|
+
data: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
6893
6947
|
driverParam: string;
|
|
6894
6948
|
notNull: true;
|
|
6895
6949
|
hasDefault: false;
|
|
6896
6950
|
isPrimaryKey: false;
|
|
6897
6951
|
isAutoincrement: false;
|
|
6898
6952
|
hasRuntimeDefault: false;
|
|
6899
|
-
enumValues: ["email", "sms", "push", "webhook", "in-app"];
|
|
6953
|
+
enumValues: ["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"];
|
|
6900
6954
|
baseColumn: never;
|
|
6901
6955
|
identity: undefined;
|
|
6902
6956
|
generated: undefined;
|
|
@@ -6942,14 +6996,14 @@ declare const selectUserChannelPreferenceSchema: import("drizzle-zod").BuildSche
|
|
|
6942
6996
|
tableName: "user_channel_preferences";
|
|
6943
6997
|
dataType: "string";
|
|
6944
6998
|
columnType: "PgEnumColumn";
|
|
6945
|
-
data: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
6999
|
+
data: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
6946
7000
|
driverParam: string;
|
|
6947
7001
|
notNull: true;
|
|
6948
7002
|
hasDefault: false;
|
|
6949
7003
|
isPrimaryKey: false;
|
|
6950
7004
|
isAutoincrement: false;
|
|
6951
7005
|
hasRuntimeDefault: false;
|
|
6952
|
-
enumValues: ["email", "sms", "push", "webhook", "in-app"];
|
|
7006
|
+
enumValues: ["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"];
|
|
6953
7007
|
baseColumn: never;
|
|
6954
7008
|
identity: undefined;
|
|
6955
7009
|
generated: undefined;
|
|
@@ -7230,14 +7284,14 @@ declare const insertMessageLogSchema: import("drizzle-zod").BuildSchema<"insert"
|
|
|
7230
7284
|
tableName: "message_logs";
|
|
7231
7285
|
dataType: "string";
|
|
7232
7286
|
columnType: "PgEnumColumn";
|
|
7233
|
-
data: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
7287
|
+
data: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
7234
7288
|
driverParam: string;
|
|
7235
7289
|
notNull: true;
|
|
7236
7290
|
hasDefault: false;
|
|
7237
7291
|
isPrimaryKey: false;
|
|
7238
7292
|
isAutoincrement: false;
|
|
7239
7293
|
hasRuntimeDefault: false;
|
|
7240
|
-
enumValues: ["email", "sms", "push", "webhook", "in-app"];
|
|
7294
|
+
enumValues: ["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"];
|
|
7241
7295
|
baseColumn: never;
|
|
7242
7296
|
identity: undefined;
|
|
7243
7297
|
generated: undefined;
|
|
@@ -7465,14 +7519,14 @@ declare const selectMessageLogSchema: import("drizzle-zod").BuildSchema<"select"
|
|
|
7465
7519
|
tableName: "message_logs";
|
|
7466
7520
|
dataType: "string";
|
|
7467
7521
|
columnType: "PgEnumColumn";
|
|
7468
|
-
data: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
7522
|
+
data: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
7469
7523
|
driverParam: string;
|
|
7470
7524
|
notNull: true;
|
|
7471
7525
|
hasDefault: false;
|
|
7472
7526
|
isPrimaryKey: false;
|
|
7473
7527
|
isAutoincrement: false;
|
|
7474
7528
|
hasRuntimeDefault: false;
|
|
7475
|
-
enumValues: ["email", "sms", "push", "webhook", "in-app"];
|
|
7529
|
+
enumValues: ["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"];
|
|
7476
7530
|
baseColumn: never;
|
|
7477
7531
|
identity: undefined;
|
|
7478
7532
|
generated: undefined;
|
|
@@ -7626,14 +7680,14 @@ declare const insertSuppressionSchema: import("drizzle-zod").BuildSchema<"insert
|
|
|
7626
7680
|
tableName: "suppressions";
|
|
7627
7681
|
dataType: "string";
|
|
7628
7682
|
columnType: "PgEnumColumn";
|
|
7629
|
-
data: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
7683
|
+
data: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
7630
7684
|
driverParam: string;
|
|
7631
7685
|
notNull: true;
|
|
7632
7686
|
hasDefault: false;
|
|
7633
7687
|
isPrimaryKey: false;
|
|
7634
7688
|
isAutoincrement: false;
|
|
7635
7689
|
hasRuntimeDefault: false;
|
|
7636
|
-
enumValues: ["email", "sms", "push", "webhook", "in-app"];
|
|
7690
|
+
enumValues: ["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"];
|
|
7637
7691
|
baseColumn: never;
|
|
7638
7692
|
identity: undefined;
|
|
7639
7693
|
generated: undefined;
|
|
@@ -7772,14 +7826,14 @@ declare const selectSuppressionSchema: import("drizzle-zod").BuildSchema<"select
|
|
|
7772
7826
|
tableName: "suppressions";
|
|
7773
7827
|
dataType: "string";
|
|
7774
7828
|
columnType: "PgEnumColumn";
|
|
7775
|
-
data: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
7829
|
+
data: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
7776
7830
|
driverParam: string;
|
|
7777
7831
|
notNull: true;
|
|
7778
7832
|
hasDefault: false;
|
|
7779
7833
|
isPrimaryKey: false;
|
|
7780
7834
|
isAutoincrement: false;
|
|
7781
7835
|
hasRuntimeDefault: false;
|
|
7782
|
-
enumValues: ["email", "sms", "push", "webhook", "in-app"];
|
|
7836
|
+
enumValues: ["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"];
|
|
7783
7837
|
baseColumn: never;
|
|
7784
7838
|
identity: undefined;
|
|
7785
7839
|
generated: undefined;
|
|
@@ -8679,14 +8733,14 @@ declare const insertDeliveryOutboxSchema: import("drizzle-zod").BuildSchema<"ins
|
|
|
8679
8733
|
tableName: "delivery_outbox";
|
|
8680
8734
|
dataType: "string";
|
|
8681
8735
|
columnType: "PgEnumColumn";
|
|
8682
|
-
data: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
8736
|
+
data: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
8683
8737
|
driverParam: string;
|
|
8684
8738
|
notNull: true;
|
|
8685
8739
|
hasDefault: false;
|
|
8686
8740
|
isPrimaryKey: false;
|
|
8687
8741
|
isAutoincrement: false;
|
|
8688
8742
|
hasRuntimeDefault: false;
|
|
8689
|
-
enumValues: ["email", "sms", "push", "webhook", "in-app"];
|
|
8743
|
+
enumValues: ["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"];
|
|
8690
8744
|
baseColumn: never;
|
|
8691
8745
|
identity: undefined;
|
|
8692
8746
|
generated: undefined;
|
|
@@ -8770,14 +8824,14 @@ declare const selectDeliveryOutboxSchema: import("drizzle-zod").BuildSchema<"sel
|
|
|
8770
8824
|
tableName: "delivery_outbox";
|
|
8771
8825
|
dataType: "string";
|
|
8772
8826
|
columnType: "PgEnumColumn";
|
|
8773
|
-
data: "push" | "email" | "sms" | "webhook" | "in-app";
|
|
8827
|
+
data: "push" | "email" | "sms" | "webhook" | "telegram" | "discord" | "whatsapp" | "slack" | "in-app";
|
|
8774
8828
|
driverParam: string;
|
|
8775
8829
|
notNull: true;
|
|
8776
8830
|
hasDefault: false;
|
|
8777
8831
|
isPrimaryKey: false;
|
|
8778
8832
|
isAutoincrement: false;
|
|
8779
8833
|
hasRuntimeDefault: false;
|
|
8780
|
-
enumValues: ["email", "sms", "push", "webhook", "in-app"];
|
|
8834
|
+
enumValues: ["email", "sms", "push", "webhook", "in-app", "telegram", "discord", "whatsapp", "slack"];
|
|
8781
8835
|
baseColumn: never;
|
|
8782
8836
|
identity: undefined;
|
|
8783
8837
|
generated: undefined;
|
|
@@ -9606,6 +9660,14 @@ interface Transport {
|
|
|
9606
9660
|
};
|
|
9607
9661
|
send(task: NotificationDispatchedPayload): Promise<DeliveryResult>;
|
|
9608
9662
|
webhookPath?: string;
|
|
9663
|
+
/**
|
|
9664
|
+
* Handles the one-time GET verification handshake some providers require
|
|
9665
|
+
* before they'll start POSTing to a webhook URL (e.g. Meta's hub.challenge
|
|
9666
|
+
* subscribe flow). Return the raw challenge string to echo back, or
|
|
9667
|
+
* undefined to reject the request. Providers that don't require this
|
|
9668
|
+
* (Resend, etc.) simply omit it.
|
|
9669
|
+
*/
|
|
9670
|
+
verifyWebhookChallenge?: (query: URLSearchParams) => Promise<string | undefined> | string | undefined;
|
|
9609
9671
|
verifyWebhook?: (rawBody: string, headers: Record<string, string | string[] | undefined>) => Promise<boolean> | boolean;
|
|
9610
9672
|
parseWebhook?: (body: any, rawBody?: string, headers?: Record<string, string | string[] | undefined>) => Promise<WebhookEvent[]>;
|
|
9611
9673
|
}
|
|
@@ -9986,6 +10048,8 @@ declare class NotifkitServer extends EventEmitter {
|
|
|
9986
10048
|
private redisContainer;
|
|
9987
10049
|
private eventCleanupFns;
|
|
9988
10050
|
private signalHandlersAttached;
|
|
10051
|
+
private sigintHandler?;
|
|
10052
|
+
private sigtermHandler?;
|
|
9989
10053
|
private logger;
|
|
9990
10054
|
constructor(options: NotifkitOptions);
|
|
9991
10055
|
start(): Promise<void>;
|