@octonodes/sdk 0.0.3 → 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.
Files changed (129) hide show
  1. package/PLUGINS.md +265 -0
  2. package/README.md +107 -9
  3. package/dist/constants.d.ts +1 -0
  4. package/dist/constants.d.ts.map +1 -1
  5. package/dist/constants.js +2 -1
  6. package/dist/constants.js.map +1 -1
  7. package/dist/gen/index.d.ts +2 -2
  8. package/dist/gen/index.d.ts.map +1 -1
  9. package/dist/gen/index.js +4 -3
  10. package/dist/gen/index.js.map +1 -1
  11. package/dist/gen/sdk.gen.d.ts +9 -1
  12. package/dist/gen/sdk.gen.d.ts.map +1 -1
  13. package/dist/gen/sdk.gen.js +21 -3
  14. package/dist/gen/sdk.gen.js.map +1 -1
  15. package/dist/gen/types.gen.d.ts +379 -1
  16. package/dist/gen/types.gen.d.ts.map +1 -1
  17. package/dist/index.d.ts +1 -1
  18. package/dist/index.d.ts.map +1 -1
  19. package/dist/index.js +2 -1
  20. package/dist/index.js.map +1 -1
  21. package/dist/plugins/index.d.ts +2 -0
  22. package/dist/plugins/index.d.ts.map +1 -0
  23. package/dist/plugins/index.js +19 -0
  24. package/dist/plugins/index.js.map +1 -0
  25. package/dist/plugins/schema/constants.d.ts +33 -0
  26. package/dist/plugins/schema/constants.d.ts.map +1 -0
  27. package/dist/plugins/schema/constants.js +207 -0
  28. package/dist/plugins/schema/constants.js.map +1 -0
  29. package/dist/plugins/schema/icons.d.ts +5 -0
  30. package/dist/plugins/schema/icons.d.ts.map +1 -0
  31. package/dist/plugins/schema/icons.js +62 -0
  32. package/dist/plugins/schema/icons.js.map +1 -0
  33. package/dist/plugins/schema/ipc-envelope.d.ts +923 -0
  34. package/dist/plugins/schema/ipc-envelope.d.ts.map +1 -0
  35. package/dist/plugins/schema/ipc-envelope.js +210 -0
  36. package/dist/plugins/schema/ipc-envelope.js.map +1 -0
  37. package/dist/plugins/schema/plugin-sdk/index.d.ts +5 -0
  38. package/dist/plugins/schema/plugin-sdk/index.d.ts.map +1 -0
  39. package/dist/plugins/schema/plugin-sdk/index.js +25 -0
  40. package/dist/plugins/schema/plugin-sdk/index.js.map +1 -0
  41. package/dist/plugins/schema/plugin.d.ts +808 -0
  42. package/dist/plugins/schema/plugin.d.ts.map +1 -0
  43. package/dist/plugins/schema/plugin.js +196 -0
  44. package/dist/plugins/schema/plugin.js.map +1 -0
  45. package/dist/plugins/sdk/define-node.d.ts +103 -0
  46. package/dist/plugins/sdk/define-node.d.ts.map +1 -0
  47. package/dist/plugins/sdk/define-node.js +58 -0
  48. package/dist/plugins/sdk/define-node.js.map +1 -0
  49. package/dist/plugins/sdk/definitions/compiler/catalog.d.ts +3 -0
  50. package/dist/plugins/sdk/definitions/compiler/catalog.d.ts.map +1 -0
  51. package/dist/plugins/sdk/definitions/compiler/catalog.js +133 -0
  52. package/dist/plugins/sdk/definitions/compiler/catalog.js.map +1 -0
  53. package/dist/plugins/sdk/definitions/compiler/constants.d.ts +6 -0
  54. package/dist/plugins/sdk/definitions/compiler/constants.d.ts.map +1 -0
  55. package/dist/plugins/sdk/definitions/compiler/constants.js +10 -0
  56. package/dist/plugins/sdk/definitions/compiler/constants.js.map +1 -0
  57. package/dist/plugins/sdk/definitions/compiler/index.d.ts +7 -0
  58. package/dist/plugins/sdk/definitions/compiler/index.d.ts.map +1 -0
  59. package/dist/plugins/sdk/definitions/compiler/index.js +411 -0
  60. package/dist/plugins/sdk/definitions/compiler/index.js.map +1 -0
  61. package/dist/plugins/sdk/definitions/compiler/literals.d.ts +5 -0
  62. package/dist/plugins/sdk/definitions/compiler/literals.d.ts.map +1 -0
  63. package/dist/plugins/sdk/definitions/compiler/literals.js +78 -0
  64. package/dist/plugins/sdk/definitions/compiler/literals.js.map +1 -0
  65. package/dist/plugins/sdk/definitions/compiler/schemas.d.ts +4 -0
  66. package/dist/plugins/sdk/definitions/compiler/schemas.d.ts.map +1 -0
  67. package/dist/plugins/sdk/definitions/compiler/schemas.js +95 -0
  68. package/dist/plugins/sdk/definitions/compiler/schemas.js.map +1 -0
  69. package/dist/plugins/sdk/definitions/compiler/types.d.ts +20 -0
  70. package/dist/plugins/sdk/definitions/compiler/types.d.ts.map +1 -0
  71. package/dist/plugins/sdk/definitions/compiler/types.js +3 -0
  72. package/dist/plugins/sdk/definitions/compiler/types.js.map +1 -0
  73. package/dist/plugins/sdk/definitions/index.d.ts +7 -0
  74. package/dist/plugins/sdk/definitions/index.d.ts.map +1 -0
  75. package/dist/plugins/sdk/definitions/index.js +16 -0
  76. package/dist/plugins/sdk/definitions/index.js.map +1 -0
  77. package/dist/plugins/sdk/definitions/npm/emit/js.d.ts +4 -0
  78. package/dist/plugins/sdk/definitions/npm/emit/js.d.ts.map +1 -0
  79. package/dist/plugins/sdk/definitions/npm/emit/js.js +190 -0
  80. package/dist/plugins/sdk/definitions/npm/emit/js.js.map +1 -0
  81. package/dist/plugins/sdk/definitions/npm/types.d.ts +63 -0
  82. package/dist/plugins/sdk/definitions/npm/types.d.ts.map +1 -0
  83. package/dist/plugins/sdk/definitions/npm/types.js +3 -0
  84. package/dist/plugins/sdk/definitions/npm/types.js.map +1 -0
  85. package/dist/plugins/sdk/definitions/types.d.ts +43 -0
  86. package/dist/plugins/sdk/definitions/types.d.ts.map +1 -0
  87. package/dist/plugins/sdk/definitions/types.js +3 -0
  88. package/dist/plugins/sdk/definitions/types.js.map +1 -0
  89. package/dist/plugins/sdk/json-schema.d.ts +17 -0
  90. package/dist/plugins/sdk/json-schema.d.ts.map +1 -0
  91. package/dist/plugins/sdk/json-schema.js +79 -0
  92. package/dist/plugins/sdk/json-schema.js.map +1 -0
  93. package/dist/plugins/sdk/nodes/index.d.ts +5 -0
  94. package/dist/plugins/sdk/nodes/index.d.ts.map +1 -0
  95. package/dist/plugins/sdk/nodes/index.js +12 -0
  96. package/dist/plugins/sdk/nodes/index.js.map +1 -0
  97. package/dist/plugins/sdk/plugin/index.d.ts +3 -0
  98. package/dist/plugins/sdk/plugin/index.d.ts.map +1 -0
  99. package/dist/plugins/sdk/plugin/index.js +8 -0
  100. package/dist/plugins/sdk/plugin/index.js.map +1 -0
  101. package/dist/plugins/sdk/plugin.d.ts +7 -0
  102. package/dist/plugins/sdk/plugin.d.ts.map +1 -0
  103. package/dist/plugins/sdk/plugin.js +74 -0
  104. package/dist/plugins/sdk/plugin.js.map +1 -0
  105. package/dist/plugins/sdk/plugin.types.d.ts +15 -0
  106. package/dist/plugins/sdk/plugin.types.d.ts.map +1 -0
  107. package/dist/plugins/sdk/plugin.types.js +3 -0
  108. package/dist/plugins/sdk/plugin.types.js.map +1 -0
  109. package/dist/plugins/sdk/plugins/define-node.d.ts +29 -0
  110. package/dist/plugins/sdk/plugins/define-node.d.ts.map +1 -0
  111. package/dist/plugins/sdk/plugins/define-node.js +16 -0
  112. package/dist/plugins/sdk/plugins/define-node.js.map +1 -0
  113. package/dist/plugins/sdk/plugins/index.d.ts +10 -0
  114. package/dist/plugins/sdk/plugins/index.d.ts.map +1 -0
  115. package/dist/plugins/sdk/plugins/index.js +23 -0
  116. package/dist/plugins/sdk/plugins/index.js.map +1 -0
  117. package/dist/plugins/sdk/plugins/types.d.ts +34 -0
  118. package/dist/plugins/sdk/plugins/types.d.ts.map +1 -0
  119. package/dist/plugins/sdk/plugins/types.js +3 -0
  120. package/dist/plugins/sdk/plugins/types.js.map +1 -0
  121. package/dist/plugins/sdk/project/index.d.ts +5 -0
  122. package/dist/plugins/sdk/project/index.d.ts.map +1 -0
  123. package/dist/plugins/sdk/project/index.js +10 -0
  124. package/dist/plugins/sdk/project/index.js.map +1 -0
  125. package/dist/plugins/sdk/runner.d.ts +36 -0
  126. package/dist/plugins/sdk/runner.d.ts.map +1 -0
  127. package/dist/plugins/sdk/runner.js +324 -0
  128. package/dist/plugins/sdk/runner.js.map +1 -0
  129. package/package.json +65 -5
@@ -0,0 +1,923 @@
1
+ import { z } from "zod";
2
+ /**
3
+ * The IPC protocol version. Every envelope carries this in its `octonode`
4
+ * field so the wire format can evolve without ambiguity. Bump only on a
5
+ * breaking change to the envelope shape.
6
+ */
7
+ export declare const PROTOCOL_VERSION: "1";
8
+ /**
9
+ * A JSON Schema object, kept deliberately loose. It is the lowest common
10
+ * denominator every language can emit and validate against, which is what
11
+ * makes "a node in any language" tractable: contracts travel as plain JSON
12
+ * Schema, not as language-specific type objects.
13
+ */
14
+ export declare const JsonSchema: z.ZodRecord<z.ZodString, z.ZodUnknown>;
15
+ export type JsonSchema = Record<string, unknown>;
16
+ /**
17
+ * Structured error codes a node (or the engine) can report. `retryable` on the
18
+ * error object — not the code alone — is what the DAG executor consults in
19
+ * later phases, but the code gives callers a stable taxonomy.
20
+ */
21
+ export declare const ErrorCode: z.ZodEnum<["VALIDATION_ERROR", "RUNTIME_ERROR", "TIMEOUT", "NON_RETRYABLE"]>;
22
+ export type ErrorCode = z.infer<typeof ErrorCode>;
23
+ /**
24
+ * Per-invocation context handed to the node. In Phase 1/2 only `config`/`attempt`
25
+ * are meaningful; `runId`/`env`/`deadlineMs` are populated once the config and
26
+ * DAG layers land, but they are part of the contract from day one.
27
+ */
28
+ export declare const InvocationContext: z.ZodObject<{
29
+ runId: z.ZodOptional<z.ZodString>;
30
+ env: z.ZodOptional<z.ZodString>;
31
+ config: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
32
+ attempt: z.ZodDefault<z.ZodNumber>;
33
+ deadlineMs: z.ZodOptional<z.ZodNumber>;
34
+ }, "strip", z.ZodTypeAny, {
35
+ config: Record<string, unknown>;
36
+ attempt: number;
37
+ runId?: string | undefined;
38
+ env?: string | undefined;
39
+ deadlineMs?: number | undefined;
40
+ }, {
41
+ config?: Record<string, unknown> | undefined;
42
+ runId?: string | undefined;
43
+ env?: string | undefined;
44
+ attempt?: number | undefined;
45
+ deadlineMs?: number | undefined;
46
+ }>;
47
+ export type InvocationContext = z.infer<typeof InvocationContext>;
48
+ /** Engine → node: a request to execute the node with the given inputs. */
49
+ export declare const InvokeRequest: z.ZodObject<{
50
+ octonode: z.ZodLiteral<"1">;
51
+ type: z.ZodLiteral<"invoke">;
52
+ invocationId: z.ZodString;
53
+ /** Optional node id — useful once one process can host multiple nodes. */
54
+ node: z.ZodOptional<z.ZodString>;
55
+ inputs: z.ZodUnknown;
56
+ context: z.ZodDefault<z.ZodObject<{
57
+ runId: z.ZodOptional<z.ZodString>;
58
+ env: z.ZodOptional<z.ZodString>;
59
+ config: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
60
+ attempt: z.ZodDefault<z.ZodNumber>;
61
+ deadlineMs: z.ZodOptional<z.ZodNumber>;
62
+ }, "strip", z.ZodTypeAny, {
63
+ config: Record<string, unknown>;
64
+ attempt: number;
65
+ runId?: string | undefined;
66
+ env?: string | undefined;
67
+ deadlineMs?: number | undefined;
68
+ }, {
69
+ config?: Record<string, unknown> | undefined;
70
+ runId?: string | undefined;
71
+ env?: string | undefined;
72
+ attempt?: number | undefined;
73
+ deadlineMs?: number | undefined;
74
+ }>>;
75
+ }, "strip", z.ZodTypeAny, {
76
+ octonode: "1";
77
+ type: "invoke";
78
+ invocationId: string;
79
+ context: {
80
+ config: Record<string, unknown>;
81
+ attempt: number;
82
+ runId?: string | undefined;
83
+ env?: string | undefined;
84
+ deadlineMs?: number | undefined;
85
+ };
86
+ node?: string | undefined;
87
+ inputs?: unknown;
88
+ }, {
89
+ octonode: "1";
90
+ type: "invoke";
91
+ invocationId: string;
92
+ node?: string | undefined;
93
+ inputs?: unknown;
94
+ context?: {
95
+ config?: Record<string, unknown> | undefined;
96
+ runId?: string | undefined;
97
+ env?: string | undefined;
98
+ attempt?: number | undefined;
99
+ deadlineMs?: number | undefined;
100
+ } | undefined;
101
+ }>;
102
+ export type InvokeRequest = z.infer<typeof InvokeRequest>;
103
+ /**
104
+ * Engine → node: a request for the node to self-report its manifest instead of
105
+ * executing. This is the universal discovery mechanism — every language that
106
+ * can answer `describe` can be scanned into `.octonode`, no AST tooling needed.
107
+ */
108
+ export declare const DescribeRequest: z.ZodObject<{
109
+ octonode: z.ZodLiteral<"1">;
110
+ type: z.ZodLiteral<"describe">;
111
+ invocationId: z.ZodString;
112
+ node: z.ZodOptional<z.ZodString>;
113
+ }, "strip", z.ZodTypeAny, {
114
+ octonode: "1";
115
+ type: "describe";
116
+ invocationId: string;
117
+ node?: string | undefined;
118
+ }, {
119
+ octonode: "1";
120
+ type: "describe";
121
+ invocationId: string;
122
+ node?: string | undefined;
123
+ }>;
124
+ export type DescribeRequest = z.infer<typeof DescribeRequest>;
125
+ /** Any engine → node request. */
126
+ export declare const RequestEnvelope: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
127
+ octonode: z.ZodLiteral<"1">;
128
+ type: z.ZodLiteral<"invoke">;
129
+ invocationId: z.ZodString;
130
+ /** Optional node id — useful once one process can host multiple nodes. */
131
+ node: z.ZodOptional<z.ZodString>;
132
+ inputs: z.ZodUnknown;
133
+ context: z.ZodDefault<z.ZodObject<{
134
+ runId: z.ZodOptional<z.ZodString>;
135
+ env: z.ZodOptional<z.ZodString>;
136
+ config: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
137
+ attempt: z.ZodDefault<z.ZodNumber>;
138
+ deadlineMs: z.ZodOptional<z.ZodNumber>;
139
+ }, "strip", z.ZodTypeAny, {
140
+ config: Record<string, unknown>;
141
+ attempt: number;
142
+ runId?: string | undefined;
143
+ env?: string | undefined;
144
+ deadlineMs?: number | undefined;
145
+ }, {
146
+ config?: Record<string, unknown> | undefined;
147
+ runId?: string | undefined;
148
+ env?: string | undefined;
149
+ attempt?: number | undefined;
150
+ deadlineMs?: number | undefined;
151
+ }>>;
152
+ }, "strip", z.ZodTypeAny, {
153
+ octonode: "1";
154
+ type: "invoke";
155
+ invocationId: string;
156
+ context: {
157
+ config: Record<string, unknown>;
158
+ attempt: number;
159
+ runId?: string | undefined;
160
+ env?: string | undefined;
161
+ deadlineMs?: number | undefined;
162
+ };
163
+ node?: string | undefined;
164
+ inputs?: unknown;
165
+ }, {
166
+ octonode: "1";
167
+ type: "invoke";
168
+ invocationId: string;
169
+ node?: string | undefined;
170
+ inputs?: unknown;
171
+ context?: {
172
+ config?: Record<string, unknown> | undefined;
173
+ runId?: string | undefined;
174
+ env?: string | undefined;
175
+ attempt?: number | undefined;
176
+ deadlineMs?: number | undefined;
177
+ } | undefined;
178
+ }>, z.ZodObject<{
179
+ octonode: z.ZodLiteral<"1">;
180
+ type: z.ZodLiteral<"describe">;
181
+ invocationId: z.ZodString;
182
+ node: z.ZodOptional<z.ZodString>;
183
+ }, "strip", z.ZodTypeAny, {
184
+ octonode: "1";
185
+ type: "describe";
186
+ invocationId: string;
187
+ node?: string | undefined;
188
+ }, {
189
+ octonode: "1";
190
+ type: "describe";
191
+ invocationId: string;
192
+ node?: string | undefined;
193
+ }>]>;
194
+ export type RequestEnvelope = z.infer<typeof RequestEnvelope>;
195
+ /** Errors are data, not just exceptions — they cross the process boundary as JSON. */
196
+ export declare const NodeError: z.ZodObject<{
197
+ code: z.ZodEnum<["VALIDATION_ERROR", "RUNTIME_ERROR", "TIMEOUT", "NON_RETRYABLE"]>;
198
+ message: z.ZodString;
199
+ retryable: z.ZodDefault<z.ZodBoolean>;
200
+ details: z.ZodOptional<z.ZodUnknown>;
201
+ stack: z.ZodOptional<z.ZodString>;
202
+ }, "strip", z.ZodTypeAny, {
203
+ message: string;
204
+ code: "VALIDATION_ERROR" | "RUNTIME_ERROR" | "TIMEOUT" | "NON_RETRYABLE";
205
+ retryable: boolean;
206
+ details?: unknown;
207
+ stack?: string | undefined;
208
+ }, {
209
+ message: string;
210
+ code: "VALIDATION_ERROR" | "RUNTIME_ERROR" | "TIMEOUT" | "NON_RETRYABLE";
211
+ retryable?: boolean | undefined;
212
+ details?: unknown;
213
+ stack?: string | undefined;
214
+ }>;
215
+ export type NodeError = z.infer<typeof NodeError>;
216
+ declare const ResultOk: z.ZodObject<{
217
+ octonode: z.ZodLiteral<"1">;
218
+ type: z.ZodLiteral<"result">;
219
+ invocationId: z.ZodString;
220
+ status: z.ZodLiteral<"ok">;
221
+ outputs: z.ZodUnknown;
222
+ }, "strip", z.ZodTypeAny, {
223
+ octonode: "1";
224
+ type: "result";
225
+ status: "ok";
226
+ invocationId: string;
227
+ outputs?: unknown;
228
+ }, {
229
+ octonode: "1";
230
+ type: "result";
231
+ status: "ok";
232
+ invocationId: string;
233
+ outputs?: unknown;
234
+ }>;
235
+ declare const ResultErr: z.ZodObject<{
236
+ octonode: z.ZodLiteral<"1">;
237
+ type: z.ZodLiteral<"result">;
238
+ invocationId: z.ZodString;
239
+ status: z.ZodLiteral<"error">;
240
+ error: z.ZodObject<{
241
+ code: z.ZodEnum<["VALIDATION_ERROR", "RUNTIME_ERROR", "TIMEOUT", "NON_RETRYABLE"]>;
242
+ message: z.ZodString;
243
+ retryable: z.ZodDefault<z.ZodBoolean>;
244
+ details: z.ZodOptional<z.ZodUnknown>;
245
+ stack: z.ZodOptional<z.ZodString>;
246
+ }, "strip", z.ZodTypeAny, {
247
+ message: string;
248
+ code: "VALIDATION_ERROR" | "RUNTIME_ERROR" | "TIMEOUT" | "NON_RETRYABLE";
249
+ retryable: boolean;
250
+ details?: unknown;
251
+ stack?: string | undefined;
252
+ }, {
253
+ message: string;
254
+ code: "VALIDATION_ERROR" | "RUNTIME_ERROR" | "TIMEOUT" | "NON_RETRYABLE";
255
+ retryable?: boolean | undefined;
256
+ details?: unknown;
257
+ stack?: string | undefined;
258
+ }>;
259
+ }, "strip", z.ZodTypeAny, {
260
+ error: {
261
+ message: string;
262
+ code: "VALIDATION_ERROR" | "RUNTIME_ERROR" | "TIMEOUT" | "NON_RETRYABLE";
263
+ retryable: boolean;
264
+ details?: unknown;
265
+ stack?: string | undefined;
266
+ };
267
+ octonode: "1";
268
+ type: "result";
269
+ status: "error";
270
+ invocationId: string;
271
+ }, {
272
+ error: {
273
+ message: string;
274
+ code: "VALIDATION_ERROR" | "RUNTIME_ERROR" | "TIMEOUT" | "NON_RETRYABLE";
275
+ retryable?: boolean | undefined;
276
+ details?: unknown;
277
+ stack?: string | undefined;
278
+ };
279
+ octonode: "1";
280
+ type: "result";
281
+ status: "error";
282
+ invocationId: string;
283
+ }>;
284
+ /** Node → engine: the outcome of an invocation. */
285
+ export declare const ResultEnvelope: z.ZodDiscriminatedUnion<"status", [z.ZodObject<{
286
+ octonode: z.ZodLiteral<"1">;
287
+ type: z.ZodLiteral<"result">;
288
+ invocationId: z.ZodString;
289
+ status: z.ZodLiteral<"ok">;
290
+ outputs: z.ZodUnknown;
291
+ }, "strip", z.ZodTypeAny, {
292
+ octonode: "1";
293
+ type: "result";
294
+ status: "ok";
295
+ invocationId: string;
296
+ outputs?: unknown;
297
+ }, {
298
+ octonode: "1";
299
+ type: "result";
300
+ status: "ok";
301
+ invocationId: string;
302
+ outputs?: unknown;
303
+ }>, z.ZodObject<{
304
+ octonode: z.ZodLiteral<"1">;
305
+ type: z.ZodLiteral<"result">;
306
+ invocationId: z.ZodString;
307
+ status: z.ZodLiteral<"error">;
308
+ error: z.ZodObject<{
309
+ code: z.ZodEnum<["VALIDATION_ERROR", "RUNTIME_ERROR", "TIMEOUT", "NON_RETRYABLE"]>;
310
+ message: z.ZodString;
311
+ retryable: z.ZodDefault<z.ZodBoolean>;
312
+ details: z.ZodOptional<z.ZodUnknown>;
313
+ stack: z.ZodOptional<z.ZodString>;
314
+ }, "strip", z.ZodTypeAny, {
315
+ message: string;
316
+ code: "VALIDATION_ERROR" | "RUNTIME_ERROR" | "TIMEOUT" | "NON_RETRYABLE";
317
+ retryable: boolean;
318
+ details?: unknown;
319
+ stack?: string | undefined;
320
+ }, {
321
+ message: string;
322
+ code: "VALIDATION_ERROR" | "RUNTIME_ERROR" | "TIMEOUT" | "NON_RETRYABLE";
323
+ retryable?: boolean | undefined;
324
+ details?: unknown;
325
+ stack?: string | undefined;
326
+ }>;
327
+ }, "strip", z.ZodTypeAny, {
328
+ error: {
329
+ message: string;
330
+ code: "VALIDATION_ERROR" | "RUNTIME_ERROR" | "TIMEOUT" | "NON_RETRYABLE";
331
+ retryable: boolean;
332
+ details?: unknown;
333
+ stack?: string | undefined;
334
+ };
335
+ octonode: "1";
336
+ type: "result";
337
+ status: "error";
338
+ invocationId: string;
339
+ }, {
340
+ error: {
341
+ message: string;
342
+ code: "VALIDATION_ERROR" | "RUNTIME_ERROR" | "TIMEOUT" | "NON_RETRYABLE";
343
+ retryable?: boolean | undefined;
344
+ details?: unknown;
345
+ stack?: string | undefined;
346
+ };
347
+ octonode: "1";
348
+ type: "result";
349
+ status: "error";
350
+ invocationId: string;
351
+ }>]>;
352
+ export type ResultEnvelope = z.infer<typeof ResultEnvelope>;
353
+ export type OkResult = z.infer<typeof ResultOk>;
354
+ export type ErrorResult = z.infer<typeof ResultErr>;
355
+ /**
356
+ * What a node declares about itself: a stable id, its language, the JSON Schema
357
+ * for its inputs and outputs, and optional presentation/runtime seeds. This is
358
+ * the payload `octonode scan` collects (Phase 3) to populate `.octonode`.
359
+ */
360
+ export declare const NodeManifest: z.ZodObject<{
361
+ id: z.ZodString;
362
+ label: z.ZodOptional<z.ZodString>;
363
+ description: z.ZodOptional<z.ZodString>;
364
+ symbol: z.ZodOptional<z.ZodString>;
365
+ defaults: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
366
+ /** A workflow wrapper receives the current execution config through its invocation context. */
367
+ workflowId: z.ZodOptional<z.ZodString>;
368
+ language: z.ZodString;
369
+ inputs: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
370
+ outputs: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
371
+ /**
372
+ * What this node is: `function` (default), `class`, `service`, or `const`.
373
+ * Set by the setup-time SDK helpers (defineService/defineClass/defineConst)
374
+ * so `scan` writes it to `.octonode`.
375
+ */
376
+ kind: z.ZodOptional<z.ZodEnum<["function", "class", "service", "const"]>>;
377
+ /** Setup params for non-function kinds (constructor/config shape). */
378
+ setup: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
379
+ /** Advisory default icon — a one-time seed; config owns it thereafter. */
380
+ 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"]>>;
381
+ /** Advisory default config — a one-time seed; config owns it thereafter. */
382
+ config: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
383
+ /** Explicit service exposure. Plain classes never populate this field. */
384
+ service: z.ZodOptional<z.ZodObject<{
385
+ lifecycle: z.ZodEnum<["invocation", "workflow-run", "worker"]>;
386
+ methods: z.ZodArray<z.ZodObject<{
387
+ name: z.ZodString;
388
+ params: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
389
+ inputs: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
390
+ outputs: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
391
+ }, "strip", z.ZodTypeAny, {
392
+ name: string;
393
+ params: string[];
394
+ inputs?: Record<string, unknown> | undefined;
395
+ outputs?: Record<string, unknown> | undefined;
396
+ }, {
397
+ name: string;
398
+ params?: string[] | undefined;
399
+ inputs?: Record<string, unknown> | undefined;
400
+ outputs?: Record<string, unknown> | undefined;
401
+ }>, "many">;
402
+ }, "strip", z.ZodTypeAny, {
403
+ lifecycle: "invocation" | "workflow-run" | "worker";
404
+ methods: {
405
+ name: string;
406
+ params: string[];
407
+ inputs?: Record<string, unknown> | undefined;
408
+ outputs?: Record<string, unknown> | undefined;
409
+ }[];
410
+ }, {
411
+ lifecycle: "invocation" | "workflow-run" | "worker";
412
+ methods: {
413
+ name: string;
414
+ params?: string[] | undefined;
415
+ inputs?: Record<string, unknown> | undefined;
416
+ outputs?: Record<string, unknown> | undefined;
417
+ }[];
418
+ }>>;
419
+ }, "strip", z.ZodTypeAny, {
420
+ id: string;
421
+ language: string;
422
+ symbol?: string | undefined;
423
+ config?: Record<string, unknown> | undefined;
424
+ service?: {
425
+ lifecycle: "invocation" | "workflow-run" | "worker";
426
+ methods: {
427
+ name: string;
428
+ params: string[];
429
+ inputs?: Record<string, unknown> | undefined;
430
+ outputs?: Record<string, unknown> | undefined;
431
+ }[];
432
+ } | undefined;
433
+ label?: string | undefined;
434
+ workflowId?: string | undefined;
435
+ inputs?: Record<string, unknown> | undefined;
436
+ outputs?: Record<string, unknown> | undefined;
437
+ description?: string | undefined;
438
+ defaults?: Record<string, unknown> | undefined;
439
+ kind?: "function" | "class" | "service" | "const" | undefined;
440
+ setup?: Record<string, unknown> | undefined;
441
+ 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;
442
+ }, {
443
+ id: string;
444
+ language: string;
445
+ symbol?: string | undefined;
446
+ config?: Record<string, unknown> | undefined;
447
+ service?: {
448
+ lifecycle: "invocation" | "workflow-run" | "worker";
449
+ methods: {
450
+ name: string;
451
+ params?: string[] | undefined;
452
+ inputs?: Record<string, unknown> | undefined;
453
+ outputs?: Record<string, unknown> | undefined;
454
+ }[];
455
+ } | undefined;
456
+ label?: string | undefined;
457
+ workflowId?: string | undefined;
458
+ inputs?: Record<string, unknown> | undefined;
459
+ outputs?: Record<string, unknown> | undefined;
460
+ description?: string | undefined;
461
+ defaults?: Record<string, unknown> | undefined;
462
+ kind?: "function" | "class" | "service" | "const" | undefined;
463
+ setup?: Record<string, unknown> | undefined;
464
+ 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;
465
+ }>;
466
+ export type NodeManifest = z.infer<typeof NodeManifest>;
467
+ declare const ManifestOk: z.ZodObject<{
468
+ octonode: z.ZodLiteral<"1">;
469
+ type: z.ZodLiteral<"manifest">;
470
+ invocationId: z.ZodString;
471
+ status: z.ZodLiteral<"ok">;
472
+ manifest: z.ZodObject<{
473
+ id: z.ZodString;
474
+ label: z.ZodOptional<z.ZodString>;
475
+ description: z.ZodOptional<z.ZodString>;
476
+ symbol: z.ZodOptional<z.ZodString>;
477
+ defaults: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
478
+ /** A workflow wrapper receives the current execution config through its invocation context. */
479
+ workflowId: z.ZodOptional<z.ZodString>;
480
+ language: z.ZodString;
481
+ inputs: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
482
+ outputs: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
483
+ /**
484
+ * What this node is: `function` (default), `class`, `service`, or `const`.
485
+ * Set by the setup-time SDK helpers (defineService/defineClass/defineConst)
486
+ * so `scan` writes it to `.octonode`.
487
+ */
488
+ kind: z.ZodOptional<z.ZodEnum<["function", "class", "service", "const"]>>;
489
+ /** Setup params for non-function kinds (constructor/config shape). */
490
+ setup: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
491
+ /** Advisory default icon — a one-time seed; config owns it thereafter. */
492
+ 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"]>>;
493
+ /** Advisory default config — a one-time seed; config owns it thereafter. */
494
+ config: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
495
+ /** Explicit service exposure. Plain classes never populate this field. */
496
+ service: z.ZodOptional<z.ZodObject<{
497
+ lifecycle: z.ZodEnum<["invocation", "workflow-run", "worker"]>;
498
+ methods: z.ZodArray<z.ZodObject<{
499
+ name: z.ZodString;
500
+ params: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
501
+ inputs: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
502
+ outputs: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
503
+ }, "strip", z.ZodTypeAny, {
504
+ name: string;
505
+ params: string[];
506
+ inputs?: Record<string, unknown> | undefined;
507
+ outputs?: Record<string, unknown> | undefined;
508
+ }, {
509
+ name: string;
510
+ params?: string[] | undefined;
511
+ inputs?: Record<string, unknown> | undefined;
512
+ outputs?: Record<string, unknown> | undefined;
513
+ }>, "many">;
514
+ }, "strip", z.ZodTypeAny, {
515
+ lifecycle: "invocation" | "workflow-run" | "worker";
516
+ methods: {
517
+ name: string;
518
+ params: string[];
519
+ inputs?: Record<string, unknown> | undefined;
520
+ outputs?: Record<string, unknown> | undefined;
521
+ }[];
522
+ }, {
523
+ lifecycle: "invocation" | "workflow-run" | "worker";
524
+ methods: {
525
+ name: string;
526
+ params?: string[] | undefined;
527
+ inputs?: Record<string, unknown> | undefined;
528
+ outputs?: Record<string, unknown> | undefined;
529
+ }[];
530
+ }>>;
531
+ }, "strip", z.ZodTypeAny, {
532
+ id: string;
533
+ language: string;
534
+ symbol?: string | undefined;
535
+ config?: Record<string, unknown> | undefined;
536
+ service?: {
537
+ lifecycle: "invocation" | "workflow-run" | "worker";
538
+ methods: {
539
+ name: string;
540
+ params: string[];
541
+ inputs?: Record<string, unknown> | undefined;
542
+ outputs?: Record<string, unknown> | undefined;
543
+ }[];
544
+ } | undefined;
545
+ label?: string | undefined;
546
+ workflowId?: string | undefined;
547
+ inputs?: Record<string, unknown> | undefined;
548
+ outputs?: Record<string, unknown> | undefined;
549
+ description?: string | undefined;
550
+ defaults?: Record<string, unknown> | undefined;
551
+ kind?: "function" | "class" | "service" | "const" | undefined;
552
+ setup?: Record<string, unknown> | undefined;
553
+ 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;
554
+ }, {
555
+ id: string;
556
+ language: string;
557
+ symbol?: string | undefined;
558
+ config?: Record<string, unknown> | undefined;
559
+ service?: {
560
+ lifecycle: "invocation" | "workflow-run" | "worker";
561
+ methods: {
562
+ name: string;
563
+ params?: string[] | undefined;
564
+ inputs?: Record<string, unknown> | undefined;
565
+ outputs?: Record<string, unknown> | undefined;
566
+ }[];
567
+ } | undefined;
568
+ label?: string | undefined;
569
+ workflowId?: string | undefined;
570
+ inputs?: Record<string, unknown> | undefined;
571
+ outputs?: Record<string, unknown> | undefined;
572
+ description?: string | undefined;
573
+ defaults?: Record<string, unknown> | undefined;
574
+ kind?: "function" | "class" | "service" | "const" | undefined;
575
+ setup?: Record<string, unknown> | undefined;
576
+ 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;
577
+ }>;
578
+ }, "strip", z.ZodTypeAny, {
579
+ octonode: "1";
580
+ type: "manifest";
581
+ status: "ok";
582
+ invocationId: string;
583
+ manifest: {
584
+ id: string;
585
+ language: string;
586
+ symbol?: string | undefined;
587
+ config?: Record<string, unknown> | undefined;
588
+ service?: {
589
+ lifecycle: "invocation" | "workflow-run" | "worker";
590
+ methods: {
591
+ name: string;
592
+ params: string[];
593
+ inputs?: Record<string, unknown> | undefined;
594
+ outputs?: Record<string, unknown> | undefined;
595
+ }[];
596
+ } | undefined;
597
+ label?: string | undefined;
598
+ workflowId?: string | undefined;
599
+ inputs?: Record<string, unknown> | undefined;
600
+ outputs?: Record<string, unknown> | undefined;
601
+ description?: string | undefined;
602
+ defaults?: Record<string, unknown> | undefined;
603
+ kind?: "function" | "class" | "service" | "const" | undefined;
604
+ setup?: Record<string, unknown> | undefined;
605
+ 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;
606
+ };
607
+ }, {
608
+ octonode: "1";
609
+ type: "manifest";
610
+ status: "ok";
611
+ invocationId: string;
612
+ manifest: {
613
+ id: string;
614
+ language: string;
615
+ symbol?: string | undefined;
616
+ config?: Record<string, unknown> | undefined;
617
+ service?: {
618
+ lifecycle: "invocation" | "workflow-run" | "worker";
619
+ methods: {
620
+ name: string;
621
+ params?: string[] | undefined;
622
+ inputs?: Record<string, unknown> | undefined;
623
+ outputs?: Record<string, unknown> | undefined;
624
+ }[];
625
+ } | undefined;
626
+ label?: string | undefined;
627
+ workflowId?: string | undefined;
628
+ inputs?: Record<string, unknown> | undefined;
629
+ outputs?: Record<string, unknown> | undefined;
630
+ description?: string | undefined;
631
+ defaults?: Record<string, unknown> | undefined;
632
+ kind?: "function" | "class" | "service" | "const" | undefined;
633
+ setup?: Record<string, unknown> | undefined;
634
+ 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;
635
+ };
636
+ }>;
637
+ declare const ManifestErr: z.ZodObject<{
638
+ octonode: z.ZodLiteral<"1">;
639
+ type: z.ZodLiteral<"manifest">;
640
+ invocationId: z.ZodString;
641
+ status: z.ZodLiteral<"error">;
642
+ error: z.ZodObject<{
643
+ code: z.ZodEnum<["VALIDATION_ERROR", "RUNTIME_ERROR", "TIMEOUT", "NON_RETRYABLE"]>;
644
+ message: z.ZodString;
645
+ retryable: z.ZodDefault<z.ZodBoolean>;
646
+ details: z.ZodOptional<z.ZodUnknown>;
647
+ stack: z.ZodOptional<z.ZodString>;
648
+ }, "strip", z.ZodTypeAny, {
649
+ message: string;
650
+ code: "VALIDATION_ERROR" | "RUNTIME_ERROR" | "TIMEOUT" | "NON_RETRYABLE";
651
+ retryable: boolean;
652
+ details?: unknown;
653
+ stack?: string | undefined;
654
+ }, {
655
+ message: string;
656
+ code: "VALIDATION_ERROR" | "RUNTIME_ERROR" | "TIMEOUT" | "NON_RETRYABLE";
657
+ retryable?: boolean | undefined;
658
+ details?: unknown;
659
+ stack?: string | undefined;
660
+ }>;
661
+ }, "strip", z.ZodTypeAny, {
662
+ error: {
663
+ message: string;
664
+ code: "VALIDATION_ERROR" | "RUNTIME_ERROR" | "TIMEOUT" | "NON_RETRYABLE";
665
+ retryable: boolean;
666
+ details?: unknown;
667
+ stack?: string | undefined;
668
+ };
669
+ octonode: "1";
670
+ type: "manifest";
671
+ status: "error";
672
+ invocationId: string;
673
+ }, {
674
+ error: {
675
+ message: string;
676
+ code: "VALIDATION_ERROR" | "RUNTIME_ERROR" | "TIMEOUT" | "NON_RETRYABLE";
677
+ retryable?: boolean | undefined;
678
+ details?: unknown;
679
+ stack?: string | undefined;
680
+ };
681
+ octonode: "1";
682
+ type: "manifest";
683
+ status: "error";
684
+ invocationId: string;
685
+ }>;
686
+ /** Node → engine: the response to a `describe` request. */
687
+ export declare const ManifestEnvelope: z.ZodDiscriminatedUnion<"status", [z.ZodObject<{
688
+ octonode: z.ZodLiteral<"1">;
689
+ type: z.ZodLiteral<"manifest">;
690
+ invocationId: z.ZodString;
691
+ status: z.ZodLiteral<"ok">;
692
+ manifest: z.ZodObject<{
693
+ id: z.ZodString;
694
+ label: z.ZodOptional<z.ZodString>;
695
+ description: z.ZodOptional<z.ZodString>;
696
+ symbol: z.ZodOptional<z.ZodString>;
697
+ defaults: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
698
+ /** A workflow wrapper receives the current execution config through its invocation context. */
699
+ workflowId: z.ZodOptional<z.ZodString>;
700
+ language: z.ZodString;
701
+ inputs: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
702
+ outputs: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
703
+ /**
704
+ * What this node is: `function` (default), `class`, `service`, or `const`.
705
+ * Set by the setup-time SDK helpers (defineService/defineClass/defineConst)
706
+ * so `scan` writes it to `.octonode`.
707
+ */
708
+ kind: z.ZodOptional<z.ZodEnum<["function", "class", "service", "const"]>>;
709
+ /** Setup params for non-function kinds (constructor/config shape). */
710
+ setup: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
711
+ /** Advisory default icon — a one-time seed; config owns it thereafter. */
712
+ 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"]>>;
713
+ /** Advisory default config — a one-time seed; config owns it thereafter. */
714
+ config: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
715
+ /** Explicit service exposure. Plain classes never populate this field. */
716
+ service: z.ZodOptional<z.ZodObject<{
717
+ lifecycle: z.ZodEnum<["invocation", "workflow-run", "worker"]>;
718
+ methods: z.ZodArray<z.ZodObject<{
719
+ name: z.ZodString;
720
+ params: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
721
+ inputs: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
722
+ outputs: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
723
+ }, "strip", z.ZodTypeAny, {
724
+ name: string;
725
+ params: string[];
726
+ inputs?: Record<string, unknown> | undefined;
727
+ outputs?: Record<string, unknown> | undefined;
728
+ }, {
729
+ name: string;
730
+ params?: string[] | undefined;
731
+ inputs?: Record<string, unknown> | undefined;
732
+ outputs?: Record<string, unknown> | undefined;
733
+ }>, "many">;
734
+ }, "strip", z.ZodTypeAny, {
735
+ lifecycle: "invocation" | "workflow-run" | "worker";
736
+ methods: {
737
+ name: string;
738
+ params: string[];
739
+ inputs?: Record<string, unknown> | undefined;
740
+ outputs?: Record<string, unknown> | undefined;
741
+ }[];
742
+ }, {
743
+ lifecycle: "invocation" | "workflow-run" | "worker";
744
+ methods: {
745
+ name: string;
746
+ params?: string[] | undefined;
747
+ inputs?: Record<string, unknown> | undefined;
748
+ outputs?: Record<string, unknown> | undefined;
749
+ }[];
750
+ }>>;
751
+ }, "strip", z.ZodTypeAny, {
752
+ id: string;
753
+ language: string;
754
+ symbol?: string | undefined;
755
+ config?: Record<string, unknown> | undefined;
756
+ service?: {
757
+ lifecycle: "invocation" | "workflow-run" | "worker";
758
+ methods: {
759
+ name: string;
760
+ params: string[];
761
+ inputs?: Record<string, unknown> | undefined;
762
+ outputs?: Record<string, unknown> | undefined;
763
+ }[];
764
+ } | undefined;
765
+ label?: string | undefined;
766
+ workflowId?: string | undefined;
767
+ inputs?: Record<string, unknown> | undefined;
768
+ outputs?: Record<string, unknown> | undefined;
769
+ description?: string | undefined;
770
+ defaults?: Record<string, unknown> | undefined;
771
+ kind?: "function" | "class" | "service" | "const" | undefined;
772
+ setup?: Record<string, unknown> | undefined;
773
+ 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;
774
+ }, {
775
+ id: string;
776
+ language: string;
777
+ symbol?: string | undefined;
778
+ config?: Record<string, unknown> | undefined;
779
+ service?: {
780
+ lifecycle: "invocation" | "workflow-run" | "worker";
781
+ methods: {
782
+ name: string;
783
+ params?: string[] | undefined;
784
+ inputs?: Record<string, unknown> | undefined;
785
+ outputs?: Record<string, unknown> | undefined;
786
+ }[];
787
+ } | undefined;
788
+ label?: string | undefined;
789
+ workflowId?: string | undefined;
790
+ inputs?: Record<string, unknown> | undefined;
791
+ outputs?: Record<string, unknown> | undefined;
792
+ description?: string | undefined;
793
+ defaults?: Record<string, unknown> | undefined;
794
+ kind?: "function" | "class" | "service" | "const" | undefined;
795
+ setup?: Record<string, unknown> | undefined;
796
+ 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;
797
+ }>;
798
+ }, "strip", z.ZodTypeAny, {
799
+ octonode: "1";
800
+ type: "manifest";
801
+ status: "ok";
802
+ invocationId: string;
803
+ manifest: {
804
+ id: string;
805
+ language: string;
806
+ symbol?: string | undefined;
807
+ config?: Record<string, unknown> | undefined;
808
+ service?: {
809
+ lifecycle: "invocation" | "workflow-run" | "worker";
810
+ methods: {
811
+ name: string;
812
+ params: string[];
813
+ inputs?: Record<string, unknown> | undefined;
814
+ outputs?: Record<string, unknown> | undefined;
815
+ }[];
816
+ } | undefined;
817
+ label?: string | undefined;
818
+ workflowId?: string | undefined;
819
+ inputs?: Record<string, unknown> | undefined;
820
+ outputs?: Record<string, unknown> | undefined;
821
+ description?: string | undefined;
822
+ defaults?: Record<string, unknown> | undefined;
823
+ kind?: "function" | "class" | "service" | "const" | undefined;
824
+ setup?: Record<string, unknown> | undefined;
825
+ 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;
826
+ };
827
+ }, {
828
+ octonode: "1";
829
+ type: "manifest";
830
+ status: "ok";
831
+ invocationId: string;
832
+ manifest: {
833
+ id: string;
834
+ language: string;
835
+ symbol?: string | undefined;
836
+ config?: Record<string, unknown> | undefined;
837
+ service?: {
838
+ lifecycle: "invocation" | "workflow-run" | "worker";
839
+ methods: {
840
+ name: string;
841
+ params?: string[] | undefined;
842
+ inputs?: Record<string, unknown> | undefined;
843
+ outputs?: Record<string, unknown> | undefined;
844
+ }[];
845
+ } | undefined;
846
+ label?: string | undefined;
847
+ workflowId?: string | undefined;
848
+ inputs?: Record<string, unknown> | undefined;
849
+ outputs?: Record<string, unknown> | undefined;
850
+ description?: string | undefined;
851
+ defaults?: Record<string, unknown> | undefined;
852
+ kind?: "function" | "class" | "service" | "const" | undefined;
853
+ setup?: Record<string, unknown> | undefined;
854
+ 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;
855
+ };
856
+ }>, z.ZodObject<{
857
+ octonode: z.ZodLiteral<"1">;
858
+ type: z.ZodLiteral<"manifest">;
859
+ invocationId: z.ZodString;
860
+ status: z.ZodLiteral<"error">;
861
+ error: z.ZodObject<{
862
+ code: z.ZodEnum<["VALIDATION_ERROR", "RUNTIME_ERROR", "TIMEOUT", "NON_RETRYABLE"]>;
863
+ message: z.ZodString;
864
+ retryable: z.ZodDefault<z.ZodBoolean>;
865
+ details: z.ZodOptional<z.ZodUnknown>;
866
+ stack: z.ZodOptional<z.ZodString>;
867
+ }, "strip", z.ZodTypeAny, {
868
+ message: string;
869
+ code: "VALIDATION_ERROR" | "RUNTIME_ERROR" | "TIMEOUT" | "NON_RETRYABLE";
870
+ retryable: boolean;
871
+ details?: unknown;
872
+ stack?: string | undefined;
873
+ }, {
874
+ message: string;
875
+ code: "VALIDATION_ERROR" | "RUNTIME_ERROR" | "TIMEOUT" | "NON_RETRYABLE";
876
+ retryable?: boolean | undefined;
877
+ details?: unknown;
878
+ stack?: string | undefined;
879
+ }>;
880
+ }, "strip", z.ZodTypeAny, {
881
+ error: {
882
+ message: string;
883
+ code: "VALIDATION_ERROR" | "RUNTIME_ERROR" | "TIMEOUT" | "NON_RETRYABLE";
884
+ retryable: boolean;
885
+ details?: unknown;
886
+ stack?: string | undefined;
887
+ };
888
+ octonode: "1";
889
+ type: "manifest";
890
+ status: "error";
891
+ invocationId: string;
892
+ }, {
893
+ error: {
894
+ message: string;
895
+ code: "VALIDATION_ERROR" | "RUNTIME_ERROR" | "TIMEOUT" | "NON_RETRYABLE";
896
+ retryable?: boolean | undefined;
897
+ details?: unknown;
898
+ stack?: string | undefined;
899
+ };
900
+ octonode: "1";
901
+ type: "manifest";
902
+ status: "error";
903
+ invocationId: string;
904
+ }>]>;
905
+ export type ManifestEnvelope = z.infer<typeof ManifestEnvelope>;
906
+ export type ManifestResult = z.infer<typeof ManifestOk>;
907
+ export type ManifestError = z.infer<typeof ManifestErr>;
908
+ export declare function makeInvokeRequest(args: {
909
+ invocationId: string;
910
+ inputs: unknown;
911
+ node?: string;
912
+ context?: Partial<InvocationContext>;
913
+ }): InvokeRequest;
914
+ export declare function makeDescribeRequest(args: {
915
+ invocationId: string;
916
+ node?: string;
917
+ }): DescribeRequest;
918
+ export declare function makeOkResult(invocationId: string, outputs: unknown): OkResult;
919
+ export declare function makeErrorResult(invocationId: string, error: NodeError): ErrorResult;
920
+ export declare function makeManifestResult(invocationId: string, manifest: NodeManifest): ManifestResult;
921
+ export declare function makeManifestError(invocationId: string, error: NodeError): ManifestError;
922
+ export {};
923
+ //# sourceMappingURL=ipc-envelope.d.ts.map