@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.
- package/docs/sdks/topics/README.md +1 -1
- package/funcs/topicsDelete.js +1 -1
- package/funcs/topicsDelete.js.map +1 -1
- package/lib/config.d.ts +2 -2
- package/lib/config.js +2 -2
- package/models/components/index.d.ts +4 -0
- package/models/components/index.d.ts.map +1 -1
- package/models/components/index.js +4 -0
- package/models/components/index.js.map +1 -1
- package/models/components/notificationtriggerresponse.d.ts +55 -0
- package/models/components/notificationtriggerresponse.d.ts.map +1 -0
- package/models/components/notificationtriggerresponse.js +72 -0
- package/models/components/notificationtriggerresponse.js.map +1 -0
- package/models/components/notificationtriggervariableresponse.d.ts +101 -0
- package/models/components/notificationtriggervariableresponse.d.ts.map +1 -0
- package/models/components/notificationtriggervariableresponse.js +111 -0
- package/models/components/notificationtriggervariableresponse.js.map +1 -0
- package/models/components/templateresponse.d.ts +3 -2
- package/models/components/templateresponse.d.ts.map +1 -1
- package/models/components/templateresponse.js +3 -2
- package/models/components/templateresponse.js.map +1 -1
- package/models/components/triggerreservedvariableresponse.d.ts +69 -0
- package/models/components/triggerreservedvariableresponse.d.ts.map +1 -0
- package/models/components/triggerreservedvariableresponse.js +83 -0
- package/models/components/triggerreservedvariableresponse.js.map +1 -0
- package/models/components/triggertypeenum.d.ts +31 -0
- package/models/components/triggertypeenum.d.ts.map +1 -0
- package/models/components/triggertypeenum.js +52 -0
- package/models/components/triggertypeenum.js.map +1 -0
- package/package.json +1 -1
- package/src/funcs/topicsDelete.ts +2 -2
- package/src/lib/config.ts +2 -2
- package/src/models/components/index.ts +4 -0
- package/src/models/components/notificationtriggerresponse.ts +126 -0
- package/src/models/components/notificationtriggervariableresponse.ts +173 -0
- package/src/models/components/templateresponse.ts +10 -4
- package/src/models/components/triggerreservedvariableresponse.ts +116 -0
- package/src/models/components/triggertypeenum.ts +38 -0
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
import * as z from "zod";
|
|
2
|
+
import { ClosedEnum } from "../../types/enums.js";
|
|
3
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
4
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
5
|
+
/**
|
|
6
|
+
* The type of the reserved variable
|
|
7
|
+
*/
|
|
8
|
+
export declare const TriggerReservedVariableResponseType: {
|
|
9
|
+
readonly Tenant: "tenant";
|
|
10
|
+
readonly Actor: "actor";
|
|
11
|
+
};
|
|
12
|
+
/**
|
|
13
|
+
* The type of the reserved variable
|
|
14
|
+
*/
|
|
15
|
+
export type TriggerReservedVariableResponseType = ClosedEnum<typeof TriggerReservedVariableResponseType>;
|
|
16
|
+
export type TriggerReservedVariableResponse = {
|
|
17
|
+
/**
|
|
18
|
+
* The type of the reserved variable
|
|
19
|
+
*/
|
|
20
|
+
type: TriggerReservedVariableResponseType;
|
|
21
|
+
/**
|
|
22
|
+
* The reserved variables of the trigger
|
|
23
|
+
*/
|
|
24
|
+
variables: Array<string>;
|
|
25
|
+
};
|
|
26
|
+
/** @internal */
|
|
27
|
+
export declare const TriggerReservedVariableResponseType$inboundSchema: z.ZodNativeEnum<typeof TriggerReservedVariableResponseType>;
|
|
28
|
+
/** @internal */
|
|
29
|
+
export declare const TriggerReservedVariableResponseType$outboundSchema: z.ZodNativeEnum<typeof TriggerReservedVariableResponseType>;
|
|
30
|
+
/**
|
|
31
|
+
* @internal
|
|
32
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
33
|
+
*/
|
|
34
|
+
export declare namespace TriggerReservedVariableResponseType$ {
|
|
35
|
+
/** @deprecated use `TriggerReservedVariableResponseType$inboundSchema` instead. */
|
|
36
|
+
const inboundSchema: z.ZodNativeEnum<{
|
|
37
|
+
readonly Tenant: "tenant";
|
|
38
|
+
readonly Actor: "actor";
|
|
39
|
+
}>;
|
|
40
|
+
/** @deprecated use `TriggerReservedVariableResponseType$outboundSchema` instead. */
|
|
41
|
+
const outboundSchema: z.ZodNativeEnum<{
|
|
42
|
+
readonly Tenant: "tenant";
|
|
43
|
+
readonly Actor: "actor";
|
|
44
|
+
}>;
|
|
45
|
+
}
|
|
46
|
+
/** @internal */
|
|
47
|
+
export declare const TriggerReservedVariableResponse$inboundSchema: z.ZodType<TriggerReservedVariableResponse, z.ZodTypeDef, unknown>;
|
|
48
|
+
/** @internal */
|
|
49
|
+
export type TriggerReservedVariableResponse$Outbound = {
|
|
50
|
+
type: string;
|
|
51
|
+
variables: Array<string>;
|
|
52
|
+
};
|
|
53
|
+
/** @internal */
|
|
54
|
+
export declare const TriggerReservedVariableResponse$outboundSchema: z.ZodType<TriggerReservedVariableResponse$Outbound, z.ZodTypeDef, TriggerReservedVariableResponse>;
|
|
55
|
+
/**
|
|
56
|
+
* @internal
|
|
57
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
58
|
+
*/
|
|
59
|
+
export declare namespace TriggerReservedVariableResponse$ {
|
|
60
|
+
/** @deprecated use `TriggerReservedVariableResponse$inboundSchema` instead. */
|
|
61
|
+
const inboundSchema: z.ZodType<TriggerReservedVariableResponse, z.ZodTypeDef, unknown>;
|
|
62
|
+
/** @deprecated use `TriggerReservedVariableResponse$outboundSchema` instead. */
|
|
63
|
+
const outboundSchema: z.ZodType<TriggerReservedVariableResponse$Outbound, z.ZodTypeDef, TriggerReservedVariableResponse>;
|
|
64
|
+
/** @deprecated use `TriggerReservedVariableResponse$Outbound` instead. */
|
|
65
|
+
type Outbound = TriggerReservedVariableResponse$Outbound;
|
|
66
|
+
}
|
|
67
|
+
export declare function triggerReservedVariableResponseToJSON(triggerReservedVariableResponse: TriggerReservedVariableResponse): string;
|
|
68
|
+
export declare function triggerReservedVariableResponseFromJSON(jsonString: string): SafeParseResult<TriggerReservedVariableResponse, SDKValidationError>;
|
|
69
|
+
//# sourceMappingURL=triggerreservedvariableresponse.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"triggerreservedvariableresponse.d.ts","sourceRoot":"","sources":["../../src/models/components/triggerreservedvariableresponse.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAEzB,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAClD,OAAO,EAAE,MAAM,IAAI,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAC9D,OAAO,EAAE,kBAAkB,EAAE,MAAM,iCAAiC,CAAC;AAErE;;GAEG;AACH,eAAO,MAAM,mCAAmC;;;CAGtC,CAAC;AACX;;GAEG;AACH,MAAM,MAAM,mCAAmC,GAAG,UAAU,CAC1D,OAAO,mCAAmC,CAC3C,CAAC;AAEF,MAAM,MAAM,+BAA+B,GAAG;IAC5C;;OAEG;IACH,IAAI,EAAE,mCAAmC,CAAC;IAC1C;;OAEG;IACH,SAAS,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;CAC1B,CAAC;AAEF,gBAAgB;AAChB,eAAO,MAAM,iDAAiD,EAAE,CAAC,CAAC,aAAa,CAC7E,OAAO,mCAAmC,CACS,CAAC;AAEtD,gBAAgB;AAChB,eAAO,MAAM,kDAAkD,EAC7D,CAAC,CAAC,aAAa,CAAC,OAAO,mCAAmC,CACP,CAAC;AAEtD;;;GAGG;AACH,yBAAiB,oCAAoC,CAAC;IACpD,mFAAmF;IAC5E,MAAM,aAAa;;;MACyB,CAAC;IACpD,oFAAoF;IAC7E,MAAM,cAAc;;;MACyB,CAAC;CACtD;AAED,gBAAgB;AAChB,eAAO,MAAM,6CAA6C,EAAE,CAAC,CAAC,OAAO,CACnE,+BAA+B,EAC/B,CAAC,CAAC,UAAU,EACZ,OAAO,CAIP,CAAC;AAEH,gBAAgB;AAChB,MAAM,MAAM,wCAAwC,GAAG;IACrD,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;CAC1B,CAAC;AAEF,gBAAgB;AAChB,eAAO,MAAM,8CAA8C,EAAE,CAAC,CAAC,OAAO,CACpE,wCAAwC,EACxC,CAAC,CAAC,UAAU,EACZ,+BAA+B,CAI/B,CAAC;AAEH;;;GAGG;AACH,yBAAiB,gCAAgC,CAAC;IAChD,+EAA+E;IACxE,MAAM,aAAa,mEAAgD,CAAC;IAC3E,gFAAgF;IACzE,MAAM,cAAc,oGAAiD,CAAC;IAC7E,0EAA0E;IAC1E,KAAY,QAAQ,GAAG,wCAAwC,CAAC;CACjE;AAED,wBAAgB,qCAAqC,CACnD,+BAA+B,EAAE,+BAA+B,GAC/D,MAAM,CAMR;AAED,wBAAgB,uCAAuC,CACrD,UAAU,EAAE,MAAM,GACjB,eAAe,CAAC,+BAA+B,EAAE,kBAAkB,CAAC,CAMtE"}
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/*
|
|
3
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
4
|
+
*/
|
|
5
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
6
|
+
if (k2 === undefined) k2 = k;
|
|
7
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
8
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
9
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
10
|
+
}
|
|
11
|
+
Object.defineProperty(o, k2, desc);
|
|
12
|
+
}) : (function(o, m, k, k2) {
|
|
13
|
+
if (k2 === undefined) k2 = k;
|
|
14
|
+
o[k2] = m[k];
|
|
15
|
+
}));
|
|
16
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
17
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
18
|
+
}) : function(o, v) {
|
|
19
|
+
o["default"] = v;
|
|
20
|
+
});
|
|
21
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
22
|
+
if (mod && mod.__esModule) return mod;
|
|
23
|
+
var result = {};
|
|
24
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
25
|
+
__setModuleDefault(result, mod);
|
|
26
|
+
return result;
|
|
27
|
+
};
|
|
28
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
|
+
exports.triggerReservedVariableResponseFromJSON = exports.triggerReservedVariableResponseToJSON = exports.TriggerReservedVariableResponse$ = exports.TriggerReservedVariableResponse$outboundSchema = exports.TriggerReservedVariableResponse$inboundSchema = exports.TriggerReservedVariableResponseType$ = exports.TriggerReservedVariableResponseType$outboundSchema = exports.TriggerReservedVariableResponseType$inboundSchema = exports.TriggerReservedVariableResponseType = void 0;
|
|
30
|
+
const z = __importStar(require("zod"));
|
|
31
|
+
const schemas_js_1 = require("../../lib/schemas.js");
|
|
32
|
+
/**
|
|
33
|
+
* The type of the reserved variable
|
|
34
|
+
*/
|
|
35
|
+
exports.TriggerReservedVariableResponseType = {
|
|
36
|
+
Tenant: "tenant",
|
|
37
|
+
Actor: "actor",
|
|
38
|
+
};
|
|
39
|
+
/** @internal */
|
|
40
|
+
exports.TriggerReservedVariableResponseType$inboundSchema = z.nativeEnum(exports.TriggerReservedVariableResponseType);
|
|
41
|
+
/** @internal */
|
|
42
|
+
exports.TriggerReservedVariableResponseType$outboundSchema = exports.TriggerReservedVariableResponseType$inboundSchema;
|
|
43
|
+
/**
|
|
44
|
+
* @internal
|
|
45
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
46
|
+
*/
|
|
47
|
+
var TriggerReservedVariableResponseType$;
|
|
48
|
+
(function (TriggerReservedVariableResponseType$) {
|
|
49
|
+
/** @deprecated use `TriggerReservedVariableResponseType$inboundSchema` instead. */
|
|
50
|
+
TriggerReservedVariableResponseType$.inboundSchema = exports.TriggerReservedVariableResponseType$inboundSchema;
|
|
51
|
+
/** @deprecated use `TriggerReservedVariableResponseType$outboundSchema` instead. */
|
|
52
|
+
TriggerReservedVariableResponseType$.outboundSchema = exports.TriggerReservedVariableResponseType$outboundSchema;
|
|
53
|
+
})(TriggerReservedVariableResponseType$ || (exports.TriggerReservedVariableResponseType$ = TriggerReservedVariableResponseType$ = {}));
|
|
54
|
+
/** @internal */
|
|
55
|
+
exports.TriggerReservedVariableResponse$inboundSchema = z.object({
|
|
56
|
+
type: exports.TriggerReservedVariableResponseType$inboundSchema,
|
|
57
|
+
variables: z.array(z.string()),
|
|
58
|
+
});
|
|
59
|
+
/** @internal */
|
|
60
|
+
exports.TriggerReservedVariableResponse$outboundSchema = z.object({
|
|
61
|
+
type: exports.TriggerReservedVariableResponseType$outboundSchema,
|
|
62
|
+
variables: z.array(z.string()),
|
|
63
|
+
});
|
|
64
|
+
/**
|
|
65
|
+
* @internal
|
|
66
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
67
|
+
*/
|
|
68
|
+
var TriggerReservedVariableResponse$;
|
|
69
|
+
(function (TriggerReservedVariableResponse$) {
|
|
70
|
+
/** @deprecated use `TriggerReservedVariableResponse$inboundSchema` instead. */
|
|
71
|
+
TriggerReservedVariableResponse$.inboundSchema = exports.TriggerReservedVariableResponse$inboundSchema;
|
|
72
|
+
/** @deprecated use `TriggerReservedVariableResponse$outboundSchema` instead. */
|
|
73
|
+
TriggerReservedVariableResponse$.outboundSchema = exports.TriggerReservedVariableResponse$outboundSchema;
|
|
74
|
+
})(TriggerReservedVariableResponse$ || (exports.TriggerReservedVariableResponse$ = TriggerReservedVariableResponse$ = {}));
|
|
75
|
+
function triggerReservedVariableResponseToJSON(triggerReservedVariableResponse) {
|
|
76
|
+
return JSON.stringify(exports.TriggerReservedVariableResponse$outboundSchema.parse(triggerReservedVariableResponse));
|
|
77
|
+
}
|
|
78
|
+
exports.triggerReservedVariableResponseToJSON = triggerReservedVariableResponseToJSON;
|
|
79
|
+
function triggerReservedVariableResponseFromJSON(jsonString) {
|
|
80
|
+
return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.TriggerReservedVariableResponse$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TriggerReservedVariableResponse' from JSON`);
|
|
81
|
+
}
|
|
82
|
+
exports.triggerReservedVariableResponseFromJSON = triggerReservedVariableResponseFromJSON;
|
|
83
|
+
//# sourceMappingURL=triggerreservedvariableresponse.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"triggerreservedvariableresponse.js","sourceRoot":"","sources":["../../src/models/components/triggerreservedvariableresponse.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;;AAEH,uCAAyB;AACzB,qDAAiD;AAKjD;;GAEG;AACU,QAAA,mCAAmC,GAAG;IACjD,MAAM,EAAE,QAAQ;IAChB,KAAK,EAAE,OAAO;CACN,CAAC;AAmBX,gBAAgB;AACH,QAAA,iDAAiD,GAE1D,CAAC,CAAC,UAAU,CAAC,2CAAmC,CAAC,CAAC;AAEtD,gBAAgB;AACH,QAAA,kDAAkD,GAE3D,yDAAiD,CAAC;AAEtD;;;GAGG;AACH,IAAiB,oCAAoC,CAOpD;AAPD,WAAiB,oCAAoC;IACnD,mFAAmF;IACtE,kDAAa,GACxB,yDAAiD,CAAC;IACpD,oFAAoF;IACvE,mDAAc,GACzB,0DAAkD,CAAC;AACvD,CAAC,EAPgB,oCAAoC,oDAApC,oCAAoC,QAOpD;AAED,gBAAgB;AACH,QAAA,6CAA6C,GAItD,CAAC,CAAC,MAAM,CAAC;IACX,IAAI,EAAE,yDAAiD;IACvD,SAAS,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC;CAC/B,CAAC,CAAC;AAQH,gBAAgB;AACH,QAAA,8CAA8C,GAIvD,CAAC,CAAC,MAAM,CAAC;IACX,IAAI,EAAE,0DAAkD;IACxD,SAAS,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC;CAC/B,CAAC,CAAC;AAEH;;;GAGG;AACH,IAAiB,gCAAgC,CAOhD;AAPD,WAAiB,gCAAgC;IAC/C,+EAA+E;IAClE,8CAAa,GAAG,qDAA6C,CAAC;IAC3E,gFAAgF;IACnE,+CAAc,GAAG,sDAA8C,CAAC;AAG/E,CAAC,EAPgB,gCAAgC,gDAAhC,gCAAgC,QAOhD;AAED,SAAgB,qCAAqC,CACnD,+BAAgE;IAEhE,OAAO,IAAI,CAAC,SAAS,CACnB,sDAA8C,CAAC,KAAK,CAClD,+BAA+B,CAChC,CACF,CAAC;AACJ,CAAC;AARD,sFAQC;AAED,SAAgB,uCAAuC,CACrD,UAAkB;IAElB,OAAO,IAAA,sBAAS,EACd,UAAU,EACV,CAAC,CAAC,EAAE,EAAE,CAAC,qDAA6C,CAAC,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,EACzE,6DAA6D,CAC9D,CAAC;AACJ,CAAC;AARD,0FAQC"}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import * as z from "zod";
|
|
2
|
+
import { ClosedEnum } from "../../types/enums.js";
|
|
3
|
+
/**
|
|
4
|
+
* The type of the trigger
|
|
5
|
+
*/
|
|
6
|
+
export declare const TriggerTypeEnum: {
|
|
7
|
+
readonly Event: "event";
|
|
8
|
+
};
|
|
9
|
+
/**
|
|
10
|
+
* The type of the trigger
|
|
11
|
+
*/
|
|
12
|
+
export type TriggerTypeEnum = ClosedEnum<typeof TriggerTypeEnum>;
|
|
13
|
+
/** @internal */
|
|
14
|
+
export declare const TriggerTypeEnum$inboundSchema: z.ZodNativeEnum<typeof TriggerTypeEnum>;
|
|
15
|
+
/** @internal */
|
|
16
|
+
export declare const TriggerTypeEnum$outboundSchema: z.ZodNativeEnum<typeof TriggerTypeEnum>;
|
|
17
|
+
/**
|
|
18
|
+
* @internal
|
|
19
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
20
|
+
*/
|
|
21
|
+
export declare namespace TriggerTypeEnum$ {
|
|
22
|
+
/** @deprecated use `TriggerTypeEnum$inboundSchema` instead. */
|
|
23
|
+
const inboundSchema: z.ZodNativeEnum<{
|
|
24
|
+
readonly Event: "event";
|
|
25
|
+
}>;
|
|
26
|
+
/** @deprecated use `TriggerTypeEnum$outboundSchema` instead. */
|
|
27
|
+
const outboundSchema: z.ZodNativeEnum<{
|
|
28
|
+
readonly Event: "event";
|
|
29
|
+
}>;
|
|
30
|
+
}
|
|
31
|
+
//# sourceMappingURL=triggertypeenum.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"triggertypeenum.d.ts","sourceRoot":"","sources":["../../src/models/components/triggertypeenum.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AACzB,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAElD;;GAEG;AACH,eAAO,MAAM,eAAe;;CAElB,CAAC;AACX;;GAEG;AACH,MAAM,MAAM,eAAe,GAAG,UAAU,CAAC,OAAO,eAAe,CAAC,CAAC;AAEjE,gBAAgB;AAChB,eAAO,MAAM,6BAA6B,EAAE,CAAC,CAAC,aAAa,CACzD,OAAO,eAAe,CACS,CAAC;AAElC,gBAAgB;AAChB,eAAO,MAAM,8BAA8B,EAAE,CAAC,CAAC,aAAa,CAC1D,OAAO,eAAe,CACS,CAAC;AAElC;;;GAGG;AACH,yBAAiB,gBAAgB,CAAC;IAChC,+DAA+D;IACxD,MAAM,aAAa;;MAAgC,CAAC;IAC3D,gEAAgE;IACzD,MAAM,cAAc;;MAAiC,CAAC;CAC9D"}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/*
|
|
3
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
4
|
+
*/
|
|
5
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
6
|
+
if (k2 === undefined) k2 = k;
|
|
7
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
8
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
9
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
10
|
+
}
|
|
11
|
+
Object.defineProperty(o, k2, desc);
|
|
12
|
+
}) : (function(o, m, k, k2) {
|
|
13
|
+
if (k2 === undefined) k2 = k;
|
|
14
|
+
o[k2] = m[k];
|
|
15
|
+
}));
|
|
16
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
17
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
18
|
+
}) : function(o, v) {
|
|
19
|
+
o["default"] = v;
|
|
20
|
+
});
|
|
21
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
22
|
+
if (mod && mod.__esModule) return mod;
|
|
23
|
+
var result = {};
|
|
24
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
25
|
+
__setModuleDefault(result, mod);
|
|
26
|
+
return result;
|
|
27
|
+
};
|
|
28
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
|
+
exports.TriggerTypeEnum$ = exports.TriggerTypeEnum$outboundSchema = exports.TriggerTypeEnum$inboundSchema = exports.TriggerTypeEnum = void 0;
|
|
30
|
+
const z = __importStar(require("zod"));
|
|
31
|
+
/**
|
|
32
|
+
* The type of the trigger
|
|
33
|
+
*/
|
|
34
|
+
exports.TriggerTypeEnum = {
|
|
35
|
+
Event: "event",
|
|
36
|
+
};
|
|
37
|
+
/** @internal */
|
|
38
|
+
exports.TriggerTypeEnum$inboundSchema = z.nativeEnum(exports.TriggerTypeEnum);
|
|
39
|
+
/** @internal */
|
|
40
|
+
exports.TriggerTypeEnum$outboundSchema = exports.TriggerTypeEnum$inboundSchema;
|
|
41
|
+
/**
|
|
42
|
+
* @internal
|
|
43
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
44
|
+
*/
|
|
45
|
+
var TriggerTypeEnum$;
|
|
46
|
+
(function (TriggerTypeEnum$) {
|
|
47
|
+
/** @deprecated use `TriggerTypeEnum$inboundSchema` instead. */
|
|
48
|
+
TriggerTypeEnum$.inboundSchema = exports.TriggerTypeEnum$inboundSchema;
|
|
49
|
+
/** @deprecated use `TriggerTypeEnum$outboundSchema` instead. */
|
|
50
|
+
TriggerTypeEnum$.outboundSchema = exports.TriggerTypeEnum$outboundSchema;
|
|
51
|
+
})(TriggerTypeEnum$ || (exports.TriggerTypeEnum$ = TriggerTypeEnum$ = {}));
|
|
52
|
+
//# sourceMappingURL=triggertypeenum.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"triggertypeenum.js","sourceRoot":"","sources":["../../src/models/components/triggertypeenum.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;;AAEH,uCAAyB;AAGzB;;GAEG;AACU,QAAA,eAAe,GAAG;IAC7B,KAAK,EAAE,OAAO;CACN,CAAC;AAMX,gBAAgB;AACH,QAAA,6BAA6B,GAEtC,CAAC,CAAC,UAAU,CAAC,uBAAe,CAAC,CAAC;AAElC,gBAAgB;AACH,QAAA,8BAA8B,GAEvC,qCAA6B,CAAC;AAElC;;;GAGG;AACH,IAAiB,gBAAgB,CAKhC;AALD,WAAiB,gBAAgB;IAC/B,+DAA+D;IAClD,8BAAa,GAAG,qCAA6B,CAAC;IAC3D,gEAAgE;IACnD,+BAAc,GAAG,sCAA8B,CAAC;AAC/D,CAAC,EALgB,gBAAgB,gCAAhB,gBAAgB,QAKhC"}
|
package/package.json
CHANGED
|
@@ -148,9 +148,9 @@ export async function topicsDelete(
|
|
|
148
148
|
operations.TopicsControllerDeleteTopicResponse$inboundSchema.optional(),
|
|
149
149
|
{ hdrs: true },
|
|
150
150
|
),
|
|
151
|
-
M.jsonErr([400, 404], errors.ErrorDto$inboundSchema, { hdrs: true }),
|
|
152
|
-
M.fail([409, 429, 503]),
|
|
151
|
+
M.jsonErr([400, 404, 409], errors.ErrorDto$inboundSchema, { hdrs: true }),
|
|
153
152
|
M.jsonErr(422, errors.ValidationErrorDto$inboundSchema, { hdrs: true }),
|
|
153
|
+
M.fail([429, 503]),
|
|
154
154
|
M.fail(["4XX", "5XX"]),
|
|
155
155
|
)(response, { extraFields: responseFields });
|
|
156
156
|
if (!result.ok) {
|
package/src/lib/config.ts
CHANGED
|
@@ -55,7 +55,7 @@ export function serverURLFromOptions(options: SDKOptions): URL | null {
|
|
|
55
55
|
export const SDK_METADATA = {
|
|
56
56
|
language: "typescript",
|
|
57
57
|
openapiDocVersion: "1.0",
|
|
58
|
-
sdkVersion: "0.0.1-alpha.
|
|
58
|
+
sdkVersion: "0.0.1-alpha.141",
|
|
59
59
|
genVersion: "2.481.0",
|
|
60
|
-
userAgent: "speakeasy-sdk/typescript 0.0.1-alpha.
|
|
60
|
+
userAgent: "speakeasy-sdk/typescript 0.0.1-alpha.141 2.481.0 1.0 @novu/api",
|
|
61
61
|
} as const;
|
|
@@ -62,7 +62,9 @@ export * from "./notificationgroup.js";
|
|
|
62
62
|
export * from "./notificationstep.js";
|
|
63
63
|
export * from "./notificationstepvariant.js";
|
|
64
64
|
export * from "./notificationtrigger.js";
|
|
65
|
+
export * from "./notificationtriggerresponse.js";
|
|
65
66
|
export * from "./notificationtriggervariable.js";
|
|
67
|
+
export * from "./notificationtriggervariableresponse.js";
|
|
66
68
|
export * from "./preference.js";
|
|
67
69
|
export * from "./preferencechannels.js";
|
|
68
70
|
export * from "./providersidenum.js";
|
|
@@ -86,6 +88,8 @@ export * from "./triggereventrequestdto.js";
|
|
|
86
88
|
export * from "./triggereventresponsedto.js";
|
|
87
89
|
export * from "./triggereventtoallrequestdto.js";
|
|
88
90
|
export * from "./triggerrecipientstypeenum.js";
|
|
91
|
+
export * from "./triggerreservedvariableresponse.js";
|
|
92
|
+
export * from "./triggertypeenum.js";
|
|
89
93
|
export * from "./unseencountresponse.js";
|
|
90
94
|
export * from "./updatedsubscriberdto.js";
|
|
91
95
|
export * from "./updateintegrationrequestdto.js";
|
|
@@ -0,0 +1,126 @@
|
|
|
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 { Result as SafeParseResult } from "../../types/fp.js";
|
|
8
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
9
|
+
import {
|
|
10
|
+
NotificationTriggerVariableResponse,
|
|
11
|
+
NotificationTriggerVariableResponse$inboundSchema,
|
|
12
|
+
NotificationTriggerVariableResponse$Outbound,
|
|
13
|
+
NotificationTriggerVariableResponse$outboundSchema,
|
|
14
|
+
} from "./notificationtriggervariableresponse.js";
|
|
15
|
+
import {
|
|
16
|
+
TriggerReservedVariableResponse,
|
|
17
|
+
TriggerReservedVariableResponse$inboundSchema,
|
|
18
|
+
TriggerReservedVariableResponse$Outbound,
|
|
19
|
+
TriggerReservedVariableResponse$outboundSchema,
|
|
20
|
+
} from "./triggerreservedvariableresponse.js";
|
|
21
|
+
import {
|
|
22
|
+
TriggerTypeEnum,
|
|
23
|
+
TriggerTypeEnum$inboundSchema,
|
|
24
|
+
TriggerTypeEnum$outboundSchema,
|
|
25
|
+
} from "./triggertypeenum.js";
|
|
26
|
+
|
|
27
|
+
export type NotificationTriggerResponse = {
|
|
28
|
+
/**
|
|
29
|
+
* The type of the trigger
|
|
30
|
+
*/
|
|
31
|
+
type: TriggerTypeEnum;
|
|
32
|
+
/**
|
|
33
|
+
* The identifier of the trigger
|
|
34
|
+
*/
|
|
35
|
+
identifier: string;
|
|
36
|
+
/**
|
|
37
|
+
* The variables of the trigger
|
|
38
|
+
*/
|
|
39
|
+
variables: Array<NotificationTriggerVariableResponse>;
|
|
40
|
+
/**
|
|
41
|
+
* The subscriber variables of the trigger
|
|
42
|
+
*/
|
|
43
|
+
subscriberVariables?: Array<NotificationTriggerVariableResponse> | undefined;
|
|
44
|
+
/**
|
|
45
|
+
* The reserved variables of the trigger
|
|
46
|
+
*/
|
|
47
|
+
reservedVariables?: Array<TriggerReservedVariableResponse> | undefined;
|
|
48
|
+
};
|
|
49
|
+
|
|
50
|
+
/** @internal */
|
|
51
|
+
export const NotificationTriggerResponse$inboundSchema: z.ZodType<
|
|
52
|
+
NotificationTriggerResponse,
|
|
53
|
+
z.ZodTypeDef,
|
|
54
|
+
unknown
|
|
55
|
+
> = z.object({
|
|
56
|
+
type: TriggerTypeEnum$inboundSchema,
|
|
57
|
+
identifier: z.string(),
|
|
58
|
+
variables: z.array(NotificationTriggerVariableResponse$inboundSchema),
|
|
59
|
+
subscriberVariables: z.array(
|
|
60
|
+
NotificationTriggerVariableResponse$inboundSchema,
|
|
61
|
+
).optional(),
|
|
62
|
+
reservedVariables: z.array(TriggerReservedVariableResponse$inboundSchema)
|
|
63
|
+
.optional(),
|
|
64
|
+
});
|
|
65
|
+
|
|
66
|
+
/** @internal */
|
|
67
|
+
export type NotificationTriggerResponse$Outbound = {
|
|
68
|
+
type: string;
|
|
69
|
+
identifier: string;
|
|
70
|
+
variables: Array<NotificationTriggerVariableResponse$Outbound>;
|
|
71
|
+
subscriberVariables?:
|
|
72
|
+
| Array<NotificationTriggerVariableResponse$Outbound>
|
|
73
|
+
| undefined;
|
|
74
|
+
reservedVariables?:
|
|
75
|
+
| Array<TriggerReservedVariableResponse$Outbound>
|
|
76
|
+
| undefined;
|
|
77
|
+
};
|
|
78
|
+
|
|
79
|
+
/** @internal */
|
|
80
|
+
export const NotificationTriggerResponse$outboundSchema: z.ZodType<
|
|
81
|
+
NotificationTriggerResponse$Outbound,
|
|
82
|
+
z.ZodTypeDef,
|
|
83
|
+
NotificationTriggerResponse
|
|
84
|
+
> = z.object({
|
|
85
|
+
type: TriggerTypeEnum$outboundSchema,
|
|
86
|
+
identifier: z.string(),
|
|
87
|
+
variables: z.array(NotificationTriggerVariableResponse$outboundSchema),
|
|
88
|
+
subscriberVariables: z.array(
|
|
89
|
+
NotificationTriggerVariableResponse$outboundSchema,
|
|
90
|
+
).optional(),
|
|
91
|
+
reservedVariables: z.array(TriggerReservedVariableResponse$outboundSchema)
|
|
92
|
+
.optional(),
|
|
93
|
+
});
|
|
94
|
+
|
|
95
|
+
/**
|
|
96
|
+
* @internal
|
|
97
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
98
|
+
*/
|
|
99
|
+
export namespace NotificationTriggerResponse$ {
|
|
100
|
+
/** @deprecated use `NotificationTriggerResponse$inboundSchema` instead. */
|
|
101
|
+
export const inboundSchema = NotificationTriggerResponse$inboundSchema;
|
|
102
|
+
/** @deprecated use `NotificationTriggerResponse$outboundSchema` instead. */
|
|
103
|
+
export const outboundSchema = NotificationTriggerResponse$outboundSchema;
|
|
104
|
+
/** @deprecated use `NotificationTriggerResponse$Outbound` instead. */
|
|
105
|
+
export type Outbound = NotificationTriggerResponse$Outbound;
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
export function notificationTriggerResponseToJSON(
|
|
109
|
+
notificationTriggerResponse: NotificationTriggerResponse,
|
|
110
|
+
): string {
|
|
111
|
+
return JSON.stringify(
|
|
112
|
+
NotificationTriggerResponse$outboundSchema.parse(
|
|
113
|
+
notificationTriggerResponse,
|
|
114
|
+
),
|
|
115
|
+
);
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
export function notificationTriggerResponseFromJSON(
|
|
119
|
+
jsonString: string,
|
|
120
|
+
): SafeParseResult<NotificationTriggerResponse, SDKValidationError> {
|
|
121
|
+
return safeParse(
|
|
122
|
+
jsonString,
|
|
123
|
+
(x) => NotificationTriggerResponse$inboundSchema.parse(JSON.parse(x)),
|
|
124
|
+
`Failed to parse 'NotificationTriggerResponse' from JSON`,
|
|
125
|
+
);
|
|
126
|
+
}
|
|
@@ -0,0 +1,173 @@
|
|
|
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 value of the variable
|
|
13
|
+
*/
|
|
14
|
+
export type Value = {};
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* The type of the variable
|
|
18
|
+
*/
|
|
19
|
+
export const NotificationTriggerVariableResponseType = {
|
|
20
|
+
String: "String",
|
|
21
|
+
Array: "Array",
|
|
22
|
+
Boolean: "Boolean",
|
|
23
|
+
} as const;
|
|
24
|
+
/**
|
|
25
|
+
* The type of the variable
|
|
26
|
+
*/
|
|
27
|
+
export type NotificationTriggerVariableResponseType = ClosedEnum<
|
|
28
|
+
typeof NotificationTriggerVariableResponseType
|
|
29
|
+
>;
|
|
30
|
+
|
|
31
|
+
export type NotificationTriggerVariableResponse = {
|
|
32
|
+
/**
|
|
33
|
+
* The name of the variable
|
|
34
|
+
*/
|
|
35
|
+
name: string;
|
|
36
|
+
/**
|
|
37
|
+
* The value of the variable
|
|
38
|
+
*/
|
|
39
|
+
value?: Value | undefined;
|
|
40
|
+
/**
|
|
41
|
+
* The type of the variable
|
|
42
|
+
*/
|
|
43
|
+
type?: NotificationTriggerVariableResponseType | undefined;
|
|
44
|
+
};
|
|
45
|
+
|
|
46
|
+
/** @internal */
|
|
47
|
+
export const Value$inboundSchema: z.ZodType<Value, z.ZodTypeDef, unknown> = z
|
|
48
|
+
.object({});
|
|
49
|
+
|
|
50
|
+
/** @internal */
|
|
51
|
+
export type Value$Outbound = {};
|
|
52
|
+
|
|
53
|
+
/** @internal */
|
|
54
|
+
export const Value$outboundSchema: z.ZodType<
|
|
55
|
+
Value$Outbound,
|
|
56
|
+
z.ZodTypeDef,
|
|
57
|
+
Value
|
|
58
|
+
> = z.object({});
|
|
59
|
+
|
|
60
|
+
/**
|
|
61
|
+
* @internal
|
|
62
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
63
|
+
*/
|
|
64
|
+
export namespace Value$ {
|
|
65
|
+
/** @deprecated use `Value$inboundSchema` instead. */
|
|
66
|
+
export const inboundSchema = Value$inboundSchema;
|
|
67
|
+
/** @deprecated use `Value$outboundSchema` instead. */
|
|
68
|
+
export const outboundSchema = Value$outboundSchema;
|
|
69
|
+
/** @deprecated use `Value$Outbound` instead. */
|
|
70
|
+
export type Outbound = Value$Outbound;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
export function valueToJSON(value: Value): string {
|
|
74
|
+
return JSON.stringify(Value$outboundSchema.parse(value));
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
export function valueFromJSON(
|
|
78
|
+
jsonString: string,
|
|
79
|
+
): SafeParseResult<Value, SDKValidationError> {
|
|
80
|
+
return safeParse(
|
|
81
|
+
jsonString,
|
|
82
|
+
(x) => Value$inboundSchema.parse(JSON.parse(x)),
|
|
83
|
+
`Failed to parse 'Value' from JSON`,
|
|
84
|
+
);
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
/** @internal */
|
|
88
|
+
export const NotificationTriggerVariableResponseType$inboundSchema:
|
|
89
|
+
z.ZodNativeEnum<typeof NotificationTriggerVariableResponseType> = z
|
|
90
|
+
.nativeEnum(NotificationTriggerVariableResponseType);
|
|
91
|
+
|
|
92
|
+
/** @internal */
|
|
93
|
+
export const NotificationTriggerVariableResponseType$outboundSchema:
|
|
94
|
+
z.ZodNativeEnum<typeof NotificationTriggerVariableResponseType> =
|
|
95
|
+
NotificationTriggerVariableResponseType$inboundSchema;
|
|
96
|
+
|
|
97
|
+
/**
|
|
98
|
+
* @internal
|
|
99
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
100
|
+
*/
|
|
101
|
+
export namespace NotificationTriggerVariableResponseType$ {
|
|
102
|
+
/** @deprecated use `NotificationTriggerVariableResponseType$inboundSchema` instead. */
|
|
103
|
+
export const inboundSchema =
|
|
104
|
+
NotificationTriggerVariableResponseType$inboundSchema;
|
|
105
|
+
/** @deprecated use `NotificationTriggerVariableResponseType$outboundSchema` instead. */
|
|
106
|
+
export const outboundSchema =
|
|
107
|
+
NotificationTriggerVariableResponseType$outboundSchema;
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
/** @internal */
|
|
111
|
+
export const NotificationTriggerVariableResponse$inboundSchema: z.ZodType<
|
|
112
|
+
NotificationTriggerVariableResponse,
|
|
113
|
+
z.ZodTypeDef,
|
|
114
|
+
unknown
|
|
115
|
+
> = z.object({
|
|
116
|
+
name: z.string(),
|
|
117
|
+
value: z.lazy(() => Value$inboundSchema).optional(),
|
|
118
|
+
type: NotificationTriggerVariableResponseType$inboundSchema.optional(),
|
|
119
|
+
});
|
|
120
|
+
|
|
121
|
+
/** @internal */
|
|
122
|
+
export type NotificationTriggerVariableResponse$Outbound = {
|
|
123
|
+
name: string;
|
|
124
|
+
value?: Value$Outbound | undefined;
|
|
125
|
+
type?: string | undefined;
|
|
126
|
+
};
|
|
127
|
+
|
|
128
|
+
/** @internal */
|
|
129
|
+
export const NotificationTriggerVariableResponse$outboundSchema: z.ZodType<
|
|
130
|
+
NotificationTriggerVariableResponse$Outbound,
|
|
131
|
+
z.ZodTypeDef,
|
|
132
|
+
NotificationTriggerVariableResponse
|
|
133
|
+
> = z.object({
|
|
134
|
+
name: z.string(),
|
|
135
|
+
value: z.lazy(() => Value$outboundSchema).optional(),
|
|
136
|
+
type: NotificationTriggerVariableResponseType$outboundSchema.optional(),
|
|
137
|
+
});
|
|
138
|
+
|
|
139
|
+
/**
|
|
140
|
+
* @internal
|
|
141
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
142
|
+
*/
|
|
143
|
+
export namespace NotificationTriggerVariableResponse$ {
|
|
144
|
+
/** @deprecated use `NotificationTriggerVariableResponse$inboundSchema` instead. */
|
|
145
|
+
export const inboundSchema =
|
|
146
|
+
NotificationTriggerVariableResponse$inboundSchema;
|
|
147
|
+
/** @deprecated use `NotificationTriggerVariableResponse$outboundSchema` instead. */
|
|
148
|
+
export const outboundSchema =
|
|
149
|
+
NotificationTriggerVariableResponse$outboundSchema;
|
|
150
|
+
/** @deprecated use `NotificationTriggerVariableResponse$Outbound` instead. */
|
|
151
|
+
export type Outbound = NotificationTriggerVariableResponse$Outbound;
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
export function notificationTriggerVariableResponseToJSON(
|
|
155
|
+
notificationTriggerVariableResponse: NotificationTriggerVariableResponse,
|
|
156
|
+
): string {
|
|
157
|
+
return JSON.stringify(
|
|
158
|
+
NotificationTriggerVariableResponse$outboundSchema.parse(
|
|
159
|
+
notificationTriggerVariableResponse,
|
|
160
|
+
),
|
|
161
|
+
);
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
export function notificationTriggerVariableResponseFromJSON(
|
|
165
|
+
jsonString: string,
|
|
166
|
+
): SafeParseResult<NotificationTriggerVariableResponse, SDKValidationError> {
|
|
167
|
+
return safeParse(
|
|
168
|
+
jsonString,
|
|
169
|
+
(x) =>
|
|
170
|
+
NotificationTriggerVariableResponse$inboundSchema.parse(JSON.parse(x)),
|
|
171
|
+
`Failed to parse 'NotificationTriggerVariableResponse' from JSON`,
|
|
172
|
+
);
|
|
173
|
+
}
|
|
@@ -7,6 +7,12 @@ import { remap as remap$ } from "../../lib/primitives.js";
|
|
|
7
7
|
import { safeParse } from "../../lib/schemas.js";
|
|
8
8
|
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
9
9
|
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
10
|
+
import {
|
|
11
|
+
NotificationTriggerResponse,
|
|
12
|
+
NotificationTriggerResponse$inboundSchema,
|
|
13
|
+
NotificationTriggerResponse$Outbound,
|
|
14
|
+
NotificationTriggerResponse$outboundSchema,
|
|
15
|
+
} from "./notificationtriggerresponse.js";
|
|
10
16
|
|
|
11
17
|
export type TemplateResponse = {
|
|
12
18
|
/**
|
|
@@ -24,7 +30,7 @@ export type TemplateResponse = {
|
|
|
24
30
|
/**
|
|
25
31
|
* Triggers are the events that will trigger the workflow.
|
|
26
32
|
*/
|
|
27
|
-
triggers: Array<
|
|
33
|
+
triggers: Array<NotificationTriggerResponse>;
|
|
28
34
|
};
|
|
29
35
|
|
|
30
36
|
/** @internal */
|
|
@@ -36,7 +42,7 @@ export const TemplateResponse$inboundSchema: z.ZodType<
|
|
|
36
42
|
_id: z.string(),
|
|
37
43
|
name: z.string(),
|
|
38
44
|
critical: z.boolean(),
|
|
39
|
-
triggers: z.array(
|
|
45
|
+
triggers: z.array(NotificationTriggerResponse$inboundSchema),
|
|
40
46
|
}).transform((v) => {
|
|
41
47
|
return remap$(v, {
|
|
42
48
|
"_id": "id",
|
|
@@ -48,7 +54,7 @@ export type TemplateResponse$Outbound = {
|
|
|
48
54
|
_id: string;
|
|
49
55
|
name: string;
|
|
50
56
|
critical: boolean;
|
|
51
|
-
triggers: Array<
|
|
57
|
+
triggers: Array<NotificationTriggerResponse$Outbound>;
|
|
52
58
|
};
|
|
53
59
|
|
|
54
60
|
/** @internal */
|
|
@@ -60,7 +66,7 @@ export const TemplateResponse$outboundSchema: z.ZodType<
|
|
|
60
66
|
id: z.string(),
|
|
61
67
|
name: z.string(),
|
|
62
68
|
critical: z.boolean(),
|
|
63
|
-
triggers: z.array(
|
|
69
|
+
triggers: z.array(NotificationTriggerResponse$outboundSchema),
|
|
64
70
|
}).transform((v) => {
|
|
65
71
|
return remap$(v, {
|
|
66
72
|
id: "_id",
|