@voyantjs/notifications-react 0.20.0 → 0.21.1

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.
@@ -1,5 +1,6 @@
1
1
  export * from "./use-notification-deliveries.js";
2
2
  export * from "./use-notification-delivery.js";
3
+ export * from "./use-notification-delivery-mutation.js";
3
4
  export * from "./use-notification-reminder-rule.js";
4
5
  export * from "./use-notification-reminder-rule-mutation.js";
5
6
  export * from "./use-notification-reminder-rules.js";
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/hooks/index.ts"],"names":[],"mappings":"AAEA,cAAc,kCAAkC,CAAA;AAChD,cAAc,gCAAgC,CAAA;AAC9C,cAAc,qCAAqC,CAAA;AACnD,cAAc,8CAA8C,CAAA;AAC5D,cAAc,sCAAsC,CAAA;AACpD,cAAc,qCAAqC,CAAA;AACnD,cAAc,gCAAgC,CAAA;AAC9C,cAAc,0CAA0C,CAAA;AACxD,cAAc,yCAAyC,CAAA;AACvD,cAAc,sCAAsC,CAAA;AACpD,cAAc,iCAAiC,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/hooks/index.ts"],"names":[],"mappings":"AAEA,cAAc,kCAAkC,CAAA;AAChD,cAAc,gCAAgC,CAAA;AAC9C,cAAc,yCAAyC,CAAA;AACvD,cAAc,qCAAqC,CAAA;AACnD,cAAc,8CAA8C,CAAA;AAC5D,cAAc,sCAAsC,CAAA;AACpD,cAAc,qCAAqC,CAAA;AACnD,cAAc,gCAAgC,CAAA;AAC9C,cAAc,0CAA0C,CAAA;AACxD,cAAc,yCAAyC,CAAA;AACvD,cAAc,sCAAsC,CAAA;AACpD,cAAc,iCAAiC,CAAA"}
@@ -1,6 +1,7 @@
1
1
  "use client";
2
2
  export * from "./use-notification-deliveries.js";
3
3
  export * from "./use-notification-delivery.js";
4
+ export * from "./use-notification-delivery-mutation.js";
4
5
  export * from "./use-notification-reminder-rule.js";
5
6
  export * from "./use-notification-reminder-rule-mutation.js";
6
7
  export * from "./use-notification-reminder-rules.js";
@@ -0,0 +1,32 @@
1
+ export declare function useNotificationDeliveryMutation(): {
2
+ resend: import("@tanstack/react-query").UseMutationResult<{
3
+ id: string;
4
+ templateId: string | null;
5
+ templateSlug: string | null;
6
+ targetType: "booking_payment_schedule" | "invoice" | "booking" | "booking_guarantee" | "payment_session" | "person" | "organization" | "other";
7
+ targetId: string | null;
8
+ personId: string | null;
9
+ organizationId: string | null;
10
+ bookingId: string | null;
11
+ invoiceId: string | null;
12
+ paymentSessionId: string | null;
13
+ channel: "email" | "sms";
14
+ provider: string;
15
+ providerMessageId: string | null;
16
+ status: "pending" | "sent" | "failed" | "cancelled";
17
+ toAddress: string;
18
+ fromAddress: string | null;
19
+ subject: string | null;
20
+ htmlBody: string | null;
21
+ textBody: string | null;
22
+ payloadData: Record<string, unknown> | null;
23
+ metadata: Record<string, unknown> | null;
24
+ errorMessage: string | null;
25
+ scheduledFor: string | null;
26
+ sentAt: string | null;
27
+ failedAt: string | null;
28
+ createdAt: string;
29
+ updatedAt: string;
30
+ }, Error, string, unknown>;
31
+ };
32
+ //# sourceMappingURL=use-notification-delivery-mutation.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"use-notification-delivery-mutation.d.ts","sourceRoot":"","sources":["../../src/hooks/use-notification-delivery-mutation.ts"],"names":[],"mappings":"AASA,wBAAgB,+BAA+B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAwB9C"}
@@ -0,0 +1,24 @@
1
+ "use client";
2
+ import { useMutation, useQueryClient } from "@tanstack/react-query";
3
+ import { fetchWithValidation } from "../client.js";
4
+ import { useVoyantNotificationsContext } from "../provider.js";
5
+ import { notificationsQueryKeys } from "../query-keys.js";
6
+ import { notificationDeliverySingleResponse } from "../schemas.js";
7
+ export function useNotificationDeliveryMutation() {
8
+ const { baseUrl, fetcher } = useVoyantNotificationsContext();
9
+ const queryClient = useQueryClient();
10
+ const resend = useMutation({
11
+ mutationFn: async (deliveryId) => {
12
+ const { data } = await fetchWithValidation(`/v1/admin/notifications/deliveries/${deliveryId}/resend`, notificationDeliverySingleResponse, { baseUrl, fetcher }, { method: "POST" });
13
+ return data;
14
+ },
15
+ onSuccess: (delivery) => {
16
+ void queryClient.invalidateQueries({ queryKey: notificationsQueryKeys.deliveries() });
17
+ void queryClient.invalidateQueries({ queryKey: notificationsQueryKeys.delivery(delivery.id) });
18
+ },
19
+ onSettled: () => {
20
+ void queryClient.invalidateQueries({ queryKey: notificationsQueryKeys.deliveries() });
21
+ },
22
+ });
23
+ return { resend };
24
+ }
@@ -8,7 +8,7 @@ export declare function useNotificationReminderRuleMutation(): {
8
8
  slug: string;
9
9
  name: string;
10
10
  status: "draft" | "active" | "archived";
11
- targetType: "booking_payment_schedule" | "invoice";
11
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
12
12
  channel: "email" | "sms";
13
13
  provider: string | null;
14
14
  templateId: string | null;
@@ -21,7 +21,7 @@ export declare function useNotificationReminderRuleMutation(): {
21
21
  }, Error, {
22
22
  slug: string;
23
23
  name: string;
24
- targetType: "booking_payment_schedule" | "invoice";
24
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
25
25
  channel: "email" | "sms";
26
26
  status?: "draft" | "active" | "archived" | undefined;
27
27
  provider?: string | null | undefined;
@@ -36,7 +36,7 @@ export declare function useNotificationReminderRuleMutation(): {
36
36
  slug: string;
37
37
  name: string;
38
38
  status: "draft" | "active" | "archived";
39
- targetType: "booking_payment_schedule" | "invoice";
39
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
40
40
  channel: "email" | "sms";
41
41
  provider: string | null;
42
42
  templateId: string | null;
@@ -6,7 +6,7 @@ export declare function useNotificationReminderRule(id: string, options?: UseNot
6
6
  slug: string;
7
7
  name: string;
8
8
  status: "draft" | "active" | "archived";
9
- targetType: "booking_payment_schedule" | "invoice";
9
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
10
10
  channel: "email" | "sms";
11
11
  provider: string | null;
12
12
  templateId: string | null;
@@ -8,7 +8,7 @@ export declare function useNotificationReminderRules(options?: UseNotificationRe
8
8
  slug: string;
9
9
  name: string;
10
10
  status: "draft" | "active" | "archived";
11
- targetType: "booking_payment_schedule" | "invoice";
11
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
12
12
  channel: "email" | "sms";
13
13
  provider: string | null;
14
14
  templateId: string | null;
@@ -6,7 +6,7 @@ export declare function useNotificationReminderRuns(options?: UseNotificationRem
6
6
  data: {
7
7
  id: string;
8
8
  reminderRuleId: string;
9
- targetType: "booking_payment_schedule" | "invoice";
9
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
10
10
  targetId: string;
11
11
  dedupeKey: string;
12
12
  status: "sent" | "failed" | "queued" | "processing" | "skipped";
@@ -31,7 +31,7 @@ export declare function useNotificationReminderRuns(options?: UseNotificationRem
31
31
  slug: string;
32
32
  name: string;
33
33
  status: "draft" | "active" | "archived";
34
- targetType: "booking_payment_schedule" | "invoice";
34
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
35
35
  channel: "email" | "sms";
36
36
  provider: string | null;
37
37
  templateId: string | null;
@@ -8,7 +8,7 @@ export interface NotificationTemplatesListFilters {
8
8
  }
9
9
  export interface NotificationReminderRulesListFilters {
10
10
  search?: string | undefined;
11
- targetType?: "booking_payment_schedule" | "invoice" | undefined;
11
+ targetType?: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice" | undefined;
12
12
  channel?: "email" | "sms" | undefined;
13
13
  status?: "draft" | "active" | "archived" | undefined;
14
14
  limit?: number | undefined;
@@ -31,7 +31,7 @@ export interface NotificationDeliveriesListFilters {
31
31
  }
32
32
  export interface NotificationReminderRunsListFilters {
33
33
  reminderRuleId?: string | undefined;
34
- targetType?: "booking_payment_schedule" | "invoice" | undefined;
34
+ targetType?: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice" | undefined;
35
35
  targetId?: string | undefined;
36
36
  scheduleId?: string | undefined;
37
37
  invoiceId?: string | undefined;
@@ -1 +1 @@
1
- {"version":3,"file":"query-keys.d.ts","sourceRoot":"","sources":["../src/query-keys.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,gCAAgC;IAC/C,MAAM,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;IAC3B,OAAO,CAAC,EAAE,OAAO,GAAG,KAAK,GAAG,SAAS,CAAA;IACrC,QAAQ,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;IAC7B,MAAM,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,UAAU,GAAG,SAAS,CAAA;IACpD,KAAK,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;IAC1B,MAAM,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;CAC5B;AAED,MAAM,WAAW,oCAAoC;IACnD,MAAM,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;IAC3B,UAAU,CAAC,EAAE,0BAA0B,GAAG,SAAS,GAAG,SAAS,CAAA;IAC/D,OAAO,CAAC,EAAE,OAAO,GAAG,KAAK,GAAG,SAAS,CAAA;IACrC,MAAM,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,UAAU,GAAG,SAAS,CAAA;IACpD,KAAK,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;IAC1B,MAAM,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;CAC5B;AAED,MAAM,WAAW,iCAAiC;IAChD,OAAO,CAAC,EAAE,OAAO,GAAG,KAAK,GAAG,SAAS,CAAA;IACrC,QAAQ,C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AAA;IAC9B,gBAAgB,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;IACrC,sBAAsB,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;IAC3C,QAAQ,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;IAC7B,cAAc,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;IACnC,SAAS,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;IAC9B,MAAM,CAAC,EAAE,QAAQ,GAAG,YAAY,GAAG,MAAM,GAAG,SAAS,GAAG,QAAQ,GAAG,SAAS,CAAA;IAC5E,KAAK,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;IAC1B,MAAM,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;CAC5B;AAED,eAAO,MAAM,sBAAsB;;;6BAGR,gCAAgC;mBAE1C,MAAM;;8BAEK,iCAAiC;mBAE5C,MAAM;;iCAEQ,oCAAoC;uBAE9C,MAAM;;gCAEG,mCAAmC;sBAE7C,MAAM;CACzB,CAAA"}
@@ -422,7 +422,7 @@ export declare function getNotificationReminderRulesQueryOptions(client: FetchWi
422
422
  slug: string;
423
423
  name: string;
424
424
  status: "draft" | "active" | "archived";
425
- targetType: "booking_payment_schedule" | "invoice";
425
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
426
426
  channel: "email" | "sms";
427
427
  provider: string | null;
428
428
  templateId: string | null;
@@ -442,7 +442,7 @@ export declare function getNotificationReminderRulesQueryOptions(client: FetchWi
442
442
  slug: string;
443
443
  name: string;
444
444
  status: "draft" | "active" | "archived";
445
- targetType: "booking_payment_schedule" | "invoice";
445
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
446
446
  channel: "email" | "sms";
447
447
  provider: string | null;
448
448
  templateId: string | null;
@@ -463,7 +463,7 @@ export declare function getNotificationReminderRulesQueryOptions(client: FetchWi
463
463
  slug: string;
464
464
  name: string;
465
465
  status: "draft" | "active" | "archived";
466
- targetType: "booking_payment_schedule" | "invoice";
466
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
467
467
  channel: "email" | "sms";
468
468
  provider: string | null;
469
469
  templateId: string | null;
@@ -486,7 +486,7 @@ export declare function getNotificationReminderRulesQueryOptions(client: FetchWi
486
486
  slug: string;
487
487
  name: string;
488
488
  status: "draft" | "active" | "archived";
489
- targetType: "booking_payment_schedule" | "invoice";
489
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
490
490
  channel: "email" | "sms";
491
491
  provider: string | null;
492
492
  templateId: string | null;
@@ -509,7 +509,7 @@ export declare function getNotificationReminderRuleQueryOptions(client: FetchWit
509
509
  slug: string;
510
510
  name: string;
511
511
  status: "draft" | "active" | "archived";
512
- targetType: "booking_payment_schedule" | "invoice";
512
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
513
513
  channel: "email" | "sms";
514
514
  provider: string | null;
515
515
  templateId: string | null;
@@ -524,7 +524,7 @@ export declare function getNotificationReminderRuleQueryOptions(client: FetchWit
524
524
  slug: string;
525
525
  name: string;
526
526
  status: "draft" | "active" | "archived";
527
- targetType: "booking_payment_schedule" | "invoice";
527
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
528
528
  channel: "email" | "sms";
529
529
  provider: string | null;
530
530
  templateId: string | null;
@@ -540,7 +540,7 @@ export declare function getNotificationReminderRuleQueryOptions(client: FetchWit
540
540
  slug: string;
541
541
  name: string;
542
542
  status: "draft" | "active" | "archived";
543
- targetType: "booking_payment_schedule" | "invoice";
543
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
544
544
  channel: "email" | "sms";
545
545
  provider: string | null;
546
546
  templateId: string | null;
@@ -558,7 +558,7 @@ export declare function getNotificationReminderRuleQueryOptions(client: FetchWit
558
558
  slug: string;
559
559
  name: string;
560
560
  status: "draft" | "active" | "archived";
561
- targetType: "booking_payment_schedule" | "invoice";
561
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
562
562
  channel: "email" | "sms";
563
563
  provider: string | null;
564
564
  templateId: string | null;
@@ -576,7 +576,7 @@ export declare function getNotificationReminderRunsQueryOptions(client: FetchWit
576
576
  data: {
577
577
  id: string;
578
578
  reminderRuleId: string;
579
- targetType: "booking_payment_schedule" | "invoice";
579
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
580
580
  targetId: string;
581
581
  dedupeKey: string;
582
582
  status: "sent" | "failed" | "queued" | "processing" | "skipped";
@@ -601,7 +601,7 @@ export declare function getNotificationReminderRunsQueryOptions(client: FetchWit
601
601
  slug: string;
602
602
  name: string;
603
603
  status: "draft" | "active" | "archived";
604
- targetType: "booking_payment_schedule" | "invoice";
604
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
605
605
  channel: "email" | "sms";
606
606
  provider: string | null;
607
607
  templateId: string | null;
@@ -627,7 +627,7 @@ export declare function getNotificationReminderRunsQueryOptions(client: FetchWit
627
627
  data: {
628
628
  id: string;
629
629
  reminderRuleId: string;
630
- targetType: "booking_payment_schedule" | "invoice";
630
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
631
631
  targetId: string;
632
632
  dedupeKey: string;
633
633
  status: "sent" | "failed" | "queued" | "processing" | "skipped";
@@ -652,7 +652,7 @@ export declare function getNotificationReminderRunsQueryOptions(client: FetchWit
652
652
  slug: string;
653
653
  name: string;
654
654
  status: "draft" | "active" | "archived";
655
- targetType: "booking_payment_schedule" | "invoice";
655
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
656
656
  channel: "email" | "sms";
657
657
  provider: string | null;
658
658
  templateId: string | null;
@@ -679,7 +679,7 @@ export declare function getNotificationReminderRunsQueryOptions(client: FetchWit
679
679
  data: {
680
680
  id: string;
681
681
  reminderRuleId: string;
682
- targetType: "booking_payment_schedule" | "invoice";
682
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
683
683
  targetId: string;
684
684
  dedupeKey: string;
685
685
  status: "sent" | "failed" | "queued" | "processing" | "skipped";
@@ -704,7 +704,7 @@ export declare function getNotificationReminderRunsQueryOptions(client: FetchWit
704
704
  slug: string;
705
705
  name: string;
706
706
  status: "draft" | "active" | "archived";
707
- targetType: "booking_payment_schedule" | "invoice";
707
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
708
708
  channel: "email" | "sms";
709
709
  provider: string | null;
710
710
  templateId: string | null;
@@ -733,7 +733,7 @@ export declare function getNotificationReminderRunsQueryOptions(client: FetchWit
733
733
  data: {
734
734
  id: string;
735
735
  reminderRuleId: string;
736
- targetType: "booking_payment_schedule" | "invoice";
736
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
737
737
  targetId: string;
738
738
  dedupeKey: string;
739
739
  status: "sent" | "failed" | "queued" | "processing" | "skipped";
@@ -758,7 +758,7 @@ export declare function getNotificationReminderRunsQueryOptions(client: FetchWit
758
758
  slug: string;
759
759
  name: string;
760
760
  status: "draft" | "active" | "archived";
761
- targetType: "booking_payment_schedule" | "invoice";
761
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
762
762
  channel: "email" | "sms";
763
763
  provider: string | null;
764
764
  templateId: string | null;
@@ -787,7 +787,7 @@ export declare function getNotificationReminderRunsQueryOptions(client: FetchWit
787
787
  export declare function getNotificationReminderRunQueryOptions(client: FetchWithValidationOptions, id: string): import("@tanstack/react-query").OmitKeyof<import("@tanstack/react-query").UseQueryOptions<{
788
788
  id: string;
789
789
  reminderRuleId: string;
790
- targetType: "booking_payment_schedule" | "invoice";
790
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
791
791
  targetId: string;
792
792
  dedupeKey: string;
793
793
  status: "sent" | "failed" | "queued" | "processing" | "skipped";
@@ -812,7 +812,7 @@ export declare function getNotificationReminderRunQueryOptions(client: FetchWith
812
812
  slug: string;
813
813
  name: string;
814
814
  status: "draft" | "active" | "archived";
815
- targetType: "booking_payment_schedule" | "invoice";
815
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
816
816
  channel: "email" | "sms";
817
817
  provider: string | null;
818
818
  templateId: string | null;
@@ -833,7 +833,7 @@ export declare function getNotificationReminderRunQueryOptions(client: FetchWith
833
833
  }, Error, {
834
834
  id: string;
835
835
  reminderRuleId: string;
836
- targetType: "booking_payment_schedule" | "invoice";
836
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
837
837
  targetId: string;
838
838
  dedupeKey: string;
839
839
  status: "sent" | "failed" | "queued" | "processing" | "skipped";
@@ -858,7 +858,7 @@ export declare function getNotificationReminderRunQueryOptions(client: FetchWith
858
858
  slug: string;
859
859
  name: string;
860
860
  status: "draft" | "active" | "archived";
861
- targetType: "booking_payment_schedule" | "invoice";
861
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
862
862
  channel: "email" | "sms";
863
863
  provider: string | null;
864
864
  templateId: string | null;
@@ -880,7 +880,7 @@ export declare function getNotificationReminderRunQueryOptions(client: FetchWith
880
880
  queryFn?: import("@tanstack/react-query").QueryFunction<{
881
881
  id: string;
882
882
  reminderRuleId: string;
883
- targetType: "booking_payment_schedule" | "invoice";
883
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
884
884
  targetId: string;
885
885
  dedupeKey: string;
886
886
  status: "sent" | "failed" | "queued" | "processing" | "skipped";
@@ -905,7 +905,7 @@ export declare function getNotificationReminderRunQueryOptions(client: FetchWith
905
905
  slug: string;
906
906
  name: string;
907
907
  status: "draft" | "active" | "archived";
908
- targetType: "booking_payment_schedule" | "invoice";
908
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
909
909
  channel: "email" | "sms";
910
910
  provider: string | null;
911
911
  templateId: string | null;
@@ -929,7 +929,7 @@ export declare function getNotificationReminderRunQueryOptions(client: FetchWith
929
929
  [dataTagSymbol]: {
930
930
  id: string;
931
931
  reminderRuleId: string;
932
- targetType: "booking_payment_schedule" | "invoice";
932
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
933
933
  targetId: string;
934
934
  dedupeKey: string;
935
935
  status: "sent" | "failed" | "queued" | "processing" | "skipped";
@@ -954,7 +954,7 @@ export declare function getNotificationReminderRunQueryOptions(client: FetchWith
954
954
  slug: string;
955
955
  name: string;
956
956
  status: "draft" | "active" | "archived";
957
- targetType: "booking_payment_schedule" | "invoice";
957
+ targetType: "booking_confirmed" | "booking_payment_schedule" | "payment_complete" | "booking_cancelled_non_payment" | "invoice";
958
958
  channel: "email" | "sms";
959
959
  provider: string | null;
960
960
  templateId: string | null;
package/dist/schemas.d.ts CHANGED
@@ -93,7 +93,10 @@ export declare const notificationReminderRuleRecordSchema: z.ZodObject<{
93
93
  archived: "archived";
94
94
  }>;
95
95
  targetType: z.ZodEnum<{
96
+ booking_confirmed: "booking_confirmed";
96
97
  booking_payment_schedule: "booking_payment_schedule";
98
+ payment_complete: "payment_complete";
99
+ booking_cancelled_non_payment: "booking_cancelled_non_payment";
97
100
  invoice: "invoice";
98
101
  }>;
99
102
  channel: z.ZodEnum<{
@@ -275,7 +278,10 @@ export declare const notificationReminderRuleListResponse: z.ZodObject<{
275
278
  archived: "archived";
276
279
  }>;
277
280
  targetType: z.ZodEnum<{
281
+ booking_confirmed: "booking_confirmed";
278
282
  booking_payment_schedule: "booking_payment_schedule";
283
+ payment_complete: "payment_complete";
284
+ booking_cancelled_non_payment: "booking_cancelled_non_payment";
279
285
  invoice: "invoice";
280
286
  }>;
281
287
  channel: z.ZodEnum<{
@@ -306,7 +312,10 @@ export declare const notificationReminderRuleSingleResponse: z.ZodObject<{
306
312
  archived: "archived";
307
313
  }>;
308
314
  targetType: z.ZodEnum<{
315
+ booking_confirmed: "booking_confirmed";
309
316
  booking_payment_schedule: "booking_payment_schedule";
317
+ payment_complete: "payment_complete";
318
+ booking_cancelled_non_payment: "booking_cancelled_non_payment";
310
319
  invoice: "invoice";
311
320
  }>;
312
321
  channel: z.ZodEnum<{
@@ -328,7 +337,10 @@ export declare const notificationReminderRunListResponse: z.ZodObject<{
328
337
  id: z.ZodString;
329
338
  reminderRuleId: z.ZodString;
330
339
  targetType: z.ZodEnum<{
340
+ booking_confirmed: "booking_confirmed";
331
341
  booking_payment_schedule: "booking_payment_schedule";
342
+ payment_complete: "payment_complete";
343
+ booking_cancelled_non_payment: "booking_cancelled_non_payment";
332
344
  invoice: "invoice";
333
345
  }>;
334
346
  targetId: z.ZodString;
@@ -366,7 +378,10 @@ export declare const notificationReminderRunListResponse: z.ZodObject<{
366
378
  archived: "archived";
367
379
  }>;
368
380
  targetType: z.ZodEnum<{
381
+ booking_confirmed: "booking_confirmed";
369
382
  booking_payment_schedule: "booking_payment_schedule";
383
+ payment_complete: "payment_complete";
384
+ booking_cancelled_non_payment: "booking_cancelled_non_payment";
370
385
  invoice: "invoice";
371
386
  }>;
372
387
  channel: z.ZodEnum<{
@@ -407,7 +422,10 @@ export declare const notificationReminderRunSingleResponse: z.ZodObject<{
407
422
  id: z.ZodString;
408
423
  reminderRuleId: z.ZodString;
409
424
  targetType: z.ZodEnum<{
425
+ booking_confirmed: "booking_confirmed";
410
426
  booking_payment_schedule: "booking_payment_schedule";
427
+ payment_complete: "payment_complete";
428
+ booking_cancelled_non_payment: "booking_cancelled_non_payment";
411
429
  invoice: "invoice";
412
430
  }>;
413
431
  targetId: z.ZodString;
@@ -445,7 +463,10 @@ export declare const notificationReminderRunSingleResponse: z.ZodObject<{
445
463
  archived: "archived";
446
464
  }>;
447
465
  targetType: z.ZodEnum<{
466
+ booking_confirmed: "booking_confirmed";
448
467
  booking_payment_schedule: "booking_payment_schedule";
468
+ payment_complete: "payment_complete";
469
+ booking_cancelled_non_payment: "booking_cancelled_non_payment";
449
470
  invoice: "invoice";
450
471
  }>;
451
472
  channel: z.ZodEnum<{
@@ -1 +1 @@
1
- {"version":3,"file":"schemas.d.ts","sourceRoot":"","sources":["../src/schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAGL,mCAAmC,EAKnC,uCAAuC,IAAI,uCAAuC,EAEnF,MAAM,yBAAyB,CAAA;AAChC,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAEvB,eAAO,MAAM,iBAAiB,GAAI,CAAC,SAAS,CAAC,CAAC,UAAU,EAAE,MAAM,CAAC;;;;;iBAM7D,CAAA;AAEJ,eAAO,MAAM,cAAc,GAAI,CAAC,SAAS,CAAC,CAAC,UAAU,EAAE,MAAM,CAAC;;iBAA6B,CAAA;AAC3F,eAAO,MAAM,eAAe;;iBAAqC,CAAA;AAEjE,eAAO,MAAM,gCAAgC;;;;;;;;;;;;;;;;;;;;;;iBAe3C,CAAA;AAEF,MAAM,MAAM,0BAA0B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gCAAgC,CAAC,CAAA;AAEzF,eAAO,MAAM,gCAAgC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBA4B3C,CAAA;AAEF,MAAM,MAAM,0BAA0B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gCAAgC,CAAC,CAAA;AAEzF,eAAO,MAAM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AkC;;;;;;;;;;;;;;;;;;;;;;;;iBAAmD,CAAA;AAClG,eAAO,MAAM,gCAAgC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAAsD,CAAA;AACnG,eAAO,MAAM,kCAAkC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAAmD,CAAA;AAClG,eAAO,MAAM,oCAAoC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAEhD,CAAA;AACD,eAAO,MAAM,sCAAsC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAElD,CAAA;AACD,eAAO,MAAM,mCAAmC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAK9C,CAAA;AACF,eAAO,MAAM,qCAAqC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAEjD,CAAA;AACD,eAAO,MAAM,mCAAmC;;;;;;;;;;;;iBAE/C,CAAA;AAED,eAAO,MAAM,gCAAgC;;;;EAA4C,CAAA;AACzF,eAAO,MAAM,uCAAuC;;;EAA4B,CAAA;AAChF,eAAO,MAAM,0CAA0C;;;;EAAmC,CAAA;AAC1F,eAAO,MAAM,yCAAyC;;;;;;EAAsC,CAAA"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@voyantjs/notifications-react",
3
- "version": "0.20.0",
3
+ "version": "0.21.1",
4
4
  "license": "Apache-2.0",
5
5
  "repository": {
6
6
  "type": "git",
@@ -41,7 +41,7 @@
41
41
  "react": "^19.0.0",
42
42
  "react-dom": "^19.0.0",
43
43
  "zod": "^4.0.0",
44
- "@voyantjs/notifications": "0.20.0"
44
+ "@voyantjs/notifications": "0.21.1"
45
45
  },
46
46
  "devDependencies": {
47
47
  "@tanstack/react-query": "^5.96.2",
@@ -52,12 +52,12 @@
52
52
  "typescript": "^6.0.2",
53
53
  "vitest": "^4.1.2",
54
54
  "zod": "^4.3.6",
55
- "@voyantjs/notifications": "0.20.0",
56
- "@voyantjs/react": "0.20.0",
55
+ "@voyantjs/notifications": "0.21.1",
56
+ "@voyantjs/react": "0.21.1",
57
57
  "@voyantjs/voyant-typescript-config": "0.1.0"
58
58
  },
59
59
  "dependencies": {
60
- "@voyantjs/react": "0.20.0"
60
+ "@voyantjs/react": "0.21.1"
61
61
  },
62
62
  "files": [
63
63
  "dist"