@octonodes/sdk 0.1.0 → 0.1.5
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/PLUGINS.md +228 -91
- package/dist/constants.d.ts +1 -0
- package/dist/constants.d.ts.map +1 -1
- package/dist/constants.js +2 -1
- package/dist/constants.js.map +1 -1
- package/dist/gen/types.gen.d.ts +149 -1
- package/dist/gen/types.gen.d.ts.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -1
- package/dist/index.js.map +1 -1
- package/dist/plugins/schema/plugin.d.ts +164 -18
- package/dist/plugins/schema/plugin.d.ts.map +1 -1
- package/dist/plugins/schema/plugin.js +53 -1
- package/dist/plugins/schema/plugin.js.map +1 -1
- package/dist/plugins/sdk/definitions/compiler/catalog.d.ts +3 -0
- package/dist/plugins/sdk/definitions/compiler/catalog.d.ts.map +1 -0
- package/dist/plugins/sdk/definitions/compiler/catalog.js +133 -0
- package/dist/plugins/sdk/definitions/compiler/catalog.js.map +1 -0
- package/dist/plugins/sdk/definitions/compiler/constants.d.ts +6 -0
- package/dist/plugins/sdk/definitions/compiler/constants.d.ts.map +1 -0
- package/dist/plugins/sdk/definitions/compiler/constants.js +10 -0
- package/dist/plugins/sdk/definitions/compiler/constants.js.map +1 -0
- package/dist/plugins/sdk/definitions/compiler/index.d.ts +7 -0
- package/dist/plugins/sdk/definitions/compiler/index.d.ts.map +1 -0
- package/dist/plugins/sdk/definitions/compiler/index.js +411 -0
- package/dist/plugins/sdk/definitions/compiler/index.js.map +1 -0
- package/dist/plugins/sdk/definitions/compiler/literals.d.ts +5 -0
- package/dist/plugins/sdk/definitions/compiler/literals.d.ts.map +1 -0
- package/dist/plugins/sdk/definitions/compiler/literals.js +78 -0
- package/dist/plugins/sdk/definitions/compiler/literals.js.map +1 -0
- package/dist/plugins/sdk/definitions/compiler/schemas.d.ts +4 -0
- package/dist/plugins/sdk/definitions/compiler/schemas.d.ts.map +1 -0
- package/dist/plugins/sdk/definitions/compiler/schemas.js +95 -0
- package/dist/plugins/sdk/definitions/compiler/schemas.js.map +1 -0
- package/dist/plugins/sdk/definitions/compiler/types.d.ts +20 -0
- package/dist/plugins/sdk/definitions/compiler/types.d.ts.map +1 -0
- package/dist/plugins/sdk/definitions/compiler/types.js +3 -0
- package/dist/plugins/sdk/definitions/compiler/types.js.map +1 -0
- package/dist/plugins/sdk/definitions/index.d.ts +7 -0
- package/dist/plugins/sdk/definitions/index.d.ts.map +1 -0
- package/dist/plugins/sdk/definitions/index.js +16 -0
- package/dist/plugins/sdk/definitions/index.js.map +1 -0
- package/dist/plugins/sdk/definitions/npm/emit/js.d.ts +4 -0
- package/dist/plugins/sdk/definitions/npm/emit/js.d.ts.map +1 -0
- package/dist/plugins/sdk/definitions/npm/emit/js.js +190 -0
- package/dist/plugins/sdk/definitions/npm/emit/js.js.map +1 -0
- package/dist/plugins/sdk/definitions/npm/types.d.ts +63 -0
- package/dist/plugins/sdk/definitions/npm/types.d.ts.map +1 -0
- package/dist/plugins/sdk/definitions/npm/types.js +3 -0
- package/dist/plugins/sdk/definitions/npm/types.js.map +1 -0
- package/dist/plugins/sdk/definitions/types.d.ts +43 -0
- package/dist/plugins/sdk/definitions/types.d.ts.map +1 -0
- package/dist/plugins/sdk/definitions/types.js +3 -0
- package/dist/plugins/sdk/definitions/types.js.map +1 -0
- package/dist/plugins/sdk/nodes/index.d.ts +5 -0
- package/dist/plugins/sdk/nodes/index.d.ts.map +1 -0
- package/dist/plugins/sdk/nodes/index.js +12 -0
- package/dist/plugins/sdk/nodes/index.js.map +1 -0
- package/dist/plugins/sdk/plugin/index.d.ts +3 -0
- package/dist/plugins/sdk/plugin/index.d.ts.map +1 -0
- package/dist/plugins/sdk/plugin/index.js +8 -0
- package/dist/plugins/sdk/plugin/index.js.map +1 -0
- package/dist/plugins/sdk/plugin.js +1 -1
- package/dist/plugins/sdk/plugin.js.map +1 -1
- package/dist/plugins/sdk/plugins/define-node.js +1 -1
- package/dist/plugins/sdk/plugins/define-node.js.map +1 -1
- package/dist/plugins/sdk/plugins/index.js +1 -1
- package/dist/plugins/sdk/plugins/index.js.map +1 -1
- package/dist/plugins/sdk/project/index.d.ts +5 -0
- package/dist/plugins/sdk/project/index.d.ts.map +1 -0
- package/dist/plugins/sdk/project/index.js +10 -0
- package/dist/plugins/sdk/project/index.js.map +1 -0
- package/dist/plugins/sdk/runner.js +1 -1
- package/dist/plugins/sdk/runner.js.map +1 -1
- package/package.json +45 -1
|
@@ -45,6 +45,24 @@ export type PluginNodeUi = z.infer<typeof PluginNodeUi>;
|
|
|
45
45
|
* Scopes supported by the hosted marketplace.
|
|
46
46
|
*/
|
|
47
47
|
export type MarketplaceScope = PluginScope;
|
|
48
|
+
/** Build an upstream SDK client from connection fields, never from public node inputs. */
|
|
49
|
+
export declare const NpmClientBinding: z.ZodObject<{
|
|
50
|
+
module: z.ZodEffects<z.ZodString, string, string>;
|
|
51
|
+
export: z.ZodString;
|
|
52
|
+
options: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
53
|
+
env: z.ZodOptional<z.ZodRecord<z.ZodEffects<z.ZodString, string, string>, z.ZodString>>;
|
|
54
|
+
}, "strict", z.ZodTypeAny, {
|
|
55
|
+
module: string;
|
|
56
|
+
export: string;
|
|
57
|
+
options?: Record<string, unknown> | undefined;
|
|
58
|
+
env?: Record<string, string> | undefined;
|
|
59
|
+
}, {
|
|
60
|
+
module: string;
|
|
61
|
+
export: string;
|
|
62
|
+
options?: Record<string, unknown> | undefined;
|
|
63
|
+
env?: Record<string, string> | undefined;
|
|
64
|
+
}>;
|
|
65
|
+
export type NpmClientBinding = z.infer<typeof NpmClientBinding>;
|
|
48
66
|
/**
|
|
49
67
|
* One node contributed by a plugin. Unlike a project node (whose signature is
|
|
50
68
|
* discovered by `octonode scan`), a plugin node declares its contract directly
|
|
@@ -67,6 +85,22 @@ export declare const PluginNode: z.ZodObject<{
|
|
|
67
85
|
env: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
68
86
|
connections: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
69
87
|
defaults: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
88
|
+
bindings: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
89
|
+
module: z.ZodEffects<z.ZodString, string, string>;
|
|
90
|
+
export: z.ZodString;
|
|
91
|
+
options: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
92
|
+
env: z.ZodOptional<z.ZodRecord<z.ZodEffects<z.ZodString, string, string>, z.ZodString>>;
|
|
93
|
+
}, "strict", z.ZodTypeAny, {
|
|
94
|
+
module: string;
|
|
95
|
+
export: string;
|
|
96
|
+
options?: Record<string, unknown> | undefined;
|
|
97
|
+
env?: Record<string, string> | undefined;
|
|
98
|
+
}, {
|
|
99
|
+
module: string;
|
|
100
|
+
export: string;
|
|
101
|
+
options?: Record<string, unknown> | undefined;
|
|
102
|
+
env?: Record<string, string> | undefined;
|
|
103
|
+
}>>>;
|
|
70
104
|
ui: z.ZodOptional<z.ZodObject<{
|
|
71
105
|
apiVersion: z.ZodLiteral<"1">;
|
|
72
106
|
renderers: z.ZodEffects<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
@@ -112,6 +146,12 @@ export declare const PluginNode: z.ZodObject<{
|
|
|
112
146
|
icon?: "function" | "group" | "workflow" | "code" | "type" | "typescript" | "variable" | "webhook" | "filter" | "replace" | "search" | "split" | "repeat" | "arrow-up-down" | "binary" | "bomb" | "boxes" | "braces" | "calculator" | "calendar" | "camera" | "clock" | "copy-x" | "database" | "dices" | "flag" | "flask" | "git-branch" | "git-merge" | "hook" | "list-filter" | "merge" | "octagon-x" | "package" | "package-x" | "pencil" | "play" | "regex" | "ruler" | "scan-eye" | "scissors" | "server-cog" | "settings" | "sigma" | "terminal" | "test-tube" | "text-cursor-input" | "ticket" | "truck" | "ungroup" | "wand" | "wave" | "x" | undefined;
|
|
113
147
|
trigger?: boolean | undefined;
|
|
114
148
|
connections?: string[] | undefined;
|
|
149
|
+
bindings?: Record<string, {
|
|
150
|
+
module: string;
|
|
151
|
+
export: string;
|
|
152
|
+
options?: Record<string, unknown> | undefined;
|
|
153
|
+
env?: Record<string, string> | undefined;
|
|
154
|
+
}> | undefined;
|
|
115
155
|
ui?: {
|
|
116
156
|
apiVersion: "1";
|
|
117
157
|
renderers: Record<string, {
|
|
@@ -133,6 +173,12 @@ export declare const PluginNode: z.ZodObject<{
|
|
|
133
173
|
icon?: "function" | "group" | "workflow" | "code" | "type" | "typescript" | "variable" | "webhook" | "filter" | "replace" | "search" | "split" | "repeat" | "arrow-up-down" | "binary" | "bomb" | "boxes" | "braces" | "calculator" | "calendar" | "camera" | "clock" | "copy-x" | "database" | "dices" | "flag" | "flask" | "git-branch" | "git-merge" | "hook" | "list-filter" | "merge" | "octagon-x" | "package" | "package-x" | "pencil" | "play" | "regex" | "ruler" | "scan-eye" | "scissors" | "server-cog" | "settings" | "sigma" | "terminal" | "test-tube" | "text-cursor-input" | "ticket" | "truck" | "ungroup" | "wand" | "wave" | "x" | undefined;
|
|
134
174
|
trigger?: boolean | undefined;
|
|
135
175
|
connections?: string[] | undefined;
|
|
176
|
+
bindings?: Record<string, {
|
|
177
|
+
module: string;
|
|
178
|
+
export: string;
|
|
179
|
+
options?: Record<string, unknown> | undefined;
|
|
180
|
+
env?: Record<string, string> | undefined;
|
|
181
|
+
}> | undefined;
|
|
136
182
|
ui?: {
|
|
137
183
|
apiVersion: "1";
|
|
138
184
|
renderers: Record<string, {
|
|
@@ -179,22 +225,22 @@ export declare const PluginIntegration: z.ZodObject<{
|
|
|
179
225
|
}>>;
|
|
180
226
|
}, "strip", z.ZodTypeAny, {
|
|
181
227
|
tags: string[];
|
|
182
|
-
auth?: string[] | undefined;
|
|
183
|
-
category?: string | undefined;
|
|
184
228
|
npm?: {
|
|
185
229
|
package: string;
|
|
186
230
|
version: string;
|
|
187
231
|
spec: string;
|
|
188
232
|
} | undefined;
|
|
189
|
-
}, {
|
|
190
233
|
auth?: string[] | undefined;
|
|
191
234
|
category?: string | undefined;
|
|
192
|
-
|
|
235
|
+
}, {
|
|
193
236
|
npm?: {
|
|
194
237
|
package: string;
|
|
195
238
|
version: string;
|
|
196
239
|
spec: string;
|
|
197
240
|
} | undefined;
|
|
241
|
+
auth?: string[] | undefined;
|
|
242
|
+
category?: string | undefined;
|
|
243
|
+
tags?: string[] | undefined;
|
|
198
244
|
}>;
|
|
199
245
|
export type PluginIntegration = z.infer<typeof PluginIntegration>;
|
|
200
246
|
/** Credential metadata only. Values are supplied by the installing user at runtime. */
|
|
@@ -245,6 +291,26 @@ export declare const PluginManifest: z.ZodEffects<z.ZodObject<{
|
|
|
245
291
|
name: z.ZodString;
|
|
246
292
|
version: z.ZodString;
|
|
247
293
|
description: z.ZodOptional<z.ZodString>;
|
|
294
|
+
/** Implementation authority; absent on legacy artifacts. */
|
|
295
|
+
source: z.ZodOptional<z.ZodDiscriminatedUnion<"kind", [z.ZodObject<{
|
|
296
|
+
kind: z.ZodLiteral<"plugin">;
|
|
297
|
+
}, "strict", z.ZodTypeAny, {
|
|
298
|
+
kind: "plugin";
|
|
299
|
+
}, {
|
|
300
|
+
kind: "plugin";
|
|
301
|
+
}>, z.ZodObject<{
|
|
302
|
+
kind: z.ZodLiteral<"npm">;
|
|
303
|
+
package: z.ZodString;
|
|
304
|
+
version: z.ZodString;
|
|
305
|
+
}, "strict", z.ZodTypeAny, {
|
|
306
|
+
package: string;
|
|
307
|
+
kind: "npm";
|
|
308
|
+
version: string;
|
|
309
|
+
}, {
|
|
310
|
+
package: string;
|
|
311
|
+
kind: "npm";
|
|
312
|
+
version: string;
|
|
313
|
+
}>]>>;
|
|
248
314
|
icon: z.ZodOptional<z.ZodEnum<["arrow-up-down", "binary", "bomb", "boxes", "braces", "calculator", "calendar", "camera", "clock", "code", "copy-x", "database", "dices", "filter", "flag", "flask", "function", "git-branch", "git-merge", "group", "hook", "list-filter", "merge", "octagon-x", "package", "package-x", "pencil", "play", "regex", "repeat", "replace", "ruler", "scan-eye", "scissors", "search", "server-cog", "settings", "sigma", "split", "terminal", "test-tube", "text-cursor-input", "ticket", "truck", "type", "typescript", "ungroup", "variable", "wand", "wave", "webhook", "workflow", "x"]>>;
|
|
249
315
|
author: z.ZodOptional<z.ZodString>;
|
|
250
316
|
homepage: z.ZodOptional<z.ZodString>;
|
|
@@ -283,22 +349,22 @@ export declare const PluginManifest: z.ZodEffects<z.ZodObject<{
|
|
|
283
349
|
}>>;
|
|
284
350
|
}, "strip", z.ZodTypeAny, {
|
|
285
351
|
tags: string[];
|
|
286
|
-
auth?: string[] | undefined;
|
|
287
|
-
category?: string | undefined;
|
|
288
352
|
npm?: {
|
|
289
353
|
package: string;
|
|
290
354
|
version: string;
|
|
291
355
|
spec: string;
|
|
292
356
|
} | undefined;
|
|
293
|
-
}, {
|
|
294
357
|
auth?: string[] | undefined;
|
|
295
358
|
category?: string | undefined;
|
|
296
|
-
|
|
359
|
+
}, {
|
|
297
360
|
npm?: {
|
|
298
361
|
package: string;
|
|
299
362
|
version: string;
|
|
300
363
|
spec: string;
|
|
301
364
|
} | undefined;
|
|
365
|
+
auth?: string[] | undefined;
|
|
366
|
+
category?: string | undefined;
|
|
367
|
+
tags?: string[] | undefined;
|
|
302
368
|
}>>;
|
|
303
369
|
connections: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
304
370
|
label: z.ZodString;
|
|
@@ -354,6 +420,22 @@ export declare const PluginManifest: z.ZodEffects<z.ZodObject<{
|
|
|
354
420
|
env: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
355
421
|
connections: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
356
422
|
defaults: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
423
|
+
bindings: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
424
|
+
module: z.ZodEffects<z.ZodString, string, string>;
|
|
425
|
+
export: z.ZodString;
|
|
426
|
+
options: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
427
|
+
env: z.ZodOptional<z.ZodRecord<z.ZodEffects<z.ZodString, string, string>, z.ZodString>>;
|
|
428
|
+
}, "strict", z.ZodTypeAny, {
|
|
429
|
+
module: string;
|
|
430
|
+
export: string;
|
|
431
|
+
options?: Record<string, unknown> | undefined;
|
|
432
|
+
env?: Record<string, string> | undefined;
|
|
433
|
+
}, {
|
|
434
|
+
module: string;
|
|
435
|
+
export: string;
|
|
436
|
+
options?: Record<string, unknown> | undefined;
|
|
437
|
+
env?: Record<string, string> | undefined;
|
|
438
|
+
}>>>;
|
|
357
439
|
ui: z.ZodOptional<z.ZodObject<{
|
|
358
440
|
apiVersion: z.ZodLiteral<"1">;
|
|
359
441
|
renderers: z.ZodEffects<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
@@ -399,6 +481,12 @@ export declare const PluginManifest: z.ZodEffects<z.ZodObject<{
|
|
|
399
481
|
icon?: "function" | "group" | "workflow" | "code" | "type" | "typescript" | "variable" | "webhook" | "filter" | "replace" | "search" | "split" | "repeat" | "arrow-up-down" | "binary" | "bomb" | "boxes" | "braces" | "calculator" | "calendar" | "camera" | "clock" | "copy-x" | "database" | "dices" | "flag" | "flask" | "git-branch" | "git-merge" | "hook" | "list-filter" | "merge" | "octagon-x" | "package" | "package-x" | "pencil" | "play" | "regex" | "ruler" | "scan-eye" | "scissors" | "server-cog" | "settings" | "sigma" | "terminal" | "test-tube" | "text-cursor-input" | "ticket" | "truck" | "ungroup" | "wand" | "wave" | "x" | undefined;
|
|
400
482
|
trigger?: boolean | undefined;
|
|
401
483
|
connections?: string[] | undefined;
|
|
484
|
+
bindings?: Record<string, {
|
|
485
|
+
module: string;
|
|
486
|
+
export: string;
|
|
487
|
+
options?: Record<string, unknown> | undefined;
|
|
488
|
+
env?: Record<string, string> | undefined;
|
|
489
|
+
}> | undefined;
|
|
402
490
|
ui?: {
|
|
403
491
|
apiVersion: "1";
|
|
404
492
|
renderers: Record<string, {
|
|
@@ -420,6 +508,12 @@ export declare const PluginManifest: z.ZodEffects<z.ZodObject<{
|
|
|
420
508
|
icon?: "function" | "group" | "workflow" | "code" | "type" | "typescript" | "variable" | "webhook" | "filter" | "replace" | "search" | "split" | "repeat" | "arrow-up-down" | "binary" | "bomb" | "boxes" | "braces" | "calculator" | "calendar" | "camera" | "clock" | "copy-x" | "database" | "dices" | "flag" | "flask" | "git-branch" | "git-merge" | "hook" | "list-filter" | "merge" | "octagon-x" | "package" | "package-x" | "pencil" | "play" | "regex" | "ruler" | "scan-eye" | "scissors" | "server-cog" | "settings" | "sigma" | "terminal" | "test-tube" | "text-cursor-input" | "ticket" | "truck" | "ungroup" | "wand" | "wave" | "x" | undefined;
|
|
421
509
|
trigger?: boolean | undefined;
|
|
422
510
|
connections?: string[] | undefined;
|
|
511
|
+
bindings?: Record<string, {
|
|
512
|
+
module: string;
|
|
513
|
+
export: string;
|
|
514
|
+
options?: Record<string, unknown> | undefined;
|
|
515
|
+
env?: Record<string, string> | undefined;
|
|
516
|
+
}> | undefined;
|
|
423
517
|
ui?: {
|
|
424
518
|
apiVersion: "1";
|
|
425
519
|
renderers: Record<string, {
|
|
@@ -443,6 +537,12 @@ export declare const PluginManifest: z.ZodEffects<z.ZodObject<{
|
|
|
443
537
|
icon?: "function" | "group" | "workflow" | "code" | "type" | "typescript" | "variable" | "webhook" | "filter" | "replace" | "search" | "split" | "repeat" | "arrow-up-down" | "binary" | "bomb" | "boxes" | "braces" | "calculator" | "calendar" | "camera" | "clock" | "copy-x" | "database" | "dices" | "flag" | "flask" | "git-branch" | "git-merge" | "hook" | "list-filter" | "merge" | "octagon-x" | "package" | "package-x" | "pencil" | "play" | "regex" | "ruler" | "scan-eye" | "scissors" | "server-cog" | "settings" | "sigma" | "terminal" | "test-tube" | "text-cursor-input" | "ticket" | "truck" | "ungroup" | "wand" | "wave" | "x" | undefined;
|
|
444
538
|
trigger?: boolean | undefined;
|
|
445
539
|
connections?: string[] | undefined;
|
|
540
|
+
bindings?: Record<string, {
|
|
541
|
+
module: string;
|
|
542
|
+
export: string;
|
|
543
|
+
options?: Record<string, unknown> | undefined;
|
|
544
|
+
env?: Record<string, string> | undefined;
|
|
545
|
+
}> | undefined;
|
|
446
546
|
ui?: {
|
|
447
547
|
apiVersion: "1";
|
|
448
548
|
renderers: Record<string, {
|
|
@@ -460,15 +560,22 @@ export declare const PluginManifest: z.ZodEffects<z.ZodObject<{
|
|
|
460
560
|
resource: "project_data" | "secrets" | "network";
|
|
461
561
|
access: "read" | "write" | "outbound";
|
|
462
562
|
}[];
|
|
563
|
+
source?: {
|
|
564
|
+
kind: "plugin";
|
|
565
|
+
} | {
|
|
566
|
+
package: string;
|
|
567
|
+
kind: "npm";
|
|
568
|
+
version: string;
|
|
569
|
+
} | undefined;
|
|
463
570
|
integration?: {
|
|
464
571
|
tags: string[];
|
|
465
|
-
auth?: string[] | undefined;
|
|
466
|
-
category?: string | undefined;
|
|
467
572
|
npm?: {
|
|
468
573
|
package: string;
|
|
469
574
|
version: string;
|
|
470
575
|
spec: string;
|
|
471
576
|
} | undefined;
|
|
577
|
+
auth?: string[] | undefined;
|
|
578
|
+
category?: string | undefined;
|
|
472
579
|
} | undefined;
|
|
473
580
|
description?: string | undefined;
|
|
474
581
|
icon?: "function" | "group" | "workflow" | "code" | "type" | "typescript" | "variable" | "webhook" | "filter" | "replace" | "search" | "split" | "repeat" | "arrow-up-down" | "binary" | "bomb" | "boxes" | "braces" | "calculator" | "calendar" | "camera" | "clock" | "copy-x" | "database" | "dices" | "flag" | "flask" | "git-branch" | "git-merge" | "hook" | "list-filter" | "merge" | "octagon-x" | "package" | "package-x" | "pencil" | "play" | "regex" | "ruler" | "scan-eye" | "scissors" | "server-cog" | "settings" | "sigma" | "terminal" | "test-tube" | "text-cursor-input" | "ticket" | "truck" | "ungroup" | "wand" | "wave" | "x" | undefined;
|
|
@@ -503,6 +610,12 @@ export declare const PluginManifest: z.ZodEffects<z.ZodObject<{
|
|
|
503
610
|
icon?: "function" | "group" | "workflow" | "code" | "type" | "typescript" | "variable" | "webhook" | "filter" | "replace" | "search" | "split" | "repeat" | "arrow-up-down" | "binary" | "bomb" | "boxes" | "braces" | "calculator" | "calendar" | "camera" | "clock" | "copy-x" | "database" | "dices" | "flag" | "flask" | "git-branch" | "git-merge" | "hook" | "list-filter" | "merge" | "octagon-x" | "package" | "package-x" | "pencil" | "play" | "regex" | "ruler" | "scan-eye" | "scissors" | "server-cog" | "settings" | "sigma" | "terminal" | "test-tube" | "text-cursor-input" | "ticket" | "truck" | "ungroup" | "wand" | "wave" | "x" | undefined;
|
|
504
611
|
trigger?: boolean | undefined;
|
|
505
612
|
connections?: string[] | undefined;
|
|
613
|
+
bindings?: Record<string, {
|
|
614
|
+
module: string;
|
|
615
|
+
export: string;
|
|
616
|
+
options?: Record<string, unknown> | undefined;
|
|
617
|
+
env?: Record<string, string> | undefined;
|
|
618
|
+
}> | undefined;
|
|
506
619
|
ui?: {
|
|
507
620
|
apiVersion: "1";
|
|
508
621
|
renderers: Record<string, {
|
|
@@ -511,15 +624,22 @@ export declare const PluginManifest: z.ZodEffects<z.ZodObject<{
|
|
|
511
624
|
}>;
|
|
512
625
|
} | undefined;
|
|
513
626
|
}[] | undefined;
|
|
627
|
+
source?: {
|
|
628
|
+
kind: "plugin";
|
|
629
|
+
} | {
|
|
630
|
+
package: string;
|
|
631
|
+
kind: "npm";
|
|
632
|
+
version: string;
|
|
633
|
+
} | undefined;
|
|
514
634
|
integration?: {
|
|
515
|
-
auth?: string[] | undefined;
|
|
516
|
-
category?: string | undefined;
|
|
517
|
-
tags?: string[] | undefined;
|
|
518
635
|
npm?: {
|
|
519
636
|
package: string;
|
|
520
637
|
version: string;
|
|
521
638
|
spec: string;
|
|
522
639
|
} | undefined;
|
|
640
|
+
auth?: string[] | undefined;
|
|
641
|
+
category?: string | undefined;
|
|
642
|
+
tags?: string[] | undefined;
|
|
523
643
|
} | undefined;
|
|
524
644
|
scope?: ("user" | "group" | "org" | "public")[] | undefined;
|
|
525
645
|
description?: string | undefined;
|
|
@@ -557,6 +677,12 @@ export declare const PluginManifest: z.ZodEffects<z.ZodObject<{
|
|
|
557
677
|
icon?: "function" | "group" | "workflow" | "code" | "type" | "typescript" | "variable" | "webhook" | "filter" | "replace" | "search" | "split" | "repeat" | "arrow-up-down" | "binary" | "bomb" | "boxes" | "braces" | "calculator" | "calendar" | "camera" | "clock" | "copy-x" | "database" | "dices" | "flag" | "flask" | "git-branch" | "git-merge" | "hook" | "list-filter" | "merge" | "octagon-x" | "package" | "package-x" | "pencil" | "play" | "regex" | "ruler" | "scan-eye" | "scissors" | "server-cog" | "settings" | "sigma" | "terminal" | "test-tube" | "text-cursor-input" | "ticket" | "truck" | "ungroup" | "wand" | "wave" | "x" | undefined;
|
|
558
678
|
trigger?: boolean | undefined;
|
|
559
679
|
connections?: string[] | undefined;
|
|
680
|
+
bindings?: Record<string, {
|
|
681
|
+
module: string;
|
|
682
|
+
export: string;
|
|
683
|
+
options?: Record<string, unknown> | undefined;
|
|
684
|
+
env?: Record<string, string> | undefined;
|
|
685
|
+
}> | undefined;
|
|
560
686
|
ui?: {
|
|
561
687
|
apiVersion: "1";
|
|
562
688
|
renderers: Record<string, {
|
|
@@ -574,15 +700,22 @@ export declare const PluginManifest: z.ZodEffects<z.ZodObject<{
|
|
|
574
700
|
resource: "project_data" | "secrets" | "network";
|
|
575
701
|
access: "read" | "write" | "outbound";
|
|
576
702
|
}[];
|
|
703
|
+
source?: {
|
|
704
|
+
kind: "plugin";
|
|
705
|
+
} | {
|
|
706
|
+
package: string;
|
|
707
|
+
kind: "npm";
|
|
708
|
+
version: string;
|
|
709
|
+
} | undefined;
|
|
577
710
|
integration?: {
|
|
578
711
|
tags: string[];
|
|
579
|
-
auth?: string[] | undefined;
|
|
580
|
-
category?: string | undefined;
|
|
581
712
|
npm?: {
|
|
582
713
|
package: string;
|
|
583
714
|
version: string;
|
|
584
715
|
spec: string;
|
|
585
716
|
} | undefined;
|
|
717
|
+
auth?: string[] | undefined;
|
|
718
|
+
category?: string | undefined;
|
|
586
719
|
} | undefined;
|
|
587
720
|
description?: string | undefined;
|
|
588
721
|
icon?: "function" | "group" | "workflow" | "code" | "type" | "typescript" | "variable" | "webhook" | "filter" | "replace" | "search" | "split" | "repeat" | "arrow-up-down" | "binary" | "bomb" | "boxes" | "braces" | "calculator" | "calendar" | "camera" | "clock" | "copy-x" | "database" | "dices" | "flag" | "flask" | "git-branch" | "git-merge" | "hook" | "list-filter" | "merge" | "octagon-x" | "package" | "package-x" | "pencil" | "play" | "regex" | "ruler" | "scan-eye" | "scissors" | "server-cog" | "settings" | "sigma" | "terminal" | "test-tube" | "text-cursor-input" | "ticket" | "truck" | "ungroup" | "wand" | "wave" | "x" | undefined;
|
|
@@ -617,6 +750,12 @@ export declare const PluginManifest: z.ZodEffects<z.ZodObject<{
|
|
|
617
750
|
icon?: "function" | "group" | "workflow" | "code" | "type" | "typescript" | "variable" | "webhook" | "filter" | "replace" | "search" | "split" | "repeat" | "arrow-up-down" | "binary" | "bomb" | "boxes" | "braces" | "calculator" | "calendar" | "camera" | "clock" | "copy-x" | "database" | "dices" | "flag" | "flask" | "git-branch" | "git-merge" | "hook" | "list-filter" | "merge" | "octagon-x" | "package" | "package-x" | "pencil" | "play" | "regex" | "ruler" | "scan-eye" | "scissors" | "server-cog" | "settings" | "sigma" | "terminal" | "test-tube" | "text-cursor-input" | "ticket" | "truck" | "ungroup" | "wand" | "wave" | "x" | undefined;
|
|
618
751
|
trigger?: boolean | undefined;
|
|
619
752
|
connections?: string[] | undefined;
|
|
753
|
+
bindings?: Record<string, {
|
|
754
|
+
module: string;
|
|
755
|
+
export: string;
|
|
756
|
+
options?: Record<string, unknown> | undefined;
|
|
757
|
+
env?: Record<string, string> | undefined;
|
|
758
|
+
}> | undefined;
|
|
620
759
|
ui?: {
|
|
621
760
|
apiVersion: "1";
|
|
622
761
|
renderers: Record<string, {
|
|
@@ -625,15 +764,22 @@ export declare const PluginManifest: z.ZodEffects<z.ZodObject<{
|
|
|
625
764
|
}>;
|
|
626
765
|
} | undefined;
|
|
627
766
|
}[] | undefined;
|
|
767
|
+
source?: {
|
|
768
|
+
kind: "plugin";
|
|
769
|
+
} | {
|
|
770
|
+
package: string;
|
|
771
|
+
kind: "npm";
|
|
772
|
+
version: string;
|
|
773
|
+
} | undefined;
|
|
628
774
|
integration?: {
|
|
629
|
-
auth?: string[] | undefined;
|
|
630
|
-
category?: string | undefined;
|
|
631
|
-
tags?: string[] | undefined;
|
|
632
775
|
npm?: {
|
|
633
776
|
package: string;
|
|
634
777
|
version: string;
|
|
635
778
|
spec: string;
|
|
636
779
|
} | undefined;
|
|
780
|
+
auth?: string[] | undefined;
|
|
781
|
+
category?: string | undefined;
|
|
782
|
+
tags?: string[] | undefined;
|
|
637
783
|
} | undefined;
|
|
638
784
|
scope?: ("user" | "group" | "org" | "public")[] | undefined;
|
|
639
785
|
description?: string | undefined;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../../../src/plugins/schema/plugin.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAKxB;;;;GAIG;AACH,eAAO,MAAM,WAAW,+CAA6C,CAAC;AACtE,MAAM,MAAM,WAAW,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,WAAW,CAAC,CAAC;AAEtD,eAAO,MAAM,cAAc,sCAAoC,CAAC;AAChE,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;AAC5D,eAAO,MAAM,0BAA0B,QAAa,CAAC;AAerD,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAed,CAAC;AACZ,MAAM,MAAM,YAAY,GAAG,CA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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA2I/E,CAAC;AACL,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;AAC5D,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.PluginManifest = exports.PluginConnection = exports.PluginIntegration = exports.PluginPermission = exports.PluginNode = exports.PluginNodeUi = exports.PLUGIN_UI_BUNDLE_MAX_BYTES = exports.PluginUiTarget = exports.PluginScope = void 0;
|
|
3
|
+
exports.PluginManifest = exports.PluginConnection = exports.PluginIntegration = exports.PluginPermission = exports.PluginNode = exports.NpmClientBinding = exports.PluginNodeUi = exports.PLUGIN_UI_BUNDLE_MAX_BYTES = exports.PluginUiTarget = exports.PluginScope = void 0;
|
|
4
4
|
// Generated from packages/schema/src/plugin.ts. Do not edit; run the Octonode SDK sync.
|
|
5
5
|
const zod_1 = require("zod");
|
|
6
6
|
const ipc_envelope_1 = require("./ipc-envelope");
|
|
@@ -35,6 +35,23 @@ exports.PluginNodeUi = zod_1.z
|
|
|
35
35
|
.refine((renderers) => Object.keys(renderers).length > 0, "UI needs at least one renderer"),
|
|
36
36
|
})
|
|
37
37
|
.strict();
|
|
38
|
+
/** Build an upstream SDK client from connection fields, never from public node inputs. */
|
|
39
|
+
exports.NpmClientBinding = zod_1.z
|
|
40
|
+
.object({
|
|
41
|
+
module: zod_1.z
|
|
42
|
+
.string()
|
|
43
|
+
.regex(/^(@[a-z0-9~._-]+\/)?[a-z0-9~._-]+(?:\/[a-zA-Z0-9~._-]+)*$/)
|
|
44
|
+
.refine((value) => !value.split("/").some((part) => part === "." || part === ".."), "Unsafe npm module path"),
|
|
45
|
+
export: zod_1.z.string().regex(/^[$A-Z_a-z][$\w]*$/),
|
|
46
|
+
options: zod_1.z.record(zod_1.z.unknown()).optional(),
|
|
47
|
+
env: zod_1.z
|
|
48
|
+
.record(zod_1.z
|
|
49
|
+
.string()
|
|
50
|
+
.regex(/^[A-Za-z_$][\w$]*(?:\.[A-Za-z_$][\w$]*)*$/)
|
|
51
|
+
.refine((path) => !path.split(".").some((key) => ["__proto__", "prototype", "constructor"].includes(key)), "Unsafe option path"), zod_1.z.string().regex(/^[A-Z_][A-Z0-9_]*$/))
|
|
52
|
+
.optional(),
|
|
53
|
+
})
|
|
54
|
+
.strict();
|
|
38
55
|
/**
|
|
39
56
|
* One node contributed by a plugin. Unlike a project node (whose signature is
|
|
40
57
|
* discovered by `octonode scan`), a plugin node declares its contract directly
|
|
@@ -57,6 +74,7 @@ exports.PluginNode = zod_1.z.object({
|
|
|
57
74
|
env: zod_1.z.array(zod_1.z.string()).optional(),
|
|
58
75
|
connections: zod_1.z.array(zod_1.z.string().min(1)).optional(),
|
|
59
76
|
defaults: zod_1.z.record(zod_1.z.unknown()).optional(),
|
|
77
|
+
bindings: zod_1.z.record(zod_1.z.string().regex(/^[A-Za-z_$][\w$]*$/), exports.NpmClientBinding).optional(),
|
|
60
78
|
ui: exports.PluginNodeUi.optional(),
|
|
61
79
|
});
|
|
62
80
|
/**
|
|
@@ -106,6 +124,19 @@ exports.PluginManifest = zod_1.z
|
|
|
106
124
|
name: zod_1.z.string(),
|
|
107
125
|
version: zod_1.z.string(),
|
|
108
126
|
description: zod_1.z.string().optional(),
|
|
127
|
+
/** Implementation authority; absent on legacy artifacts. */
|
|
128
|
+
source: zod_1.z
|
|
129
|
+
.discriminatedUnion("kind", [
|
|
130
|
+
zod_1.z.object({ kind: zod_1.z.literal("plugin") }).strict(),
|
|
131
|
+
zod_1.z
|
|
132
|
+
.object({
|
|
133
|
+
kind: zod_1.z.literal("npm"),
|
|
134
|
+
package: zod_1.z.string().regex(/^(@[a-z0-9~._-]+\/)?[a-z0-9~._-]+$/),
|
|
135
|
+
version: zod_1.z.string().regex(/^\d+\.\d+\.\d+(?:-[0-9A-Za-z.-]+)?(?:\+[0-9A-Za-z.-]+)?$/),
|
|
136
|
+
})
|
|
137
|
+
.strict(),
|
|
138
|
+
])
|
|
139
|
+
.optional(),
|
|
109
140
|
icon: icons_1.IconName.optional(),
|
|
110
141
|
author: zod_1.z.string().optional(),
|
|
111
142
|
homepage: zod_1.z.string().optional(),
|
|
@@ -119,11 +150,32 @@ exports.PluginManifest = zod_1.z
|
|
|
119
150
|
nodes: zod_1.z.array(exports.PluginNode).default([]),
|
|
120
151
|
})
|
|
121
152
|
.superRefine((manifest, ctx) => {
|
|
153
|
+
const npm = manifest.integration?.npm;
|
|
154
|
+
if ((manifest.source?.kind === "plugin" && npm) ||
|
|
155
|
+
(manifest.source?.kind === "npm" &&
|
|
156
|
+
(npm?.package !== manifest.source.package || npm?.version !== manifest.source.version)))
|
|
157
|
+
ctx.addIssue({ code: "custom", path: ["source"], message: "source authority must match integration.npm" });
|
|
122
158
|
const ids = new Set();
|
|
123
159
|
manifest.nodes.forEach((node, index) => {
|
|
124
160
|
if (ids.has(node.id))
|
|
125
161
|
ctx.addIssue({ code: "custom", path: ["nodes", index, "id"], message: "node IDs must be unique" });
|
|
126
162
|
ids.add(node.id);
|
|
163
|
+
for (const binding of Object.values(node.bindings ?? {})) {
|
|
164
|
+
if (!npm || (binding.module !== npm.package && !binding.module.startsWith(`${npm.package}/`)))
|
|
165
|
+
ctx.addIssue({
|
|
166
|
+
code: "custom",
|
|
167
|
+
path: ["nodes", index, "bindings"],
|
|
168
|
+
message: "SDK factories must belong to the original npm package",
|
|
169
|
+
});
|
|
170
|
+
const credentialFields = new Set((node.connections ?? []).flatMap((name) => Object.keys(manifest.connections?.[name]?.fields ?? {})));
|
|
171
|
+
for (const name of Object.values(binding.env ?? {}))
|
|
172
|
+
if (!credentialFields.has(name))
|
|
173
|
+
ctx.addIssue({
|
|
174
|
+
code: "custom",
|
|
175
|
+
path: ["nodes", index, "bindings"],
|
|
176
|
+
message: `SDK binding requires connection field "${name}"`,
|
|
177
|
+
});
|
|
178
|
+
}
|
|
127
179
|
for (const connection of node.connections ?? []) {
|
|
128
180
|
if (!Object.hasOwn(manifest.connections ?? {}, connection))
|
|
129
181
|
ctx.addIssue({
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"plugin.js","sourceRoot":"","sources":["../../../src/plugins/schema/plugin.ts"],"names":[],"mappings":";;;AAAA,wFAAwF;AACxF,6BAAwB;AACxB,iDAA4C;AAC5C,mCAAmC;AACnC,2CAAoD;AAEpD;;;;GAIG;AACU,QAAA,WAAW,GAAG,OAAC,CAAC,IAAI,CAAC,CAAC,MAAM,EAAE,OAAO,EAAE,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC;AAGzD,QAAA,cAAc,GAAG,OAAC,CAAC,IAAI,CAAC,CAAC,uBAAuB,CAAC,CAAC,CAAC;AAEnD,QAAA,0BAA0B,GAAG,GAAG,GAAG,IAAI,CAAC;AAErD,MAAM,aAAa,GAAG,OAAC;KACpB,MAAM,EAAE;KACR,GAAG,CAAC,CAAC,CAAC;KACN,GAAG,CAAC,KAAK,CAAC;KACV,MAAM,CACL,CAAC,KAAK,EAAE,EAAE,CACR,CAAC,KAAK,CAAC,UAAU,CAAC,GAAG,CAAC;IACtB,CAAC,KAAK,CAAC,QAAQ,CAAC,IAAI,CAAC;IACrB,CAAC,KAAK,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,QAAQ,CAAC,IAAI,CAAC;IAChC,iBAAiB,CAAC,IAAI,CAAC,KAAK,CAAC,EAC/B,gEAAgE,CACjE,CAAC;AAES,QAAA,YAAY,GAAG,OAAC;KAC1B,MAAM,CAAC;IACN,UAAU,EAAE,OAAC,CAAC,OAAO,CAAC,GAAG,CAAC;IAC1B,SAAS,EAAE,OAAC;SACT,MAAM,CAC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EAAE,CAAC,OAAO,EAAE,KAAK,EAAE,aAAa,CAAC;oBACrC,OAAO,EAAE,uBAAuB,UAAU,GAAG;iBAC9C,CAAC,CAAC;QACP,CAAC;IACH,CAAC,CAAC,CAAC;IACH,IACE,MAAM,CAAC,IAAI,CAAC,QAAQ,CAAC,WAAW,IAAI,EAAE,CAAC,CAAC,MAAM;QAC9C,CAAC,QAAQ,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC,UAAU,EAAE,EAAE,CAAC,UAAU,CAAC,QAAQ,KAAK,SAAS,IAAI,UAAU,CAAC,MAAM,KAAK,MAAM,CAAC;QAE7G,GAAG,CAAC,QAAQ,CAAC;YACX,IAAI,EAAE,QAAQ;YACd,IAAI,EAAE,CAAC,aAAa,CAAC;YACrB,OAAO,EAAE,wDAAwD;SAClE,CAAC,CAAC;AACP,CAAC,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"catalog.d.ts","sourceRoot":"","sources":["../../../../../src/plugins/sdk/definitions/compiler/catalog.ts"],"names":[],"mappings":"AAOA,kFAAkF;AAClF,wBAAgB,mBAAmB,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,SAAS,MAAM,EAAE,EAAE,KAAK,UAAQ,GAAG,MAAM,CAyFlG"}
|
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
+
var ownKeys = function(o) {
|
|
20
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
+
var ar = [];
|
|
22
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
+
return ar;
|
|
24
|
+
};
|
|
25
|
+
return ownKeys(o);
|
|
26
|
+
};
|
|
27
|
+
return function (mod) {
|
|
28
|
+
if (mod && mod.__esModule) return mod;
|
|
29
|
+
var result = {};
|
|
30
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
+
__setModuleDefault(result, mod);
|
|
32
|
+
return result;
|
|
33
|
+
};
|
|
34
|
+
})();
|
|
35
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
|
+
exports.generateNodeCatalog = generateNodeCatalog;
|
|
37
|
+
// Generated from packages/plugin-runtime/src/definitions/compiler/catalog.ts. Do not edit; run the Octonode SDK sync.
|
|
38
|
+
const ts = __importStar(require("typescript"));
|
|
39
|
+
const node_fs_1 = require("node:fs");
|
|
40
|
+
const node_path_1 = require("node:path");
|
|
41
|
+
const node_crypto_1 = require("node:crypto");
|
|
42
|
+
const constants_1 = require("./constants");
|
|
43
|
+
/** Discovery is static: importing application modules would execute user code. */
|
|
44
|
+
function generateNodeCatalog(root, files, check = false) {
|
|
45
|
+
root = (0, node_fs_1.realpathSync)(root);
|
|
46
|
+
const inventory = (0, node_path_1.resolve)(root, constants_1.NODES_FILENAME);
|
|
47
|
+
if ((0, node_fs_1.existsSync)(inventory)) {
|
|
48
|
+
if ((0, node_fs_1.realpathSync)(inventory) !== inventory)
|
|
49
|
+
throw new Error(`${constants_1.NODES_FILENAME} must not be a symlink`);
|
|
50
|
+
const current = (0, node_fs_1.readFileSync)(inventory, "utf8");
|
|
51
|
+
const prefix = ["// Generated npm inventory: ", "// Generated workflow inventory: "].find((prefix) => current.startsWith(prefix));
|
|
52
|
+
if (prefix) {
|
|
53
|
+
const newline = current.indexOf("\n");
|
|
54
|
+
const body = current.slice(newline + 1);
|
|
55
|
+
if (current.slice(prefix.length, newline) !== (0, node_crypto_1.createHash)("sha256").update(body).digest("hex"))
|
|
56
|
+
throw new Error(`${constants_1.NODES_FILENAME} was edited; regenerate from the original package or workflow`);
|
|
57
|
+
return current;
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
const configPath = (0, node_fs_1.existsSync)((0, node_path_1.resolve)(root, "tsconfig.json")) ? (0, node_path_1.resolve)(root, "tsconfig.json") : undefined;
|
|
61
|
+
const config = configPath ? ts.readConfigFile(configPath, ts.sys.readFile) : { config: {} };
|
|
62
|
+
if (config.error)
|
|
63
|
+
throw new Error(ts.flattenDiagnosticMessageText(config.error.messageText, "\n"));
|
|
64
|
+
const parsed = ts.parseJsonConfigFileContent(config.config, ts.sys, root);
|
|
65
|
+
const error = parsed.errors.find((error) => error.code !== 18003);
|
|
66
|
+
if (error)
|
|
67
|
+
throw new Error(ts.flattenDiagnosticMessageText(error.messageText, "\n"));
|
|
68
|
+
const paths = (files ?? parsed.fileNames)
|
|
69
|
+
.map((file) => (0, node_path_1.resolve)(root, file))
|
|
70
|
+
.filter((file) => {
|
|
71
|
+
const path = (0, node_path_1.relative)(root, file).replaceAll("\\", "/");
|
|
72
|
+
return (!path.startsWith("../") &&
|
|
73
|
+
!path.split("/").some((part) => part === "node_modules" || part === "dist" || part.startsWith(".")) &&
|
|
74
|
+
!constants_1.DEFINITION_FILES.includes(path) &&
|
|
75
|
+
!/\.d\.[cm]?ts$/.test(path) &&
|
|
76
|
+
/\.[cm]?ts$/.test(path));
|
|
77
|
+
})
|
|
78
|
+
.sort();
|
|
79
|
+
// Inventory needs callable export identities only; definition compilation checks full types.
|
|
80
|
+
const program = ts.createProgram(paths, {
|
|
81
|
+
...parsed.options,
|
|
82
|
+
noEmit: true,
|
|
83
|
+
noLib: true,
|
|
84
|
+
noResolve: true,
|
|
85
|
+
types: [],
|
|
86
|
+
skipLibCheck: true,
|
|
87
|
+
});
|
|
88
|
+
const checker = program.getTypeChecker();
|
|
89
|
+
const entries = [];
|
|
90
|
+
for (const path of paths) {
|
|
91
|
+
const source = program.getSourceFile(path);
|
|
92
|
+
const module = source && checker.getSymbolAtLocation(source);
|
|
93
|
+
if (!module)
|
|
94
|
+
continue;
|
|
95
|
+
for (const exported of checker.getExportsOfModule(module).sort((a, b) => a.name.localeCompare(b.name))) {
|
|
96
|
+
const symbol = exported.flags & ts.SymbolFlags.Alias ? checker.getAliasedSymbol(exported) : exported;
|
|
97
|
+
const declaration = symbol.valueDeclaration;
|
|
98
|
+
if (!declaration || (0, node_path_1.resolve)(declaration.getSourceFile().fileName) !== path)
|
|
99
|
+
continue;
|
|
100
|
+
if (!checker.getTypeOfSymbolAtLocation(symbol, declaration).getCallSignatures().length)
|
|
101
|
+
continue;
|
|
102
|
+
entries.push({ path: (0, node_path_1.relative)(root, path).replaceAll("\\", "/"), name: exported.name });
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
const counts = new Map();
|
|
106
|
+
for (const entry of entries)
|
|
107
|
+
counts.set(entry.name, (counts.get(entry.name) ?? 0) + 1);
|
|
108
|
+
const key = (entry) => counts.get(entry.name) === 1
|
|
109
|
+
? entry.name
|
|
110
|
+
: `${entry.name}_${(0, node_crypto_1.createHash)("sha256").update(entry.path).digest("hex").slice(0, 8)}`;
|
|
111
|
+
const text = "// Generated by Octonode. Do not edit.\n" +
|
|
112
|
+
entries
|
|
113
|
+
.map((entry, index) => `import { ${entry.name} as node${index} } from ${JSON.stringify("./" +
|
|
114
|
+
entry.path
|
|
115
|
+
.replace(/\.ts$/, ".js")
|
|
116
|
+
.replace(/\.mts$/, ".mjs")
|
|
117
|
+
.replace(/\.cts$/, ".cjs"))};`)
|
|
118
|
+
.join("\n") +
|
|
119
|
+
"\nexport const nodes = {\n" +
|
|
120
|
+
entries.map((entry, index) => ` ${JSON.stringify(key(entry))}: node${index},`).join("\n") +
|
|
121
|
+
"\n} as const;\n";
|
|
122
|
+
const output = (0, node_path_1.resolve)(root, constants_1.NODES_FILENAME);
|
|
123
|
+
if ((0, node_fs_1.existsSync)(output) && (0, node_fs_1.realpathSync)(output) !== output)
|
|
124
|
+
throw new Error(`${constants_1.NODES_FILENAME} must not be a symlink`);
|
|
125
|
+
if (check) {
|
|
126
|
+
if (!(0, node_fs_1.existsSync)(output) || (0, node_fs_1.readFileSync)(output, "utf8") !== text)
|
|
127
|
+
throw new Error(`${constants_1.NODES_FILENAME} is stale; regenerate the node inventory`);
|
|
128
|
+
}
|
|
129
|
+
else if (!(0, node_fs_1.existsSync)(output) || (0, node_fs_1.readFileSync)(output, "utf8") !== text)
|
|
130
|
+
(0, node_fs_1.writeFileSync)(output, text);
|
|
131
|
+
return text;
|
|
132
|
+
}
|
|
133
|
+
//# sourceMappingURL=catalog.js.map
|