@vantageos/agent-engine 0.1.0-alpha.7 → 0.3.0-alpha.0

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 (62) hide show
  1. package/README.md +153 -50
  2. package/dist/component/_generated/api.d.ts +14 -27
  3. package/dist/component/_generated/api.js +0 -25
  4. package/dist/component/_generated/component.d.ts +369 -92
  5. package/dist/component/_generated/component.js +0 -9
  6. package/dist/component/_generated/dataModel.d.ts +0 -38
  7. package/dist/component/_generated/dataModel.js +0 -9
  8. package/dist/component/_generated/server.d.ts +0 -106
  9. package/dist/component/_generated/server.js +0 -69
  10. package/dist/component/convex.config.js +0 -44
  11. package/dist/component/engine/agents.js +0 -7
  12. package/dist/component/engine/awaitEventTimeout.d.ts +1 -1
  13. package/dist/component/engine/awaitEventTimeout.js +18 -26
  14. package/dist/component/engine/connections.d.ts +74 -0
  15. package/dist/component/engine/connections.js +254 -0
  16. package/dist/component/engine/delegation.d.ts +1 -1
  17. package/dist/component/engine/delegation.js +0 -74
  18. package/dist/component/engine/directory.js +0 -18
  19. package/dist/component/engine/durableJob.d.ts +34 -4
  20. package/dist/component/engine/durableJob.js +333 -86
  21. package/dist/component/engine/mandates.js +0 -59
  22. package/dist/component/engine/queue.d.ts +97 -0
  23. package/dist/component/engine/queue.js +201 -0
  24. package/dist/component/engine/resolvers.d.ts +1 -1
  25. package/dist/component/engine/resolvers.js +6 -18
  26. package/dist/component/engine/sandboxCallback.d.ts +1 -1
  27. package/dist/component/engine/sandboxCallback.js +2 -79
  28. package/dist/component/engine/sandboxConfigProvider.d.ts +9 -0
  29. package/dist/component/engine/sandboxConfigProvider.js +32 -0
  30. package/dist/component/engine/sessions.d.ts +28 -10
  31. package/dist/component/engine/sessions.js +153 -165
  32. package/dist/component/engine/streams.d.ts +47 -0
  33. package/dist/component/engine/streams.js +162 -0
  34. package/dist/component/engine/toolApprovals.d.ts +1 -1
  35. package/dist/component/engine/toolApprovals.js +12 -37
  36. package/dist/component/engine/vpConnection.js +0 -40
  37. package/dist/component/engine/wakeup.d.ts +5 -7
  38. package/dist/component/engine/wakeup.js +54 -127
  39. package/dist/component/engine/workflows.d.ts +42 -0
  40. package/dist/component/engine/workflows.js +100 -41
  41. package/dist/component/engine/world.d.ts +249 -0
  42. package/dist/component/engine/world.js +665 -0
  43. package/dist/component/lib/auth.js +0 -26
  44. package/dist/component/lib/connectionSecret.d.ts +5 -0
  45. package/dist/component/lib/connectionSecret.js +32 -0
  46. package/dist/component/schema.d.ts +227 -77
  47. package/dist/component/schema.js +137 -250
  48. package/package.json +17 -3
  49. package/dist/component/engine/habits.d.ts +0 -70
  50. package/dist/component/engine/habits.js +0 -218
  51. package/dist/component/testFixtures/callerSteps.d.ts +0 -20
  52. package/dist/component/testFixtures/callerSteps.js +0 -90
  53. package/dist/component/testFixtures/delegationDemoWorkflow.d.ts +0 -18
  54. package/dist/component/testFixtures/delegationDemoWorkflow.js +0 -75
  55. package/dist/component/testFixtures/sandboxDemoWorkflow.d.ts +0 -19
  56. package/dist/component/testFixtures/sandboxDemoWorkflow.js +0 -69
  57. package/dist/component/testFixtures/vpTool.d.ts +0 -4
  58. package/dist/component/testFixtures/vpTool.js +0 -25
  59. package/dist/component/testFixtures/wakeupDemoWorkflow.d.ts +0 -19
  60. package/dist/component/testFixtures/wakeupDemoWorkflow.js +0 -77
  61. package/dist/component/testFixtures/wakeupWork.d.ts +0 -8
  62. package/dist/component/testFixtures/wakeupWork.js +0 -21
@@ -0,0 +1,5 @@
1
+ export interface EncryptedSecret {
2
+ ciphertextBase64: string;
3
+ ivBase64: string;
4
+ }
5
+ export declare function encryptSecret(plaintext: string, encryptionKeyBase64: string): Promise<EncryptedSecret>;
@@ -0,0 +1,32 @@
1
+ function bytesToBase64(bytes) {
2
+ let binary = "";
3
+ for (const byte of bytes)
4
+ binary += String.fromCharCode(byte);
5
+ return btoa(binary);
6
+ }
7
+ function base64ToBytes(base64) {
8
+ const binary = atob(base64);
9
+ const bytes = new Uint8Array(binary.length);
10
+ for (let i = 0; i < binary.length; i++)
11
+ bytes[i] = binary.charCodeAt(i);
12
+ return bytes;
13
+ }
14
+ export async function encryptSecret(plaintext, encryptionKeyBase64) {
15
+ if (plaintext.length === 0) {
16
+ throw new Error("Validation: secret plaintext must not be empty");
17
+ }
18
+ if (!encryptionKeyBase64 || encryptionKeyBase64.trim().length === 0) {
19
+ throw new Error("Validation: encryptionKeyBase64 must not be empty -- caller must supply a key, this component never reads one from process.env");
20
+ }
21
+ const keyBytes = base64ToBytes(encryptionKeyBase64);
22
+ if (keyBytes.length !== 32) {
23
+ throw new Error(`Validation: encryptionKeyBase64 must decode to exactly 32 bytes (AES-256), got ${keyBytes.length}`);
24
+ }
25
+ const key = await crypto.subtle.importKey("raw", keyBytes, { name: "AES-GCM" }, false, ["encrypt"]);
26
+ const iv = crypto.getRandomValues(new Uint8Array(12));
27
+ const ciphertext = await crypto.subtle.encrypt({ name: "AES-GCM", iv }, key, new TextEncoder().encode(plaintext));
28
+ return {
29
+ ciphertextBase64: bytesToBase64(new Uint8Array(ciphertext)),
30
+ ivBase64: bytesToBase64(iv),
31
+ };
32
+ }
@@ -134,47 +134,28 @@ declare const _default: import("convex/server").SchemaDefinition<{
134
134
  by_org: ["orgId", "_creationTime"];
135
135
  by_org_session: ["orgId", "sessionId", "_creationTime"];
136
136
  }, {}, {}>;
137
- wakeableWork: import("convex/server").TableDefinition<import("convex/values").VObject<{
138
- resultSummary?: string | undefined;
139
- orgId: string;
140
- status: "completed" | "cancelled" | "pending" | "failed";
141
- workflowId: string;
142
- createdAt: number;
143
- updatedAt: number;
144
- awaitedEventName: string;
145
- workId: string;
146
- }, {
147
- orgId: import("convex/values").VString<string, "required">;
148
- workflowId: import("convex/values").VString<string, "required">;
149
- awaitedEventName: import("convex/values").VString<string, "required">;
150
- workId: import("convex/values").VString<string, "required">;
151
- status: import("convex/values").VUnion<"completed" | "cancelled" | "pending" | "failed", [import("convex/values").VLiteral<"pending", "required">, import("convex/values").VLiteral<"completed", "required">, import("convex/values").VLiteral<"failed", "required">, import("convex/values").VLiteral<"cancelled", "required">], "required", never>;
152
- resultSummary: import("convex/values").VString<string | undefined, "optional">;
153
- createdAt: import("convex/values").VFloat64<number, "required">;
154
- updatedAt: import("convex/values").VFloat64<number, "required">;
155
- }, "required", "orgId" | "status" | "workflowId" | "createdAt" | "updatedAt" | "awaitedEventName" | "workId" | "resultSummary">, {
156
- by_org: ["orgId", "_creationTime"];
157
- by_org_workflow: ["orgId", "workflowId", "_creationTime"];
158
- }, {}, {}>;
159
137
  awaitEventTimeouts: import("convex/server").TableDefinition<import("convex/values").VObject<{
138
+ sessionId?: import("convex/values").GenericId<"sessions"> | undefined;
139
+ runId?: string | undefined;
160
140
  scheduledFunctionId?: import("convex/values").GenericId<"_scheduled_functions"> | undefined;
161
141
  firedAt?: number | undefined;
162
142
  cancelledAt?: number | undefined;
163
143
  orgId: string;
164
- sessionId: import("convex/values").GenericId<"sessions">;
165
144
  awaitedEventName: string;
166
145
  deadlineAt: number;
167
146
  }, {
168
147
  orgId: import("convex/values").VString<string, "required">;
169
- sessionId: import("convex/values").VId<import("convex/values").GenericId<"sessions">, "required">;
148
+ runId: import("convex/values").VString<string | undefined, "optional">;
149
+ sessionId: import("convex/values").VId<import("convex/values").GenericId<"sessions"> | undefined, "optional">;
170
150
  awaitedEventName: import("convex/values").VString<string, "required">;
171
151
  deadlineAt: import("convex/values").VFloat64<number, "required">;
172
152
  scheduledFunctionId: import("convex/values").VId<import("convex/values").GenericId<"_scheduled_functions"> | undefined, "optional">;
173
153
  firedAt: import("convex/values").VFloat64<number | undefined, "optional">;
174
154
  cancelledAt: import("convex/values").VFloat64<number | undefined, "optional">;
175
- }, "required", "orgId" | "sessionId" | "awaitedEventName" | "deadlineAt" | "scheduledFunctionId" | "firedAt" | "cancelledAt">, {
155
+ }, "required", "orgId" | "sessionId" | "runId" | "awaitedEventName" | "deadlineAt" | "scheduledFunctionId" | "firedAt" | "cancelledAt">, {
176
156
  by_org: ["orgId", "_creationTime"];
177
157
  by_org_session: ["orgId", "sessionId", "_creationTime"];
158
+ by_org_run: ["orgId", "runId", "_creationTime"];
178
159
  }, {}, {}>;
179
160
  wakeupDemoResults: import("convex/server").TableDefinition<import("convex/values").VObject<{
180
161
  wokenAt?: number | undefined;
@@ -241,74 +222,36 @@ declare const _default: import("convex/server").SchemaDefinition<{
241
222
  by_org_agent: ["orgId", "agentId", "_creationTime"];
242
223
  by_org_status: ["orgId", "status", "_creationTime"];
243
224
  }, {}, {}>;
244
- habits: import("convex/server").TableDefinition<import("convex/values").VObject<{
245
- cronJobId?: string | undefined;
246
- lastRunAt?: number | undefined;
247
- name: string;
248
- orgId: string;
249
- createdAt: number;
250
- updatedAt: number;
251
- agentId: import("convex/values").GenericId<"agents">;
252
- cronExpression: string;
253
- prompt: string;
254
- enabled: boolean;
255
- }, {
256
- orgId: import("convex/values").VString<string, "required">;
257
- agentId: import("convex/values").VId<import("convex/values").GenericId<"agents">, "required">;
258
- name: import("convex/values").VString<string, "required">;
259
- cronExpression: import("convex/values").VString<string, "required">;
260
- prompt: import("convex/values").VString<string, "required">;
261
- enabled: import("convex/values").VBoolean<boolean, "required">;
262
- cronJobId: import("convex/values").VString<string | undefined, "optional">;
263
- lastRunAt: import("convex/values").VFloat64<number | undefined, "optional">;
264
- createdAt: import("convex/values").VFloat64<number, "required">;
265
- updatedAt: import("convex/values").VFloat64<number, "required">;
266
- }, "required", "name" | "orgId" | "createdAt" | "updatedAt" | "agentId" | "cronExpression" | "prompt" | "enabled" | "cronJobId" | "lastRunAt">, {
267
- by_org: ["orgId", "_creationTime"];
268
- by_org_agent: ["orgId", "agentId", "_creationTime"];
269
- }, {}, {}>;
270
- habitRuns: import("convex/server").TableDefinition<import("convex/values").VObject<{
271
- orgId: string;
272
- agentId: import("convex/values").GenericId<"agents">;
273
- habitId: import("convex/values").GenericId<"habits">;
274
- ranAt: number;
275
- }, {
276
- orgId: import("convex/values").VString<string, "required">;
277
- habitId: import("convex/values").VId<import("convex/values").GenericId<"habits">, "required">;
278
- agentId: import("convex/values").VId<import("convex/values").GenericId<"agents">, "required">;
279
- ranAt: import("convex/values").VFloat64<number, "required">;
280
- }, "required", "orgId" | "agentId" | "habitId" | "ranAt">, {
281
- by_org: ["orgId", "_creationTime"];
282
- by_org_habit: ["orgId", "habitId", "_creationTime"];
283
- }, {}, {}>;
284
225
  sandboxConfig: import("convex/server").TableDefinition<import("convex/values").VObject<{
285
226
  image?: string | undefined;
227
+ boxId?: string | undefined;
286
228
  orgId: string;
287
229
  createdAt: number;
288
230
  updatedAt: number;
289
231
  agentId: import("convex/values").GenericId<"agents">;
290
- provider: "vercel-sandbox";
232
+ provider: "vercel-sandbox" | "e2b" | "daytona" | "box";
291
233
  timeoutSeconds: number;
292
234
  egressPolicy: "allow-all" | "deny-all-allowlist";
293
235
  allowlistDomains: string[];
294
236
  }, {
295
237
  orgId: import("convex/values").VString<string, "required">;
296
238
  agentId: import("convex/values").VId<import("convex/values").GenericId<"agents">, "required">;
297
- provider: import("convex/values").VLiteral<"vercel-sandbox", "required">;
239
+ provider: import("convex/values").VUnion<"vercel-sandbox" | "e2b" | "daytona" | "box", [import("convex/values").VLiteral<"vercel-sandbox", "required">, import("convex/values").VLiteral<"e2b", "required">, import("convex/values").VLiteral<"daytona", "required">, import("convex/values").VLiteral<"box", "required">], "required", never>;
298
240
  image: import("convex/values").VString<string | undefined, "optional">;
299
241
  timeoutSeconds: import("convex/values").VFloat64<number, "required">;
300
242
  egressPolicy: import("convex/values").VUnion<"allow-all" | "deny-all-allowlist", [import("convex/values").VLiteral<"allow-all", "required">, import("convex/values").VLiteral<"deny-all-allowlist", "required">], "required", never>;
301
243
  allowlistDomains: import("convex/values").VArray<string[], import("convex/values").VString<string, "required">, "required">;
244
+ boxId: import("convex/values").VString<string | undefined, "optional">;
302
245
  createdAt: import("convex/values").VFloat64<number, "required">;
303
246
  updatedAt: import("convex/values").VFloat64<number, "required">;
304
- }, "required", "orgId" | "createdAt" | "updatedAt" | "agentId" | "provider" | "image" | "timeoutSeconds" | "egressPolicy" | "allowlistDomains">, {
247
+ }, "required", "orgId" | "createdAt" | "updatedAt" | "agentId" | "provider" | "image" | "timeoutSeconds" | "egressPolicy" | "allowlistDomains" | "boxId">, {
305
248
  by_org: ["orgId", "_creationTime"];
306
249
  by_org_agent: ["orgId", "agentId", "_creationTime"];
307
250
  }, {}, {}>;
308
251
  sandboxRuns: import("convex/server").TableDefinition<import("convex/values").VObject<{
309
252
  resultSummary?: string | undefined;
310
253
  orgId: string;
311
- status: "completed" | "pending" | "failed" | "timedOut";
254
+ status: "completed" | "failed" | "pending" | "timedOut";
312
255
  workflowId: string;
313
256
  createdAt: number;
314
257
  updatedAt: number;
@@ -319,11 +262,11 @@ declare const _default: import("convex/server").SchemaDefinition<{
319
262
  workflowId: import("convex/values").VString<string, "required">;
320
263
  awaitedEventName: import("convex/values").VString<string, "required">;
321
264
  sandboxId: import("convex/values").VString<string, "required">;
322
- status: import("convex/values").VUnion<"completed" | "pending" | "failed" | "timedOut", [import("convex/values").VLiteral<"pending", "required">, import("convex/values").VLiteral<"completed", "required">, import("convex/values").VLiteral<"failed", "required">, import("convex/values").VLiteral<"timedOut", "required">], "required", never>;
265
+ status: import("convex/values").VUnion<"completed" | "failed" | "pending" | "timedOut", [import("convex/values").VLiteral<"pending", "required">, import("convex/values").VLiteral<"completed", "required">, import("convex/values").VLiteral<"failed", "required">, import("convex/values").VLiteral<"timedOut", "required">], "required", never>;
323
266
  resultSummary: import("convex/values").VString<string | undefined, "optional">;
324
267
  createdAt: import("convex/values").VFloat64<number, "required">;
325
268
  updatedAt: import("convex/values").VFloat64<number, "required">;
326
- }, "required", "orgId" | "status" | "workflowId" | "createdAt" | "updatedAt" | "awaitedEventName" | "resultSummary" | "sandboxId">, {
269
+ }, "required", "orgId" | "status" | "workflowId" | "createdAt" | "updatedAt" | "awaitedEventName" | "sandboxId" | "resultSummary">, {
327
270
  by_org: ["orgId", "_creationTime"];
328
271
  by_org_workflow: ["orgId", "workflowId", "_creationTime"];
329
272
  by_org_sandbox: ["orgId", "sandboxId", "_creationTime"];
@@ -365,9 +308,9 @@ declare const _default: import("convex/server").SchemaDefinition<{
365
308
  orgId: string;
366
309
  createdAt: number;
367
310
  toolName: string;
368
- enabled: boolean;
369
311
  parentAgentId: import("convex/values").GenericId<"agents">;
370
312
  childAgentId: import("convex/values").GenericId<"agents">;
313
+ enabled: boolean;
371
314
  }, {
372
315
  orgId: import("convex/values").VString<string, "required">;
373
316
  parentAgentId: import("convex/values").VId<import("convex/values").GenericId<"agents">, "required">;
@@ -376,7 +319,7 @@ declare const _default: import("convex/server").SchemaDefinition<{
376
319
  description: import("convex/values").VString<string | undefined, "optional">;
377
320
  enabled: import("convex/values").VBoolean<boolean, "required">;
378
321
  createdAt: import("convex/values").VFloat64<number, "required">;
379
- }, "required", "description" | "orgId" | "createdAt" | "toolName" | "enabled" | "parentAgentId" | "childAgentId">, {
322
+ }, "required", "description" | "orgId" | "createdAt" | "toolName" | "parentAgentId" | "childAgentId" | "enabled">, {
380
323
  by_org: ["orgId", "_creationTime"];
381
324
  by_org_parent: ["orgId", "parentAgentId", "_creationTime"];
382
325
  by_org_child: ["orgId", "childAgentId", "_creationTime"];
@@ -385,7 +328,7 @@ declare const _default: import("convex/server").SchemaDefinition<{
385
328
  delegationRuns: import("convex/server").TableDefinition<import("convex/values").VObject<{
386
329
  resultSummary?: string | undefined;
387
330
  orgId: string;
388
- status: "completed" | "cancelled" | "pending" | "failed";
331
+ status: "completed" | "cancelled" | "failed" | "pending";
389
332
  workflowId: string;
390
333
  createdAt: number;
391
334
  updatedAt: number;
@@ -400,7 +343,7 @@ declare const _default: import("convex/server").SchemaDefinition<{
400
343
  toolName: import("convex/values").VString<string, "required">;
401
344
  workflowId: import("convex/values").VString<string, "required">;
402
345
  awaitedEventName: import("convex/values").VString<string, "required">;
403
- status: import("convex/values").VUnion<"completed" | "cancelled" | "pending" | "failed", [import("convex/values").VLiteral<"pending", "required">, import("convex/values").VLiteral<"completed", "required">, import("convex/values").VLiteral<"failed", "required">, import("convex/values").VLiteral<"cancelled", "required">], "required", never>;
346
+ status: import("convex/values").VUnion<"completed" | "cancelled" | "failed" | "pending", [import("convex/values").VLiteral<"pending", "required">, import("convex/values").VLiteral<"completed", "required">, import("convex/values").VLiteral<"failed", "required">, import("convex/values").VLiteral<"cancelled", "required">], "required", never>;
404
347
  resultSummary: import("convex/values").VString<string | undefined, "optional">;
405
348
  createdAt: import("convex/values").VFloat64<number, "required">;
406
349
  updatedAt: import("convex/values").VFloat64<number, "required">;
@@ -413,7 +356,7 @@ declare const _default: import("convex/server").SchemaDefinition<{
413
356
  agentCloneRuns: import("convex/server").TableDefinition<import("convex/values").VObject<{
414
357
  resultSummary?: string | undefined;
415
358
  orgId: string;
416
- status: "completed" | "cancelled" | "pending" | "failed";
359
+ status: "completed" | "cancelled" | "failed" | "pending";
417
360
  workflowId: string;
418
361
  createdAt: number;
419
362
  updatedAt: number;
@@ -424,7 +367,7 @@ declare const _default: import("convex/server").SchemaDefinition<{
424
367
  agentId: import("convex/values").VId<import("convex/values").GenericId<"agents">, "required">;
425
368
  workflowId: import("convex/values").VString<string, "required">;
426
369
  awaitedEventName: import("convex/values").VString<string, "required">;
427
- status: import("convex/values").VUnion<"completed" | "cancelled" | "pending" | "failed", [import("convex/values").VLiteral<"pending", "required">, import("convex/values").VLiteral<"completed", "required">, import("convex/values").VLiteral<"failed", "required">, import("convex/values").VLiteral<"cancelled", "required">], "required", never>;
370
+ status: import("convex/values").VUnion<"completed" | "cancelled" | "failed" | "pending", [import("convex/values").VLiteral<"pending", "required">, import("convex/values").VLiteral<"completed", "required">, import("convex/values").VLiteral<"failed", "required">, import("convex/values").VLiteral<"cancelled", "required">], "required", never>;
428
371
  resultSummary: import("convex/values").VString<string | undefined, "optional">;
429
372
  createdAt: import("convex/values").VFloat64<number, "required">;
430
373
  updatedAt: import("convex/values").VFloat64<number, "required">;
@@ -468,6 +411,62 @@ declare const _default: import("convex/server").SchemaDefinition<{
468
411
  by_org: ["orgId", "_creationTime"];
469
412
  by_org_agent: ["orgId", "agentId", "_creationTime"];
470
413
  }, {}, {}>;
414
+ connections: import("convex/server").TableDefinition<import("convex/values").VObject<{
415
+ encryptedSecretCiphertext?: string | undefined;
416
+ encryptedSecretIv?: string | undefined;
417
+ name: string;
418
+ orgId: string;
419
+ type: "mcp" | "openapi";
420
+ status: "active" | "pending_authorization" | "error";
421
+ createdAt: number;
422
+ updatedAt: number;
423
+ agentId: import("convex/values").GenericId<"agents">;
424
+ serverConfig: string;
425
+ authMode: "none" | "app-token" | "user-oauth" | "header";
426
+ }, {
427
+ orgId: import("convex/values").VString<string, "required">;
428
+ agentId: import("convex/values").VId<import("convex/values").GenericId<"agents">, "required">;
429
+ type: import("convex/values").VUnion<"mcp" | "openapi", [import("convex/values").VLiteral<"mcp", "required">, import("convex/values").VLiteral<"openapi", "required">], "required", never>;
430
+ name: import("convex/values").VString<string, "required">;
431
+ serverConfig: import("convex/values").VString<string, "required">;
432
+ authMode: import("convex/values").VUnion<"none" | "app-token" | "user-oauth" | "header", [import("convex/values").VLiteral<"app-token", "required">, import("convex/values").VLiteral<"user-oauth", "required">, import("convex/values").VLiteral<"none", "required">, import("convex/values").VLiteral<"header", "required">], "required", never>;
433
+ encryptedSecretCiphertext: import("convex/values").VString<string | undefined, "optional">;
434
+ encryptedSecretIv: import("convex/values").VString<string | undefined, "optional">;
435
+ status: import("convex/values").VUnion<"active" | "pending_authorization" | "error", [import("convex/values").VLiteral<"active", "required">, import("convex/values").VLiteral<"pending_authorization", "required">, import("convex/values").VLiteral<"error", "required">], "required", never>;
436
+ createdAt: import("convex/values").VFloat64<number, "required">;
437
+ updatedAt: import("convex/values").VFloat64<number, "required">;
438
+ }, "required", "name" | "orgId" | "type" | "status" | "createdAt" | "updatedAt" | "agentId" | "serverConfig" | "authMode" | "encryptedSecretCiphertext" | "encryptedSecretIv">, {
439
+ by_org: ["orgId", "_creationTime"];
440
+ by_org_agent: ["orgId", "agentId", "_creationTime"];
441
+ }, {}, {}>;
442
+ connectionAuthorizations: import("convex/server").TableDefinition<import("convex/values").VObject<{
443
+ resolvedAt?: number | undefined;
444
+ resultSummary?: string | undefined;
445
+ orgId: string;
446
+ status: "pending" | "denied" | "authorized";
447
+ workflowId: string;
448
+ createdAt: number;
449
+ updatedAt: number;
450
+ awaitedEventName: string;
451
+ connectionId: import("convex/values").GenericId<"connections">;
452
+ url: string;
453
+ userCode: string;
454
+ }, {
455
+ orgId: import("convex/values").VString<string, "required">;
456
+ connectionId: import("convex/values").VId<import("convex/values").GenericId<"connections">, "required">;
457
+ workflowId: import("convex/values").VString<string, "required">;
458
+ awaitedEventName: import("convex/values").VString<string, "required">;
459
+ url: import("convex/values").VString<string, "required">;
460
+ userCode: import("convex/values").VString<string, "required">;
461
+ status: import("convex/values").VUnion<"pending" | "denied" | "authorized", [import("convex/values").VLiteral<"pending", "required">, import("convex/values").VLiteral<"authorized", "required">, import("convex/values").VLiteral<"denied", "required">], "required", never>;
462
+ resultSummary: import("convex/values").VString<string | undefined, "optional">;
463
+ createdAt: import("convex/values").VFloat64<number, "required">;
464
+ updatedAt: import("convex/values").VFloat64<number, "required">;
465
+ resolvedAt: import("convex/values").VFloat64<number | undefined, "optional">;
466
+ }, "required", "orgId" | "status" | "workflowId" | "createdAt" | "updatedAt" | "awaitedEventName" | "resolvedAt" | "resultSummary" | "connectionId" | "url" | "userCode">, {
467
+ by_org: ["orgId", "_creationTime"];
468
+ by_org_connection: ["orgId", "connectionId", "_creationTime"];
469
+ }, {}, {}>;
471
470
  vpTenantFixture: import("convex/server").TableDefinition<import("convex/values").VObject<{
472
471
  orgId: string;
473
472
  createdAt: number;
@@ -481,5 +480,156 @@ declare const _default: import("convex/server").SchemaDefinition<{
481
480
  }, "required", "orgId" | "createdAt" | "tool" | "argsJson">, {
482
481
  by_org: ["orgId", "_creationTime"];
483
482
  }, {}, {}>;
483
+ worldRuns: import("convex/server").TableDefinition<import("convex/values").VObject<{
484
+ orgId: string;
485
+ status: "running" | "completed" | "cancelled" | "failed";
486
+ createdAt: number;
487
+ updatedAt: number;
488
+ runId: string;
489
+ eventCount: number;
490
+ }, {
491
+ orgId: import("convex/values").VString<string, "required">;
492
+ runId: import("convex/values").VString<string, "required">;
493
+ status: import("convex/values").VUnion<"running" | "completed" | "cancelled" | "failed", [import("convex/values").VLiteral<"running", "required">, import("convex/values").VLiteral<"completed", "required">, import("convex/values").VLiteral<"failed", "required">, import("convex/values").VLiteral<"cancelled", "required">], "required", never>;
494
+ eventCount: import("convex/values").VFloat64<number, "required">;
495
+ createdAt: import("convex/values").VFloat64<number, "required">;
496
+ updatedAt: import("convex/values").VFloat64<number, "required">;
497
+ }, "required", "orgId" | "status" | "createdAt" | "updatedAt" | "runId" | "eventCount">, {
498
+ by_org: ["orgId", "_creationTime"];
499
+ by_org_run: ["orgId", "runId", "_creationTime"];
500
+ }, {}, {}>;
501
+ worldSteps: import("convex/server").TableDefinition<import("convex/values").VObject<{
502
+ dataJson?: string | undefined;
503
+ orgId: string;
504
+ status: "running" | "completed" | "failed";
505
+ createdAt: number;
506
+ updatedAt: number;
507
+ runId: string;
508
+ stepId: string;
509
+ }, {
510
+ orgId: import("convex/values").VString<string, "required">;
511
+ runId: import("convex/values").VString<string, "required">;
512
+ stepId: import("convex/values").VString<string, "required">;
513
+ status: import("convex/values").VUnion<"running" | "completed" | "failed", [import("convex/values").VLiteral<"running", "required">, import("convex/values").VLiteral<"completed", "required">, import("convex/values").VLiteral<"failed", "required">], "required", never>;
514
+ dataJson: import("convex/values").VString<string | undefined, "optional">;
515
+ createdAt: import("convex/values").VFloat64<number, "required">;
516
+ updatedAt: import("convex/values").VFloat64<number, "required">;
517
+ }, "required", "orgId" | "status" | "createdAt" | "updatedAt" | "runId" | "stepId" | "dataJson">, {
518
+ by_org_run: ["orgId", "runId", "_creationTime"];
519
+ by_org_run_step: ["orgId", "runId", "stepId", "_creationTime"];
520
+ }, {}, {}>;
521
+ worldHooks: import("convex/server").TableDefinition<import("convex/values").VObject<{
522
+ orgId: string;
523
+ status: "pending" | "disposed";
524
+ createdAt: number;
525
+ updatedAt: number;
526
+ runId: string;
527
+ hookId: string;
528
+ token: string;
529
+ }, {
530
+ orgId: import("convex/values").VString<string, "required">;
531
+ runId: import("convex/values").VString<string, "required">;
532
+ hookId: import("convex/values").VString<string, "required">;
533
+ token: import("convex/values").VString<string, "required">;
534
+ status: import("convex/values").VUnion<"pending" | "disposed", [import("convex/values").VLiteral<"pending", "required">, import("convex/values").VLiteral<"disposed", "required">], "required", never>;
535
+ createdAt: import("convex/values").VFloat64<number, "required">;
536
+ updatedAt: import("convex/values").VFloat64<number, "required">;
537
+ }, "required", "orgId" | "status" | "createdAt" | "updatedAt" | "runId" | "hookId" | "token">, {
538
+ by_org_run: ["orgId", "runId", "_creationTime"];
539
+ by_org_hook: ["orgId", "hookId", "_creationTime"];
540
+ by_org_token: ["orgId", "token", "_creationTime"];
541
+ }, {}, {}>;
542
+ worldEvents: import("convex/server").TableDefinition<import("convex/values").VObject<{
543
+ stepId?: string | undefined;
544
+ hookId?: string | undefined;
545
+ correlationId?: string | undefined;
546
+ orgId: string;
547
+ createdAt: number;
548
+ runId: string;
549
+ dataJson: string;
550
+ seq: number;
551
+ eventType: string;
552
+ }, {
553
+ orgId: import("convex/values").VString<string, "required">;
554
+ runId: import("convex/values").VString<string, "required">;
555
+ seq: import("convex/values").VFloat64<number, "required">;
556
+ eventType: import("convex/values").VString<string, "required">;
557
+ stepId: import("convex/values").VString<string | undefined, "optional">;
558
+ hookId: import("convex/values").VString<string | undefined, "optional">;
559
+ correlationId: import("convex/values").VString<string | undefined, "optional">;
560
+ dataJson: import("convex/values").VString<string, "required">;
561
+ createdAt: import("convex/values").VFloat64<number, "required">;
562
+ }, "required", "orgId" | "createdAt" | "runId" | "stepId" | "dataJson" | "hookId" | "seq" | "eventType" | "correlationId">, {
563
+ by_org_run: ["orgId", "runId", "_creationTime"];
564
+ by_org_run_seq: ["orgId", "runId", "seq", "_creationTime"];
565
+ by_org_correlation: ["orgId", "correlationId", "_creationTime"];
566
+ }, {}, {}>;
567
+ worldQueueMessages: import("convex/server").TableDefinition<import("convex/values").VObject<{
568
+ idempotencyKey?: string | undefined;
569
+ orgId: string;
570
+ status: "failed" | "pending" | "claimed" | "delivered";
571
+ createdAt: number;
572
+ updatedAt: number;
573
+ queueName: string;
574
+ messageId: string;
575
+ payloadJson: string;
576
+ attempt: number;
577
+ deliverAt: number;
578
+ }, {
579
+ orgId: import("convex/values").VString<string, "required">;
580
+ queueName: import("convex/values").VString<string, "required">;
581
+ messageId: import("convex/values").VString<string, "required">;
582
+ payloadJson: import("convex/values").VString<string, "required">;
583
+ idempotencyKey: import("convex/values").VString<string | undefined, "optional">;
584
+ attempt: import("convex/values").VFloat64<number, "required">;
585
+ status: import("convex/values").VUnion<"failed" | "pending" | "claimed" | "delivered", [import("convex/values").VLiteral<"pending", "required">, import("convex/values").VLiteral<"claimed", "required">, import("convex/values").VLiteral<"delivered", "required">, import("convex/values").VLiteral<"failed", "required">], "required", never>;
586
+ deliverAt: import("convex/values").VFloat64<number, "required">;
587
+ createdAt: import("convex/values").VFloat64<number, "required">;
588
+ updatedAt: import("convex/values").VFloat64<number, "required">;
589
+ }, "required", "orgId" | "status" | "createdAt" | "updatedAt" | "queueName" | "messageId" | "payloadJson" | "idempotencyKey" | "attempt" | "deliverAt">, {
590
+ by_org: ["orgId", "_creationTime"];
591
+ by_org_queue: ["orgId", "queueName", "_creationTime"];
592
+ by_org_message: ["orgId", "messageId", "_creationTime"];
593
+ by_org_queue_idempotencyKey: ["orgId", "queueName", "idempotencyKey", "_creationTime"];
594
+ by_org_queue_status_deliverAt: ["orgId", "queueName", "status", "deliverAt", "_creationTime"];
595
+ }, {}, {}>;
596
+ worldStreams: import("convex/server").TableDefinition<import("convex/values").VObject<{
597
+ name: string;
598
+ orgId: string;
599
+ createdAt: number;
600
+ updatedAt: number;
601
+ runId: string;
602
+ chunkCount: number;
603
+ done: boolean;
604
+ }, {
605
+ orgId: import("convex/values").VString<string, "required">;
606
+ runId: import("convex/values").VString<string, "required">;
607
+ name: import("convex/values").VString<string, "required">;
608
+ chunkCount: import("convex/values").VFloat64<number, "required">;
609
+ done: import("convex/values").VBoolean<boolean, "required">;
610
+ createdAt: import("convex/values").VFloat64<number, "required">;
611
+ updatedAt: import("convex/values").VFloat64<number, "required">;
612
+ }, "required", "name" | "orgId" | "createdAt" | "updatedAt" | "runId" | "chunkCount" | "done">, {
613
+ by_org: ["orgId", "_creationTime"];
614
+ by_org_run: ["orgId", "runId", "_creationTime"];
615
+ by_org_run_name: ["orgId", "runId", "name", "_creationTime"];
616
+ }, {}, {}>;
617
+ worldStreamChunks: import("convex/server").TableDefinition<import("convex/values").VObject<{
618
+ name: string;
619
+ orgId: string;
620
+ createdAt: number;
621
+ runId: string;
622
+ index: number;
623
+ dataBase64: string;
624
+ }, {
625
+ orgId: import("convex/values").VString<string, "required">;
626
+ runId: import("convex/values").VString<string, "required">;
627
+ name: import("convex/values").VString<string, "required">;
628
+ index: import("convex/values").VFloat64<number, "required">;
629
+ dataBase64: import("convex/values").VString<string, "required">;
630
+ createdAt: import("convex/values").VFloat64<number, "required">;
631
+ }, "required", "name" | "orgId" | "createdAt" | "runId" | "index" | "dataBase64">, {
632
+ by_org_run_name_index: ["orgId", "runId", "name", "index", "_creationTime"];
633
+ }, {}, {}>;
484
634
  }, true>;
485
635
  export default _default;