ue-mcp 1.2.2 → 1.2.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -4,16 +4,18 @@ import { z } from "zod";
4
4
  * each plugin npm package. Resolved from node_modules; never authored by the
5
5
  * end user.
6
6
  */
7
+ declare const ParamTypeSchema: z.ZodEnum<["string", "number", "boolean", "object", "array"]>;
8
+ export type ManifestParamType = z.infer<typeof ParamTypeSchema>;
7
9
  declare const SchemaFieldSchema: z.ZodObject<{
8
- type: z.ZodEnum<["string", "number", "boolean", "object", "array"]>;
10
+ type: z.ZodOptional<z.ZodUnion<[z.ZodEnum<["string", "number", "boolean", "object", "array"]>, z.ZodArray<z.ZodEnum<["string", "number", "boolean", "object", "array"]>, "atleastone">]>>;
9
11
  required: z.ZodOptional<z.ZodBoolean>;
10
12
  description: z.ZodOptional<z.ZodString>;
11
13
  }, "strip", z.ZodTypeAny, {
12
- type: "string" | "number" | "boolean" | "object" | "array";
14
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
13
15
  description?: string | undefined;
14
16
  required?: boolean | undefined;
15
17
  }, {
16
- type: "string" | "number" | "boolean" | "object" | "array";
18
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
17
19
  description?: string | undefined;
18
20
  required?: boolean | undefined;
19
21
  }>;
@@ -22,15 +24,15 @@ declare const InjectActionSchema: z.ZodObject<{
22
24
  task: z.ZodString;
23
25
  description: z.ZodOptional<z.ZodString>;
24
26
  schema: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
25
- type: z.ZodEnum<["string", "number", "boolean", "object", "array"]>;
27
+ type: z.ZodOptional<z.ZodUnion<[z.ZodEnum<["string", "number", "boolean", "object", "array"]>, z.ZodArray<z.ZodEnum<["string", "number", "boolean", "object", "array"]>, "atleastone">]>>;
26
28
  required: z.ZodOptional<z.ZodBoolean>;
27
29
  description: z.ZodOptional<z.ZodString>;
28
30
  }, "strip", z.ZodTypeAny, {
29
- type: "string" | "number" | "boolean" | "object" | "array";
31
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
30
32
  description?: string | undefined;
31
33
  required?: boolean | undefined;
32
34
  }, {
33
- type: "string" | "number" | "boolean" | "object" | "array";
35
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
34
36
  description?: string | undefined;
35
37
  required?: boolean | undefined;
36
38
  }>>>;
@@ -38,7 +40,7 @@ declare const InjectActionSchema: z.ZodObject<{
38
40
  task: string;
39
41
  description?: string | undefined;
40
42
  schema?: Record<string, {
41
- type: "string" | "number" | "boolean" | "object" | "array";
43
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
42
44
  description?: string | undefined;
43
45
  required?: boolean | undefined;
44
46
  }> | undefined;
@@ -46,7 +48,7 @@ declare const InjectActionSchema: z.ZodObject<{
46
48
  task: string;
47
49
  description?: string | undefined;
48
50
  schema?: Record<string, {
49
- type: "string" | "number" | "boolean" | "object" | "array";
51
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
50
52
  description?: string | undefined;
51
53
  required?: boolean | undefined;
52
54
  }> | undefined;
@@ -61,15 +63,15 @@ declare const ProvidedActionSchema: z.ZodObject<{
61
63
  task: z.ZodString;
62
64
  description: z.ZodOptional<z.ZodString>;
63
65
  schema: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
64
- type: z.ZodEnum<["string", "number", "boolean", "object", "array"]>;
66
+ type: z.ZodOptional<z.ZodUnion<[z.ZodEnum<["string", "number", "boolean", "object", "array"]>, z.ZodArray<z.ZodEnum<["string", "number", "boolean", "object", "array"]>, "atleastone">]>>;
65
67
  required: z.ZodOptional<z.ZodBoolean>;
66
68
  description: z.ZodOptional<z.ZodString>;
67
69
  }, "strip", z.ZodTypeAny, {
68
- type: "string" | "number" | "boolean" | "object" | "array";
70
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
69
71
  description?: string | undefined;
70
72
  required?: boolean | undefined;
71
73
  }, {
72
- type: "string" | "number" | "boolean" | "object" | "array";
74
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
73
75
  description?: string | undefined;
74
76
  required?: boolean | undefined;
75
77
  }>>>;
@@ -77,7 +79,7 @@ declare const ProvidedActionSchema: z.ZodObject<{
77
79
  task: string;
78
80
  description?: string | undefined;
79
81
  schema?: Record<string, {
80
- type: "string" | "number" | "boolean" | "object" | "array";
82
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
81
83
  description?: string | undefined;
82
84
  required?: boolean | undefined;
83
85
  }> | undefined;
@@ -85,7 +87,7 @@ declare const ProvidedActionSchema: z.ZodObject<{
85
87
  task: string;
86
88
  description?: string | undefined;
87
89
  schema?: Record<string, {
88
- type: "string" | "number" | "boolean" | "object" | "array";
90
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
89
91
  description?: string | undefined;
90
92
  required?: boolean | undefined;
91
93
  }> | undefined;
@@ -97,15 +99,15 @@ declare const ProvidedCategorySchema: z.ZodObject<{
97
99
  task: z.ZodString;
98
100
  description: z.ZodOptional<z.ZodString>;
99
101
  schema: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
100
- type: z.ZodEnum<["string", "number", "boolean", "object", "array"]>;
102
+ type: z.ZodOptional<z.ZodUnion<[z.ZodEnum<["string", "number", "boolean", "object", "array"]>, z.ZodArray<z.ZodEnum<["string", "number", "boolean", "object", "array"]>, "atleastone">]>>;
101
103
  required: z.ZodOptional<z.ZodBoolean>;
102
104
  description: z.ZodOptional<z.ZodString>;
103
105
  }, "strip", z.ZodTypeAny, {
104
- type: "string" | "number" | "boolean" | "object" | "array";
106
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
105
107
  description?: string | undefined;
106
108
  required?: boolean | undefined;
107
109
  }, {
108
- type: "string" | "number" | "boolean" | "object" | "array";
110
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
109
111
  description?: string | undefined;
110
112
  required?: boolean | undefined;
111
113
  }>>>;
@@ -113,7 +115,7 @@ declare const ProvidedCategorySchema: z.ZodObject<{
113
115
  task: string;
114
116
  description?: string | undefined;
115
117
  schema?: Record<string, {
116
- type: "string" | "number" | "boolean" | "object" | "array";
118
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
117
119
  description?: string | undefined;
118
120
  required?: boolean | undefined;
119
121
  }> | undefined;
@@ -121,7 +123,7 @@ declare const ProvidedCategorySchema: z.ZodObject<{
121
123
  task: string;
122
124
  description?: string | undefined;
123
125
  schema?: Record<string, {
124
- type: "string" | "number" | "boolean" | "object" | "array";
126
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
125
127
  description?: string | undefined;
126
128
  required?: boolean | undefined;
127
129
  }> | undefined;
@@ -131,7 +133,7 @@ declare const ProvidedCategorySchema: z.ZodObject<{
131
133
  task: string;
132
134
  description?: string | undefined;
133
135
  schema?: Record<string, {
134
- type: "string" | "number" | "boolean" | "object" | "array";
136
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
135
137
  description?: string | undefined;
136
138
  required?: boolean | undefined;
137
139
  }> | undefined;
@@ -142,7 +144,7 @@ declare const ProvidedCategorySchema: z.ZodObject<{
142
144
  task: string;
143
145
  description?: string | undefined;
144
146
  schema?: Record<string, {
145
- type: "string" | "number" | "boolean" | "object" | "array";
147
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
146
148
  description?: string | undefined;
147
149
  required?: boolean | undefined;
148
150
  }> | undefined;
@@ -175,22 +177,22 @@ declare const NativeModuleSchema: z.ZodObject<{
175
177
  description: z.ZodOptional<z.ZodString>;
176
178
  timeoutSeconds: z.ZodOptional<z.ZodNumber>;
177
179
  schema: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
178
- type: z.ZodEnum<["string", "number", "boolean", "object", "array"]>;
180
+ type: z.ZodOptional<z.ZodUnion<[z.ZodEnum<["string", "number", "boolean", "object", "array"]>, z.ZodArray<z.ZodEnum<["string", "number", "boolean", "object", "array"]>, "atleastone">]>>;
179
181
  required: z.ZodOptional<z.ZodBoolean>;
180
182
  description: z.ZodOptional<z.ZodString>;
181
183
  }, "strip", z.ZodTypeAny, {
182
- type: "string" | "number" | "boolean" | "object" | "array";
184
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
183
185
  description?: string | undefined;
184
186
  required?: boolean | undefined;
185
187
  }, {
186
- type: "string" | "number" | "boolean" | "object" | "array";
188
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
187
189
  description?: string | undefined;
188
190
  required?: boolean | undefined;
189
191
  }>>>;
190
192
  }, "strip", z.ZodTypeAny, {
191
193
  description?: string | undefined;
192
194
  schema?: Record<string, {
193
- type: "string" | "number" | "boolean" | "object" | "array";
195
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
194
196
  description?: string | undefined;
195
197
  required?: boolean | undefined;
196
198
  }> | undefined;
@@ -198,7 +200,7 @@ declare const NativeModuleSchema: z.ZodObject<{
198
200
  }, {
199
201
  description?: string | undefined;
200
202
  schema?: Record<string, {
201
- type: "string" | "number" | "boolean" | "object" | "array";
203
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
202
204
  description?: string | undefined;
203
205
  required?: boolean | undefined;
204
206
  }> | undefined;
@@ -212,7 +214,7 @@ declare const NativeModuleSchema: z.ZodObject<{
212
214
  handlers: Record<string, {
213
215
  description?: string | undefined;
214
216
  schema?: Record<string, {
215
- type: "string" | "number" | "boolean" | "object" | "array";
217
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
216
218
  description?: string | undefined;
217
219
  required?: boolean | undefined;
218
220
  }> | undefined;
@@ -230,7 +232,7 @@ declare const NativeModuleSchema: z.ZodObject<{
230
232
  handlers?: Record<string, {
231
233
  description?: string | undefined;
232
234
  schema?: Record<string, {
233
- type: "string" | "number" | "boolean" | "object" | "array";
235
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
234
236
  description?: string | undefined;
235
237
  required?: boolean | undefined;
236
238
  }> | undefined;
@@ -246,15 +248,15 @@ export declare const PluginManifestSchema: z.ZodObject<{
246
248
  task: z.ZodString;
247
249
  description: z.ZodOptional<z.ZodString>;
248
250
  schema: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
249
- type: z.ZodEnum<["string", "number", "boolean", "object", "array"]>;
251
+ type: z.ZodOptional<z.ZodUnion<[z.ZodEnum<["string", "number", "boolean", "object", "array"]>, z.ZodArray<z.ZodEnum<["string", "number", "boolean", "object", "array"]>, "atleastone">]>>;
250
252
  required: z.ZodOptional<z.ZodBoolean>;
251
253
  description: z.ZodOptional<z.ZodString>;
252
254
  }, "strip", z.ZodTypeAny, {
253
- type: "string" | "number" | "boolean" | "object" | "array";
255
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
254
256
  description?: string | undefined;
255
257
  required?: boolean | undefined;
256
258
  }, {
257
- type: "string" | "number" | "boolean" | "object" | "array";
259
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
258
260
  description?: string | undefined;
259
261
  required?: boolean | undefined;
260
262
  }>>>;
@@ -262,7 +264,7 @@ export declare const PluginManifestSchema: z.ZodObject<{
262
264
  task: string;
263
265
  description?: string | undefined;
264
266
  schema?: Record<string, {
265
- type: "string" | "number" | "boolean" | "object" | "array";
267
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
266
268
  description?: string | undefined;
267
269
  required?: boolean | undefined;
268
270
  }> | undefined;
@@ -270,7 +272,7 @@ export declare const PluginManifestSchema: z.ZodObject<{
270
272
  task: string;
271
273
  description?: string | undefined;
272
274
  schema?: Record<string, {
273
- type: "string" | "number" | "boolean" | "object" | "array";
275
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
274
276
  description?: string | undefined;
275
277
  required?: boolean | undefined;
276
278
  }> | undefined;
@@ -281,15 +283,15 @@ export declare const PluginManifestSchema: z.ZodObject<{
281
283
  task: z.ZodString;
282
284
  description: z.ZodOptional<z.ZodString>;
283
285
  schema: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
284
- type: z.ZodEnum<["string", "number", "boolean", "object", "array"]>;
286
+ type: z.ZodOptional<z.ZodUnion<[z.ZodEnum<["string", "number", "boolean", "object", "array"]>, z.ZodArray<z.ZodEnum<["string", "number", "boolean", "object", "array"]>, "atleastone">]>>;
285
287
  required: z.ZodOptional<z.ZodBoolean>;
286
288
  description: z.ZodOptional<z.ZodString>;
287
289
  }, "strip", z.ZodTypeAny, {
288
- type: "string" | "number" | "boolean" | "object" | "array";
290
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
289
291
  description?: string | undefined;
290
292
  required?: boolean | undefined;
291
293
  }, {
292
- type: "string" | "number" | "boolean" | "object" | "array";
294
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
293
295
  description?: string | undefined;
294
296
  required?: boolean | undefined;
295
297
  }>>>;
@@ -297,7 +299,7 @@ export declare const PluginManifestSchema: z.ZodObject<{
297
299
  task: string;
298
300
  description?: string | undefined;
299
301
  schema?: Record<string, {
300
- type: "string" | "number" | "boolean" | "object" | "array";
302
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
301
303
  description?: string | undefined;
302
304
  required?: boolean | undefined;
303
305
  }> | undefined;
@@ -305,7 +307,7 @@ export declare const PluginManifestSchema: z.ZodObject<{
305
307
  task: string;
306
308
  description?: string | undefined;
307
309
  schema?: Record<string, {
308
- type: "string" | "number" | "boolean" | "object" | "array";
310
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
309
311
  description?: string | undefined;
310
312
  required?: boolean | undefined;
311
313
  }> | undefined;
@@ -315,7 +317,7 @@ export declare const PluginManifestSchema: z.ZodObject<{
315
317
  task: string;
316
318
  description?: string | undefined;
317
319
  schema?: Record<string, {
318
- type: "string" | "number" | "boolean" | "object" | "array";
320
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
319
321
  description?: string | undefined;
320
322
  required?: boolean | undefined;
321
323
  }> | undefined;
@@ -326,7 +328,7 @@ export declare const PluginManifestSchema: z.ZodObject<{
326
328
  task: string;
327
329
  description?: string | undefined;
328
330
  schema?: Record<string, {
329
- type: "string" | "number" | "boolean" | "object" | "array";
331
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
330
332
  description?: string | undefined;
331
333
  required?: boolean | undefined;
332
334
  }> | undefined;
@@ -344,22 +346,22 @@ export declare const PluginManifestSchema: z.ZodObject<{
344
346
  description: z.ZodOptional<z.ZodString>;
345
347
  timeoutSeconds: z.ZodOptional<z.ZodNumber>;
346
348
  schema: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
347
- type: z.ZodEnum<["string", "number", "boolean", "object", "array"]>;
349
+ type: z.ZodOptional<z.ZodUnion<[z.ZodEnum<["string", "number", "boolean", "object", "array"]>, z.ZodArray<z.ZodEnum<["string", "number", "boolean", "object", "array"]>, "atleastone">]>>;
348
350
  required: z.ZodOptional<z.ZodBoolean>;
349
351
  description: z.ZodOptional<z.ZodString>;
350
352
  }, "strip", z.ZodTypeAny, {
351
- type: "string" | "number" | "boolean" | "object" | "array";
353
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
352
354
  description?: string | undefined;
353
355
  required?: boolean | undefined;
354
356
  }, {
355
- type: "string" | "number" | "boolean" | "object" | "array";
357
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
356
358
  description?: string | undefined;
357
359
  required?: boolean | undefined;
358
360
  }>>>;
359
361
  }, "strip", z.ZodTypeAny, {
360
362
  description?: string | undefined;
361
363
  schema?: Record<string, {
362
- type: "string" | "number" | "boolean" | "object" | "array";
364
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
363
365
  description?: string | undefined;
364
366
  required?: boolean | undefined;
365
367
  }> | undefined;
@@ -367,7 +369,7 @@ export declare const PluginManifestSchema: z.ZodObject<{
367
369
  }, {
368
370
  description?: string | undefined;
369
371
  schema?: Record<string, {
370
- type: "string" | "number" | "boolean" | "object" | "array";
372
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
371
373
  description?: string | undefined;
372
374
  required?: boolean | undefined;
373
375
  }> | undefined;
@@ -381,7 +383,7 @@ export declare const PluginManifestSchema: z.ZodObject<{
381
383
  handlers: Record<string, {
382
384
  description?: string | undefined;
383
385
  schema?: Record<string, {
384
- type: "string" | "number" | "boolean" | "object" | "array";
386
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
385
387
  description?: string | undefined;
386
388
  required?: boolean | undefined;
387
389
  }> | undefined;
@@ -399,7 +401,7 @@ export declare const PluginManifestSchema: z.ZodObject<{
399
401
  handlers?: Record<string, {
400
402
  description?: string | undefined;
401
403
  schema?: Record<string, {
402
- type: "string" | "number" | "boolean" | "object" | "array";
404
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
403
405
  description?: string | undefined;
404
406
  required?: boolean | undefined;
405
407
  }> | undefined;
@@ -492,7 +494,7 @@ export declare const PluginManifestSchema: z.ZodObject<{
492
494
  task: string;
493
495
  description?: string | undefined;
494
496
  schema?: Record<string, {
495
- type: "string" | "number" | "boolean" | "object" | "array";
497
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
496
498
  description?: string | undefined;
497
499
  required?: boolean | undefined;
498
500
  }> | undefined;
@@ -502,7 +504,7 @@ export declare const PluginManifestSchema: z.ZodObject<{
502
504
  task: string;
503
505
  description?: string | undefined;
504
506
  schema?: Record<string, {
505
- type: "string" | "number" | "boolean" | "object" | "array";
507
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
506
508
  description?: string | undefined;
507
509
  required?: boolean | undefined;
508
510
  }> | undefined;
@@ -519,7 +521,7 @@ export declare const PluginManifestSchema: z.ZodObject<{
519
521
  handlers: Record<string, {
520
522
  description?: string | undefined;
521
523
  schema?: Record<string, {
522
- type: "string" | "number" | "boolean" | "object" | "array";
524
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
523
525
  description?: string | undefined;
524
526
  required?: boolean | undefined;
525
527
  }> | undefined;
@@ -554,7 +556,7 @@ export declare const PluginManifestSchema: z.ZodObject<{
554
556
  task: string;
555
557
  description?: string | undefined;
556
558
  schema?: Record<string, {
557
- type: "string" | "number" | "boolean" | "object" | "array";
559
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
558
560
  description?: string | undefined;
559
561
  required?: boolean | undefined;
560
562
  }> | undefined;
@@ -564,7 +566,7 @@ export declare const PluginManifestSchema: z.ZodObject<{
564
566
  task: string;
565
567
  description?: string | undefined;
566
568
  schema?: Record<string, {
567
- type: "string" | "number" | "boolean" | "object" | "array";
569
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
568
570
  description?: string | undefined;
569
571
  required?: boolean | undefined;
570
572
  }> | undefined;
@@ -581,7 +583,7 @@ export declare const PluginManifestSchema: z.ZodObject<{
581
583
  handlers?: Record<string, {
582
584
  description?: string | undefined;
583
585
  schema?: Record<string, {
584
- type: "string" | "number" | "boolean" | "object" | "array";
586
+ type?: "string" | "number" | "boolean" | "object" | "array" | ["string" | "number" | "boolean" | "object" | "array", ...("string" | "number" | "boolean" | "object" | "array")[]] | undefined;
585
587
  description?: string | undefined;
586
588
  required?: boolean | undefined;
587
589
  }> | undefined;
@@ -595,10 +597,28 @@ export type PluginManifest = z.infer<typeof PluginManifestSchema>;
595
597
  * `ue-mcp.plugin.yml`, but `.yaml` is accepted as a fallback.
596
598
  */
597
599
  export declare function findManifestPath(pkgDir: string): string | null;
600
+ /** One manifest subtree removed to keep the rest of the plugin loadable. */
601
+ export interface DroppedUnit {
602
+ /** Dotted manifest path, e.g. `nativeModule.handlers.actor_set`. */
603
+ path: string;
604
+ /** The validation error that cost it, already rendered for a log line. */
605
+ reason: string;
606
+ }
598
607
  export interface ManifestParseResult {
599
608
  manifest: PluginManifest;
600
609
  manifestPath: string;
610
+ /** Units dropped by salvage. Empty when the manifest validated as authored. */
611
+ dropped: DroppedUnit[];
601
612
  }
613
+ /**
614
+ * Validate a manifest, dropping individually-salvageable units rather than
615
+ * rejecting the whole plugin. Throws (with Zod's full issue dump, as before)
616
+ * when any error lands outside a droppable unit.
617
+ */
618
+ export declare function parseManifest(raw: unknown): {
619
+ manifest: PluginManifest;
620
+ dropped: DroppedUnit[];
621
+ };
602
622
  export declare function loadManifest(pkgDir: string): ManifestParseResult;
603
623
  /**
604
624
  * Compile a manifest schema field map into a Zod object schema. Used to merge
@@ -7,8 +7,14 @@ import yaml from "js-yaml";
7
7
  * each plugin npm package. Resolved from node_modules; never authored by the
8
8
  * end user.
9
9
  */
10
+ const ParamTypeSchema = z.enum(["string", "number", "boolean", "object", "array"]);
10
11
  const SchemaFieldSchema = z.object({
11
- type: z.enum(["string", "number", "boolean", "object", "array"]),
12
+ // Omitted means "any JSON value". Some handler params genuinely have no one
13
+ // type: a property write coerced through UE's ImportText takes a number, a
14
+ // bool, a string or an enum name with equal validity, and forcing the author
15
+ // to pick one of them would lie about the surface. A list of type names
16
+ // narrows that to a union when the author does know the alternatives.
17
+ type: z.union([ParamTypeSchema, z.array(ParamTypeSchema).nonempty()]).optional(),
12
18
  required: z.boolean().optional(),
13
19
  description: z.string().optional(),
14
20
  });
@@ -123,14 +129,92 @@ export function findManifestPath(pkgDir) {
123
129
  }
124
130
  return null;
125
131
  }
132
+ /**
133
+ * The smallest manifest subtree a validation error can be confined to. An
134
+ * error inside one of these costs that unit and nothing else, so a single
135
+ * malformed handler no longer takes its whole category off the surface.
136
+ * Returns null for anything structural (actionPrefix, nativeModule.source,
137
+ * a manifest that is not an object at all), which still fails the plugin.
138
+ */
139
+ function salvageableUnit(issuePath) {
140
+ const p = issuePath;
141
+ if (p[0] === "nativeModule" && p[1] === "handlers" && p.length >= 3)
142
+ return p.slice(0, 3);
143
+ if (p[0] === "inject" && p.length >= 3)
144
+ return p.slice(0, 3);
145
+ if (p[0] === "inject" && p.length === 2)
146
+ return p.slice(0, 2);
147
+ if (p[0] === "provides" && p[2] === "actions" && p.length >= 4)
148
+ return p.slice(0, 4);
149
+ if (p[0] === "provides" && p.length >= 2)
150
+ return p.slice(0, 2);
151
+ if (p[0] === "flows" && p.length >= 2)
152
+ return p.slice(0, 2);
153
+ if (p[0] === "tasks" && p.length >= 2)
154
+ return p.slice(0, 2);
155
+ if (p[0] === "knowledge" && p.length >= 2)
156
+ return p.slice(0, 2);
157
+ return null;
158
+ }
159
+ /** Delete `path` from a nested plain object. No-op if the path is not there. */
160
+ function deleteAt(root, path) {
161
+ let cur = root;
162
+ for (const key of path.slice(0, -1)) {
163
+ if (typeof cur !== "object" || cur === null)
164
+ return;
165
+ cur = cur[key];
166
+ }
167
+ if (typeof cur !== "object" || cur === null)
168
+ return;
169
+ delete cur[path[path.length - 1]];
170
+ }
171
+ /**
172
+ * Validate a manifest, dropping individually-salvageable units rather than
173
+ * rejecting the whole plugin. Throws (with Zod's full issue dump, as before)
174
+ * when any error lands outside a droppable unit.
175
+ */
176
+ export function parseManifest(raw) {
177
+ const dropped = [];
178
+ let current = raw;
179
+ // Each pass removes at least one unit, so the loop is bounded by the number
180
+ // of units in the manifest; the cap is a backstop against a pathological
181
+ // schema where pruning cannot make progress.
182
+ for (let pass = 0; pass < 100; pass++) {
183
+ const result = PluginManifestSchema.safeParse(current);
184
+ if (result.success)
185
+ return { manifest: result.data, dropped };
186
+ // Keyed by the rendered path only for dedup; the pruning itself uses the
187
+ // segment array, since a segment (a task name, say) may contain a dot.
188
+ const units = new Map();
189
+ for (const issue of result.error.issues) {
190
+ const unit = salvageableUnit(issue.path);
191
+ if (!unit)
192
+ throw result.error;
193
+ const key = unit.join(".");
194
+ if (!units.has(key)) {
195
+ units.set(key, { unit, reason: `${issue.path.join(".")}: ${issue.message}` });
196
+ }
197
+ }
198
+ if (units.size === 0)
199
+ throw result.error;
200
+ current = structuredClone(current);
201
+ for (const [key, { unit, reason }] of units) {
202
+ deleteAt(current, unit);
203
+ dropped.push({ path: key, reason });
204
+ }
205
+ }
206
+ // Unreachable in practice: pruning that never converges means the schema
207
+ // rejects the pruned shape too, which is a bug in the schema, not the input.
208
+ throw new Error("manifest validation did not converge after 100 salvage passes");
209
+ }
126
210
  export function loadManifest(pkgDir) {
127
211
  const manifestPath = findManifestPath(pkgDir);
128
212
  if (!manifestPath) {
129
213
  throw new Error(`ue-mcp.plugin.yml not found in ${pkgDir}`);
130
214
  }
131
215
  const raw = yaml.load(fs.readFileSync(manifestPath, "utf-8"));
132
- const manifest = PluginManifestSchema.parse(raw);
133
- return { manifest, manifestPath };
216
+ const { manifest, dropped } = parseManifest(raw);
217
+ return { manifest, manifestPath, dropped };
134
218
  }
135
219
  /**
136
220
  * Compile a manifest schema field map into a Zod object schema. Used to merge
@@ -141,24 +225,7 @@ export function compileSchemaFields(fields) {
141
225
  return {};
142
226
  const out = {};
143
227
  for (const [key, def] of Object.entries(fields)) {
144
- let zod;
145
- switch (def.type) {
146
- case "string":
147
- zod = z.string();
148
- break;
149
- case "number":
150
- zod = z.number();
151
- break;
152
- case "boolean":
153
- zod = z.boolean();
154
- break;
155
- case "object":
156
- zod = z.record(z.unknown());
157
- break;
158
- case "array":
159
- zod = z.array(z.unknown());
160
- break;
161
- }
228
+ let zod = zodForDeclaredType(def.type, def.required === true);
162
229
  if (def.description)
163
230
  zod = zod.describe(def.description);
164
231
  if (!def.required)
@@ -167,6 +234,36 @@ export function compileSchemaFields(fields) {
167
234
  }
168
235
  return out;
169
236
  }
237
+ function zodForParamType(type) {
238
+ switch (type) {
239
+ case "string": return z.string();
240
+ case "number": return z.number();
241
+ case "boolean": return z.boolean();
242
+ case "object": return z.record(z.unknown());
243
+ case "array": return z.array(z.unknown());
244
+ }
245
+ }
246
+ /**
247
+ * Zod for one declared `type`, which is a single name, a list of names, or
248
+ * absent. Absent compiles to `z.any()`, which accepts undefined on its own, so
249
+ * a required untyped param carries a refinement that puts the presence check
250
+ * back: `.isOptional()` is what the SDK reads to build the JSON Schema
251
+ * `required` list.
252
+ */
253
+ function zodForDeclaredType(type, required) {
254
+ if (type === undefined) {
255
+ return required
256
+ ? z.any().refine((v) => v !== undefined, { message: "Required" })
257
+ : z.any();
258
+ }
259
+ if (Array.isArray(type)) {
260
+ const members = type.map(zodForParamType);
261
+ return members.length === 1
262
+ ? members[0]
263
+ : z.union(members);
264
+ }
265
+ return zodForParamType(type);
266
+ }
170
267
  /**
171
268
  * Compute the prefixed action name as it appears on the injected category
172
269
  * tool: `<actionPrefix>_<bareAction>`.