@novu/api 0.0.1-alpha.107 → 0.0.1-alpha.109
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/lib/config.d.ts +2 -2
- package/lib/config.js +2 -2
- package/models/errors/validationerrordto.d.ts +20 -46
- package/models/errors/validationerrordto.d.ts.map +1 -1
- package/models/errors/validationerrordto.js +9 -57
- package/models/errors/validationerrordto.js.map +1 -1
- package/package.json +1 -1
- package/src/lib/config.ts +2 -2
- package/src/models/errors/validationerrordto.ts +25 -94
package/lib/config.d.ts
CHANGED
|
@@ -27,8 +27,8 @@ export declare function serverURLFromOptions(options: SDKOptions): URL | null;
|
|
|
27
27
|
export declare const SDK_METADATA: {
|
|
28
28
|
readonly language: "typescript";
|
|
29
29
|
readonly openapiDocVersion: "1.0";
|
|
30
|
-
readonly sdkVersion: "0.0.1-alpha.
|
|
30
|
+
readonly sdkVersion: "0.0.1-alpha.109";
|
|
31
31
|
readonly genVersion: "2.477.4";
|
|
32
|
-
readonly userAgent: "speakeasy-sdk/typescript 0.0.1-alpha.
|
|
32
|
+
readonly userAgent: "speakeasy-sdk/typescript 0.0.1-alpha.109 2.477.4 1.0 @novu/api";
|
|
33
33
|
};
|
|
34
34
|
//# sourceMappingURL=config.d.ts.map
|
package/lib/config.js
CHANGED
|
@@ -30,8 +30,8 @@ exports.serverURLFromOptions = serverURLFromOptions;
|
|
|
30
30
|
exports.SDK_METADATA = {
|
|
31
31
|
language: "typescript",
|
|
32
32
|
openapiDocVersion: "1.0",
|
|
33
|
-
sdkVersion: "0.0.1-alpha.
|
|
33
|
+
sdkVersion: "0.0.1-alpha.109",
|
|
34
34
|
genVersion: "2.477.4",
|
|
35
|
-
userAgent: "speakeasy-sdk/typescript 0.0.1-alpha.
|
|
35
|
+
userAgent: "speakeasy-sdk/typescript 0.0.1-alpha.109 2.477.4 1.0 @novu/api",
|
|
36
36
|
};
|
|
37
37
|
//# sourceMappingURL=config.js.map
|
|
@@ -1,12 +1,18 @@
|
|
|
1
1
|
import * as z from "zod";
|
|
2
2
|
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
3
3
|
import { SDKValidationError } from "./sdkvalidationerror.js";
|
|
4
|
-
export type
|
|
5
|
-
|
|
6
|
-
|
|
4
|
+
export type Value = string | number | boolean | {
|
|
5
|
+
[k: string]: any;
|
|
6
|
+
} | Array<{
|
|
7
|
+
[k: string]: any;
|
|
8
|
+
}>;
|
|
7
9
|
export type Errors = {
|
|
8
10
|
messages: Array<string>;
|
|
9
|
-
value:
|
|
11
|
+
value: string | number | boolean | {
|
|
12
|
+
[k: string]: any;
|
|
13
|
+
} | Array<{
|
|
14
|
+
[k: string]: any;
|
|
15
|
+
}> | null;
|
|
10
16
|
};
|
|
11
17
|
export type ValidationErrorDtoData = {
|
|
12
18
|
/**
|
|
@@ -82,49 +88,13 @@ export declare class ValidationErrorDto extends Error {
|
|
|
82
88
|
constructor(err: ValidationErrorDtoData);
|
|
83
89
|
}
|
|
84
90
|
/** @internal */
|
|
85
|
-
export declare const Five$inboundSchema: z.ZodType<Five, z.ZodTypeDef, unknown>;
|
|
86
|
-
/** @internal */
|
|
87
|
-
export type Five$Outbound = {};
|
|
88
|
-
/** @internal */
|
|
89
|
-
export declare const Five$outboundSchema: z.ZodType<Five$Outbound, z.ZodTypeDef, Five>;
|
|
90
|
-
/**
|
|
91
|
-
* @internal
|
|
92
|
-
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
93
|
-
*/
|
|
94
|
-
export declare namespace Five$ {
|
|
95
|
-
/** @deprecated use `Five$inboundSchema` instead. */
|
|
96
|
-
const inboundSchema: z.ZodType<Five, z.ZodTypeDef, unknown>;
|
|
97
|
-
/** @deprecated use `Five$outboundSchema` instead. */
|
|
98
|
-
const outboundSchema: z.ZodType<Five$Outbound, z.ZodTypeDef, Five>;
|
|
99
|
-
/** @deprecated use `Five$Outbound` instead. */
|
|
100
|
-
type Outbound = Five$Outbound;
|
|
101
|
-
}
|
|
102
|
-
export declare function fiveToJSON(five: Five): string;
|
|
103
|
-
export declare function fiveFromJSON(jsonString: string): SafeParseResult<Five, SDKValidationError>;
|
|
104
|
-
/** @internal */
|
|
105
|
-
export declare const Four$inboundSchema: z.ZodType<Four, z.ZodTypeDef, unknown>;
|
|
106
|
-
/** @internal */
|
|
107
|
-
export type Four$Outbound = {};
|
|
108
|
-
/** @internal */
|
|
109
|
-
export declare const Four$outboundSchema: z.ZodType<Four$Outbound, z.ZodTypeDef, Four>;
|
|
110
|
-
/**
|
|
111
|
-
* @internal
|
|
112
|
-
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
113
|
-
*/
|
|
114
|
-
export declare namespace Four$ {
|
|
115
|
-
/** @deprecated use `Four$inboundSchema` instead. */
|
|
116
|
-
const inboundSchema: z.ZodType<Four, z.ZodTypeDef, unknown>;
|
|
117
|
-
/** @deprecated use `Four$outboundSchema` instead. */
|
|
118
|
-
const outboundSchema: z.ZodType<Four$Outbound, z.ZodTypeDef, Four>;
|
|
119
|
-
/** @deprecated use `Four$Outbound` instead. */
|
|
120
|
-
type Outbound = Four$Outbound;
|
|
121
|
-
}
|
|
122
|
-
export declare function fourToJSON(four: Four): string;
|
|
123
|
-
export declare function fourFromJSON(jsonString: string): SafeParseResult<Four, SDKValidationError>;
|
|
124
|
-
/** @internal */
|
|
125
91
|
export declare const Value$inboundSchema: z.ZodType<Value, z.ZodTypeDef, unknown>;
|
|
126
92
|
/** @internal */
|
|
127
|
-
export type Value$Outbound =
|
|
93
|
+
export type Value$Outbound = string | number | boolean | {
|
|
94
|
+
[k: string]: any;
|
|
95
|
+
} | Array<{
|
|
96
|
+
[k: string]: any;
|
|
97
|
+
}>;
|
|
128
98
|
/** @internal */
|
|
129
99
|
export declare const Value$outboundSchema: z.ZodType<Value$Outbound, z.ZodTypeDef, Value>;
|
|
130
100
|
/**
|
|
@@ -146,7 +116,11 @@ export declare const Errors$inboundSchema: z.ZodType<Errors, z.ZodTypeDef, unkno
|
|
|
146
116
|
/** @internal */
|
|
147
117
|
export type Errors$Outbound = {
|
|
148
118
|
messages: Array<string>;
|
|
149
|
-
value:
|
|
119
|
+
value: string | number | boolean | {
|
|
120
|
+
[k: string]: any;
|
|
121
|
+
} | Array<{
|
|
122
|
+
[k: string]: any;
|
|
123
|
+
}> | null;
|
|
150
124
|
};
|
|
151
125
|
/** @internal */
|
|
152
126
|
export declare const Errors$outboundSchema: z.ZodType<Errors$Outbound, z.ZodTypeDef, Errors>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"validationerrordto.d.ts","sourceRoot":"","sources":["../../src/models/errors/validationerrordto.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAEzB,OAAO,EAAE,MAAM,IAAI,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAC9D,OAAO,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAC;AAE7D,MAAM,MAAM,
|
|
1
|
+
{"version":3,"file":"validationerrordto.d.ts","sourceRoot":"","sources":["../../src/models/errors/validationerrordto.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAEzB,OAAO,EAAE,MAAM,IAAI,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAC9D,OAAO,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAC;AAE7D,MAAM,MAAM,KAAK,GACb,MAAM,GACN,MAAM,GACN,OAAO,GACP;IAAE,CAAC,CAAC,EAAE,MAAM,GAAG,GAAG,CAAA;CAAE,GACpB,KAAK,CAAC;IAAE,CAAC,CAAC,EAAE,MAAM,GAAG,GAAG,CAAA;CAAE,CAAC,CAAC;AAEhC,MAAM,MAAM,MAAM,GAAG;IACnB,QAAQ,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;IACxB,KAAK,EACD,MAAM,GACN,MAAM,GACN,OAAO,GACP;QAAE,CAAC,CAAC,EAAE,MAAM,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AC;CACpD"}
|
|
@@ -26,7 +26,7 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
26
26
|
return result;
|
|
27
27
|
};
|
|
28
28
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
|
-
exports.ValidationErrorDto$ = exports.ValidationErrorDto$outboundSchema = exports.ValidationErrorDto$inboundSchema = exports.errorsFromJSON = exports.errorsToJSON = exports.Errors$ = exports.Errors$outboundSchema = exports.Errors$inboundSchema = exports.valueFromJSON = exports.valueToJSON = exports.Value$ = exports.Value$outboundSchema = exports.Value$inboundSchema = exports.
|
|
29
|
+
exports.ValidationErrorDto$ = exports.ValidationErrorDto$outboundSchema = exports.ValidationErrorDto$inboundSchema = exports.errorsFromJSON = exports.errorsToJSON = exports.Errors$ = exports.Errors$outboundSchema = exports.Errors$inboundSchema = exports.valueFromJSON = exports.valueToJSON = exports.Value$ = exports.Value$outboundSchema = exports.Value$inboundSchema = exports.ValidationErrorDto = void 0;
|
|
30
30
|
const z = __importStar(require("zod"));
|
|
31
31
|
const schemas_js_1 = require("../../lib/schemas.js");
|
|
32
32
|
class ValidationErrorDto extends Error {
|
|
@@ -49,69 +49,21 @@ class ValidationErrorDto extends Error {
|
|
|
49
49
|
}
|
|
50
50
|
exports.ValidationErrorDto = ValidationErrorDto;
|
|
51
51
|
/** @internal */
|
|
52
|
-
exports.Five$inboundSchema = z
|
|
53
|
-
.object({});
|
|
54
|
-
/** @internal */
|
|
55
|
-
exports.Five$outboundSchema = z.object({});
|
|
56
|
-
/**
|
|
57
|
-
* @internal
|
|
58
|
-
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
59
|
-
*/
|
|
60
|
-
var Five$;
|
|
61
|
-
(function (Five$) {
|
|
62
|
-
/** @deprecated use `Five$inboundSchema` instead. */
|
|
63
|
-
Five$.inboundSchema = exports.Five$inboundSchema;
|
|
64
|
-
/** @deprecated use `Five$outboundSchema` instead. */
|
|
65
|
-
Five$.outboundSchema = exports.Five$outboundSchema;
|
|
66
|
-
})(Five$ || (exports.Five$ = Five$ = {}));
|
|
67
|
-
function fiveToJSON(five) {
|
|
68
|
-
return JSON.stringify(exports.Five$outboundSchema.parse(five));
|
|
69
|
-
}
|
|
70
|
-
exports.fiveToJSON = fiveToJSON;
|
|
71
|
-
function fiveFromJSON(jsonString) {
|
|
72
|
-
return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.Five$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'Five' from JSON`);
|
|
73
|
-
}
|
|
74
|
-
exports.fiveFromJSON = fiveFromJSON;
|
|
75
|
-
/** @internal */
|
|
76
|
-
exports.Four$inboundSchema = z
|
|
77
|
-
.object({});
|
|
78
|
-
/** @internal */
|
|
79
|
-
exports.Four$outboundSchema = z.object({});
|
|
80
|
-
/**
|
|
81
|
-
* @internal
|
|
82
|
-
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
83
|
-
*/
|
|
84
|
-
var Four$;
|
|
85
|
-
(function (Four$) {
|
|
86
|
-
/** @deprecated use `Four$inboundSchema` instead. */
|
|
87
|
-
Four$.inboundSchema = exports.Four$inboundSchema;
|
|
88
|
-
/** @deprecated use `Four$outboundSchema` instead. */
|
|
89
|
-
Four$.outboundSchema = exports.Four$outboundSchema;
|
|
90
|
-
})(Four$ || (exports.Four$ = Four$ = {}));
|
|
91
|
-
function fourToJSON(four) {
|
|
92
|
-
return JSON.stringify(exports.Four$outboundSchema.parse(four));
|
|
93
|
-
}
|
|
94
|
-
exports.fourToJSON = fourToJSON;
|
|
95
|
-
function fourFromJSON(jsonString) {
|
|
96
|
-
return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.Four$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'Four' from JSON`);
|
|
97
|
-
}
|
|
98
|
-
exports.fourFromJSON = fourFromJSON;
|
|
99
|
-
/** @internal */
|
|
100
52
|
exports.Value$inboundSchema = z
|
|
101
53
|
.union([
|
|
102
|
-
z.lazy(() => exports.Four$inboundSchema),
|
|
103
54
|
z.string(),
|
|
104
55
|
z.number(),
|
|
105
56
|
z.boolean(),
|
|
106
|
-
z.
|
|
57
|
+
z.record(z.any()),
|
|
58
|
+
z.array(z.record(z.any())),
|
|
107
59
|
]);
|
|
108
60
|
/** @internal */
|
|
109
61
|
exports.Value$outboundSchema = z.union([
|
|
110
|
-
z.lazy(() => exports.Four$outboundSchema),
|
|
111
62
|
z.string(),
|
|
112
63
|
z.number(),
|
|
113
64
|
z.boolean(),
|
|
114
|
-
z.
|
|
65
|
+
z.record(z.any()),
|
|
66
|
+
z.array(z.record(z.any())),
|
|
115
67
|
]);
|
|
116
68
|
/**
|
|
117
69
|
* @internal
|
|
@@ -137,22 +89,22 @@ exports.Errors$inboundSchema = z
|
|
|
137
89
|
.object({
|
|
138
90
|
messages: z.array(z.string()),
|
|
139
91
|
value: z.nullable(z.union([
|
|
140
|
-
z.lazy(() => exports.Four$inboundSchema),
|
|
141
92
|
z.string(),
|
|
142
93
|
z.number(),
|
|
143
94
|
z.boolean(),
|
|
144
|
-
z.
|
|
95
|
+
z.record(z.any()),
|
|
96
|
+
z.array(z.record(z.any())),
|
|
145
97
|
])),
|
|
146
98
|
});
|
|
147
99
|
/** @internal */
|
|
148
100
|
exports.Errors$outboundSchema = z.object({
|
|
149
101
|
messages: z.array(z.string()),
|
|
150
102
|
value: z.nullable(z.union([
|
|
151
|
-
z.lazy(() => exports.Four$outboundSchema),
|
|
152
103
|
z.string(),
|
|
153
104
|
z.number(),
|
|
154
105
|
z.boolean(),
|
|
155
|
-
z.
|
|
106
|
+
z.record(z.any()),
|
|
107
|
+
z.array(z.record(z.any())),
|
|
156
108
|
])),
|
|
157
109
|
});
|
|
158
110
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"validationerrordto.js","sourceRoot":"","sources":["../../src/models/errors/validationerrordto.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;;AAEH,uCAAy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,CAAC,6BAAqB,CAAC,CAAC;CACtD,CAAC,CAAC,CAAC;AAEN;;;GAGG;AACH,IAAiB,mBAAmB,CAOnC;AAPD,WAAiB,mBAAmB;IAClC,kEAAkE;IACrD,iCAAa,GAAG,wCAAgC,CAAC;IAC9D,mEAAmE;IACtD,kCAAc,GAAG,yCAAiC,CAAC;AAGlE,CAAC,EAPgB,mBAAmB,mCAAnB,mBAAmB,QAOnC"}
|
package/package.json
CHANGED
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.109",
|
|
59
59
|
genVersion: "2.477.4",
|
|
60
|
-
userAgent: "speakeasy-sdk/typescript 0.0.1-alpha.
|
|
60
|
+
userAgent: "speakeasy-sdk/typescript 0.0.1-alpha.109 2.477.4 1.0 @novu/api",
|
|
61
61
|
} as const;
|
|
@@ -7,15 +7,22 @@ import { safeParse } from "../../lib/schemas.js";
|
|
|
7
7
|
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
8
8
|
import { SDKValidationError } from "./sdkvalidationerror.js";
|
|
9
9
|
|
|
10
|
-
export type
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
10
|
+
export type Value =
|
|
11
|
+
| string
|
|
12
|
+
| number
|
|
13
|
+
| boolean
|
|
14
|
+
| { [k: string]: any }
|
|
15
|
+
| Array<{ [k: string]: any }>;
|
|
15
16
|
|
|
16
17
|
export type Errors = {
|
|
17
18
|
messages: Array<string>;
|
|
18
|
-
value:
|
|
19
|
+
value:
|
|
20
|
+
| string
|
|
21
|
+
| number
|
|
22
|
+
| boolean
|
|
23
|
+
| { [k: string]: any }
|
|
24
|
+
| Array<{ [k: string]: any }>
|
|
25
|
+
| null;
|
|
19
26
|
};
|
|
20
27
|
|
|
21
28
|
export type ValidationErrorDtoData = {
|
|
@@ -102,99 +109,23 @@ export class ValidationErrorDto extends Error {
|
|
|
102
109
|
}
|
|
103
110
|
}
|
|
104
111
|
|
|
105
|
-
/** @internal */
|
|
106
|
-
export const Five$inboundSchema: z.ZodType<Five, z.ZodTypeDef, unknown> = z
|
|
107
|
-
.object({});
|
|
108
|
-
|
|
109
|
-
/** @internal */
|
|
110
|
-
export type Five$Outbound = {};
|
|
111
|
-
|
|
112
|
-
/** @internal */
|
|
113
|
-
export const Five$outboundSchema: z.ZodType<Five$Outbound, z.ZodTypeDef, Five> =
|
|
114
|
-
z.object({});
|
|
115
|
-
|
|
116
|
-
/**
|
|
117
|
-
* @internal
|
|
118
|
-
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
119
|
-
*/
|
|
120
|
-
export namespace Five$ {
|
|
121
|
-
/** @deprecated use `Five$inboundSchema` instead. */
|
|
122
|
-
export const inboundSchema = Five$inboundSchema;
|
|
123
|
-
/** @deprecated use `Five$outboundSchema` instead. */
|
|
124
|
-
export const outboundSchema = Five$outboundSchema;
|
|
125
|
-
/** @deprecated use `Five$Outbound` instead. */
|
|
126
|
-
export type Outbound = Five$Outbound;
|
|
127
|
-
}
|
|
128
|
-
|
|
129
|
-
export function fiveToJSON(five: Five): string {
|
|
130
|
-
return JSON.stringify(Five$outboundSchema.parse(five));
|
|
131
|
-
}
|
|
132
|
-
|
|
133
|
-
export function fiveFromJSON(
|
|
134
|
-
jsonString: string,
|
|
135
|
-
): SafeParseResult<Five, SDKValidationError> {
|
|
136
|
-
return safeParse(
|
|
137
|
-
jsonString,
|
|
138
|
-
(x) => Five$inboundSchema.parse(JSON.parse(x)),
|
|
139
|
-
`Failed to parse 'Five' from JSON`,
|
|
140
|
-
);
|
|
141
|
-
}
|
|
142
|
-
|
|
143
|
-
/** @internal */
|
|
144
|
-
export const Four$inboundSchema: z.ZodType<Four, z.ZodTypeDef, unknown> = z
|
|
145
|
-
.object({});
|
|
146
|
-
|
|
147
|
-
/** @internal */
|
|
148
|
-
export type Four$Outbound = {};
|
|
149
|
-
|
|
150
|
-
/** @internal */
|
|
151
|
-
export const Four$outboundSchema: z.ZodType<Four$Outbound, z.ZodTypeDef, Four> =
|
|
152
|
-
z.object({});
|
|
153
|
-
|
|
154
|
-
/**
|
|
155
|
-
* @internal
|
|
156
|
-
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
157
|
-
*/
|
|
158
|
-
export namespace Four$ {
|
|
159
|
-
/** @deprecated use `Four$inboundSchema` instead. */
|
|
160
|
-
export const inboundSchema = Four$inboundSchema;
|
|
161
|
-
/** @deprecated use `Four$outboundSchema` instead. */
|
|
162
|
-
export const outboundSchema = Four$outboundSchema;
|
|
163
|
-
/** @deprecated use `Four$Outbound` instead. */
|
|
164
|
-
export type Outbound = Four$Outbound;
|
|
165
|
-
}
|
|
166
|
-
|
|
167
|
-
export function fourToJSON(four: Four): string {
|
|
168
|
-
return JSON.stringify(Four$outboundSchema.parse(four));
|
|
169
|
-
}
|
|
170
|
-
|
|
171
|
-
export function fourFromJSON(
|
|
172
|
-
jsonString: string,
|
|
173
|
-
): SafeParseResult<Four, SDKValidationError> {
|
|
174
|
-
return safeParse(
|
|
175
|
-
jsonString,
|
|
176
|
-
(x) => Four$inboundSchema.parse(JSON.parse(x)),
|
|
177
|
-
`Failed to parse 'Four' from JSON`,
|
|
178
|
-
);
|
|
179
|
-
}
|
|
180
|
-
|
|
181
112
|
/** @internal */
|
|
182
113
|
export const Value$inboundSchema: z.ZodType<Value, z.ZodTypeDef, unknown> = z
|
|
183
114
|
.union([
|
|
184
|
-
z.lazy(() => Four$inboundSchema),
|
|
185
115
|
z.string(),
|
|
186
116
|
z.number(),
|
|
187
117
|
z.boolean(),
|
|
188
|
-
z.
|
|
118
|
+
z.record(z.any()),
|
|
119
|
+
z.array(z.record(z.any())),
|
|
189
120
|
]);
|
|
190
121
|
|
|
191
122
|
/** @internal */
|
|
192
123
|
export type Value$Outbound =
|
|
193
|
-
| Four$Outbound
|
|
194
124
|
| string
|
|
195
125
|
| number
|
|
196
126
|
| boolean
|
|
197
|
-
|
|
|
127
|
+
| { [k: string]: any }
|
|
128
|
+
| Array<{ [k: string]: any }>;
|
|
198
129
|
|
|
199
130
|
/** @internal */
|
|
200
131
|
export const Value$outboundSchema: z.ZodType<
|
|
@@ -202,11 +133,11 @@ export const Value$outboundSchema: z.ZodType<
|
|
|
202
133
|
z.ZodTypeDef,
|
|
203
134
|
Value
|
|
204
135
|
> = z.union([
|
|
205
|
-
z.lazy(() => Four$outboundSchema),
|
|
206
136
|
z.string(),
|
|
207
137
|
z.number(),
|
|
208
138
|
z.boolean(),
|
|
209
|
-
z.
|
|
139
|
+
z.record(z.any()),
|
|
140
|
+
z.array(z.record(z.any())),
|
|
210
141
|
]);
|
|
211
142
|
|
|
212
143
|
/**
|
|
@@ -242,11 +173,11 @@ export const Errors$inboundSchema: z.ZodType<Errors, z.ZodTypeDef, unknown> = z
|
|
|
242
173
|
messages: z.array(z.string()),
|
|
243
174
|
value: z.nullable(
|
|
244
175
|
z.union([
|
|
245
|
-
z.lazy(() => Four$inboundSchema),
|
|
246
176
|
z.string(),
|
|
247
177
|
z.number(),
|
|
248
178
|
z.boolean(),
|
|
249
|
-
z.
|
|
179
|
+
z.record(z.any()),
|
|
180
|
+
z.array(z.record(z.any())),
|
|
250
181
|
]),
|
|
251
182
|
),
|
|
252
183
|
});
|
|
@@ -255,11 +186,11 @@ export const Errors$inboundSchema: z.ZodType<Errors, z.ZodTypeDef, unknown> = z
|
|
|
255
186
|
export type Errors$Outbound = {
|
|
256
187
|
messages: Array<string>;
|
|
257
188
|
value:
|
|
258
|
-
| Four$Outbound
|
|
259
189
|
| string
|
|
260
190
|
| number
|
|
261
191
|
| boolean
|
|
262
|
-
|
|
|
192
|
+
| { [k: string]: any }
|
|
193
|
+
| Array<{ [k: string]: any }>
|
|
263
194
|
| null;
|
|
264
195
|
};
|
|
265
196
|
|
|
@@ -272,11 +203,11 @@ export const Errors$outboundSchema: z.ZodType<
|
|
|
272
203
|
messages: z.array(z.string()),
|
|
273
204
|
value: z.nullable(
|
|
274
205
|
z.union([
|
|
275
|
-
z.lazy(() => Four$outboundSchema),
|
|
276
206
|
z.string(),
|
|
277
207
|
z.number(),
|
|
278
208
|
z.boolean(),
|
|
279
|
-
z.
|
|
209
|
+
z.record(z.any()),
|
|
210
|
+
z.array(z.record(z.any())),
|
|
280
211
|
]),
|
|
281
212
|
),
|
|
282
213
|
});
|