@novu/api 0.0.1-alpha.139 → 0.0.1-alpha.141

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.
Files changed (38) hide show
  1. package/docs/sdks/topics/README.md +1 -1
  2. package/funcs/topicsDelete.js +1 -1
  3. package/funcs/topicsDelete.js.map +1 -1
  4. package/lib/config.d.ts +2 -2
  5. package/lib/config.js +2 -2
  6. package/models/components/index.d.ts +4 -0
  7. package/models/components/index.d.ts.map +1 -1
  8. package/models/components/index.js +4 -0
  9. package/models/components/index.js.map +1 -1
  10. package/models/components/notificationtriggerresponse.d.ts +55 -0
  11. package/models/components/notificationtriggerresponse.d.ts.map +1 -0
  12. package/models/components/notificationtriggerresponse.js +72 -0
  13. package/models/components/notificationtriggerresponse.js.map +1 -0
  14. package/models/components/notificationtriggervariableresponse.d.ts +101 -0
  15. package/models/components/notificationtriggervariableresponse.d.ts.map +1 -0
  16. package/models/components/notificationtriggervariableresponse.js +111 -0
  17. package/models/components/notificationtriggervariableresponse.js.map +1 -0
  18. package/models/components/templateresponse.d.ts +3 -2
  19. package/models/components/templateresponse.d.ts.map +1 -1
  20. package/models/components/templateresponse.js +3 -2
  21. package/models/components/templateresponse.js.map +1 -1
  22. package/models/components/triggerreservedvariableresponse.d.ts +69 -0
  23. package/models/components/triggerreservedvariableresponse.d.ts.map +1 -0
  24. package/models/components/triggerreservedvariableresponse.js +83 -0
  25. package/models/components/triggerreservedvariableresponse.js.map +1 -0
  26. package/models/components/triggertypeenum.d.ts +31 -0
  27. package/models/components/triggertypeenum.d.ts.map +1 -0
  28. package/models/components/triggertypeenum.js +52 -0
  29. package/models/components/triggertypeenum.js.map +1 -0
  30. package/package.json +1 -1
  31. package/src/funcs/topicsDelete.ts +2 -2
  32. package/src/lib/config.ts +2 -2
  33. package/src/models/components/index.ts +4 -0
  34. package/src/models/components/notificationtriggerresponse.ts +126 -0
  35. package/src/models/components/notificationtriggervariableresponse.ts +173 -0
  36. package/src/models/components/templateresponse.ts +10 -4
  37. package/src/models/components/triggerreservedvariableresponse.ts +116 -0
  38. package/src/models/components/triggertypeenum.ts +38 -0
@@ -0,0 +1,116 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod";
6
+ import { safeParse } from "../../lib/schemas.js";
7
+ import { ClosedEnum } from "../../types/enums.js";
8
+ import { Result as SafeParseResult } from "../../types/fp.js";
9
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
+
11
+ /**
12
+ * The type of the reserved variable
13
+ */
14
+ export const TriggerReservedVariableResponseType = {
15
+ Tenant: "tenant",
16
+ Actor: "actor",
17
+ } as const;
18
+ /**
19
+ * The type of the reserved variable
20
+ */
21
+ export type TriggerReservedVariableResponseType = ClosedEnum<
22
+ typeof TriggerReservedVariableResponseType
23
+ >;
24
+
25
+ export type TriggerReservedVariableResponse = {
26
+ /**
27
+ * The type of the reserved variable
28
+ */
29
+ type: TriggerReservedVariableResponseType;
30
+ /**
31
+ * The reserved variables of the trigger
32
+ */
33
+ variables: Array<string>;
34
+ };
35
+
36
+ /** @internal */
37
+ export const TriggerReservedVariableResponseType$inboundSchema: z.ZodNativeEnum<
38
+ typeof TriggerReservedVariableResponseType
39
+ > = z.nativeEnum(TriggerReservedVariableResponseType);
40
+
41
+ /** @internal */
42
+ export const TriggerReservedVariableResponseType$outboundSchema:
43
+ z.ZodNativeEnum<typeof TriggerReservedVariableResponseType> =
44
+ TriggerReservedVariableResponseType$inboundSchema;
45
+
46
+ /**
47
+ * @internal
48
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
49
+ */
50
+ export namespace TriggerReservedVariableResponseType$ {
51
+ /** @deprecated use `TriggerReservedVariableResponseType$inboundSchema` instead. */
52
+ export const inboundSchema =
53
+ TriggerReservedVariableResponseType$inboundSchema;
54
+ /** @deprecated use `TriggerReservedVariableResponseType$outboundSchema` instead. */
55
+ export const outboundSchema =
56
+ TriggerReservedVariableResponseType$outboundSchema;
57
+ }
58
+
59
+ /** @internal */
60
+ export const TriggerReservedVariableResponse$inboundSchema: z.ZodType<
61
+ TriggerReservedVariableResponse,
62
+ z.ZodTypeDef,
63
+ unknown
64
+ > = z.object({
65
+ type: TriggerReservedVariableResponseType$inboundSchema,
66
+ variables: z.array(z.string()),
67
+ });
68
+
69
+ /** @internal */
70
+ export type TriggerReservedVariableResponse$Outbound = {
71
+ type: string;
72
+ variables: Array<string>;
73
+ };
74
+
75
+ /** @internal */
76
+ export const TriggerReservedVariableResponse$outboundSchema: z.ZodType<
77
+ TriggerReservedVariableResponse$Outbound,
78
+ z.ZodTypeDef,
79
+ TriggerReservedVariableResponse
80
+ > = z.object({
81
+ type: TriggerReservedVariableResponseType$outboundSchema,
82
+ variables: z.array(z.string()),
83
+ });
84
+
85
+ /**
86
+ * @internal
87
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
88
+ */
89
+ export namespace TriggerReservedVariableResponse$ {
90
+ /** @deprecated use `TriggerReservedVariableResponse$inboundSchema` instead. */
91
+ export const inboundSchema = TriggerReservedVariableResponse$inboundSchema;
92
+ /** @deprecated use `TriggerReservedVariableResponse$outboundSchema` instead. */
93
+ export const outboundSchema = TriggerReservedVariableResponse$outboundSchema;
94
+ /** @deprecated use `TriggerReservedVariableResponse$Outbound` instead. */
95
+ export type Outbound = TriggerReservedVariableResponse$Outbound;
96
+ }
97
+
98
+ export function triggerReservedVariableResponseToJSON(
99
+ triggerReservedVariableResponse: TriggerReservedVariableResponse,
100
+ ): string {
101
+ return JSON.stringify(
102
+ TriggerReservedVariableResponse$outboundSchema.parse(
103
+ triggerReservedVariableResponse,
104
+ ),
105
+ );
106
+ }
107
+
108
+ export function triggerReservedVariableResponseFromJSON(
109
+ jsonString: string,
110
+ ): SafeParseResult<TriggerReservedVariableResponse, SDKValidationError> {
111
+ return safeParse(
112
+ jsonString,
113
+ (x) => TriggerReservedVariableResponse$inboundSchema.parse(JSON.parse(x)),
114
+ `Failed to parse 'TriggerReservedVariableResponse' from JSON`,
115
+ );
116
+ }
@@ -0,0 +1,38 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod";
6
+ import { ClosedEnum } from "../../types/enums.js";
7
+
8
+ /**
9
+ * The type of the trigger
10
+ */
11
+ export const TriggerTypeEnum = {
12
+ Event: "event",
13
+ } as const;
14
+ /**
15
+ * The type of the trigger
16
+ */
17
+ export type TriggerTypeEnum = ClosedEnum<typeof TriggerTypeEnum>;
18
+
19
+ /** @internal */
20
+ export const TriggerTypeEnum$inboundSchema: z.ZodNativeEnum<
21
+ typeof TriggerTypeEnum
22
+ > = z.nativeEnum(TriggerTypeEnum);
23
+
24
+ /** @internal */
25
+ export const TriggerTypeEnum$outboundSchema: z.ZodNativeEnum<
26
+ typeof TriggerTypeEnum
27
+ > = TriggerTypeEnum$inboundSchema;
28
+
29
+ /**
30
+ * @internal
31
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
32
+ */
33
+ export namespace TriggerTypeEnum$ {
34
+ /** @deprecated use `TriggerTypeEnum$inboundSchema` instead. */
35
+ export const inboundSchema = TriggerTypeEnum$inboundSchema;
36
+ /** @deprecated use `TriggerTypeEnum$outboundSchema` instead. */
37
+ export const outboundSchema = TriggerTypeEnum$outboundSchema;
38
+ }