eve 0.58.0 → 0.59.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.
- package/CHANGELOG.md +28 -0
- package/README.md +1 -0
- package/dist/src/channel/session.d.ts +2 -0
- package/dist/src/channel/session.js +1 -1
- package/dist/src/channel/types.d.ts +8 -1
- package/dist/src/chunks/{use-eve-agent-X0asmJg-.js → use-eve-agent-Dmc6sX4d.js} +558 -233
- package/dist/src/chunks/{use-eve-agent-CxWcZCsU.js → use-eve-agent-jSR8P4nK.js} +565 -235
- package/dist/src/cli/dev/tui/runner.d.ts +4 -0
- package/dist/src/cli/dev/tui/runner.js +1 -1
- package/dist/src/cli/dev/tui/setup-issues.js +1 -1
- package/dist/src/cli/dev/tui/terminal-renderer.js +12 -12
- package/dist/src/client/eve-agent-projection.d.ts +10 -0
- package/dist/src/client/eve-agent-projection.js +1 -0
- package/dist/src/client/eve-agent-store-helpers.d.ts +6 -2
- package/dist/src/client/eve-agent-store-helpers.js +2 -2
- package/dist/src/client/eve-agent-store-state.d.ts +54 -1
- package/dist/src/client/eve-agent-store.d.ts +12 -82
- package/dist/src/client/eve-agent-store.js +1 -1
- package/dist/src/client/index.d.ts +2 -2
- package/dist/src/client/index.js +1 -1
- package/dist/src/client/message-response.d.ts +5 -1
- package/dist/src/client/message-response.js +1 -1
- package/dist/src/client/ndjson.d.ts +1 -0
- package/dist/src/client/ndjson.js +2 -2
- package/dist/src/client/open-stream.d.ts +4 -1
- package/dist/src/client/open-stream.js +1 -1
- package/dist/src/client/session-event-stream.d.ts +30 -0
- package/dist/src/client/session-event-stream.js +1 -0
- package/dist/src/client/session-utils.d.ts +2 -1
- package/dist/src/client/session-utils.js +1 -1
- package/dist/src/client/session.d.ts +14 -1
- package/dist/src/client/session.js +1 -1
- package/dist/src/client/sessions.d.ts +8 -2
- package/dist/src/client/sessions.js +1 -1
- package/dist/src/client/types.d.ts +7 -0
- package/dist/src/compiled/.vendor-stamp.json +2 -3
- package/dist/src/compiled/@vercel/sandbox/api-client/api-client.d.ts +88 -1
- package/dist/src/compiled/@vercel/sandbox/api-client/index.d.ts +1 -1
- package/dist/src/compiled/@vercel/sandbox/api-client/validators.d.ts +41 -1
- package/dist/src/compiled/@vercel/sandbox/constants.d.ts +3 -3
- package/dist/src/compiled/@vercel/{sandbox-drives → sandbox}/drive.d.ts +13 -2
- package/dist/src/compiled/@vercel/sandbox/index.d.ts +3 -2
- package/dist/src/compiled/@vercel/sandbox/index.js +15 -9
- package/dist/src/compiled/@vercel/sandbox/sandbox.d.ts +40 -5
- package/dist/src/compiled/_chunks/node/auth-DDrvYko5.js +2 -0
- package/dist/src/compiled/_chunks/node/version-C__MqbLM.js +1 -0
- package/dist/src/compiler/extension-compatibility.d.ts +14 -14
- package/dist/src/compiler/extension-compatibility.js +1 -1
- package/dist/src/context/build-dynamic-tools.js +1 -1
- package/dist/src/context/dynamic-tool-lifecycle.js +1 -1
- package/dist/src/context/memory-tools.js +1 -1
- package/dist/src/evals/context.d.ts +1 -1
- package/dist/src/evals/context.js +1 -1
- package/dist/src/evals/define-eval.d.ts +1 -1
- package/dist/src/evals/define-eval.js +1 -1
- package/dist/src/evals/index.js +1 -1
- package/dist/src/evals/judge.d.ts +1 -1
- package/dist/src/evals/runner/execute-task.d.ts +1 -1
- package/dist/src/evals/runner/execute-task.js +1 -1
- package/dist/src/evals/session-manager.d.ts +27 -0
- package/dist/src/evals/session-manager.js +1 -0
- package/dist/src/evals/session.d.ts +8 -28
- package/dist/src/evals/session.js +2 -1
- package/dist/src/evals/target.d.ts +1 -1
- package/dist/src/evals/target.js +1 -1
- package/dist/src/evals/types.d.ts +19 -15
- package/dist/src/eve-channel/create-request.d.ts +24 -0
- package/dist/src/eve-channel/create-request.js +1 -0
- package/dist/src/eve-channel/index.js +1 -1
- package/dist/src/eve-channel/request.d.ts +3 -12
- package/dist/src/eve-channel/request.js +2 -2
- package/dist/src/eve-channel/types.d.ts +4 -2
- package/dist/src/execution/dynamic-workflow/tool.js +1 -1
- package/dist/src/execution/legacy-session/turn-workflow.js +1 -1
- package/dist/src/execution/runtime-context.js +1 -1
- package/dist/src/execution/sandbox/bindings/vercel-lifecycle.d.ts +3 -3
- package/dist/src/execution/sandbox/bindings/vercel-lifecycle.js +1 -1
- package/dist/src/execution/sandbox/bindings/vercel-sdk-types.d.ts +1 -4
- package/dist/src/execution/sandbox/bindings/vercel.d.ts +1 -2
- package/dist/src/execution/sandbox/bindings/vercel.js +1 -1
- package/dist/src/execution/session/entry.js +1 -1
- package/dist/src/execution/session/handoff-steps.js +1 -1
- package/dist/src/execution/session/program.d.ts +2 -0
- package/dist/src/execution/session/program.js +1 -1
- package/dist/src/execution/session/turn-step.js +1 -1
- package/dist/src/execution/session/turn.js +1 -1
- package/dist/src/execution/session-inbox/protocol.js +1 -1
- package/dist/src/execution/tools/connection-search.js +1 -1
- package/dist/src/execution/tools/sleep-workflow.js +1 -1
- package/dist/src/execution/workflow-runtime.js +1 -1
- package/dist/src/experimental/evaluate/auto-model.js +2 -2
- package/dist/src/experimental/evaluate/evaluate.d.ts +7 -0
- package/dist/src/experimental/evaluate/evaluate.js +1 -0
- package/dist/src/harness/compaction.d.ts +3 -3
- package/dist/src/harness/compaction.js +1 -1
- package/dist/src/harness/request-envelope.d.ts +11 -0
- package/dist/src/harness/request-envelope.js +1 -0
- package/dist/src/harness/tool-loop.js +2 -2
- package/dist/src/instrumentation/prepare-trace-context.d.ts +2 -1
- package/dist/src/instrumentation/prepare-trace-context.js +1 -1
- package/dist/src/internal/application/package.js +1 -1
- package/dist/src/internal/authored-module-loader.d.ts +4 -1
- package/dist/src/internal/authored-module-loader.js +1 -1
- package/dist/src/internal/bundler/nitro-rolldown.d.ts +2 -0
- package/dist/src/internal/model-auth/transport.d.ts +3 -1
- package/dist/src/internal/model-auth/transport.js +1 -1
- package/dist/src/internal/nitro/host/build-extension.js +1 -1
- package/dist/src/internal/nitro/host/extension-capability-requirements.d.ts +1 -0
- package/dist/src/internal/nitro/host/extension-capability-requirements.js +1 -1
- package/dist/src/internal/nitro/host/extension-distribution.d.ts +1 -1
- package/dist/src/internal/nitro/host/extension-distribution.js +1 -1
- package/dist/src/internal/workflow-bundle/dynamic-tool-transform.js +1 -1
- package/dist/src/public/experimental/evaluate/index.d.ts +1 -0
- package/dist/src/public/experimental/evaluate/index.js +1 -1
- package/dist/src/public/models/anthropic/index.js +1 -1
- package/dist/src/public/sandbox/vercel-sandbox.d.ts +1 -1
- package/dist/src/public/sandbox/vercel.d.ts +1 -1
- package/dist/src/public/sandbox/vercel.js +1 -1
- package/dist/src/public/tools/index.d.ts +1 -0
- package/dist/src/public/tools/index.js +1 -1
- package/dist/src/react/use-eve-agent.d.ts +4 -0
- package/dist/src/react/use-eve-agent.js +1 -1
- package/dist/src/runtime/agent/resolve-model.js +1 -1
- package/dist/src/setup/flows/model-login-connection.js +1 -1
- package/dist/src/setup/scaffold/create/project.js +1 -1
- package/dist/src/subagents/handle-dispatch.js +1 -1
- package/dist/src/svelte/index.js +1 -1
- package/dist/src/svelte/use-eve-agent.d.ts +4 -0
- package/dist/src/svelte/use-eve-agent.js +1 -1
- package/dist/src/tools/definition.d.ts +2 -0
- package/dist/src/tools/definition.js +1 -1
- package/dist/src/tools/durable-callbacks.d.ts +8 -2
- package/dist/src/tools/durable-callbacks.js +1 -1
- package/dist/src/tools/durable-schema.d.ts +16 -0
- package/dist/src/tools/durable-schema.js +1 -0
- package/dist/src/vue/index.js +1 -1
- package/dist/src/vue/use-eve-agent.d.ts +4 -0
- package/dist/src/vue/use-eve-agent.js +1 -1
- package/docs/README.md +1 -0
- package/docs/channels/eve.mdx +20 -10
- package/docs/concepts/context-control.md +4 -0
- package/docs/concepts/sessions-runs-and-streaming.md +18 -3
- package/docs/evals/assertions.mdx +6 -6
- package/docs/evals/cases.mdx +59 -23
- package/docs/evals/judge.mdx +10 -8
- package/docs/evals/overview.mdx +6 -6
- package/docs/evals/reporters.mdx +1 -1
- package/docs/evals/targets.mdx +5 -0
- package/docs/guides/client/messages.mdx +5 -5
- package/docs/guides/client/overview.mdx +15 -1
- package/docs/guides/dynamic-capabilities.md +22 -0
- package/docs/guides/evaluate.md +58 -4
- package/docs/guides/frontend/overview.mdx +54 -5
- package/docs/guides/frontend/use-eve-agent-svelte.mdx +13 -8
- package/docs/guides/frontend/use-eve-agent-vue.mdx +13 -8
- package/docs/reference/typescript-api.md +38 -36
- package/package.json +2 -3
- package/dist/src/compiled/@vercel/sandbox-drives/LICENSE +0 -201
- package/dist/src/compiled/@vercel/sandbox-drives/_async-retry.d.ts +0 -8
- package/dist/src/compiled/@vercel/sandbox-drives/_workflow-serde.d.ts +0 -5
- package/dist/src/compiled/@vercel/sandbox-drives/api-client/api-client.d.ts +0 -1815
- package/dist/src/compiled/@vercel/sandbox-drives/api-client/api-error.d.ts +0 -29
- package/dist/src/compiled/@vercel/sandbox-drives/api-client/base-client.d.ts +0 -39
- package/dist/src/compiled/@vercel/sandbox-drives/api-client/file-writer.d.ts +0 -66
- package/dist/src/compiled/@vercel/sandbox-drives/api-client/index.d.ts +0 -2
- package/dist/src/compiled/@vercel/sandbox-drives/api-client/validators.d.ts +0 -932
- package/dist/src/compiled/@vercel/sandbox-drives/api-client/with-retry.d.ts +0 -10
- package/dist/src/compiled/@vercel/sandbox-drives/auth/error.d.ts +0 -15
- package/dist/src/compiled/@vercel/sandbox-drives/auth/file.d.ts +0 -18
- package/dist/src/compiled/@vercel/sandbox-drives/auth/index.d.ts +0 -6
- package/dist/src/compiled/@vercel/sandbox-drives/auth/oauth.d.ts +0 -111
- package/dist/src/compiled/@vercel/sandbox-drives/auth/poll-for-token.d.ts +0 -28
- package/dist/src/compiled/@vercel/sandbox-drives/auth/project.d.ts +0 -40
- package/dist/src/compiled/@vercel/sandbox-drives/command.d.ts +0 -292
- package/dist/src/compiled/@vercel/sandbox-drives/constants.d.ts +0 -15
- package/dist/src/compiled/@vercel/sandbox-drives/execution-context.d.ts +0 -116
- package/dist/src/compiled/@vercel/sandbox-drives/filesystem.d.ts +0 -258
- package/dist/src/compiled/@vercel/sandbox-drives/index.d.ts +0 -14
- package/dist/src/compiled/@vercel/sandbox-drives/index.js +0 -9
- package/dist/src/compiled/@vercel/sandbox-drives/network-policy.d.ts +0 -169
- package/dist/src/compiled/@vercel/sandbox-drives/proxy.d.ts +0 -55
- package/dist/src/compiled/@vercel/sandbox-drives/sandbox-user.d.ts +0 -211
- package/dist/src/compiled/@vercel/sandbox-drives/sandbox.d.ts +0 -1287
- package/dist/src/compiled/@vercel/sandbox-drives/session.d.ts +0 -435
- package/dist/src/compiled/@vercel/sandbox-drives/snapshot.d.ts +0 -238
- package/dist/src/compiled/@vercel/sandbox-drives/utils/get-credentials.d.ts +0 -21
- package/dist/src/compiled/@vercel/sandbox-drives/utils/paginator.d.ts +0 -16
- package/dist/src/compiled/@vercel/sandbox-drives/utils/resolveSignal.d.ts +0 -15
- package/dist/src/compiled/@vercel/sandbox-drives/utils/sandbox-snapshot.d.ts +0 -11
- package/dist/src/compiled/@vercel/sandbox-drives/utils/types.d.ts +0 -11
- package/dist/src/compiled/_chunks/node/auth-8aQozzfi.js +0 -2
- package/dist/src/compiled/_chunks/node/auth-Bvv0xGTY.js +0 -2
- package/dist/src/compiled/_chunks/node/esm-Fqlolk7e.js +0 -7
- package/dist/src/compiled/_chunks/node/version-BC6t2Txc.js +0 -1
- package/dist/src/compiled/_chunks/node/version-DSQqVZ5T.js +0 -1
- package/dist/src/compiled/_chunks/node/xdg-app-paths-F-QHrdza.js +0 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { BaseClient, Parsed, RequestParams } from "./base-client.js";
|
|
2
|
-
import { CommandData, CommandFinishedData, CommandFinishedResponse, CommandResponse, CreateSnapshotResponse, InteractiveSessionResponse, LogOutputLine, SessionResponse, SnapshotResponse, StopSessionResponse } from "./validators.js";
|
|
2
|
+
import { CommandData, CommandFinishedData, CommandFinishedResponse, CommandResponse, CreateSnapshotResponse, InteractiveSessionResponse, LogOutputLine, SandboxMetaData, SessionResponse, SnapshotResponse, StopSessionResponse } from "./validators.js";
|
|
3
3
|
import { FileWriter } from "./file-writer.js";
|
|
4
4
|
import { NetworkPolicy } from "../network-policy.js";
|
|
5
5
|
import { WithPrivate } from "../utils/types.js";
|
|
@@ -180,6 +180,7 @@ declare class APIClient extends BaseClient {
|
|
|
180
180
|
expiration?: number;
|
|
181
181
|
deleteEvicted?: boolean;
|
|
182
182
|
};
|
|
183
|
+
mounts?: SandboxMetaData["mounts"];
|
|
183
184
|
region?: SandboxRegion;
|
|
184
185
|
failoverRegions?: SandboxRegion[];
|
|
185
186
|
signal?: AbortSignal;
|
|
@@ -293,6 +294,10 @@ declare class APIClient extends BaseClient {
|
|
|
293
294
|
statusUpdatedAt?: number | undefined;
|
|
294
295
|
cwd?: string | undefined;
|
|
295
296
|
tags?: Record<string, string> | undefined;
|
|
297
|
+
mounts?: Record<string, {
|
|
298
|
+
drive: string;
|
|
299
|
+
mode: "snapshot" | "read-write";
|
|
300
|
+
}> | undefined;
|
|
296
301
|
snapshotExpiration?: number | undefined;
|
|
297
302
|
keepLastSnapshots?: {
|
|
298
303
|
count: number;
|
|
@@ -553,6 +558,10 @@ declare class APIClient extends BaseClient {
|
|
|
553
558
|
statusUpdatedAt?: number | undefined;
|
|
554
559
|
cwd?: string | undefined;
|
|
555
560
|
tags?: Record<string, string> | undefined;
|
|
561
|
+
mounts?: Record<string, {
|
|
562
|
+
drive: string;
|
|
563
|
+
mode: "snapshot" | "read-write";
|
|
564
|
+
}> | undefined;
|
|
556
565
|
snapshotExpiration?: number | undefined;
|
|
557
566
|
keepLastSnapshots?: {
|
|
558
567
|
count: number;
|
|
@@ -1010,6 +1019,50 @@ declare class APIClient extends BaseClient {
|
|
|
1010
1019
|
count: string;
|
|
1011
1020
|
} | undefined;
|
|
1012
1021
|
}>>;
|
|
1022
|
+
listDrives(params: {
|
|
1023
|
+
projectId: string;
|
|
1024
|
+
limit?: number;
|
|
1025
|
+
cursor?: string;
|
|
1026
|
+
sortBy?: "createdAt" | "updatedAt" | "name";
|
|
1027
|
+
sortOrder?: "asc" | "desc";
|
|
1028
|
+
namePrefix?: string;
|
|
1029
|
+
signal?: AbortSignal;
|
|
1030
|
+
}): Promise<Parsed<{
|
|
1031
|
+
drives: {
|
|
1032
|
+
id: string;
|
|
1033
|
+
name: string;
|
|
1034
|
+
projectId: string;
|
|
1035
|
+
region: string;
|
|
1036
|
+
maxSizeBytes: number;
|
|
1037
|
+
createdAt: number;
|
|
1038
|
+
updatedAt: number;
|
|
1039
|
+
currentSessionId?: string | undefined;
|
|
1040
|
+
currentSandboxName?: string | undefined;
|
|
1041
|
+
}[];
|
|
1042
|
+
pagination: {
|
|
1043
|
+
count: number;
|
|
1044
|
+
next: string | null;
|
|
1045
|
+
};
|
|
1046
|
+
}>>;
|
|
1047
|
+
getOrCreateDrive(params: {
|
|
1048
|
+
projectId: string;
|
|
1049
|
+
name: string;
|
|
1050
|
+
region?: string;
|
|
1051
|
+
maxSizeBytes?: number;
|
|
1052
|
+
signal?: AbortSignal;
|
|
1053
|
+
}): Promise<Parsed<{
|
|
1054
|
+
drive: {
|
|
1055
|
+
id: string;
|
|
1056
|
+
name: string;
|
|
1057
|
+
projectId: string;
|
|
1058
|
+
region: string;
|
|
1059
|
+
maxSizeBytes: number;
|
|
1060
|
+
createdAt: number;
|
|
1061
|
+
updatedAt: number;
|
|
1062
|
+
currentSessionId?: string | undefined;
|
|
1063
|
+
currentSandboxName?: string | undefined;
|
|
1064
|
+
};
|
|
1065
|
+
}>>;
|
|
1013
1066
|
writeFiles(params: {
|
|
1014
1067
|
sessionId: string;
|
|
1015
1068
|
cwd: string;
|
|
@@ -1193,6 +1246,10 @@ declare class APIClient extends BaseClient {
|
|
|
1193
1246
|
statusUpdatedAt?: number | undefined;
|
|
1194
1247
|
cwd?: string | undefined;
|
|
1195
1248
|
tags?: Record<string, string> | undefined;
|
|
1249
|
+
mounts?: Record<string, {
|
|
1250
|
+
drive: string;
|
|
1251
|
+
mode: "snapshot" | "read-write";
|
|
1252
|
+
}> | undefined;
|
|
1196
1253
|
snapshotExpiration?: number | undefined;
|
|
1197
1254
|
keepLastSnapshots?: {
|
|
1198
1255
|
count: number;
|
|
@@ -1444,6 +1501,10 @@ declare class APIClient extends BaseClient {
|
|
|
1444
1501
|
statusUpdatedAt?: number | undefined;
|
|
1445
1502
|
cwd?: string | undefined;
|
|
1446
1503
|
tags?: Record<string, string> | undefined;
|
|
1504
|
+
mounts?: Record<string, {
|
|
1505
|
+
drive: string;
|
|
1506
|
+
mode: "snapshot" | "read-write";
|
|
1507
|
+
}> | undefined;
|
|
1447
1508
|
snapshotExpiration?: number | undefined;
|
|
1448
1509
|
keepLastSnapshots?: {
|
|
1449
1510
|
count: number;
|
|
@@ -1456,6 +1517,23 @@ declare class APIClient extends BaseClient {
|
|
|
1456
1517
|
next: string | null;
|
|
1457
1518
|
};
|
|
1458
1519
|
}>>;
|
|
1520
|
+
deleteDrive(params: {
|
|
1521
|
+
projectId: string;
|
|
1522
|
+
name: string;
|
|
1523
|
+
signal?: AbortSignal;
|
|
1524
|
+
}): Promise<Parsed<{
|
|
1525
|
+
drive: {
|
|
1526
|
+
id: string;
|
|
1527
|
+
name: string;
|
|
1528
|
+
projectId: string;
|
|
1529
|
+
region: string;
|
|
1530
|
+
maxSizeBytes: number;
|
|
1531
|
+
createdAt: number;
|
|
1532
|
+
updatedAt: number;
|
|
1533
|
+
currentSessionId?: string | undefined;
|
|
1534
|
+
currentSandboxName?: string | undefined;
|
|
1535
|
+
};
|
|
1536
|
+
}>>;
|
|
1459
1537
|
updateSandbox(params: {
|
|
1460
1538
|
name: string;
|
|
1461
1539
|
projectId: string;
|
|
@@ -1477,6 +1555,7 @@ declare class APIClient extends BaseClient {
|
|
|
1477
1555
|
currentSnapshotId?: string;
|
|
1478
1556
|
region?: SandboxRegion;
|
|
1479
1557
|
failoverRegions?: SandboxRegion[];
|
|
1558
|
+
mounts?: SandboxMetaData["mounts"];
|
|
1480
1559
|
signal?: AbortSignal;
|
|
1481
1560
|
}): Promise<Parsed<{
|
|
1482
1561
|
sandbox: {
|
|
@@ -1588,6 +1667,10 @@ declare class APIClient extends BaseClient {
|
|
|
1588
1667
|
statusUpdatedAt?: number | undefined;
|
|
1589
1668
|
cwd?: string | undefined;
|
|
1590
1669
|
tags?: Record<string, string> | undefined;
|
|
1670
|
+
mounts?: Record<string, {
|
|
1671
|
+
drive: string;
|
|
1672
|
+
mode: "snapshot" | "read-write";
|
|
1673
|
+
}> | undefined;
|
|
1591
1674
|
snapshotExpiration?: number | undefined;
|
|
1592
1675
|
keepLastSnapshots?: {
|
|
1593
1676
|
count: number;
|
|
@@ -1716,6 +1799,10 @@ declare class APIClient extends BaseClient {
|
|
|
1716
1799
|
statusUpdatedAt?: number | undefined;
|
|
1717
1800
|
cwd?: string | undefined;
|
|
1718
1801
|
tags?: Record<string, string> | undefined;
|
|
1802
|
+
mounts?: Record<string, {
|
|
1803
|
+
drive: string;
|
|
1804
|
+
mode: "snapshot" | "read-write";
|
|
1805
|
+
}> | undefined;
|
|
1719
1806
|
snapshotExpiration?: number | undefined;
|
|
1720
1807
|
keepLastSnapshots?: {
|
|
1721
1808
|
count: number;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { Command, CommandData, CommandFinishedData, CommandFinishedResponse, CommandResponse, CreateSnapshotResponse, InteractiveSessionResponse, LogError, LogLine, LogLineData, LogOutputLine, Sandbox, SandboxMetaData, SandboxRoute, SandboxRouteData, Session, SessionMetaData, SessionResponse, Snapshot, SnapshotMetadata, SnapshotResponse, SnapshotTreeNode, SnapshotTreeNodeData, StopSessionResponse } from "./validators.js";
|
|
1
|
+
import { Command, CommandData, CommandFinishedData, CommandFinishedResponse, CommandResponse, CreateSnapshotResponse, Drive, DriveMetadata, InteractiveSessionResponse, LogError, LogLine, LogLineData, LogOutputLine, Sandbox, SandboxMetaData, SandboxRoute, SandboxRouteData, Session, SessionMetaData, SessionResponse, Snapshot, SnapshotMetadata, SnapshotResponse, SnapshotTreeNode, SnapshotTreeNodeData, StopSessionResponse } from "./validators.js";
|
|
2
2
|
import { APIClient } from "./api-client.js";
|
|
@@ -522,6 +522,18 @@ declare const SnapshotResponse: z.ZodObject<{
|
|
|
522
522
|
parentId: z.ZodOptional<z.ZodString>;
|
|
523
523
|
}, z.core.$strip>;
|
|
524
524
|
}, z.core.$strip>;
|
|
525
|
+
declare const Drive: z.ZodObject<{
|
|
526
|
+
id: z.ZodString;
|
|
527
|
+
name: z.ZodString;
|
|
528
|
+
projectId: z.ZodString;
|
|
529
|
+
region: z.ZodString;
|
|
530
|
+
maxSizeBytes: z.ZodNumber;
|
|
531
|
+
currentSessionId: z.ZodOptional<z.ZodString>;
|
|
532
|
+
currentSandboxName: z.ZodOptional<z.ZodString>;
|
|
533
|
+
createdAt: z.ZodNumber;
|
|
534
|
+
updatedAt: z.ZodNumber;
|
|
535
|
+
}, z.core.$strip>;
|
|
536
|
+
type DriveMetadata = z.infer<typeof Drive>;
|
|
525
537
|
declare const Sandbox: z.ZodObject<{
|
|
526
538
|
name: z.ZodString;
|
|
527
539
|
persistent: z.ZodBoolean;
|
|
@@ -636,6 +648,20 @@ declare const Sandbox: z.ZodObject<{
|
|
|
636
648
|
statusUpdatedAt: z.ZodOptional<z.ZodNumber>;
|
|
637
649
|
cwd: z.ZodOptional<z.ZodString>;
|
|
638
650
|
tags: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
651
|
+
mounts: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodPipe<z.ZodObject<{
|
|
652
|
+
drive: z.ZodString;
|
|
653
|
+
mode: z.ZodOptional<z.ZodEnum<{
|
|
654
|
+
snapshot: "snapshot";
|
|
655
|
+
"read-write": "read-write";
|
|
656
|
+
"read-only": "read-only";
|
|
657
|
+
}>>;
|
|
658
|
+
}, z.core.$strip>, z.ZodTransform<{
|
|
659
|
+
drive: string;
|
|
660
|
+
mode: "snapshot" | "read-write";
|
|
661
|
+
}, {
|
|
662
|
+
drive: string;
|
|
663
|
+
mode?: "snapshot" | "read-write" | "read-only" | undefined;
|
|
664
|
+
}>>>>;
|
|
639
665
|
snapshotExpiration: z.ZodOptional<z.ZodNumber>;
|
|
640
666
|
keepLastSnapshots: z.ZodOptional<z.ZodObject<{
|
|
641
667
|
count: z.ZodNumber;
|
|
@@ -876,6 +902,20 @@ declare const StopSessionResponse: z.ZodObject<{
|
|
|
876
902
|
statusUpdatedAt: z.ZodOptional<z.ZodNumber>;
|
|
877
903
|
cwd: z.ZodOptional<z.ZodString>;
|
|
878
904
|
tags: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
905
|
+
mounts: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodPipe<z.ZodObject<{
|
|
906
|
+
drive: z.ZodString;
|
|
907
|
+
mode: z.ZodOptional<z.ZodEnum<{
|
|
908
|
+
snapshot: "snapshot";
|
|
909
|
+
"read-write": "read-write";
|
|
910
|
+
"read-only": "read-only";
|
|
911
|
+
}>>;
|
|
912
|
+
}, z.core.$strip>, z.ZodTransform<{
|
|
913
|
+
drive: string;
|
|
914
|
+
mode: "snapshot" | "read-write";
|
|
915
|
+
}, {
|
|
916
|
+
drive: string;
|
|
917
|
+
mode?: "snapshot" | "read-write" | "read-only" | undefined;
|
|
918
|
+
}>>>>;
|
|
879
919
|
snapshotExpiration: z.ZodOptional<z.ZodNumber>;
|
|
880
920
|
keepLastSnapshots: z.ZodOptional<z.ZodObject<{
|
|
881
921
|
count: z.ZodNumber;
|
|
@@ -903,5 +943,5 @@ declare const StopSessionResponse: z.ZodObject<{
|
|
|
903
943
|
}, z.core.$strip>>;
|
|
904
944
|
}, z.core.$strip>;
|
|
905
945
|
//#endregion
|
|
906
|
-
export { Command, CommandData, CommandFinishedData, CommandFinishedResponse, CommandResponse, CreateSnapshotResponse, InteractiveSessionResponse, LogError, LogLine, LogLineData, LogOutputLine, Sandbox, SandboxMetaData, SandboxRoute, SandboxRouteData, Session, SessionMetaData, SessionResponse, Snapshot, SnapshotMetadata, SnapshotResponse, SnapshotTreeNode, SnapshotTreeNodeData, StopSessionResponse };
|
|
946
|
+
export { Command, CommandData, CommandFinishedData, CommandFinishedResponse, CommandResponse, CreateSnapshotResponse, Drive, DriveMetadata, InteractiveSessionResponse, LogError, LogLine, LogLineData, LogOutputLine, Sandbox, SandboxMetaData, SandboxRoute, SandboxRouteData, Session, SessionMetaData, SessionResponse, Snapshot, SnapshotMetadata, SnapshotResponse, SnapshotTreeNode, SnapshotTreeNodeData, StopSessionResponse };
|
|
907
947
|
//# sourceMappingURL=validators.d.ts.map
|
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
type RUNTIMES = "node26" | "node24" | "node22" | "python3.13";
|
|
3
3
|
type ManagedImage = "universal" | "node:22" | "node:24" | "node:26" | "python:3.14" | "ubuntu" | "arch";
|
|
4
4
|
/**
|
|
5
|
-
* Regions a sandbox can
|
|
6
|
-
* other region string is accepted too.
|
|
5
|
+
* Regions a sandbox, snapshot, or drive can live in. More regions may
|
|
6
|
+
* become available, so any other region string is accepted too.
|
|
7
7
|
*/
|
|
8
|
-
type SandboxRegion = "iad1" | "sfo1" | "cle1" | "cdg1" | (string & {});
|
|
8
|
+
type SandboxRegion = "iad1" | "sfo1" | "cle1" | "cdg1" | "fra1" | "arn1" | "sin1" | "pdx1" | "lhr1" | "icn1" | "bom1" | "cpt1" | "dub1" | "gru1" | "hkg1" | "syd1" | "yul1" | "hnd1" | "kix1" | (string & {});
|
|
9
9
|
/**
|
|
10
10
|
* Region a sandbox runs in when none is requested.
|
|
11
11
|
*/
|
|
@@ -23,7 +23,7 @@ interface GetOrCreateDriveParams {
|
|
|
23
23
|
*/
|
|
24
24
|
region?: SandboxRegion;
|
|
25
25
|
/**
|
|
26
|
-
*
|
|
26
|
+
* Drive size in bytes. Defaults to 1 TiB.
|
|
27
27
|
*/
|
|
28
28
|
maxSize?: number;
|
|
29
29
|
/**
|
|
@@ -33,7 +33,7 @@ interface GetOrCreateDriveParams {
|
|
|
33
33
|
}
|
|
34
34
|
/**
|
|
35
35
|
* A Drive is a persistent, bottomless storage that can be attached and detached to Sandboxes.
|
|
36
|
-
* Drives can be mounted as read-write or read-only, at a configurable path with `Sandbox.create()`.
|
|
36
|
+
* Drives can be mounted as read-write or as read-only snapshots, at a configurable path with `Sandbox.create()`.
|
|
37
37
|
*
|
|
38
38
|
* Use {@link Drive.getOrCreate} to construct.
|
|
39
39
|
* @hideconstructor
|
|
@@ -47,6 +47,10 @@ declare class Drive {
|
|
|
47
47
|
* @internal
|
|
48
48
|
*/
|
|
49
49
|
private ensureClient;
|
|
50
|
+
/**
|
|
51
|
+
* Unique ID of this drive.
|
|
52
|
+
*/
|
|
53
|
+
get driveId(): string;
|
|
50
54
|
/**
|
|
51
55
|
* The name of the drive.
|
|
52
56
|
*/
|
|
@@ -79,6 +83,13 @@ declare class Drive {
|
|
|
79
83
|
* Timestamp when the drive was last updated.
|
|
80
84
|
*/
|
|
81
85
|
get updatedAt(): Date;
|
|
86
|
+
/**
|
|
87
|
+
* Mount this drive as a read-only snapshot.
|
|
88
|
+
*/
|
|
89
|
+
snapshot(): {
|
|
90
|
+
drive: string;
|
|
91
|
+
mode: "snapshot";
|
|
92
|
+
};
|
|
82
93
|
/**
|
|
83
94
|
* Serialize a Drive instance to plain data for @workflow/serde.
|
|
84
95
|
*
|
|
@@ -6,8 +6,9 @@ import { Command, CommandFinished, CommandOutput, SerializedCommand, SerializedC
|
|
|
6
6
|
import { SerializedSnapshot, Snapshot } from "./snapshot.js";
|
|
7
7
|
import { ExecutionContext } from "./execution-context.js";
|
|
8
8
|
import { Session } from "./session.js";
|
|
9
|
+
import { Drive, SerializedDrive } from "./drive.js";
|
|
9
10
|
import { FileSystem } from "./filesystem.js";
|
|
10
11
|
import { SandboxUser, SandboxUserAlreadyExistsError } from "./sandbox-user.js";
|
|
11
|
-
import { Sandbox, SerializedSandbox } from "./sandbox.js";
|
|
12
|
+
import { Sandbox, SandboxMountMode, SandboxMounts, SerializedSandbox } from "./sandbox.js";
|
|
12
13
|
import { InvalidRequestProxyHandler, ProxyHandler, ProxyMeta, defineSandboxProxy } from "./proxy.js";
|
|
13
|
-
export { APIError, Command, CommandFinished, type CommandOutput, DEFAULT_SANDBOX_REGION, type ExecutionContext, FileSystem, type InvalidRequestProxyHandler, type NetworkPolicy, type NetworkPolicyKeyValueMatcher, type NetworkPolicyMatch, type NetworkPolicyMatcher, type NetworkPolicyRule, type NetworkTransformer, type ProxyHandler, type ProxyMeta, Sandbox, type SandboxRegion, SandboxUser, SandboxUserAlreadyExistsError, type SerializedCommand, type SerializedCommandFinished, type SerializedSandbox, type SerializedSnapshot, Session, Snapshot, type SnapshotTreeNodeData, StreamError, defineSandboxProxy };
|
|
14
|
+
export { APIError, Command, CommandFinished, type CommandOutput, DEFAULT_SANDBOX_REGION, Drive, type ExecutionContext, FileSystem, type InvalidRequestProxyHandler, type NetworkPolicy, type NetworkPolicyKeyValueMatcher, type NetworkPolicyMatch, type NetworkPolicyMatcher, type NetworkPolicyRule, type NetworkTransformer, type ProxyHandler, type ProxyMeta, Sandbox, type SandboxMountMode, type SandboxMounts, type SandboxRegion, SandboxUser, SandboxUserAlreadyExistsError, type SerializedCommand, type SerializedCommandFinished, type SerializedDrive, type SerializedSandbox, type SerializedSnapshot, Session, Snapshot, type SnapshotTreeNodeData, StreamError, defineSandboxProxy };
|