@spencerboucher/switchyard-client 0.0.0-stage → 0.14.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.
@@ -0,0 +1,1456 @@
1
+ import { z } from "zod";
2
+ export declare const HostCommand: z.ZodDiscriminatedUnion<[z.ZodObject<{
3
+ type: z.ZodLiteral<"session.start">;
4
+ sessionId: z.ZodString;
5
+ title: z.ZodString;
6
+ workspacePath: z.ZodString;
7
+ projectId: z.ZodNullable<z.ZodString>;
8
+ profile: z.ZodObject<{
9
+ id: z.ZodString;
10
+ name: z.ZodString;
11
+ provider: z.ZodNullable<z.ZodString>;
12
+ model: z.ZodNullable<z.ZodString>;
13
+ thinking: z.ZodNullable<z.ZodEnum<{
14
+ high: "high";
15
+ low: "low";
16
+ max: "max";
17
+ medium: "medium";
18
+ minimal: "minimal";
19
+ off: "off";
20
+ xhigh: "xhigh";
21
+ }>>;
22
+ projectTrust: z.ZodEnum<{
23
+ approve: "approve";
24
+ ask: "ask";
25
+ ignore: "ignore";
26
+ }>;
27
+ extraArgs: z.ZodArray<z.ZodString>;
28
+ resources: z.ZodOptional<z.ZodEnum<{
29
+ all: "all";
30
+ vanilla: "vanilla";
31
+ }>>;
32
+ }, z.core.$strip>;
33
+ nativeHandle: z.ZodNullable<z.ZodObject<{
34
+ sessionId: z.ZodString;
35
+ sessionFile: z.ZodString;
36
+ }, z.core.$strip>>;
37
+ initialPrompt: z.ZodNullable<z.ZodString>;
38
+ dispatchKey: z.ZodNullable<z.ZodString>;
39
+ controlRevision: z.ZodNumber;
40
+ controlMode: z.ZodEnum<{
41
+ automation: "automation";
42
+ human: "human";
43
+ }>;
44
+ origin: z.ZodEnum<{
45
+ automation: "automation";
46
+ human: "human";
47
+ }>;
48
+ readOnly: z.ZodDefault<z.ZodBoolean>;
49
+ policyRequired: z.ZodOptional<z.ZodBoolean>;
50
+ }, z.core.$strip>, z.ZodObject<{
51
+ type: z.ZodLiteral<"session.deliverMessage">;
52
+ sessionId: z.ZodString;
53
+ messageId: z.ZodString;
54
+ payload: z.ZodObject<{
55
+ deliveryId: z.ZodString;
56
+ kind: z.ZodEnum<{
57
+ completion: "completion";
58
+ message: "message";
59
+ }>;
60
+ text: z.ZodString;
61
+ }, z.core.$strip>;
62
+ mode: z.ZodEnum<{
63
+ queue: "queue";
64
+ steer: "steer";
65
+ }>;
66
+ holdUntil: z.ZodString;
67
+ }, z.core.$strip>, z.ZodObject<{
68
+ sessionId: z.ZodString;
69
+ nativeSessionId: z.ZodString;
70
+ runtimeId: z.ZodString;
71
+ sampleId: z.ZodString;
72
+ tool: z.ZodObject<{
73
+ name: z.ZodString;
74
+ args: z.ZodCustom<Record<string, import("./policies.js").JsonValue>, Record<string, import("./policies.js").JsonValue>>;
75
+ }, z.core.$strict>;
76
+ type: z.ZodLiteral<"session.classifyPolicySample">;
77
+ }, z.core.$strict>, z.ZodObject<{
78
+ type: z.ZodLiteral<"session.messageStatus">;
79
+ sessionId: z.ZodString;
80
+ messageIds: z.ZodArray<z.ZodString>;
81
+ }, z.core.$strip>, z.ZodObject<{
82
+ type: z.ZodLiteral<"session.prompt">;
83
+ sessionId: z.ZodString;
84
+ text: z.ZodString;
85
+ images: z.ZodDefault<z.ZodArray<z.ZodObject<{
86
+ mimeType: z.ZodString;
87
+ data: z.ZodString;
88
+ }, z.core.$strip>>>;
89
+ mode: z.ZodEnum<{
90
+ followUp: "followUp";
91
+ prompt: "prompt";
92
+ steer: "steer";
93
+ }>;
94
+ origin: z.ZodEnum<{
95
+ automation: "automation";
96
+ human: "human";
97
+ }>;
98
+ controlRevision: z.ZodNumber;
99
+ }, z.core.$strip>, z.ZodObject<{
100
+ type: z.ZodLiteral<"session.abort">;
101
+ sessionId: z.ZodString;
102
+ clearQueue: z.ZodBoolean;
103
+ }, z.core.$strip>, z.ZodObject<{
104
+ type: z.ZodLiteral<"session.stop">;
105
+ sessionId: z.ZodString;
106
+ }, z.core.$strip>, z.ZodObject<{
107
+ type: z.ZodLiteral<"session.answer">;
108
+ sessionId: z.ZodString;
109
+ interactionId: z.ZodString;
110
+ revision: z.ZodNumber;
111
+ response: z.ZodDiscriminatedUnion<[z.ZodObject<{
112
+ kind: z.ZodLiteral<"form">;
113
+ values: z.ZodRecord<z.ZodString, z.ZodType<import("./ui.js").FormValue, unknown, z.core.$ZodTypeInternals<import("./ui.js").FormValue, unknown>>>;
114
+ }, z.core.$strip>, z.ZodObject<{
115
+ kind: z.ZodLiteral<"confirm">;
116
+ confirmed: z.ZodBoolean;
117
+ }, z.core.$strip>, z.ZodObject<{
118
+ kind: z.ZodLiteral<"action">;
119
+ actionId: z.ZodString;
120
+ }, z.core.$strip>, z.ZodObject<{
121
+ kind: z.ZodLiteral<"cancel">;
122
+ }, z.core.$strip>], "kind">;
123
+ deviceId: z.ZodString;
124
+ }, z.core.$strip>, z.ZodObject<{
125
+ type: z.ZodLiteral<"session.adapterAction">;
126
+ sessionId: z.ZodString;
127
+ generation: z.ZodOptional<z.ZodString>;
128
+ adapterId: z.ZodString;
129
+ actionId: z.ZodString;
130
+ payload: z.ZodUnknown;
131
+ }, z.core.$strip>, z.ZodObject<{
132
+ type: z.ZodLiteral<"session.setControl">;
133
+ sessionId: z.ZodString;
134
+ controlRevision: z.ZodNumber;
135
+ mode: z.ZodEnum<{
136
+ automation: "automation";
137
+ human: "human";
138
+ }>;
139
+ }, z.core.$strip>, z.ZodObject<{
140
+ type: z.ZodLiteral<"session.rename">;
141
+ sessionId: z.ZodString;
142
+ title: z.ZodString;
143
+ }, z.core.$strip>, z.ZodObject<{
144
+ type: z.ZodLiteral<"session.importable">;
145
+ }, z.core.$strip>, z.ZodObject<{
146
+ type: z.ZodLiteral<"session.readNative">;
147
+ sessionFile: z.ZodString;
148
+ }, z.core.$strip>, z.ZodObject<{
149
+ type: z.ZodLiteral<"session.snapshot">;
150
+ sessionId: z.ZodString;
151
+ }, z.core.$strip>, z.ZodObject<{
152
+ type: z.ZodLiteral<"session.models">;
153
+ sessionId: z.ZodString;
154
+ }, z.core.$strip>, z.ZodObject<{
155
+ type: z.ZodLiteral<"session.commands">;
156
+ sessionId: z.ZodString;
157
+ }, z.core.$strip>, z.ZodObject<{
158
+ type: z.ZodLiteral<"session.complete">;
159
+ sessionId: z.ZodString;
160
+ text: z.ZodString;
161
+ }, z.core.$strip>, z.ZodObject<{
162
+ type: z.ZodLiteral<"session.tree">;
163
+ sessionId: z.ZodString;
164
+ }, z.core.$strip>, z.ZodObject<{
165
+ type: z.ZodLiteral<"session.branch">;
166
+ sessionId: z.ZodString;
167
+ entryId: z.ZodNullable<z.ZodString>;
168
+ fork: z.ZodBoolean;
169
+ }, z.core.$strip>, z.ZodObject<{
170
+ type: z.ZodLiteral<"session.navigate">;
171
+ sessionId: z.ZodString;
172
+ entryId: z.ZodString;
173
+ summarize: z.ZodBoolean;
174
+ instructions: z.ZodNullable<z.ZodString>;
175
+ }, z.core.$strip>, z.ZodObject<{
176
+ type: z.ZodLiteral<"session.reload">;
177
+ sessionId: z.ZodString;
178
+ }, z.core.$strip>, z.ZodObject<{
179
+ type: z.ZodLiteral<"session.adapters">;
180
+ sessionId: z.ZodString;
181
+ }, z.core.$strip>, z.ZodObject<{
182
+ type: z.ZodLiteral<"session.reloadAdapters">;
183
+ sessionId: z.ZodString;
184
+ }, z.core.$strip>, z.ZodObject<{
185
+ type: z.ZodLiteral<"session.export">;
186
+ sessionId: z.ZodString;
187
+ }, z.core.$strip>, z.ZodObject<{
188
+ type: z.ZodLiteral<"session.setModel">;
189
+ sessionId: z.ZodString;
190
+ provider: z.ZodString;
191
+ modelId: z.ZodString;
192
+ }, z.core.$strip>, z.ZodObject<{
193
+ type: z.ZodLiteral<"session.setThinking">;
194
+ sessionId: z.ZodString;
195
+ level: z.ZodEnum<{
196
+ high: "high";
197
+ low: "low";
198
+ max: "max";
199
+ medium: "medium";
200
+ minimal: "minimal";
201
+ off: "off";
202
+ xhigh: "xhigh";
203
+ }>;
204
+ }, z.core.$strip>, z.ZodObject<{
205
+ type: z.ZodLiteral<"session.compact">;
206
+ sessionId: z.ZodString;
207
+ instructions: z.ZodNullable<z.ZodString>;
208
+ }, z.core.$strip>, z.ZodObject<{
209
+ type: z.ZodLiteral<"checkout.inspect">;
210
+ path: z.ZodString;
211
+ }, z.core.$strip>, z.ZodObject<{
212
+ type: z.ZodLiteral<"projects.scan">;
213
+ folder: z.ZodString;
214
+ }, z.core.$strip>, z.ZodObject<{
215
+ type: z.ZodLiteral<"projects.suggest">;
216
+ days: z.ZodDefault<z.ZodNumber>;
217
+ }, z.core.$strip>, z.ZodObject<{
218
+ type: z.ZodLiteral<"workspace.discover">;
219
+ checkoutPath: z.ZodString;
220
+ worktreeDir: z.ZodDefault<z.ZodString>;
221
+ }, z.core.$strip>, z.ZodObject<{
222
+ type: z.ZodLiteral<"workspace.create">;
223
+ checkoutPath: z.ZodString;
224
+ branch: z.ZodString;
225
+ base: z.ZodString;
226
+ setupCommand: z.ZodNullable<z.ZodString>;
227
+ worktreeDir: z.ZodDefault<z.ZodString>;
228
+ }, z.core.$strip>, z.ZodObject<{
229
+ type: z.ZodLiteral<"workspace.status">;
230
+ path: z.ZodString;
231
+ base: z.ZodNullable<z.ZodString>;
232
+ }, z.core.$strip>, z.ZodObject<{
233
+ type: z.ZodLiteral<"workspace.remove">;
234
+ path: z.ZodString;
235
+ checkoutPath: z.ZodString;
236
+ base: z.ZodNullable<z.ZodString>;
237
+ force: z.ZodObject<{
238
+ dirty: z.ZodBoolean;
239
+ unmerged: z.ZodBoolean;
240
+ }, z.core.$strip>;
241
+ }, z.core.$strip>, z.ZodObject<{
242
+ type: z.ZodLiteral<"workspace.diff">;
243
+ path: z.ZodString;
244
+ base: z.ZodNullable<z.ZodString>;
245
+ file: z.ZodNullable<z.ZodString>;
246
+ }, z.core.$strip>, z.ZodObject<{
247
+ type: z.ZodLiteral<"workspace.files">;
248
+ path: z.ZodString;
249
+ dir: z.ZodString;
250
+ }, z.core.$strip>, z.ZodObject<{
251
+ type: z.ZodLiteral<"workspace.readFile">;
252
+ path: z.ZodString;
253
+ file: z.ZodString;
254
+ }, z.core.$strip>, z.ZodObject<{
255
+ path: z.ZodString;
256
+ type: z.ZodLiteral<"workspace.prView">;
257
+ }, z.core.$strict>, z.ZodObject<{
258
+ path: z.ZodString;
259
+ repository: z.ZodString;
260
+ number: z.ZodNumber;
261
+ expectedHeadOid: z.ZodString;
262
+ type: z.ZodLiteral<"workspace.prFailedLogs">;
263
+ }, z.core.$strict>, z.ZodObject<{
264
+ path: z.ZodString;
265
+ repository: z.ZodString;
266
+ number: z.ZodNumber;
267
+ expectedHeadOid: z.ZodString;
268
+ expectedPullRequestNodeId: z.ZodString;
269
+ type: z.ZodLiteral<"workspace.prMerge">;
270
+ }, z.core.$strict>, z.ZodObject<{
271
+ type: z.ZodLiteral<"dispatch.start">;
272
+ dispatchKey: z.ZodString;
273
+ runId: z.ZodString;
274
+ taskId: z.ZodString;
275
+ sessionId: z.ZodString;
276
+ projectId: z.ZodString;
277
+ title: z.ZodString;
278
+ workspace: z.ZodUnion<readonly [z.ZodObject<{
279
+ path: z.ZodString;
280
+ }, z.core.$strip>, z.ZodObject<{
281
+ createFrom: z.ZodObject<{
282
+ checkoutPath: z.ZodString;
283
+ branch: z.ZodString;
284
+ base: z.ZodString;
285
+ setupCommand: z.ZodNullable<z.ZodString>;
286
+ worktreeDir: z.ZodDefault<z.ZodString>;
287
+ }, z.core.$strip>;
288
+ }, z.core.$strip>]>;
289
+ nativeHandle: z.ZodNullable<z.ZodObject<{
290
+ sessionId: z.ZodString;
291
+ sessionFile: z.ZodString;
292
+ }, z.core.$strip>>;
293
+ profile: z.ZodObject<{
294
+ id: z.ZodString;
295
+ name: z.ZodString;
296
+ provider: z.ZodNullable<z.ZodString>;
297
+ model: z.ZodNullable<z.ZodString>;
298
+ thinking: z.ZodNullable<z.ZodEnum<{
299
+ high: "high";
300
+ low: "low";
301
+ max: "max";
302
+ medium: "medium";
303
+ minimal: "minimal";
304
+ off: "off";
305
+ xhigh: "xhigh";
306
+ }>>;
307
+ projectTrust: z.ZodEnum<{
308
+ approve: "approve";
309
+ ask: "ask";
310
+ ignore: "ignore";
311
+ }>;
312
+ extraArgs: z.ZodArray<z.ZodString>;
313
+ resources: z.ZodOptional<z.ZodEnum<{
314
+ all: "all";
315
+ vanilla: "vanilla";
316
+ }>>;
317
+ }, z.core.$strip>;
318
+ prompt: z.ZodString;
319
+ controlRevision: z.ZodNumber;
320
+ controlMode: z.ZodDefault<z.ZodEnum<{
321
+ automation: "automation";
322
+ human: "human";
323
+ }>>;
324
+ policyRequired: z.ZodOptional<z.ZodBoolean>;
325
+ }, z.core.$strip>, z.ZodObject<{
326
+ type: z.ZodLiteral<"dispatch.reconcile">;
327
+ dispatchKey: z.ZodString;
328
+ }, z.core.$strip>, z.ZodObject<{
329
+ type: z.ZodLiteral<"checks.run">;
330
+ sessionId: z.ZodString;
331
+ path: z.ZodString;
332
+ commands: z.ZodArray<z.ZodString>;
333
+ }, z.core.$strip>], "type">;
334
+ export type HostCommand = z.infer<typeof HostCommand>;
335
+ export type HostCommandType = HostCommand["type"];
336
+ export type HostCommandOf<T extends HostCommandType> = Extract<HostCommand, {
337
+ type: T;
338
+ }>;
339
+ /** Result payloads for commands that return data. */
340
+ export declare const ImportableSession: z.ZodObject<{
341
+ sessionFile: z.ZodString;
342
+ sessionId: z.ZodString;
343
+ cwd: z.ZodString;
344
+ name: z.ZodNullable<z.ZodString>;
345
+ mtime: z.ZodString;
346
+ inactive: z.ZodBoolean;
347
+ }, z.core.$strip>;
348
+ export type ImportableSession = z.infer<typeof ImportableSession>;
349
+ export declare const DiscoveredWorktree: z.ZodObject<{
350
+ path: z.ZodString;
351
+ head: z.ZodNullable<z.ZodString>;
352
+ branch: z.ZodNullable<z.ZodString>;
353
+ bare: z.ZodBoolean;
354
+ detached: z.ZodBoolean;
355
+ locked: z.ZodBoolean;
356
+ prunable: z.ZodBoolean;
357
+ provenance: z.ZodEnum<{
358
+ discovered: "discovered";
359
+ main: "main";
360
+ managed: "managed";
361
+ }>;
362
+ git: z.ZodNullable<z.ZodObject<{
363
+ dirty: z.ZodBoolean;
364
+ changedFiles: z.ZodNumber;
365
+ ahead: z.ZodNumber;
366
+ behind: z.ZodNumber;
367
+ unmerged: z.ZodBoolean;
368
+ }, z.core.$strip>>;
369
+ }, z.core.$strip>;
370
+ export type DiscoveredWorktree = z.infer<typeof DiscoveredWorktree>;
371
+ export declare const CheckoutInfo: z.ZodObject<{
372
+ root: z.ZodString;
373
+ commonDir: z.ZodString;
374
+ repoIdentity: z.ZodString;
375
+ defaultBranch: z.ZodString;
376
+ }, z.core.$strip>;
377
+ export type CheckoutInfo = z.infer<typeof CheckoutInfo>;
378
+ export declare const ScannedRepository: z.ZodObject<{
379
+ root: z.ZodString;
380
+ commonDir: z.ZodString;
381
+ repoIdentity: z.ZodString;
382
+ defaultBranch: z.ZodString;
383
+ name: z.ZodString;
384
+ }, z.core.$strip>;
385
+ export type ScannedRepository = z.infer<typeof ScannedRepository>;
386
+ export declare const ProjectFolderScan: z.ZodObject<{
387
+ folder: z.ZodString;
388
+ repositories: z.ZodArray<z.ZodObject<{
389
+ root: z.ZodString;
390
+ commonDir: z.ZodString;
391
+ repoIdentity: z.ZodString;
392
+ defaultBranch: z.ZodString;
393
+ name: z.ZodString;
394
+ }, z.core.$strip>>;
395
+ }, z.core.$strip>;
396
+ export type ProjectFolderScan = z.infer<typeof ProjectFolderScan>;
397
+ export declare const ProjectSuggestion: z.ZodObject<{
398
+ rootPath: z.ZodString;
399
+ sessionCount: z.ZodNumber;
400
+ lastActivityAt: z.ZodString;
401
+ }, z.core.$strip>;
402
+ export type ProjectSuggestion = z.infer<typeof ProjectSuggestion>;
403
+ export declare const ProjectSuggestions: z.ZodObject<{
404
+ suggestions: z.ZodArray<z.ZodObject<{
405
+ rootPath: z.ZodString;
406
+ sessionCount: z.ZodNumber;
407
+ lastActivityAt: z.ZodString;
408
+ }, z.core.$strip>>;
409
+ }, z.core.$strip>;
410
+ export type ProjectSuggestions = z.infer<typeof ProjectSuggestions>;
411
+ export declare const DiffFile: z.ZodObject<{
412
+ path: z.ZodString;
413
+ oldPath: z.ZodNullable<z.ZodString>;
414
+ added: z.ZodNumber;
415
+ deleted: z.ZodNumber;
416
+ status: z.ZodEnum<{
417
+ added: "added";
418
+ binary: "binary";
419
+ deleted: "deleted";
420
+ modified: "modified";
421
+ renamed: "renamed";
422
+ untracked: "untracked";
423
+ }>;
424
+ }, z.core.$strip>;
425
+ export type DiffFile = z.infer<typeof DiffFile>;
426
+ export declare const DiffResult: z.ZodObject<{
427
+ base: z.ZodString;
428
+ files: z.ZodArray<z.ZodObject<{
429
+ path: z.ZodString;
430
+ oldPath: z.ZodNullable<z.ZodString>;
431
+ added: z.ZodNumber;
432
+ deleted: z.ZodNumber;
433
+ status: z.ZodEnum<{
434
+ added: "added";
435
+ binary: "binary";
436
+ deleted: "deleted";
437
+ modified: "modified";
438
+ renamed: "renamed";
439
+ untracked: "untracked";
440
+ }>;
441
+ }, z.core.$strip>>;
442
+ patch: z.ZodNullable<z.ZodString>;
443
+ }, z.core.$strip>;
444
+ export type DiffResult = z.infer<typeof DiffResult>;
445
+ export declare const FileEntry: z.ZodObject<{
446
+ name: z.ZodString;
447
+ path: z.ZodString;
448
+ kind: z.ZodEnum<{
449
+ dir: "dir";
450
+ file: "file";
451
+ symlink: "symlink";
452
+ }>;
453
+ size: z.ZodNullable<z.ZodNumber>;
454
+ }, z.core.$strip>;
455
+ export type FileEntry = z.infer<typeof FileEntry>;
456
+ export declare const ReconcileResult: z.ZodUnion<readonly [z.ZodObject<{
457
+ known: z.ZodLiteral<false>;
458
+ }, z.core.$strip>, z.ZodObject<{
459
+ known: z.ZodLiteral<true>;
460
+ sessionId: z.ZodNullable<z.ZodString>;
461
+ state: z.ZodEnum<{
462
+ accepted: "accepted";
463
+ failed: "failed";
464
+ started: "started";
465
+ workspace_ready: "workspace_ready";
466
+ }>;
467
+ runtime: z.ZodNullable<z.ZodEnum<{
468
+ failed: "failed";
469
+ idle: "idle";
470
+ interrupted: "interrupted";
471
+ running: "running";
472
+ starting: "starting";
473
+ stopped: "stopped";
474
+ waiting_input: "waiting_input";
475
+ }>>;
476
+ workspacePath: z.ZodNullable<z.ZodString>;
477
+ nativeHandle: z.ZodNullable<z.ZodObject<{
478
+ sessionId: z.ZodString;
479
+ sessionFile: z.ZodString;
480
+ }, z.core.$strip>>;
481
+ error: z.ZodNullable<z.ZodString>;
482
+ errorDetails: z.ZodDefault<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
483
+ }, z.core.$strip>]>;
484
+ export type ReconcileResult = z.infer<typeof ReconcileResult>;
485
+ export declare const DispatchStartResult: z.ZodObject<{
486
+ sessionId: z.ZodString;
487
+ workspacePath: z.ZodString;
488
+ nativeHandle: z.ZodNullable<z.ZodObject<{
489
+ sessionId: z.ZodString;
490
+ sessionFile: z.ZodString;
491
+ }, z.core.$strip>>;
492
+ reused: z.ZodBoolean;
493
+ promptError: z.ZodOptional<z.ZodNullable<z.ZodString>>;
494
+ }, z.core.$strip>;
495
+ export type DispatchStartResult = z.infer<typeof DispatchStartResult>;
496
+ export declare const AnswerResult: z.ZodObject<{
497
+ status: z.ZodEnum<{
498
+ already_answered: "already_answered";
499
+ answered: "answered";
500
+ }>;
501
+ interaction: z.ZodObject<{
502
+ id: z.ZodString;
503
+ sessionId: z.ZodString;
504
+ revision: z.ZodNumber;
505
+ source: z.ZodDiscriminatedUnion<[z.ZodObject<{
506
+ kind: z.ZodLiteral<"extension_ui">;
507
+ method: z.ZodEnum<{
508
+ confirm: "confirm";
509
+ editor: "editor";
510
+ input: "input";
511
+ select: "select";
512
+ }>;
513
+ piRequestIds: z.ZodArray<z.ZodString>;
514
+ }, z.core.$strip>, z.ZodObject<{
515
+ kind: z.ZodLiteral<"unsupported_custom">;
516
+ title: z.ZodNullable<z.ZodString>;
517
+ }, z.core.$strip>], "kind">;
518
+ adapterId: z.ZodNullable<z.ZodString>;
519
+ permission: z.ZodOptional<z.ZodObject<{
520
+ kind: z.ZodLiteral<"policy">;
521
+ decisionId: z.ZodString;
522
+ rootTaskId: z.ZodNullable<z.ZodString>;
523
+ ruleId: z.ZodString;
524
+ ruleRevision: z.ZodNumber;
525
+ fingerprint: z.ZodString;
526
+ }, z.core.$strict>>;
527
+ title: z.ZodString;
528
+ presentation: z.ZodType<import("./ui.js").UINode, unknown, z.core.$ZodTypeInternals<import("./ui.js").UINode, unknown>>;
529
+ state: z.ZodPreprocess<z.ZodEnum<{
530
+ canceled: "canceled";
531
+ expired: "expired";
532
+ pending: "pending";
533
+ resolved: "resolved";
534
+ unsupported: "unsupported";
535
+ }>, unknown>;
536
+ resolution: z.ZodNullable<z.ZodObject<{
537
+ by: z.ZodString;
538
+ summary: z.ZodString;
539
+ at: z.ZodString;
540
+ }, z.core.$strip>>;
541
+ createdAt: z.ZodString;
542
+ }, z.core.$strip>;
543
+ }, z.core.$strip>;
544
+ export type AnswerResult = z.infer<typeof AnswerResult>;
545
+ export declare const SnapshotResult: z.ZodObject<{
546
+ partial: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
547
+ id: z.ZodString;
548
+ sessionId: z.ZodString;
549
+ order: z.ZodNumber;
550
+ at: z.ZodString;
551
+ kind: z.ZodLiteral<"user">;
552
+ data: z.ZodObject<{
553
+ text: z.ZodString;
554
+ images: z.ZodOptional<z.ZodNumber>;
555
+ entryId: z.ZodOptional<z.ZodString>;
556
+ }, z.core.$strip>;
557
+ }, z.core.$strip>, z.ZodObject<{
558
+ id: z.ZodString;
559
+ sessionId: z.ZodString;
560
+ order: z.ZodNumber;
561
+ at: z.ZodString;
562
+ kind: z.ZodLiteral<"assistant">;
563
+ data: z.ZodObject<{
564
+ text: z.ZodString;
565
+ streaming: z.ZodOptional<z.ZodBoolean>;
566
+ }, z.core.$strip>;
567
+ }, z.core.$strip>, z.ZodObject<{
568
+ id: z.ZodString;
569
+ sessionId: z.ZodString;
570
+ order: z.ZodNumber;
571
+ at: z.ZodString;
572
+ kind: z.ZodLiteral<"thinking">;
573
+ data: z.ZodObject<{
574
+ text: z.ZodString;
575
+ }, z.core.$strip>;
576
+ }, z.core.$strip>, z.ZodObject<{
577
+ id: z.ZodString;
578
+ sessionId: z.ZodString;
579
+ order: z.ZodNumber;
580
+ at: z.ZodString;
581
+ kind: z.ZodLiteral<"tool">;
582
+ data: z.ZodObject<{
583
+ toolCallId: z.ZodString;
584
+ name: z.ZodString;
585
+ status: z.ZodEnum<{
586
+ error: "error";
587
+ ok: "ok";
588
+ running: "running";
589
+ }>;
590
+ args: z.ZodUnknown;
591
+ summary: z.ZodString;
592
+ output: z.ZodString;
593
+ startedAt: z.ZodString;
594
+ durationMs: z.ZodNullable<z.ZodNumber>;
595
+ card: z.ZodNullable<z.ZodType<import("./ui.js").UINode, unknown, z.core.$ZodTypeInternals<import("./ui.js").UINode, unknown>>>;
596
+ adapterId: z.ZodNullable<z.ZodString>;
597
+ adapterGeneration: z.ZodOptional<z.ZodString>;
598
+ }, z.core.$strip>;
599
+ }, z.core.$strip>, z.ZodObject<{
600
+ id: z.ZodString;
601
+ sessionId: z.ZodString;
602
+ order: z.ZodNumber;
603
+ at: z.ZodString;
604
+ kind: z.ZodLiteral<"notice">;
605
+ data: z.ZodObject<{
606
+ level: z.ZodEnum<{
607
+ error: "error";
608
+ info: "info";
609
+ warning: "warning";
610
+ }>;
611
+ text: z.ZodString;
612
+ customType: z.ZodOptional<z.ZodString>;
613
+ card: z.ZodOptional<z.ZodType<import("./ui.js").UINode, unknown, z.core.$ZodTypeInternals<import("./ui.js").UINode, unknown>>>;
614
+ adapterId: z.ZodOptional<z.ZodString>;
615
+ adapterGeneration: z.ZodOptional<z.ZodString>;
616
+ }, z.core.$strip>;
617
+ }, z.core.$strip>, z.ZodObject<{
618
+ id: z.ZodString;
619
+ sessionId: z.ZodString;
620
+ order: z.ZodNumber;
621
+ at: z.ZodString;
622
+ kind: z.ZodLiteral<"interaction">;
623
+ data: z.ZodObject<{
624
+ interactionId: z.ZodString;
625
+ }, z.core.$strip>;
626
+ }, z.core.$strip>, z.ZodObject<{
627
+ id: z.ZodString;
628
+ sessionId: z.ZodString;
629
+ order: z.ZodNumber;
630
+ at: z.ZodString;
631
+ kind: z.ZodLiteral<"subagent">;
632
+ data: z.ZodObject<{
633
+ runId: z.ZodString;
634
+ label: z.ZodString;
635
+ status: z.ZodString;
636
+ sessionFile: z.ZodNullable<z.ZodString>;
637
+ linkedSessionId: z.ZodNullable<z.ZodString>;
638
+ }, z.core.$strip>;
639
+ }, z.core.$strip>, z.ZodObject<{
640
+ id: z.ZodString;
641
+ sessionId: z.ZodString;
642
+ order: z.ZodNumber;
643
+ at: z.ZodString;
644
+ kind: z.ZodLiteral<"system">;
645
+ data: z.ZodObject<{
646
+ text: z.ZodString;
647
+ suggestion: z.ZodOptional<z.ZodBoolean>;
648
+ }, z.core.$strip>;
649
+ }, z.core.$strip>], "kind">>;
650
+ pendingInteractions: z.ZodArray<z.ZodObject<{
651
+ id: z.ZodString;
652
+ sessionId: z.ZodString;
653
+ revision: z.ZodNumber;
654
+ source: z.ZodDiscriminatedUnion<[z.ZodObject<{
655
+ kind: z.ZodLiteral<"extension_ui">;
656
+ method: z.ZodEnum<{
657
+ confirm: "confirm";
658
+ editor: "editor";
659
+ input: "input";
660
+ select: "select";
661
+ }>;
662
+ piRequestIds: z.ZodArray<z.ZodString>;
663
+ }, z.core.$strip>, z.ZodObject<{
664
+ kind: z.ZodLiteral<"unsupported_custom">;
665
+ title: z.ZodNullable<z.ZodString>;
666
+ }, z.core.$strip>], "kind">;
667
+ adapterId: z.ZodNullable<z.ZodString>;
668
+ permission: z.ZodOptional<z.ZodObject<{
669
+ kind: z.ZodLiteral<"policy">;
670
+ decisionId: z.ZodString;
671
+ rootTaskId: z.ZodNullable<z.ZodString>;
672
+ ruleId: z.ZodString;
673
+ ruleRevision: z.ZodNumber;
674
+ fingerprint: z.ZodString;
675
+ }, z.core.$strict>>;
676
+ title: z.ZodString;
677
+ presentation: z.ZodType<import("./ui.js").UINode, unknown, z.core.$ZodTypeInternals<import("./ui.js").UINode, unknown>>;
678
+ state: z.ZodPreprocess<z.ZodEnum<{
679
+ canceled: "canceled";
680
+ expired: "expired";
681
+ pending: "pending";
682
+ resolved: "resolved";
683
+ unsupported: "unsupported";
684
+ }>, unknown>;
685
+ resolution: z.ZodNullable<z.ZodObject<{
686
+ by: z.ZodString;
687
+ summary: z.ZodString;
688
+ at: z.ZodString;
689
+ }, z.core.$strip>>;
690
+ createdAt: z.ZodString;
691
+ }, z.core.$strip>>;
692
+ }, z.core.$strip>;
693
+ export type SnapshotResult = z.infer<typeof SnapshotResult>;
694
+ export declare const ChecksResult: z.ZodObject<{
695
+ results: z.ZodArray<z.ZodObject<{
696
+ command: z.ZodString;
697
+ exitCode: z.ZodNullable<z.ZodNumber>;
698
+ outputTail: z.ZodString;
699
+ }, z.core.$strip>>;
700
+ }, z.core.$strip>;
701
+ export type ChecksResult = z.infer<typeof ChecksResult>;
702
+ export declare const Receipt: z.ZodUnion<readonly [z.ZodObject<{
703
+ commandId: z.ZodString;
704
+ ok: z.ZodLiteral<true>;
705
+ result: z.ZodUnknown;
706
+ }, z.core.$strip>, z.ZodObject<{
707
+ commandId: z.ZodString;
708
+ ok: z.ZodLiteral<false>;
709
+ error: z.ZodObject<{
710
+ code: z.ZodEnum<{
711
+ already_answered: "already_answered";
712
+ branch_invalid: "branch_invalid";
713
+ conflict: "conflict";
714
+ dependency_cycle: "dependency_cycle";
715
+ device_revoked: "device_revoked";
716
+ enrollment_expired: "enrollment_expired";
717
+ enrollment_used: "enrollment_used";
718
+ forbidden: "forbidden";
719
+ host_unreachable: "host_unreachable";
720
+ internal: "internal";
721
+ invalid_request: "invalid_request";
722
+ invalid_transition: "invalid_transition";
723
+ native_session_missing: "native_session_missing";
724
+ not_a_git_repo: "not_a_git_repo";
725
+ not_found: "not_found";
726
+ path_collision: "path_collision";
727
+ pi_incompatible: "pi_incompatible";
728
+ rate_limited: "rate_limited";
729
+ repo_mismatch: "repo_mismatch";
730
+ stale_control: "stale_control";
731
+ timeout: "timeout";
732
+ too_large: "too_large";
733
+ ui_tree_too_large: "ui_tree_too_large";
734
+ unauthorized: "unauthorized";
735
+ unsupported_capability: "unsupported_capability";
736
+ workspace_active_sessions: "workspace_active_sessions";
737
+ workspace_dirty: "workspace_dirty";
738
+ workspace_unmerged: "workspace_unmerged";
739
+ }>;
740
+ message: z.ZodString;
741
+ details: z.ZodOptional<z.ZodUnknown>;
742
+ }, z.core.$strip>;
743
+ }, z.core.$strip>]>;
744
+ export type Receipt = z.infer<typeof Receipt>;
745
+ /** Trusted host attestation is not part of the extension's global/local request envelope. */
746
+ export declare const HostAgentRequestFrame: z.ZodObject<{
747
+ type: z.ZodLiteral<"agent.request">;
748
+ requestId: z.ZodString;
749
+ sessionId: z.ZodString;
750
+ nativeSessionId: z.ZodString;
751
+ runtimeId: z.ZodString;
752
+ context: z.ZodObject<{
753
+ humanInputId: z.ZodNullable<z.ZodString>;
754
+ causalMessageId: z.ZodNullable<z.ZodString>;
755
+ }, z.core.$strict>;
756
+ toolCallId: z.ZodOptional<z.ZodString>;
757
+ receiptReplay: z.ZodOptional<z.ZodObject<{
758
+ requestHash: z.ZodString;
759
+ }, z.core.$strict>>;
760
+ deadlineAt: z.ZodOptional<z.ZodString>;
761
+ method: z.ZodEnum<{
762
+ "inbox.read": "inbox.read";
763
+ "message.send": "message.send";
764
+ "policy.cancel": "policy.cancel";
765
+ "policy.evaluate": "policy.evaluate";
766
+ "policy.status": "policy.status";
767
+ "receipt.peek": "receipt.peek";
768
+ "session.bind": "session.bind";
769
+ "task.create": "task.create";
770
+ }>;
771
+ args: z.ZodUnknown;
772
+ policyContext: z.ZodOptional<z.ZodObject<{
773
+ version: z.ZodLiteral<1>;
774
+ toolCallId: z.ZodString;
775
+ toolHash: z.ZodString;
776
+ boundary: z.ZodObject<{
777
+ cwd: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
778
+ workspaceRoot: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
779
+ cwdReal: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
780
+ workspaceRootReal: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
781
+ }, z.core.$strict>;
782
+ defaultBranch: z.ZodNullable<z.ZodString>;
783
+ safety: z.ZodObject<{
784
+ destructiveDelete: z.ZodBoolean;
785
+ forcePush: z.ZodBoolean;
786
+ defaultBranchPush: z.ZodBoolean;
787
+ uncertain: z.ZodBoolean;
788
+ reasons: z.ZodArray<z.ZodString>;
789
+ }, z.core.$strict>;
790
+ }, z.core.$strict>>;
791
+ }, z.core.$strict>;
792
+ export type HostAgentRequestFrame = z.infer<typeof HostAgentRequestFrame>;
793
+ /** Host -> coordinator frames. */
794
+ export declare const HostToCoordinator: z.ZodDiscriminatedUnion<[z.ZodObject<{
795
+ type: z.ZodLiteral<"hello">;
796
+ hostId: z.ZodString;
797
+ credential: z.ZodString;
798
+ name: z.ZodString;
799
+ agentVersion: z.ZodString;
800
+ piVersion: z.ZodNullable<z.ZodString>;
801
+ piCompatible: z.ZodBoolean;
802
+ platform: z.ZodEnum<{
803
+ darwin: "darwin";
804
+ linux: "linux";
805
+ }>;
806
+ capabilities: z.ZodNullable<z.ZodObject<{
807
+ prompt: z.ZodBoolean;
808
+ steer: z.ZodBoolean;
809
+ followUp: z.ZodBoolean;
810
+ abort: z.ZodBoolean;
811
+ resume: z.ZodBoolean;
812
+ rename: z.ZodBoolean;
813
+ importInactive: z.ZodBoolean;
814
+ extensionDialogs: z.ZodBoolean;
815
+ customUi: z.ZodBoolean;
816
+ widgetsText: z.ZodBoolean;
817
+ widgetsComponent: z.ZodBoolean;
818
+ tokenAccounting: z.ZodBoolean;
819
+ costAccounting: z.ZodBoolean;
820
+ terminal: z.ZodOptional<z.ZodBoolean>;
821
+ sessionControls: z.ZodOptional<z.ZodBoolean>;
822
+ treeNavigation: z.ZodOptional<z.ZodBoolean>;
823
+ agentRequests: z.ZodOptional<z.ZodBoolean>;
824
+ messageDelivery: z.ZodOptional<z.ZodBoolean>;
825
+ policies: z.ZodOptional<z.ZodBoolean>;
826
+ adapterDevelopment: z.ZodOptional<z.ZodBoolean>;
827
+ unsupported: z.ZodArray<z.ZodObject<{
828
+ capability: z.ZodString;
829
+ reason: z.ZodString;
830
+ }, z.core.$strip>>;
831
+ }, z.core.$strip>>;
832
+ github: z.ZodOptional<z.ZodObject<{
833
+ available: z.ZodBoolean;
834
+ reason: z.ZodNullable<z.ZodString>;
835
+ }, z.core.$strict>>;
836
+ protocolVersion: z.ZodNumber;
837
+ features: z.ZodOptional<z.ZodArray<z.ZodString>>;
838
+ }, z.core.$strip>, z.ZodObject<{
839
+ type: z.ZodLiteral<"agent.request">;
840
+ requestId: z.ZodString;
841
+ sessionId: z.ZodString;
842
+ nativeSessionId: z.ZodString;
843
+ runtimeId: z.ZodString;
844
+ context: z.ZodObject<{
845
+ humanInputId: z.ZodNullable<z.ZodString>;
846
+ causalMessageId: z.ZodNullable<z.ZodString>;
847
+ }, z.core.$strict>;
848
+ toolCallId: z.ZodOptional<z.ZodString>;
849
+ receiptReplay: z.ZodOptional<z.ZodObject<{
850
+ requestHash: z.ZodString;
851
+ }, z.core.$strict>>;
852
+ deadlineAt: z.ZodOptional<z.ZodString>;
853
+ method: z.ZodEnum<{
854
+ "inbox.read": "inbox.read";
855
+ "message.send": "message.send";
856
+ "policy.cancel": "policy.cancel";
857
+ "policy.evaluate": "policy.evaluate";
858
+ "policy.status": "policy.status";
859
+ "receipt.peek": "receipt.peek";
860
+ "session.bind": "session.bind";
861
+ "task.create": "task.create";
862
+ }>;
863
+ args: z.ZodUnknown;
864
+ policyContext: z.ZodOptional<z.ZodObject<{
865
+ version: z.ZodLiteral<1>;
866
+ toolCallId: z.ZodString;
867
+ toolHash: z.ZodString;
868
+ boundary: z.ZodObject<{
869
+ cwd: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
870
+ workspaceRoot: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
871
+ cwdReal: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
872
+ workspaceRootReal: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
873
+ }, z.core.$strict>;
874
+ defaultBranch: z.ZodNullable<z.ZodString>;
875
+ safety: z.ZodObject<{
876
+ destructiveDelete: z.ZodBoolean;
877
+ forcePush: z.ZodBoolean;
878
+ defaultBranchPush: z.ZodBoolean;
879
+ uncertain: z.ZodBoolean;
880
+ reasons: z.ZodArray<z.ZodString>;
881
+ }, z.core.$strict>;
882
+ }, z.core.$strict>>;
883
+ }, z.core.$strict>, z.ZodObject<{
884
+ type: z.ZodLiteral<"event">;
885
+ hostSeq: z.ZodNumber;
886
+ event: z.ZodObject<{
887
+ hostId: z.ZodOptional<z.ZodString>;
888
+ sessionId: z.ZodOptional<z.ZodString>;
889
+ taskId: z.ZodOptional<z.ZodString>;
890
+ projectId: z.ZodOptional<z.ZodString>;
891
+ eventId: z.ZodString;
892
+ type: z.ZodPreprocess<z.ZodEnum<{
893
+ "adapters.updated": "adapters.updated";
894
+ diagnostic: "diagnostic";
895
+ "interaction.updated": "interaction.updated";
896
+ "panel.updated": "panel.updated";
897
+ "session.updated": "session.updated";
898
+ "transcript.item": "transcript.item";
899
+ "workspace.deleted": "workspace.deleted";
900
+ "workspace.updated": "workspace.updated";
901
+ }>, unknown>;
902
+ at: z.ZodString;
903
+ data: z.ZodUnknown;
904
+ }, z.core.$strip>;
905
+ }, z.core.$strip>, z.ZodObject<{
906
+ type: z.ZodLiteral<"stream">;
907
+ delta: z.ZodObject<{
908
+ sessionId: z.ZodString;
909
+ itemId: z.ZodString;
910
+ kind: z.ZodEnum<{
911
+ text: "text";
912
+ thinking: "thinking";
913
+ tool_args: "tool_args";
914
+ tool_output: "tool_output";
915
+ }>;
916
+ delta: z.ZodString;
917
+ order: z.ZodOptional<z.ZodNumber>;
918
+ }, z.core.$strip>;
919
+ }, z.core.$strip>, z.ZodObject<{
920
+ type: z.ZodLiteral<"receipt">;
921
+ receipt: z.ZodUnion<readonly [z.ZodObject<{
922
+ commandId: z.ZodString;
923
+ ok: z.ZodLiteral<true>;
924
+ result: z.ZodUnknown;
925
+ }, z.core.$strip>, z.ZodObject<{
926
+ commandId: z.ZodString;
927
+ ok: z.ZodLiteral<false>;
928
+ error: z.ZodObject<{
929
+ code: z.ZodEnum<{
930
+ already_answered: "already_answered";
931
+ branch_invalid: "branch_invalid";
932
+ conflict: "conflict";
933
+ dependency_cycle: "dependency_cycle";
934
+ device_revoked: "device_revoked";
935
+ enrollment_expired: "enrollment_expired";
936
+ enrollment_used: "enrollment_used";
937
+ forbidden: "forbidden";
938
+ host_unreachable: "host_unreachable";
939
+ internal: "internal";
940
+ invalid_request: "invalid_request";
941
+ invalid_transition: "invalid_transition";
942
+ native_session_missing: "native_session_missing";
943
+ not_a_git_repo: "not_a_git_repo";
944
+ not_found: "not_found";
945
+ path_collision: "path_collision";
946
+ pi_incompatible: "pi_incompatible";
947
+ rate_limited: "rate_limited";
948
+ repo_mismatch: "repo_mismatch";
949
+ stale_control: "stale_control";
950
+ timeout: "timeout";
951
+ too_large: "too_large";
952
+ ui_tree_too_large: "ui_tree_too_large";
953
+ unauthorized: "unauthorized";
954
+ unsupported_capability: "unsupported_capability";
955
+ workspace_active_sessions: "workspace_active_sessions";
956
+ workspace_dirty: "workspace_dirty";
957
+ workspace_unmerged: "workspace_unmerged";
958
+ }>;
959
+ message: z.ZodString;
960
+ details: z.ZodOptional<z.ZodUnknown>;
961
+ }, z.core.$strip>;
962
+ }, z.core.$strip>]>;
963
+ }, z.core.$strip>, z.ZodObject<{
964
+ type: z.ZodLiteral<"pong">;
965
+ }, z.core.$strip>, z.ZodObject<{
966
+ type: z.ZodLiteral<"usage">;
967
+ usage: z.ZodArray<z.ZodObject<{
968
+ provider: z.ZodEnum<{
969
+ anthropic: "anthropic";
970
+ "openai-codex": "openai-codex";
971
+ }>;
972
+ status: z.ZodEnum<{
973
+ available: "available";
974
+ error: "error";
975
+ expired: "expired";
976
+ rejected: "rejected";
977
+ }>;
978
+ message: z.ZodNullable<z.ZodString>;
979
+ windows: z.ZodArray<z.ZodObject<{
980
+ id: z.ZodEnum<{
981
+ five_hour: "five_hour";
982
+ weekly: "weekly";
983
+ }>;
984
+ usedPct: z.ZodNumber;
985
+ resetsAt: z.ZodNullable<z.ZodString>;
986
+ }, z.core.$strip>>;
987
+ fetchedAt: z.ZodString;
988
+ }, z.core.$strip>>;
989
+ }, z.core.$strip>, z.ZodObject<{
990
+ type: z.ZodLiteral<"term">;
991
+ streamId: z.ZodString;
992
+ msg: z.ZodDiscriminatedUnion<[z.ZodObject<{
993
+ t: z.ZodLiteral<"out">;
994
+ d: z.ZodString;
995
+ }, z.core.$strip>, z.ZodObject<{
996
+ t: z.ZodLiteral<"closed">;
997
+ reason: z.ZodString;
998
+ }, z.core.$strip>, z.ZodObject<{
999
+ t: z.ZodLiteral<"size">;
1000
+ cols: z.ZodNumber;
1001
+ rows: z.ZodNumber;
1002
+ owner: z.ZodBoolean;
1003
+ }, z.core.$strip>], "t">;
1004
+ }, z.core.$strip>], "type">;
1005
+ export type HostToCoordinator = z.infer<typeof HostToCoordinator>;
1006
+ /** Coordinator -> host frames. */
1007
+ export declare const CoordinatorToHost: z.ZodDiscriminatedUnion<[z.ZodObject<{
1008
+ type: z.ZodLiteral<"welcome">;
1009
+ coordinatorVersion: z.ZodString;
1010
+ ackedHostSeq: z.ZodNumber;
1011
+ features: z.ZodOptional<z.ZodArray<z.ZodString>>;
1012
+ }, z.core.$strip>, z.ZodDiscriminatedUnion<[z.ZodObject<{
1013
+ type: z.ZodLiteral<"agent.result">;
1014
+ requestId: z.ZodString;
1015
+ runtimeId: z.ZodString;
1016
+ ok: z.ZodLiteral<true>;
1017
+ result: z.ZodUnknown;
1018
+ }, z.core.$strip>, z.ZodObject<{
1019
+ type: z.ZodLiteral<"agent.result">;
1020
+ requestId: z.ZodString;
1021
+ runtimeId: z.ZodString;
1022
+ ok: z.ZodLiteral<false>;
1023
+ error: z.ZodObject<{
1024
+ code: z.ZodEnum<{
1025
+ already_answered: "already_answered";
1026
+ branch_invalid: "branch_invalid";
1027
+ conflict: "conflict";
1028
+ dependency_cycle: "dependency_cycle";
1029
+ device_revoked: "device_revoked";
1030
+ enrollment_expired: "enrollment_expired";
1031
+ enrollment_used: "enrollment_used";
1032
+ forbidden: "forbidden";
1033
+ host_unreachable: "host_unreachable";
1034
+ internal: "internal";
1035
+ invalid_request: "invalid_request";
1036
+ invalid_transition: "invalid_transition";
1037
+ native_session_missing: "native_session_missing";
1038
+ not_a_git_repo: "not_a_git_repo";
1039
+ not_found: "not_found";
1040
+ path_collision: "path_collision";
1041
+ pi_incompatible: "pi_incompatible";
1042
+ rate_limited: "rate_limited";
1043
+ repo_mismatch: "repo_mismatch";
1044
+ stale_control: "stale_control";
1045
+ timeout: "timeout";
1046
+ too_large: "too_large";
1047
+ ui_tree_too_large: "ui_tree_too_large";
1048
+ unauthorized: "unauthorized";
1049
+ unsupported_capability: "unsupported_capability";
1050
+ workspace_active_sessions: "workspace_active_sessions";
1051
+ workspace_dirty: "workspace_dirty";
1052
+ workspace_unmerged: "workspace_unmerged";
1053
+ }>;
1054
+ message: z.ZodString;
1055
+ details: z.ZodOptional<z.ZodUnknown>;
1056
+ }, z.core.$strip>;
1057
+ }, z.core.$strip>], "ok">, z.ZodObject<{
1058
+ type: z.ZodLiteral<"ack">;
1059
+ hostSeq: z.ZodNumber;
1060
+ }, z.core.$strip>, z.ZodObject<{
1061
+ type: z.ZodLiteral<"command">;
1062
+ commandId: z.ZodString;
1063
+ command: z.ZodDiscriminatedUnion<[z.ZodObject<{
1064
+ type: z.ZodLiteral<"session.start">;
1065
+ sessionId: z.ZodString;
1066
+ title: z.ZodString;
1067
+ workspacePath: z.ZodString;
1068
+ projectId: z.ZodNullable<z.ZodString>;
1069
+ profile: z.ZodObject<{
1070
+ id: z.ZodString;
1071
+ name: z.ZodString;
1072
+ provider: z.ZodNullable<z.ZodString>;
1073
+ model: z.ZodNullable<z.ZodString>;
1074
+ thinking: z.ZodNullable<z.ZodEnum<{
1075
+ high: "high";
1076
+ low: "low";
1077
+ max: "max";
1078
+ medium: "medium";
1079
+ minimal: "minimal";
1080
+ off: "off";
1081
+ xhigh: "xhigh";
1082
+ }>>;
1083
+ projectTrust: z.ZodEnum<{
1084
+ approve: "approve";
1085
+ ask: "ask";
1086
+ ignore: "ignore";
1087
+ }>;
1088
+ extraArgs: z.ZodArray<z.ZodString>;
1089
+ resources: z.ZodOptional<z.ZodEnum<{
1090
+ all: "all";
1091
+ vanilla: "vanilla";
1092
+ }>>;
1093
+ }, z.core.$strip>;
1094
+ nativeHandle: z.ZodNullable<z.ZodObject<{
1095
+ sessionId: z.ZodString;
1096
+ sessionFile: z.ZodString;
1097
+ }, z.core.$strip>>;
1098
+ initialPrompt: z.ZodNullable<z.ZodString>;
1099
+ dispatchKey: z.ZodNullable<z.ZodString>;
1100
+ controlRevision: z.ZodNumber;
1101
+ controlMode: z.ZodEnum<{
1102
+ automation: "automation";
1103
+ human: "human";
1104
+ }>;
1105
+ origin: z.ZodEnum<{
1106
+ automation: "automation";
1107
+ human: "human";
1108
+ }>;
1109
+ readOnly: z.ZodDefault<z.ZodBoolean>;
1110
+ policyRequired: z.ZodOptional<z.ZodBoolean>;
1111
+ }, z.core.$strip>, z.ZodObject<{
1112
+ type: z.ZodLiteral<"session.deliverMessage">;
1113
+ sessionId: z.ZodString;
1114
+ messageId: z.ZodString;
1115
+ payload: z.ZodObject<{
1116
+ deliveryId: z.ZodString;
1117
+ kind: z.ZodEnum<{
1118
+ completion: "completion";
1119
+ message: "message";
1120
+ }>;
1121
+ text: z.ZodString;
1122
+ }, z.core.$strip>;
1123
+ mode: z.ZodEnum<{
1124
+ queue: "queue";
1125
+ steer: "steer";
1126
+ }>;
1127
+ holdUntil: z.ZodString;
1128
+ }, z.core.$strip>, z.ZodObject<{
1129
+ sessionId: z.ZodString;
1130
+ nativeSessionId: z.ZodString;
1131
+ runtimeId: z.ZodString;
1132
+ sampleId: z.ZodString;
1133
+ tool: z.ZodObject<{
1134
+ name: z.ZodString;
1135
+ args: z.ZodCustom<Record<string, import("./policies.js").JsonValue>, Record<string, import("./policies.js").JsonValue>>;
1136
+ }, z.core.$strict>;
1137
+ type: z.ZodLiteral<"session.classifyPolicySample">;
1138
+ }, z.core.$strict>, z.ZodObject<{
1139
+ type: z.ZodLiteral<"session.messageStatus">;
1140
+ sessionId: z.ZodString;
1141
+ messageIds: z.ZodArray<z.ZodString>;
1142
+ }, z.core.$strip>, z.ZodObject<{
1143
+ type: z.ZodLiteral<"session.prompt">;
1144
+ sessionId: z.ZodString;
1145
+ text: z.ZodString;
1146
+ images: z.ZodDefault<z.ZodArray<z.ZodObject<{
1147
+ mimeType: z.ZodString;
1148
+ data: z.ZodString;
1149
+ }, z.core.$strip>>>;
1150
+ mode: z.ZodEnum<{
1151
+ followUp: "followUp";
1152
+ prompt: "prompt";
1153
+ steer: "steer";
1154
+ }>;
1155
+ origin: z.ZodEnum<{
1156
+ automation: "automation";
1157
+ human: "human";
1158
+ }>;
1159
+ controlRevision: z.ZodNumber;
1160
+ }, z.core.$strip>, z.ZodObject<{
1161
+ type: z.ZodLiteral<"session.abort">;
1162
+ sessionId: z.ZodString;
1163
+ clearQueue: z.ZodBoolean;
1164
+ }, z.core.$strip>, z.ZodObject<{
1165
+ type: z.ZodLiteral<"session.stop">;
1166
+ sessionId: z.ZodString;
1167
+ }, z.core.$strip>, z.ZodObject<{
1168
+ type: z.ZodLiteral<"session.answer">;
1169
+ sessionId: z.ZodString;
1170
+ interactionId: z.ZodString;
1171
+ revision: z.ZodNumber;
1172
+ response: z.ZodDiscriminatedUnion<[z.ZodObject<{
1173
+ kind: z.ZodLiteral<"form">;
1174
+ values: z.ZodRecord<z.ZodString, z.ZodType<import("./ui.js").FormValue, unknown, z.core.$ZodTypeInternals<import("./ui.js").FormValue, unknown>>>;
1175
+ }, z.core.$strip>, z.ZodObject<{
1176
+ kind: z.ZodLiteral<"confirm">;
1177
+ confirmed: z.ZodBoolean;
1178
+ }, z.core.$strip>, z.ZodObject<{
1179
+ kind: z.ZodLiteral<"action">;
1180
+ actionId: z.ZodString;
1181
+ }, z.core.$strip>, z.ZodObject<{
1182
+ kind: z.ZodLiteral<"cancel">;
1183
+ }, z.core.$strip>], "kind">;
1184
+ deviceId: z.ZodString;
1185
+ }, z.core.$strip>, z.ZodObject<{
1186
+ type: z.ZodLiteral<"session.adapterAction">;
1187
+ sessionId: z.ZodString;
1188
+ generation: z.ZodOptional<z.ZodString>;
1189
+ adapterId: z.ZodString;
1190
+ actionId: z.ZodString;
1191
+ payload: z.ZodUnknown;
1192
+ }, z.core.$strip>, z.ZodObject<{
1193
+ type: z.ZodLiteral<"session.setControl">;
1194
+ sessionId: z.ZodString;
1195
+ controlRevision: z.ZodNumber;
1196
+ mode: z.ZodEnum<{
1197
+ automation: "automation";
1198
+ human: "human";
1199
+ }>;
1200
+ }, z.core.$strip>, z.ZodObject<{
1201
+ type: z.ZodLiteral<"session.rename">;
1202
+ sessionId: z.ZodString;
1203
+ title: z.ZodString;
1204
+ }, z.core.$strip>, z.ZodObject<{
1205
+ type: z.ZodLiteral<"session.importable">;
1206
+ }, z.core.$strip>, z.ZodObject<{
1207
+ type: z.ZodLiteral<"session.readNative">;
1208
+ sessionFile: z.ZodString;
1209
+ }, z.core.$strip>, z.ZodObject<{
1210
+ type: z.ZodLiteral<"session.snapshot">;
1211
+ sessionId: z.ZodString;
1212
+ }, z.core.$strip>, z.ZodObject<{
1213
+ type: z.ZodLiteral<"session.models">;
1214
+ sessionId: z.ZodString;
1215
+ }, z.core.$strip>, z.ZodObject<{
1216
+ type: z.ZodLiteral<"session.commands">;
1217
+ sessionId: z.ZodString;
1218
+ }, z.core.$strip>, z.ZodObject<{
1219
+ type: z.ZodLiteral<"session.complete">;
1220
+ sessionId: z.ZodString;
1221
+ text: z.ZodString;
1222
+ }, z.core.$strip>, z.ZodObject<{
1223
+ type: z.ZodLiteral<"session.tree">;
1224
+ sessionId: z.ZodString;
1225
+ }, z.core.$strip>, z.ZodObject<{
1226
+ type: z.ZodLiteral<"session.branch">;
1227
+ sessionId: z.ZodString;
1228
+ entryId: z.ZodNullable<z.ZodString>;
1229
+ fork: z.ZodBoolean;
1230
+ }, z.core.$strip>, z.ZodObject<{
1231
+ type: z.ZodLiteral<"session.navigate">;
1232
+ sessionId: z.ZodString;
1233
+ entryId: z.ZodString;
1234
+ summarize: z.ZodBoolean;
1235
+ instructions: z.ZodNullable<z.ZodString>;
1236
+ }, z.core.$strip>, z.ZodObject<{
1237
+ type: z.ZodLiteral<"session.reload">;
1238
+ sessionId: z.ZodString;
1239
+ }, z.core.$strip>, z.ZodObject<{
1240
+ type: z.ZodLiteral<"session.adapters">;
1241
+ sessionId: z.ZodString;
1242
+ }, z.core.$strip>, z.ZodObject<{
1243
+ type: z.ZodLiteral<"session.reloadAdapters">;
1244
+ sessionId: z.ZodString;
1245
+ }, z.core.$strip>, z.ZodObject<{
1246
+ type: z.ZodLiteral<"session.export">;
1247
+ sessionId: z.ZodString;
1248
+ }, z.core.$strip>, z.ZodObject<{
1249
+ type: z.ZodLiteral<"session.setModel">;
1250
+ sessionId: z.ZodString;
1251
+ provider: z.ZodString;
1252
+ modelId: z.ZodString;
1253
+ }, z.core.$strip>, z.ZodObject<{
1254
+ type: z.ZodLiteral<"session.setThinking">;
1255
+ sessionId: z.ZodString;
1256
+ level: z.ZodEnum<{
1257
+ high: "high";
1258
+ low: "low";
1259
+ max: "max";
1260
+ medium: "medium";
1261
+ minimal: "minimal";
1262
+ off: "off";
1263
+ xhigh: "xhigh";
1264
+ }>;
1265
+ }, z.core.$strip>, z.ZodObject<{
1266
+ type: z.ZodLiteral<"session.compact">;
1267
+ sessionId: z.ZodString;
1268
+ instructions: z.ZodNullable<z.ZodString>;
1269
+ }, z.core.$strip>, z.ZodObject<{
1270
+ type: z.ZodLiteral<"checkout.inspect">;
1271
+ path: z.ZodString;
1272
+ }, z.core.$strip>, z.ZodObject<{
1273
+ type: z.ZodLiteral<"projects.scan">;
1274
+ folder: z.ZodString;
1275
+ }, z.core.$strip>, z.ZodObject<{
1276
+ type: z.ZodLiteral<"projects.suggest">;
1277
+ days: z.ZodDefault<z.ZodNumber>;
1278
+ }, z.core.$strip>, z.ZodObject<{
1279
+ type: z.ZodLiteral<"workspace.discover">;
1280
+ checkoutPath: z.ZodString;
1281
+ worktreeDir: z.ZodDefault<z.ZodString>;
1282
+ }, z.core.$strip>, z.ZodObject<{
1283
+ type: z.ZodLiteral<"workspace.create">;
1284
+ checkoutPath: z.ZodString;
1285
+ branch: z.ZodString;
1286
+ base: z.ZodString;
1287
+ setupCommand: z.ZodNullable<z.ZodString>;
1288
+ worktreeDir: z.ZodDefault<z.ZodString>;
1289
+ }, z.core.$strip>, z.ZodObject<{
1290
+ type: z.ZodLiteral<"workspace.status">;
1291
+ path: z.ZodString;
1292
+ base: z.ZodNullable<z.ZodString>;
1293
+ }, z.core.$strip>, z.ZodObject<{
1294
+ type: z.ZodLiteral<"workspace.remove">;
1295
+ path: z.ZodString;
1296
+ checkoutPath: z.ZodString;
1297
+ base: z.ZodNullable<z.ZodString>;
1298
+ force: z.ZodObject<{
1299
+ dirty: z.ZodBoolean;
1300
+ unmerged: z.ZodBoolean;
1301
+ }, z.core.$strip>;
1302
+ }, z.core.$strip>, z.ZodObject<{
1303
+ type: z.ZodLiteral<"workspace.diff">;
1304
+ path: z.ZodString;
1305
+ base: z.ZodNullable<z.ZodString>;
1306
+ file: z.ZodNullable<z.ZodString>;
1307
+ }, z.core.$strip>, z.ZodObject<{
1308
+ type: z.ZodLiteral<"workspace.files">;
1309
+ path: z.ZodString;
1310
+ dir: z.ZodString;
1311
+ }, z.core.$strip>, z.ZodObject<{
1312
+ type: z.ZodLiteral<"workspace.readFile">;
1313
+ path: z.ZodString;
1314
+ file: z.ZodString;
1315
+ }, z.core.$strip>, z.ZodObject<{
1316
+ path: z.ZodString;
1317
+ type: z.ZodLiteral<"workspace.prView">;
1318
+ }, z.core.$strict>, z.ZodObject<{
1319
+ path: z.ZodString;
1320
+ repository: z.ZodString;
1321
+ number: z.ZodNumber;
1322
+ expectedHeadOid: z.ZodString;
1323
+ type: z.ZodLiteral<"workspace.prFailedLogs">;
1324
+ }, z.core.$strict>, z.ZodObject<{
1325
+ path: z.ZodString;
1326
+ repository: z.ZodString;
1327
+ number: z.ZodNumber;
1328
+ expectedHeadOid: z.ZodString;
1329
+ expectedPullRequestNodeId: z.ZodString;
1330
+ type: z.ZodLiteral<"workspace.prMerge">;
1331
+ }, z.core.$strict>, z.ZodObject<{
1332
+ type: z.ZodLiteral<"dispatch.start">;
1333
+ dispatchKey: z.ZodString;
1334
+ runId: z.ZodString;
1335
+ taskId: z.ZodString;
1336
+ sessionId: z.ZodString;
1337
+ projectId: z.ZodString;
1338
+ title: z.ZodString;
1339
+ workspace: z.ZodUnion<readonly [z.ZodObject<{
1340
+ path: z.ZodString;
1341
+ }, z.core.$strip>, z.ZodObject<{
1342
+ createFrom: z.ZodObject<{
1343
+ checkoutPath: z.ZodString;
1344
+ branch: z.ZodString;
1345
+ base: z.ZodString;
1346
+ setupCommand: z.ZodNullable<z.ZodString>;
1347
+ worktreeDir: z.ZodDefault<z.ZodString>;
1348
+ }, z.core.$strip>;
1349
+ }, z.core.$strip>]>;
1350
+ nativeHandle: z.ZodNullable<z.ZodObject<{
1351
+ sessionId: z.ZodString;
1352
+ sessionFile: z.ZodString;
1353
+ }, z.core.$strip>>;
1354
+ profile: z.ZodObject<{
1355
+ id: z.ZodString;
1356
+ name: z.ZodString;
1357
+ provider: z.ZodNullable<z.ZodString>;
1358
+ model: z.ZodNullable<z.ZodString>;
1359
+ thinking: z.ZodNullable<z.ZodEnum<{
1360
+ high: "high";
1361
+ low: "low";
1362
+ max: "max";
1363
+ medium: "medium";
1364
+ minimal: "minimal";
1365
+ off: "off";
1366
+ xhigh: "xhigh";
1367
+ }>>;
1368
+ projectTrust: z.ZodEnum<{
1369
+ approve: "approve";
1370
+ ask: "ask";
1371
+ ignore: "ignore";
1372
+ }>;
1373
+ extraArgs: z.ZodArray<z.ZodString>;
1374
+ resources: z.ZodOptional<z.ZodEnum<{
1375
+ all: "all";
1376
+ vanilla: "vanilla";
1377
+ }>>;
1378
+ }, z.core.$strip>;
1379
+ prompt: z.ZodString;
1380
+ controlRevision: z.ZodNumber;
1381
+ controlMode: z.ZodDefault<z.ZodEnum<{
1382
+ automation: "automation";
1383
+ human: "human";
1384
+ }>>;
1385
+ policyRequired: z.ZodOptional<z.ZodBoolean>;
1386
+ }, z.core.$strip>, z.ZodObject<{
1387
+ type: z.ZodLiteral<"dispatch.reconcile">;
1388
+ dispatchKey: z.ZodString;
1389
+ }, z.core.$strip>, z.ZodObject<{
1390
+ type: z.ZodLiteral<"checks.run">;
1391
+ sessionId: z.ZodString;
1392
+ path: z.ZodString;
1393
+ commands: z.ZodArray<z.ZodString>;
1394
+ }, z.core.$strip>], "type">;
1395
+ }, z.core.$strip>, z.ZodObject<{
1396
+ type: z.ZodLiteral<"ping">;
1397
+ }, z.core.$strip>, z.ZodObject<{
1398
+ type: z.ZodLiteral<"reject">;
1399
+ error: z.ZodObject<{
1400
+ code: z.ZodEnum<{
1401
+ already_answered: "already_answered";
1402
+ branch_invalid: "branch_invalid";
1403
+ conflict: "conflict";
1404
+ dependency_cycle: "dependency_cycle";
1405
+ device_revoked: "device_revoked";
1406
+ enrollment_expired: "enrollment_expired";
1407
+ enrollment_used: "enrollment_used";
1408
+ forbidden: "forbidden";
1409
+ host_unreachable: "host_unreachable";
1410
+ internal: "internal";
1411
+ invalid_request: "invalid_request";
1412
+ invalid_transition: "invalid_transition";
1413
+ native_session_missing: "native_session_missing";
1414
+ not_a_git_repo: "not_a_git_repo";
1415
+ not_found: "not_found";
1416
+ path_collision: "path_collision";
1417
+ pi_incompatible: "pi_incompatible";
1418
+ rate_limited: "rate_limited";
1419
+ repo_mismatch: "repo_mismatch";
1420
+ stale_control: "stale_control";
1421
+ timeout: "timeout";
1422
+ too_large: "too_large";
1423
+ ui_tree_too_large: "ui_tree_too_large";
1424
+ unauthorized: "unauthorized";
1425
+ unsupported_capability: "unsupported_capability";
1426
+ workspace_active_sessions: "workspace_active_sessions";
1427
+ workspace_dirty: "workspace_dirty";
1428
+ workspace_unmerged: "workspace_unmerged";
1429
+ }>;
1430
+ message: z.ZodString;
1431
+ details: z.ZodOptional<z.ZodUnknown>;
1432
+ }, z.core.$strip>;
1433
+ }, z.core.$strip>, z.ZodObject<{
1434
+ type: z.ZodLiteral<"term">;
1435
+ streamId: z.ZodString;
1436
+ msg: z.ZodDiscriminatedUnion<[z.ZodObject<{
1437
+ t: z.ZodLiteral<"open">;
1438
+ sessionId: z.ZodString;
1439
+ cols: z.ZodNumber;
1440
+ rows: z.ZodNumber;
1441
+ passive: z.ZodOptional<z.ZodBoolean>;
1442
+ }, z.core.$strip>, z.ZodObject<{
1443
+ t: z.ZodLiteral<"claim">;
1444
+ }, z.core.$strip>, z.ZodObject<{
1445
+ t: z.ZodLiteral<"in">;
1446
+ d: z.ZodString;
1447
+ }, z.core.$strip>, z.ZodObject<{
1448
+ t: z.ZodLiteral<"resize">;
1449
+ cols: z.ZodNumber;
1450
+ rows: z.ZodNumber;
1451
+ }, z.core.$strip>, z.ZodObject<{
1452
+ t: z.ZodLiteral<"close">;
1453
+ }, z.core.$strip>], "t">;
1454
+ }, z.core.$strip>], "type">;
1455
+ export type CoordinatorToHost = z.infer<typeof CoordinatorToHost>;
1456
+ //# sourceMappingURL=host-wire.d.ts.map