@tangle-network/sandbox 0.30.2-develop.20260820100122.dc85046 → 0.30.2-develop.20260820200640.75917

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 (35) hide show
  1. package/README.md +1 -0
  2. package/dist/abort-signal-si1WMfJb.js +31 -0
  3. package/dist/agent/index.d.ts +3 -3
  4. package/dist/agent/index.js +3 -3
  5. package/dist/{agent-run-outcome-TwIC-Ccd.d.ts → agent-run-outcome-CM7xD7Mg.d.ts} +1 -1
  6. package/dist/auth/index.d.ts +1 -1
  7. package/dist/browser-interactive-control-controller-B476gcui.d.ts +96 -0
  8. package/dist/browser-interactive-control-controller-wXQ7W5pT.js +276 -0
  9. package/dist/{client-CCKEVUaD.js → client-BfnJ44gF.js} +19 -6
  10. package/dist/{client-1OK1sjCh.d.ts → client-Do_HS671.d.ts} +20 -3
  11. package/dist/collaboration/index.d.ts +1 -1
  12. package/dist/collaboration/index.js +1 -1
  13. package/dist/core.d.ts +4 -4
  14. package/dist/core.js +2 -2
  15. package/dist/{index-DAxioMfr.d.ts → index-ebsVOlUc.d.ts} +2 -2
  16. package/dist/index.d.ts +11 -9
  17. package/dist/index.js +7 -6
  18. package/dist/interactive-control.d.ts +2 -0
  19. package/dist/interactive-control.js +2 -0
  20. package/dist/{runtime-api-TVLbV10b.js → runtime-api-B0tx7NJM.js} +2 -6
  21. package/dist/runtime.d.ts +3 -3
  22. package/dist/runtime.js +2 -1
  23. package/dist/{sandbox-DM-VD8ja.js → sandbox-AUHcCJe1.js} +1418 -565
  24. package/dist/{sandbox-Caev7isY.d.ts → sandbox-Cr-4qzaA.d.ts} +134 -187
  25. package/dist/tangle/index.d.ts +1 -1
  26. package/dist/tangle/index.js +1 -1
  27. package/dist/{tangle-lzUyvhKp.js → tangle-iDk_s8vt.js} +1 -1
  28. package/dist/terminal-stream-4KNJ6SmL.d.ts +256 -0
  29. package/dist/{types-D_ykdqn6.d.ts → types-BwYLVqxX.d.ts} +14 -250
  30. package/package.json +9 -4
  31. /package/dist/{collaboration-COCXdRrk.js → collaboration-DQD9kCdN.js} +0 -0
  32. /package/dist/{errors-Bdy5jXzc.d.ts → errors-CQOvGddH.d.ts} +0 -0
  33. /package/dist/{index-DtRFVx5U.d.ts → index-Bq_z_u6A.d.ts} +0 -0
  34. /package/dist/{index-Cp1KYanB.d.ts → index-CMLW3u5K.d.ts} +0 -0
  35. /package/dist/{local-cli-auth-D4u7fsnH.js → local-cli-auth-CJmSpTjk.js} +0 -0
@@ -0,0 +1,256 @@
1
+ import { AgentInteractiveSessionControlClaim, AgentInteractiveSessionRef } from "@tangle-network/agent-interface";
2
+ import { z } from "zod";
3
+
4
+ //#region ../../../packages/runtime-contracts/dist/terminal-websocket.d.ts
5
+ /** Non-credential protocol selected during a successful terminal handshake. */
6
+ declare const TERMINAL_WS_ECHO_SUBPROTOCOL = "tangle.terminal.v1";
7
+ declare const terminalReadyMessageSchema: z.ZodObject<{
8
+ type: z.ZodLiteral<"ready">;
9
+ connectionId: z.ZodString;
10
+ sessionId: z.ZodString;
11
+ restored: z.ZodBoolean;
12
+ detachTimeoutMs: z.ZodNumber;
13
+ }, z.core.$strip>;
14
+ type TerminalReadyMessage = z.infer<typeof terminalReadyMessageSchema>;
15
+ type TerminalReadyInfo = Omit<TerminalReadyMessage, "type">;
16
+ declare const terminalExitMessageSchema: z.ZodObject<{
17
+ type: z.ZodLiteral<"exit">;
18
+ exitCode: z.ZodOptional<z.ZodNumber>;
19
+ exitSignal: z.ZodOptional<z.ZodString>;
20
+ }, z.core.$strip>;
21
+ type TerminalExitMessage = z.infer<typeof terminalExitMessageSchema>;
22
+ type TerminalExitInfo = Omit<TerminalExitMessage, "type">;
23
+ type TerminalStreamAuthFormat = "edge" | "sidecar-direct";
24
+ interface TerminalInteractiveSessionIdentity {
25
+ incarnationId: AgentInteractiveSessionRef["incarnationId"];
26
+ control: AgentInteractiveSessionControlClaim;
27
+ }
28
+ //#endregion
29
+ //#region src/scoped-token-types.d.ts
30
+ /**
31
+ * Public types for scoped consumer-side tokens.
32
+ *
33
+ * This module intentionally has no SDK implementation imports. Terminal
34
+ * streams and token requests share these contracts without depending on the
35
+ * SDK's aggregate types module.
36
+ */
37
+ /**
38
+ * Scope of a `box.mintScopedToken()` request. `session` and `project` mint
39
+ * SessionGateway read tokens. `session-runtime` and `read-only` mint sidecar
40
+ * capability tokens for browser-safe runtime access.
41
+ */
42
+ type ScopedTokenScope = "session" | "session-runtime" | "project" | "read-only";
43
+ interface MintScopedTokenBase {
44
+ /** TTL in minutes. Default 5; clamped to [1, 15]. */
45
+ ttlMinutes?: number;
46
+ /** Cancel the token request before it reaches the terminal dial. */
47
+ signal?: AbortSignal;
48
+ }
49
+ /** Options for `box.mintScopedToken()`, narrowed by consumer scope. */
50
+ type MintScopedTokenOptions = (MintScopedTokenBase & {
51
+ scope: "session"; /** Client-facing browser session ID. */
52
+ sessionId: string; /** Actual runtime session ID used to filter the sandbox event stream. */
53
+ runtimeSessionId: string;
54
+ }) | (MintScopedTokenBase & {
55
+ scope: "session-runtime";
56
+ sessionId: string;
57
+ runtimeSessionId?: never;
58
+ }) | (MintScopedTokenBase & {
59
+ scope: "project" | "read-only";
60
+ sessionId?: never;
61
+ runtimeSessionId?: never;
62
+ });
63
+ /** Options for the server-side exact interactive-session token request. */
64
+ type MintInteractiveSessionTokenOptions = Pick<MintScopedTokenBase, "ttlMinutes" | "signal">;
65
+ /**
66
+ * Returned by `box.mintScopedToken()`. Use session/project tokens with
67
+ * `SessionGatewayClient`; use session-runtime/read-only tokens with
68
+ * `SandboxRuntimeClient`.
69
+ */
70
+ interface ScopedToken {
71
+ /** Bearer token (JWT) for the consumer selected by `scope`. */
72
+ token: string;
73
+ /** When the token expires. */
74
+ expiresAt: Date;
75
+ /** The runtime's direct edge URL. Use with runtime scopes; session/project
76
+ * tokens instead connect to the Sandbox API's `/session` WebSocket. */
77
+ runtimeUrl: string;
78
+ /** Browser-safe Sandbox API proxy base for terminal and runtime requests. */
79
+ sidecarProxyUrl: string;
80
+ /** Echo of the requested scope. */
81
+ scope: ScopedTokenScope;
82
+ }
83
+ //#endregion
84
+ //#region src/terminal-stream.d.ts
85
+ /** A protocol `error` control frame or a transport failure. */
86
+ declare class TerminalStreamError extends Error {
87
+ /** Protocol error code (e.g. `INIT_FAILED`) or `TRANSPORT` for socket faults. */
88
+ readonly code: string;
89
+ constructor(message: string, code: string);
90
+ }
91
+ /**
92
+ * Event callbacks, passed at construction (the same idiom as
93
+ * `SessionGatewayClient`'s `handlers` config). Registering them up front is
94
+ * load-bearing: the server replays PTY history immediately after `ready`, so
95
+ * a handler attached after connect would miss the replayed screen.
96
+ */
97
+ interface TerminalStreamHandlers {
98
+ /** Raw PTY output bytes (both live output and reattach history replay). */
99
+ onData?: (data: Uint8Array) => void;
100
+ onReady?: (info: TerminalReadyInfo) => void;
101
+ onExit?: (info: TerminalExitInfo) => void;
102
+ /** Protocol `error` frames and post-connect transport failures. */
103
+ onError?: (error: TerminalStreamError) => void;
104
+ /** Socket closed — by the server, the network, or a local `close()`. */
105
+ onClose?: (code: number, reason: string) => void;
106
+ }
107
+ /**
108
+ * Which WebSocket-subprotocol auth envelope to offer. A WebSocket client
109
+ * cannot set an Authorization header, so the bearer rides the
110
+ * `Sec-WebSocket-Protocol` offer — and the two dialable endpoints expect
111
+ * DIFFERENT envelopes:
112
+ *
113
+ * - `"edge"` (default): the public API proxy
114
+ * (`wss://<api>/v1/sidecar-proxy/{sidecarId}/terminals/{id}/ws`) expects
115
+ * `bearer.<base64url(token)>` — see `parseTerminalWsSubprotocolToken` in
116
+ * `products/sandbox/api/src/lib/terminal-websocket.ts`. The fixed
117
+ * `tangle.terminal.v1` marker is offered alongside the credential (see
118
+ * {@link TERMINAL_WS_ECHO_SUBPROTOCOL}).
119
+ * - `"sidecar-direct"`: the sidecar's own `/terminals/{id}/ws` route expects
120
+ * `tangle.bearer.<token>` plus the same `tangle.terminal.v1` echo marker —
121
+ * see `apps/sidecar/src/routes/ws-subprotocol-auth.ts`. Only
122
+ * platform-internal callers (and the composed integration tests) dial the
123
+ * sidecar directly.
124
+ */
125
+ /**
126
+ * Bearer credential for the dial: a token string, or a provider invoked on
127
+ * EVERY dial (including {@link TerminalStream.reconnect}). The provider
128
+ * receives that dial's AbortSignal so token minting observes cancellation.
129
+ * Scoped terminal tokens are short-lived (the platform clamps them to <= 15
130
+ * minutes), so a provider lets the SDK re-mint a fresh token per dial.
131
+ */
132
+ type TerminalStreamToken = string | ScopedToken | ((signal?: AbortSignal) => Promise<string | ScopedToken> | string | ScopedToken);
133
+ /** Authority refreshed before an interactive stream reconnects. */
134
+ interface TerminalStreamReconnectBinding {
135
+ incarnationId: TerminalInteractiveSessionIdentity["incarnationId"];
136
+ control: TerminalInteractiveSessionIdentity["control"];
137
+ /** Release a claim if the new socket cannot be opened. */
138
+ onFailure?: () => Promise<void> | void;
139
+ }
140
+ /** Internal SDK hook that reclaims interactive authority before reconnect. */
141
+ interface TerminalStreamReconnectAuthority {
142
+ acquire(signal?: AbortSignal): Promise<TerminalStreamReconnectBinding>;
143
+ }
144
+ interface TerminalStreamOptions {
145
+ /**
146
+ * Absolute URL of the terminal WebSocket endpoint. `http(s)` URLs are
147
+ * converted to `ws(s)` automatically.
148
+ */
149
+ url: string;
150
+ /**
151
+ * Bearer token carried in the auth subprotocol (see `authFormat`) — a
152
+ * string, or a provider re-invoked on every dial so short-lived scoped
153
+ * tokens stay fresh across reconnects.
154
+ */
155
+ token: TerminalStreamToken;
156
+ /**
157
+ * PTY connection id — also sent in the `init` frame; the server rejects a
158
+ * mismatch with the URL's id. Reusing an id reattaches the existing PTY.
159
+ */
160
+ connectionId: string;
161
+ cols?: number;
162
+ rows?: number;
163
+ /** Command to run when the id has no live PTY (defaults to the shell). */
164
+ command?: string;
165
+ cwd?: string;
166
+ env?: Record<string, string>;
167
+ /**
168
+ * Exact interactive-agent incarnation. Ordinary terminal consumers omit
169
+ * both interactive fields and retain the existing wire contract.
170
+ */
171
+ incarnationId?: TerminalInteractiveSessionIdentity["incarnationId"];
172
+ /** Exact active control claim for the interactive-agent incarnation. */
173
+ control?: TerminalInteractiveSessionIdentity["control"];
174
+ /** Auth subprotocol envelope. Default `"edge"`. */
175
+ authFormat?: TerminalStreamAuthFormat;
176
+ handlers?: TerminalStreamHandlers;
177
+ /** Reject `connect()` if `ready` has not arrived within this window. */
178
+ connectTimeoutMs?: number;
179
+ /** Cancel token resolution or an in-progress WebSocket handshake. */
180
+ signal?: AbortSignal;
181
+ /** Reclaim interactive authority before a reconnecting dial. */
182
+ reconnectAuthority?: TerminalStreamReconnectAuthority;
183
+ }
184
+ /**
185
+ * Client for one terminal WebSocket connection. Construct via
186
+ * {@link TerminalStream.connect}, which resolves once the server
187
+ * acknowledges the attach with `ready` (history replay then streams through
188
+ * `handlers.onData`).
189
+ */
190
+ declare class TerminalStream {
191
+ private readonly ws;
192
+ private readonly options;
193
+ private readonly interactiveIdentity;
194
+ private readonly initMessage;
195
+ private readonly handlers;
196
+ private readyInfo;
197
+ private closed;
198
+ private closeWaiters;
199
+ private readonly textDecoder;
200
+ private reconnectInFlight?;
201
+ /**
202
+ * Dial the endpoint, send `init` as the first frame, and resolve once the
203
+ * server responds `ready`. Rejects on a protocol `error` frame, a socket
204
+ * close/failure before `ready`, or the connect timeout — always with the
205
+ * reason the server gave. A token PROVIDER is awaited here, before the
206
+ * socket opens, so every dial (first connect and each reconnect) carries a
207
+ * fresh credential.
208
+ */
209
+ static connect(options: TerminalStreamOptions): Promise<TerminalStream>;
210
+ private constructor();
211
+ private establish;
212
+ private handleMessage;
213
+ /** PTY connection id this stream is attached to. */
214
+ get connectionId(): string;
215
+ /** The server's `ready` acknowledgement. Set once `connect()` resolves. */
216
+ get ready(): TerminalReadyInfo;
217
+ /** True while the socket is open. */
218
+ get isOpen(): boolean;
219
+ /**
220
+ * Send input keystrokes to the PTY. `Uint8Array` input is decoded as
221
+ * UTF-8 (the wire protocol carries input as JSON text). Input larger than
222
+ * the server's 1 MiB frame cap is split across multiple `input` frames in
223
+ * order on the same socket, so delivery order is preserved.
224
+ */
225
+ write(data: string | Uint8Array): void;
226
+ /** Resize the PTY. */
227
+ resize(cols: number, rows: number): void;
228
+ /**
229
+ * Detach cleanly: close the socket and resolve once the close completes.
230
+ * The PTY survives server-side for `ready.detachTimeoutMs` (5 minutes
231
+ * today) — reattach within that window via {@link reconnect} (or a fresh
232
+ * `connect()` with the same connectionId) to replay history and continue.
233
+ */
234
+ close(): Promise<void>;
235
+ /**
236
+ * Re-dial the same endpoint with the same connectionId on a fresh socket
237
+ * — the server reattaches the PTY and replays its buffered history. When
238
+ * the stream was constructed with a token PROVIDER, it is re-invoked for
239
+ * the new dial (scoped terminal tokens expire within minutes, so the
240
+ * original credential may be dead by reconnect time); with a plain string
241
+ * token, pass a fresh `token` override yourself when it may have expired.
242
+ * `handlers` rebinds callbacks for the new stream.
243
+ */
244
+ reconnect(overrides?: {
245
+ token?: TerminalStreamToken;
246
+ handlers?: TerminalStreamHandlers;
247
+ cols?: number;
248
+ rows?: number;
249
+ signal?: AbortSignal;
250
+ }): Promise<TerminalStream>;
251
+ private reconnectOnce;
252
+ private handlersForReconnect;
253
+ private assertOpen;
254
+ }
255
+ //#endregion
256
+ export { TerminalStreamReconnectAuthority as a, MintScopedTokenOptions as c, TERMINAL_WS_ECHO_SUBPROTOCOL as d, TerminalExitInfo as f, TerminalStreamAuthFormat as h, TerminalStreamOptions as i, ScopedToken as l, TerminalReadyInfo as m, TerminalStreamError as n, TerminalStreamToken as o, TerminalInteractiveSessionIdentity as p, TerminalStreamHandlers as r, MintInteractiveSessionTokenOptions as s, TerminalStream as t, ScopedTokenScope as u };
@@ -1,214 +1,8 @@
1
+ import { r as TerminalStreamHandlers, t as TerminalStream } from "./terminal-stream-4KNJ6SmL.js";
1
2
  import * as _$_tangle_network_agent_interface0 from "@tangle-network/agent-interface";
2
3
  import { AgentExactRunControlRef, AgentProfile, AgentProfileCapabilities, AgentProfileConfidential, AgentProfileValidationResult, HarnessType, ReasoningEffort } from "@tangle-network/agent-interface";
3
4
  import { z } from "zod";
4
5
 
5
- //#region src/terminal-stream.d.ts
6
- /**
7
- * TerminalStream — typed client for the sandbox terminal WebSocket protocol.
8
- *
9
- * Drives a live PTY session (an interactive harness TUI or a plain shell)
10
- * from the caller's own program: binary frames stream raw PTY output bytes,
11
- * TEXT JSON frames carry the control protocol. The wire contract is defined
12
- * by the sidecar in `apps/sidecar/src/terminal/websocket-protocol.ts` (the
13
- * source of truth for these message shapes — its zod schemas cannot be
14
- * imported here without pulling sidecar dependencies into the SDK bundle,
15
- * so the types are mirrored locally):
16
- *
17
- * client → server (TEXT JSON):
18
- * init {connectionId?, cols, rows, command?, cwd?, env?} — MUST be first
19
- * input {data}
20
- * resize {cols, rows}
21
- * server → client (TEXT JSON):
22
- * ready {connectionId, sessionId, restored, detachTimeoutMs}
23
- * exit {exitCode?, exitSignal?}
24
- * error {code, message}
25
- * rec / rec.done — recording tee frames for the platform's session
26
- * capture consumer; not part of the client surface
27
- * server → client (BINARY): raw PTY output bytes
28
- *
29
- * Detach/reconnect: the server keeps the PTY alive for `detachTimeoutMs`
30
- * (5 minutes today) after the socket closes; re-dialing with the SAME
31
- * connectionId reattaches and replays the buffered output history, so a
32
- * fresh client repaints the current screen.
33
- *
34
- * Browser-safe: uses the global `WebSocket` (browsers, Workers, Node >= 22)
35
- * and never imports `ws` — the same environment contract as
36
- * `session-gateway/client.ts`.
37
- */
38
- /** Ready acknowledgement — the PTY is attached and history replay follows. */
39
- interface TerminalReadyInfo {
40
- connectionId: string;
41
- sessionId: string;
42
- /** True when an existing PTY was reattached (its history is replayed). */
43
- restored: boolean;
44
- /** How long (ms) the server keeps the PTY alive after this socket closes. */
45
- detachTimeoutMs: number;
46
- }
47
- /** Terminal process exit notification. */
48
- interface TerminalExitInfo {
49
- exitCode?: number;
50
- exitSignal?: string;
51
- }
52
- /** A protocol `error` control frame or a transport failure. */
53
- declare class TerminalStreamError extends Error {
54
- /** Protocol error code (e.g. `INIT_FAILED`) or `TRANSPORT` for socket faults. */
55
- readonly code: string;
56
- constructor(message: string, code: string);
57
- }
58
- /**
59
- * Event callbacks, passed at construction (the same idiom as
60
- * `SessionGatewayClient`'s `handlers` config). Registering them up front is
61
- * load-bearing: the server replays PTY history immediately after `ready`, so
62
- * a handler attached after connect would miss the replayed screen.
63
- */
64
- interface TerminalStreamHandlers {
65
- /** Raw PTY output bytes (both live output and reattach history replay). */
66
- onData?: (data: Uint8Array) => void;
67
- onReady?: (info: TerminalReadyInfo) => void;
68
- onExit?: (info: TerminalExitInfo) => void;
69
- /** Protocol `error` frames and post-connect transport failures. */
70
- onError?: (error: TerminalStreamError) => void;
71
- /** Socket closed — by the server, the network, or a local `close()`. */
72
- onClose?: (code: number, reason: string) => void;
73
- }
74
- /**
75
- * Which WebSocket-subprotocol auth envelope to offer. A WebSocket client
76
- * cannot set an Authorization header, so the bearer rides the
77
- * `Sec-WebSocket-Protocol` offer — and the two dialable endpoints expect
78
- * DIFFERENT envelopes:
79
- *
80
- * - `"edge"` (default): the public API proxy
81
- * (`wss://<api>/v1/sidecar-proxy/{sidecarId}/terminals/{id}/ws`) expects
82
- * `bearer.<base64url(token)>` — see `parseTerminalWsSubprotocolToken` in
83
- * `products/sandbox/api/src/lib/terminal-websocket.ts`. The fixed
84
- * `tangle.terminal.v1` marker is offered alongside the credential (see
85
- * {@link TERMINAL_WS_ECHO_SUBPROTOCOL}).
86
- * - `"sidecar-direct"`: the sidecar's own `/terminals/{id}/ws` route expects
87
- * `tangle.bearer.<token>` plus the same `tangle.terminal.v1` echo marker —
88
- * see `apps/sidecar/src/routes/ws-subprotocol-auth.ts`. Only
89
- * platform-internal callers (and the composed integration tests) dial the
90
- * sidecar directly.
91
- */
92
- type TerminalStreamAuthFormat = "edge" | "sidecar-direct";
93
- /**
94
- * Bearer credential for the dial: a token string, or a provider invoked on
95
- * EVERY dial (including {@link TerminalStream.reconnect}). Scoped terminal
96
- * tokens are short-lived (the platform clamps them to <= 15 minutes), so a
97
- * reconnect after the detach window with the original string would be
98
- * rejected — a provider lets the SDK re-mint a fresh token per dial.
99
- */
100
- type TerminalStreamToken = string | (() => Promise<string> | string);
101
- interface TerminalStreamOptions {
102
- /**
103
- * Absolute URL of the terminal WebSocket endpoint. `http(s)` URLs are
104
- * converted to `ws(s)` automatically.
105
- */
106
- url: string;
107
- /**
108
- * Bearer token carried in the auth subprotocol (see `authFormat`) — a
109
- * string, or a provider re-invoked on every dial so short-lived scoped
110
- * tokens stay fresh across reconnects.
111
- */
112
- token: TerminalStreamToken;
113
- /**
114
- * PTY connection id — also sent in the `init` frame; the server rejects a
115
- * mismatch with the URL's id. Reusing an id reattaches the existing PTY.
116
- */
117
- connectionId: string;
118
- cols?: number;
119
- rows?: number;
120
- /** Command to run when the id has no live PTY (defaults to the shell). */
121
- command?: string;
122
- cwd?: string;
123
- env?: Record<string, string>;
124
- /** Auth subprotocol envelope. Default `"edge"`. */
125
- authFormat?: TerminalStreamAuthFormat;
126
- handlers?: TerminalStreamHandlers;
127
- /** Reject `connect()` if `ready` has not arrived within this window. */
128
- connectTimeoutMs?: number;
129
- }
130
- /**
131
- * Fixed non-credential marker offered on EVERY dial (both auth formats),
132
- * giving a spec-compliant server something safe to select into the 101's
133
- * `Sec-WebSocket-Protocol`. Two reasons it exists:
134
- *
135
- * 1. RFC 6455 §4.1 says a client that offered subprotocols MUST fail the
136
- * connection when the server selects none. Node's WebSocket (undici,
137
- * per the WHATWG spec) enforces this strictly; browsers are lenient and
138
- * tolerate a 101 with no selected subprotocol — which is why the
139
- * browser-only reference client got away with offering just the
140
- * credential.
141
- * 2. The server must never echo the token-bearing offer back (that would
142
- * leak the live credential into a response header) — so it needs a
143
- * non-credential protocol it CAN select.
144
- */
145
- declare const TERMINAL_WS_ECHO_SUBPROTOCOL = "tangle.terminal.v1";
146
- /**
147
- * Client for one terminal WebSocket connection. Construct via
148
- * {@link TerminalStream.connect}, which resolves once the server
149
- * acknowledges the attach with `ready` (history replay then streams through
150
- * `handlers.onData`).
151
- */
152
- declare class TerminalStream {
153
- private readonly ws;
154
- private readonly options;
155
- private readonly handlers;
156
- private readyInfo;
157
- private closed;
158
- private closeWaiters;
159
- private readonly textDecoder;
160
- /**
161
- * Dial the endpoint, send `init` as the first frame, and resolve once the
162
- * server responds `ready`. Rejects on a protocol `error` frame, a socket
163
- * close/failure before `ready`, or the connect timeout — always with the
164
- * reason the server gave. A token PROVIDER is awaited here, before the
165
- * socket opens, so every dial (first connect and each reconnect) carries a
166
- * fresh credential.
167
- */
168
- static connect(options: TerminalStreamOptions): Promise<TerminalStream>;
169
- private constructor();
170
- private establish;
171
- private handleMessage;
172
- /** PTY connection id this stream is attached to. */
173
- get connectionId(): string;
174
- /** The server's `ready` acknowledgement. Set once `connect()` resolves. */
175
- get ready(): TerminalReadyInfo;
176
- /** True while the socket is open. */
177
- get isOpen(): boolean;
178
- /**
179
- * Send input keystrokes to the PTY. `Uint8Array` input is decoded as
180
- * UTF-8 (the wire protocol carries input as JSON text). Input larger than
181
- * the server's 1 MiB frame cap is split across multiple `input` frames in
182
- * order on the same socket, so delivery order is preserved.
183
- */
184
- write(data: string | Uint8Array): void;
185
- /** Resize the PTY. */
186
- resize(cols: number, rows: number): void;
187
- /**
188
- * Detach cleanly: close the socket and resolve once the close completes.
189
- * The PTY survives server-side for `ready.detachTimeoutMs` (5 minutes
190
- * today) — reattach within that window via {@link reconnect} (or a fresh
191
- * `connect()` with the same connectionId) to replay history and continue.
192
- */
193
- close(): Promise<void>;
194
- /**
195
- * Re-dial the same endpoint with the same connectionId on a fresh socket
196
- * — the server reattaches the PTY and replays its buffered history. When
197
- * the stream was constructed with a token PROVIDER, it is re-invoked for
198
- * the new dial (scoped terminal tokens expire within minutes, so the
199
- * original credential may be dead by reconnect time); with a plain string
200
- * token, pass a fresh `token` override yourself when it may have expired.
201
- * `handlers` rebinds callbacks for the new stream.
202
- */
203
- reconnect(overrides?: {
204
- token?: TerminalStreamToken;
205
- handlers?: TerminalStreamHandlers;
206
- cols?: number;
207
- rows?: number;
208
- }): Promise<TerminalStream>;
209
- private assertOpen;
210
- }
211
- //#endregion
212
6
  //#region ../../../packages/runtime-contracts/dist/backend-types.d.ts
213
7
  /**
214
8
  * Canonical harnesses this repo ships no provider adapter for.
@@ -3198,6 +2992,18 @@ interface SandboxRuntimeCapabilities {
3198
2992
  * record. Absent on an image that predates the flag. */
3199
2993
  responseDedupe?: boolean;
3200
2994
  };
2995
+ /** Native TUI lifecycle and control operations exposed by the deployment. */
2996
+ interactiveAgent?: {
2997
+ /** Start one native TUI for the requested session. */start: boolean; /** Read durable TUI state. */
2998
+ status: boolean; /** Attach to the existing native TUI. */
2999
+ attach: boolean; /** Fence concurrent TUI writers with an exact control claim. */
3000
+ control: boolean; /** Reattach after a client disconnect. */
3001
+ reattach: boolean; /** Send a prompt to the existing TUI. */
3002
+ sendPrompt: boolean; /** Send terminal input to the existing TUI. */
3003
+ input: boolean; /** Resize the existing TUI. */
3004
+ resize: boolean; /** Stop the exact TUI session. */
3005
+ stop: boolean;
3006
+ };
3201
3007
  }
3202
3008
  /**
3203
3009
  * Lifecycle state of an agent session inside a sandbox.
@@ -3654,48 +3460,6 @@ type FleetDriveTurnOutcome = {
3654
3460
  outcome: "error";
3655
3461
  error: string;
3656
3462
  };
3657
- /**
3658
- * Scope of a `box.mintScopedToken()` request. `session` and `project` mint
3659
- * SessionGateway read tokens. `session-runtime` and `read-only` mint sidecar
3660
- * capability tokens for browser-safe runtime access.
3661
- */
3662
- type ScopedTokenScope = "session" | "session-runtime" | "project" | "read-only";
3663
- interface MintScopedTokenBase {
3664
- /** TTL in minutes. Default 5; clamped to [1, 15]. */
3665
- ttlMinutes?: number;
3666
- }
3667
- /** Options for `box.mintScopedToken()`, narrowed by consumer scope. */
3668
- type MintScopedTokenOptions = (MintScopedTokenBase & {
3669
- scope: "session"; /** Client-facing browser session ID. */
3670
- sessionId: string; /** Actual runtime session ID used to filter the sandbox event stream. */
3671
- runtimeSessionId: string;
3672
- }) | (MintScopedTokenBase & {
3673
- scope: "session-runtime";
3674
- sessionId: string;
3675
- runtimeSessionId?: never;
3676
- }) | (MintScopedTokenBase & {
3677
- scope: "project" | "read-only";
3678
- sessionId?: never;
3679
- runtimeSessionId?: never;
3680
- });
3681
- /**
3682
- * Returned by `box.mintScopedToken()`. Use session/project tokens with
3683
- * `SessionGatewayClient`; use session-runtime/read-only tokens with
3684
- * `SandboxRuntimeClient`.
3685
- */
3686
- interface ScopedToken {
3687
- /** Bearer token (JWT) for the consumer selected by `scope`. */
3688
- token: string;
3689
- /** When the token expires. */
3690
- expiresAt: Date;
3691
- /** The runtime's direct edge URL. Use with runtime scopes; session/project
3692
- * tokens instead connect to the Sandbox API's `/session` WebSocket. */
3693
- runtimeUrl: string;
3694
- /** Browser-safe Sandbox API proxy base for terminal and runtime requests. */
3695
- sidecarProxyUrl: string;
3696
- /** Echo of the requested scope. */
3697
- scope: ScopedTokenScope;
3698
- }
3699
3463
  /**
3700
3464
  * Callback invoked when the SDK refreshes a sandbox bearer transparently
3701
3465
  * (e.g. after a 401 retry against the runtime endpoint). Lets long-
@@ -6482,4 +6246,4 @@ interface CodeExecutionOptions {
6482
6246
  idempotencyKey?: string;
6483
6247
  }
6484
6248
  //#endregion
6485
- export { EffectiveBackend as $, UsageInfo as $i, RolloutStartResult as $n, SandboxTerminalRequestOptions as $r, HostAgentRuntimeBackend as $t, CreateGpuLeaseOptions as A, SnapshotOptions as Ai, ProcessStatus as An, SandboxFleetTraceBundle as Ar, FleetExecDispatchResult as At, DevServerInfo as B, TaskSessionInfo as Bi, PublishPublicTemplateOptions as Bn, SandboxInfo as Br, GitCommit as Bt, ChunkedUploadResult as C, SessionMessageInputPart as Ci, Process as Cn, SandboxFleetMachineRecord as Cr, FleetDispatchCancelResult as Ct, CodeResultPart as D, SnapshotDeleteOutcome as Di, ProcessManager as Dn, SandboxFleetOperationsSummary as Dr, FleetDriveTurnOutcome as Dt, CodeLanguage as E, SnapshotDeleteAcknowledgement as Ei, ProcessLogEntry as En, SandboxFleetManifestMachine as Er, FleetDispatchStreamOptions as Et, CreateSandboxFleetWithCoordinatorOptions as F, StorageConfig as Fi, ProvisionResult as Fn, SandboxFleetWorkspace as Fr, ForkIdempotency as Ft, DownloadProgress as G, TeePublicKey as Gi, ReconcileSandboxFleetsResult as Gn, SandboxResources as Gr, GpuLeaseBilling as Gt, DispatchPromptOptions as H, TeeAttestationOptions as Hi, ReapExpiredSandboxFleetsOptions as Hn, SandboxPortBinding as Hr, GitDiff as Ht, CreateSandboxOptions as I, SubscriptionInfo as Ii, ProvisionStatus as In, SandboxFleetWorkspaceReconcileResult as Ir, ForkLookupOptions as It, DriverInfo as J, TokenUsage as Ji, ResumeOptions as Jn, SandboxStatus as Jr, GpuLeaseExecResult as Jt, DriveTurnOptions as K, TeePublicKeyResponse as Ki, RenameOptions as Kn, SandboxRuntimeCapabilities as Kr, GpuLeaseCommandResult as Kt, CreateSessionOptions as L, TaskSessionChanges as Li, ProvisionStep as Ln, SandboxFleetWorkspaceRestoreResult as Lr, GPU_LEASE_PROVIDER_NAMES as Lt, CreateRequestOptions as M, SshKeysManager as Mi, PromptOptions as Mn, SandboxFleetTraceExport as Mr, FleetPromptDispatchOptions as Mt, CreateSandboxFleetOptions as N, StartupDiagnostics as Ni, PromptResult as Nn, SandboxFleetTraceOptions as Nr, FleetPromptDispatchResult as Nt, CommitTaskSessionOptions as O, SnapshotIdempotency as Oi, ProcessSignal as On, SandboxFleetPolicy as Or, FleetDriveTurnRequest as Ot, CreateSandboxFleetTokenOptions as P, StartupOperation as Pi, ProvisionEvent as Pn, SandboxFleetUsage as Pr, ForkCounts as Pt, DurablePlanSnapshot as Q, UploadProgress as Qi, RolloutScorer as Qn, SandboxTerminalManager as Qr, HostAgentDriverConfig as Qt, CreateTaskSessionOptions as R, TaskSessionCommitResult as Ri, PublicTemplateInfo as Rn, SandboxFleetWorkspaceSnapshotResult as Rr, GitAuth as Rt, ChunkedUploadOptions as S, TerminalStreamToken as Sa, SessionMessage as Si, PreviewLinkWaitOptions as Sn, SandboxFleetMachineMeteredUsage as Sr, FileWriteResult as St, CodeExecutionResult as T, SessionStatus as Ti, ProcessListOptions as Tn, SandboxFleetManifest as Tr, FleetDispatchResultBufferOptions as Tt, DispatchedSession as U, TeeAttestationReport as Ui, ReapExpiredSandboxFleetsResult as Un, SandboxPortPreviewLink as Ur, GitStatus as Ut, DirectoryPermission as V, TaskSessionProfile as Vi, PublishPublicTemplateVersionOptions as Vn, SandboxIntelligenceEnvelope as Vr, GitConfig as Vt, DownloadOptions as W, TeeAttestationResponse as Wi, ReconcileSandboxFleetsOptions as Wn, SandboxResourceUsage as Wr, GpuLease as Wt, DurablePlan as X, UpdateUserOptions as Xi, RolloutChildResult as Xn, SandboxTerminalCreateOptions as Xr, GpuLeaseProviderName as Xt, DriverType as Y, TurnDriveResult as Yi, Rollout as Yn, SandboxTerminalAttachOptions as Yr, GpuLeaseManager as Yt, DurablePlanDecisionResult as Z, UploadOptions as Zi, RolloutOptions as Zn, SandboxTerminalInfo as Zr, GpuLeaseStatus as Zt, BatchRunOptions as _, TerminalStream as _a, SessionFailureReason as _i, NonHostAgentDriverConfig as _n, SandboxFleetDriverCapability as _r, FileTreeFile as _t, AgentQuestionRequest as a, WriteManyOptions as aa, SandboxUser as ai, IntelligenceReportWindow as an, SandboxConnection as ar, EnsureDevServerOptions as at, BatchTaskResult as b, TerminalStreamHandlers as ba, SessionInterruptOptions as bi, PreviewLinkInfo as bn, SandboxFleetIntelligenceEnvelope as br, FileUsageOptions as bt, AttachGpuLeaseOptions as c, BatchEventDataMap as ca, SearchMatch as ci, ListOptions as cn, SandboxDeleteAcknowledgement as cr, ExecOptions as ct, BackendConfig as d, PublicBatchRunRequest as da, SecretsManager as di, MAX_EGRESS_DENIALS_LIMIT as dn, SandboxEvent as dr, FileReadBatchOptions as dt, WaitForOptions as ea, SandboxTerminals as ei, InstalledTool as en, RolloutStatus as er, EffectiveBackendProfile as et, BackendInfo as f, BackendType as fa, SendSessionMessageOptions as fi, McpServerConfig as fn, SandboxFleetArtifact as fr, FileReadBatchResult as ft, BatchResult as g, TerminalReadyInfo as ga, SessionEventStreamOptions as gi, NetworkManager as gn, SandboxFleetDispatchResponse as gr, FileSystem as gt, BatchBackend as h, TerminalExitInfo as ha, SessionBackendCredentials as hi, NetworkConfig as hn, SandboxFleetDispatchFailureClass as hr, FileRenameResult as ht, AgentApprovalRequirement as i, WriteManyFile as ia, SandboxTraceOptions as ii, IntelligenceReportSubjectType as in, SandboxConfig as ir, EgressPolicy as it, CreateIntelligenceReportOptions as j, SnapshotResult as ji, PromptInputPart as jn, SandboxFleetTraceEvent as jr, FleetMachineId as jt, CompletedTurnResult as k, SnapshotInfo as ki, ProcessSpawnOptions as kn, SandboxFleetToken as kr, FleetExecDispatchOptions as kt, AttachSandboxFleetMachineOptions as l, BatchSidecarGroup as la, SearchOptions as li, ListSandboxFleetOptions as ln, SandboxDeleteOutcome as lr, ExecResult as lt, BackendStatus as m, TERMINAL_WS_ECHO_SUBPROTOCOL as ma, SentSessionMessage as mi, MkdirOptions as mn, SandboxFleetCostEstimate as mr, FileReadResult as mt, AccessPolicyRule as n, WorkspaceOperationLookup as na, SandboxTraceEvent as ni, IntelligenceReportBudget as nn, SSHCommandDescriptor as nr, EgressDenial as nt, AgentRunStatus as o, BatchBackendStats as oa, ScopedToken as oi, JsonValue as on, SandboxCreateOutcome as or, EventStreamOptions as ot, BackendManager as p, parseBackendType as pa, SendSessionMessageRequest as pi, MintScopedTokenOptions as pn, SandboxFleetArtifactSpec as pr, FileReadError as pt, DriverConfig as q, TokenRefreshHandler as qi, RestoreSnapshotOptions as qn, SandboxRuntimeHealth as qr, GpuLeaseExecOptions as qt, AddUserOptions as r, WriteFileOptions as ra, SandboxTraceExport as ri, IntelligenceReportCompareTo as rn, SSHCredentials as rr, EgressManager as rt, AgentToolInvocation as s, BatchEvent as sa, ScopedTokenScope as si, ListMessagesOptions as sn, SandboxCreateReceipt as sr, ExactProcessSpawnOptions as st, AcceleratorKind as t, WaitForRolloutOptions as ta, SandboxTraceBundle as ti, IntelligenceReport as tn, RolloutTurnPart as tr, EffectiveBackendSource as tt, BackendCapabilities as u, BatchTaskUsage as ua, SecretInfo as ui, ListSandboxOptions as un, SandboxEnvironment as ur, FileInfo as ut, BatchRunRequest as v, TerminalStreamAuthFormat as va, SessionForkOptions as vi, PermissionLevel as vn, SandboxFleetDriverTimings as vr, FileTreeOptions as vt, CodeExecutionOptions as w, SessionResultOptions as wi, ProcessInfo as wn, SandboxFleetMachineSpec as wr, FleetDispatchResultBuffer as wt, BranchOptions as x, TerminalStreamOptions as xa, SessionListOptions as xi, PreviewLinkManager as xn, SandboxFleetMachine as xr, FileUsageResult as xt, BatchTask as y, TerminalStreamError as ya, SessionInfo as yi, PermissionsManager as yn, SandboxFleetInfo as yr, FileTreeResult as yt, DeleteOptions as z, TaskSessionFileChange as zi, PublicTemplateVersionInfo as zn, SandboxIdentity as zr, GitBranch as zt };
6249
+ export { EffectiveBackend as $, WorkspaceOperationLookup as $i, RolloutStatus as $n, SandboxTerminals as $r, HostAgentRuntimeBackend as $t, CreateGpuLeaseOptions as A, StartupDiagnostics as Ai, PromptInputPart as An, SandboxFleetTraceEvent as Ar, FleetExecDispatchResult as At, DevServerInfo as B, TeeAttestationReport as Bi, PublishPublicTemplateVersionOptions as Bn, SandboxIntelligenceEnvelope as Br, GitCommit as Bt, ChunkedUploadResult as C, SnapshotDeleteAcknowledgement as Ci, ProcessInfo as Cn, SandboxFleetMachineSpec as Cr, FleetDispatchCancelResult as Ct, CodeResultPart as D, SnapshotOptions as Di, ProcessSignal as Dn, SandboxFleetPolicy as Dr, FleetDriveTurnOutcome as Dt, CodeLanguage as E, SnapshotInfo as Ei, ProcessManager as En, SandboxFleetOperationsSummary as Er, FleetDispatchStreamOptions as Et, CreateSandboxFleetWithCoordinatorOptions as F, TaskSessionCommitResult as Fi, ProvisionStatus as Fn, SandboxFleetWorkspaceReconcileResult as Fr, ForkIdempotency as Ft, DownloadProgress as G, TokenUsage as Gi, RenameOptions as Gn, SandboxRuntimeCapabilities as Gr, GpuLeaseBilling as Gt, DispatchPromptOptions as H, TeePublicKey as Hi, ReapExpiredSandboxFleetsResult as Hn, SandboxPortPreviewLink as Hr, GitDiff as Ht, CreateSandboxOptions as I, TaskSessionFileChange as Ii, ProvisionStep as In, SandboxFleetWorkspaceRestoreResult as Ir, ForkLookupOptions as It, DriverInfo as J, UploadOptions as Ji, Rollout as Jn, SandboxTerminalAttachOptions as Jr, GpuLeaseExecResult as Jt, DriveTurnOptions as K, TurnDriveResult as Ki, RestoreSnapshotOptions as Kn, SandboxRuntimeHealth as Kr, GpuLeaseCommandResult as Kt, CreateSessionOptions as L, TaskSessionInfo as Li, PublicTemplateInfo as Ln, SandboxFleetWorkspaceSnapshotResult as Lr, GPU_LEASE_PROVIDER_NAMES as Lt, CreateRequestOptions as M, StorageConfig as Mi, PromptResult as Mn, SandboxFleetTraceOptions as Mr, FleetPromptDispatchOptions as Mt, CreateSandboxFleetOptions as N, SubscriptionInfo as Ni, ProvisionEvent as Nn, SandboxFleetUsage as Nr, FleetPromptDispatchResult as Nt, CommitTaskSessionOptions as O, SnapshotResult as Oi, ProcessSpawnOptions as On, SandboxFleetToken as Or, FleetDriveTurnRequest as Ot, CreateSandboxFleetTokenOptions as P, TaskSessionChanges as Pi, ProvisionResult as Pn, SandboxFleetWorkspace as Pr, ForkCounts as Pt, DurablePlanSnapshot as Q, WaitForRolloutOptions as Qi, RolloutStartResult as Qn, SandboxTerminalRequestOptions as Qr, HostAgentDriverConfig as Qt, CreateTaskSessionOptions as R, TaskSessionProfile as Ri, PublicTemplateVersionInfo as Rn, SandboxIdentity as Rr, GitAuth as Rt, ChunkedUploadOptions as S, SessionStatus as Si, Process as Sn, SandboxFleetMachineRecord as Sr, FileWriteResult as St, CodeExecutionResult as T, SnapshotIdempotency as Ti, ProcessLogEntry as Tn, SandboxFleetManifestMachine as Tr, FleetDispatchResultBufferOptions as Tt, DispatchedSession as U, TeePublicKeyResponse as Ui, ReconcileSandboxFleetsOptions as Un, SandboxResourceUsage as Ur, GitStatus as Ut, DirectoryPermission as V, TeeAttestationResponse as Vi, ReapExpiredSandboxFleetsOptions as Vn, SandboxPortBinding as Vr, GitConfig as Vt, DownloadOptions as W, TokenRefreshHandler as Wi, ReconcileSandboxFleetsResult as Wn, SandboxResources as Wr, GpuLease as Wt, DurablePlan as X, UsageInfo as Xi, RolloutOptions as Xn, SandboxTerminalInfo as Xr, GpuLeaseProviderName as Xt, DriverType as Y, UploadProgress as Yi, RolloutChildResult as Yn, SandboxTerminalCreateOptions as Yr, GpuLeaseManager as Yt, DurablePlanDecisionResult as Z, WaitForOptions as Zi, RolloutScorer as Zn, SandboxTerminalManager as Zr, GpuLeaseStatus as Zt, BatchRunOptions as _, SessionInterruptOptions as _i, PermissionLevel as _n, SandboxFleetDriverTimings as _r, FileTreeFile as _t, AgentQuestionRequest as a, BatchEventDataMap as aa, SearchMatch as ai, IntelligenceReportWindow as an, SandboxCreateOutcome as ar, EnsureDevServerOptions as at, BatchTaskResult as b, SessionMessageInputPart as bi, PreviewLinkManager as bn, SandboxFleetMachine as br, FileUsageOptions as bt, AttachGpuLeaseOptions as c, PublicBatchRunRequest as ca, SecretsManager as ci, ListOptions as cn, SandboxDeleteOutcome as cr, ExecOptions as ct, BackendConfig as d, SentSessionMessage as di, MAX_EGRESS_DENIALS_LIMIT as dn, SandboxFleetArtifact as dr, FileReadBatchOptions as dt, WriteFileOptions as ea, SandboxTraceBundle as ei, InstalledTool as en, RolloutTurnPart as er, EffectiveBackendProfile as et, BackendInfo as f, SessionBackendCredentials as fi, McpServerConfig as fn, SandboxFleetArtifactSpec as fr, FileReadBatchResult as ft, BatchResult as g, SessionInfo as gi, NonHostAgentDriverConfig as gn, SandboxFleetDriverCapability as gr, FileSystem as gt, BatchBackend as h, SessionForkOptions as hi, NetworkManager as hn, SandboxFleetDispatchResponse as hr, FileRenameResult as ht, AgentApprovalRequirement as i, BatchEvent as ia, SandboxUser as ii, IntelligenceReportSubjectType as in, SandboxConnection as ir, EgressPolicy as it, CreateIntelligenceReportOptions as j, StartupOperation as ji, PromptOptions as jn, SandboxFleetTraceExport as jr, FleetMachineId as jt, CompletedTurnResult as k, SshKeysManager as ki, ProcessStatus as kn, SandboxFleetTraceBundle as kr, FleetExecDispatchOptions as kt, AttachSandboxFleetMachineOptions as l, BackendType as la, SendSessionMessageOptions as li, ListSandboxFleetOptions as ln, SandboxEnvironment as lr, ExecResult as lt, BackendStatus as m, SessionFailureReason as mi, NetworkConfig as mn, SandboxFleetDispatchFailureClass as mr, FileReadResult as mt, AccessPolicyRule as n, WriteManyOptions as na, SandboxTraceExport as ni, IntelligenceReportBudget as nn, SSHCredentials as nr, EgressDenial as nt, AgentRunStatus as o, BatchSidecarGroup as oa, SearchOptions as oi, JsonValue as on, SandboxCreateReceipt as or, EventStreamOptions as ot, BackendManager as p, SessionEventStreamOptions as pi, MkdirOptions as pn, SandboxFleetCostEstimate as pr, FileReadError as pt, DriverConfig as q, UpdateUserOptions as qi, ResumeOptions as qn, SandboxStatus as qr, GpuLeaseExecOptions as qt, AddUserOptions as r, BatchBackendStats as ra, SandboxTraceOptions as ri, IntelligenceReportCompareTo as rn, SandboxConfig as rr, EgressManager as rt, AgentToolInvocation as s, BatchTaskUsage as sa, SecretInfo as si, ListMessagesOptions as sn, SandboxDeleteAcknowledgement as sr, ExactProcessSpawnOptions as st, AcceleratorKind as t, WriteManyFile as ta, SandboxTraceEvent as ti, IntelligenceReport as tn, SSHCommandDescriptor as tr, EffectiveBackendSource as tt, BackendCapabilities as u, parseBackendType as ua, SendSessionMessageRequest as ui, ListSandboxOptions as un, SandboxEvent as ur, FileInfo as ut, BatchRunRequest as v, SessionListOptions as vi, PermissionsManager as vn, SandboxFleetInfo as vr, FileTreeOptions as vt, CodeExecutionOptions as w, SnapshotDeleteOutcome as wi, ProcessListOptions as wn, SandboxFleetManifest as wr, FleetDispatchResultBuffer as wt, BranchOptions as x, SessionResultOptions as xi, PreviewLinkWaitOptions as xn, SandboxFleetMachineMeteredUsage as xr, FileUsageResult as xt, BatchTask as y, SessionMessage as yi, PreviewLinkInfo as yn, SandboxFleetIntelligenceEnvelope as yr, FileTreeResult as yt, DeleteOptions as z, TeeAttestationOptions as zi, PublishPublicTemplateOptions as zn, SandboxInfo as zr, GitBranch as zt };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tangle-network/sandbox",
3
- "version": "0.30.2-develop.20260820100122.dc85046",
3
+ "version": "0.30.2-develop.20260820200640.0075917",
4
4
  "description": "Client SDK for the Tangle Sandbox platform - build AI agent applications with dev containers",
5
5
  "type": "module",
6
6
  "sideEffects": [
@@ -24,6 +24,11 @@
24
24
  "types": "./dist/runtime.d.ts",
25
25
  "default": "./dist/runtime.js"
26
26
  },
27
+ "./interactive-control": {
28
+ "import": "./dist/interactive-control.js",
29
+ "types": "./dist/interactive-control.d.ts",
30
+ "default": "./dist/interactive-control.js"
31
+ },
27
32
  "./tangle": {
28
33
  "import": "./dist/tangle/index.js",
29
34
  "types": "./dist/tangle/index.d.ts",
@@ -91,7 +96,7 @@
91
96
  },
92
97
  "dependencies": {
93
98
  "@tangle-network/agent-core": "0.9.4",
94
- "@tangle-network/agent-interface": "^1.0.0",
99
+ "@tangle-network/agent-interface": "^1.3.0",
95
100
  "zod": "4.4.3"
96
101
  },
97
102
  "peerDependencies": {
@@ -132,8 +137,8 @@
132
137
  "yjs": "13.6.30",
133
138
  "@repo/shared": "0.0.0",
134
139
  "@tangle-network/cli-agent-registry": "0.3.10",
135
- "@tangle-network/sse-core": "0.0.0",
136
- "@tangle-network/runtime-contracts": "0.6.1"
140
+ "@tangle-network/runtime-contracts": "0.6.1",
141
+ "@tangle-network/sse-core": "0.0.0"
137
142
  },
138
143
  "scripts": {
139
144
  "build": "node scripts/build-dist.mjs",