@opengeni/contracts 0.2.0 → 0.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -14,8 +14,83 @@ declare const SandboxBackend: z.ZodEnum<{
14
14
  modal: "modal";
15
15
  local: "local";
16
16
  none: "none";
17
+ daytona: "daytona";
18
+ runloop: "runloop";
19
+ e2b: "e2b";
20
+ blaxel: "blaxel";
21
+ cloudflare: "cloudflare";
22
+ vercel: "vercel";
23
+ selfhosted: "selfhosted";
17
24
  }>;
18
25
  type SandboxBackend = z.infer<typeof SandboxBackend>;
26
+ declare const SandboxOs: z.ZodEnum<{
27
+ linux: "linux";
28
+ macos: "macos";
29
+ windows: "windows";
30
+ }>;
31
+ type SandboxOs = z.infer<typeof SandboxOs>;
32
+ declare const SandboxCapabilityName: z.ZodEnum<{
33
+ FileSystem: "FileSystem";
34
+ Terminal: "Terminal";
35
+ Git: "Git";
36
+ DesktopStream: "DesktopStream";
37
+ Recording: "Recording";
38
+ }>;
39
+ type SandboxCapabilityName = z.infer<typeof SandboxCapabilityName>;
40
+ type PortExposureKind = "provider-tunnel" | "preview-url" | "local-port" | "none";
41
+ type CapabilityDescriptor = {
42
+ backend: SandboxBackend;
43
+ backendId: string;
44
+ tier: "desktop" | "headless" | "dev" | "none";
45
+ os: {
46
+ supported: SandboxOs[];
47
+ default: SandboxOs;
48
+ };
49
+ capabilities: {
50
+ FileSystem: {
51
+ available: boolean;
52
+ readOnly: boolean;
53
+ };
54
+ Terminal: {
55
+ available: boolean;
56
+ transport: "sse-events" | "pty-ws" | null;
57
+ pty: boolean;
58
+ };
59
+ Git: {
60
+ available: boolean;
61
+ };
62
+ DesktopStream: {
63
+ available: boolean;
64
+ transport: "vnc-ws" | "rdp-ws" | "webrtc" | null;
65
+ };
66
+ Recording: {
67
+ available: boolean;
68
+ };
69
+ };
70
+ lifetime: {
71
+ hardLifetimeMs?: number;
72
+ requiresSnapshotRollover: boolean;
73
+ hasIdleKiller: boolean;
74
+ supportsSuspendResume: boolean;
75
+ resumeIsLockFree: boolean;
76
+ idleKillDisableHint?: string;
77
+ };
78
+ snapshot: {
79
+ kind: "native-fs" | "native-dir" | "native-snapshot-id" | "tar-only" | "none";
80
+ hasTarFallback: boolean;
81
+ };
82
+ portExposure: {
83
+ kind: PortExposureKind;
84
+ supportsOnDemandPorts: boolean;
85
+ };
86
+ workspaceRoot: string;
87
+ nativeBucketMount: boolean;
88
+ persistable: boolean;
89
+ supportsRunAs: boolean;
90
+ };
91
+ declare const DESKTOP_STREAM_PORT = 6080;
92
+ declare const TERMINAL_STREAM_PORT = 7681;
93
+ declare const CAPABILITY_DESCRIPTORS: Record<SandboxBackend, CapabilityDescriptor>;
19
94
  declare const ReasoningEffort: z.ZodEnum<{
20
95
  none: "none";
21
96
  minimal: "minimal";
@@ -84,8 +159,13 @@ declare const Permission: z.ZodEnum<{
84
159
  "sessions:create": "sessions:create";
85
160
  "sessions:read": "sessions:read";
86
161
  "sessions:control": "sessions:control";
162
+ "stream:view": "stream:view";
163
+ "stream:control": "stream:control";
164
+ "stream:acknowledge": "stream:acknowledge";
87
165
  "files:upload": "files:upload";
88
166
  "files:read": "files:read";
167
+ "files:write": "files:write";
168
+ "terminal:attach": "terminal:attach";
89
169
  "documents:manage": "documents:manage";
90
170
  "documents:search": "documents:search";
91
171
  "scheduled_tasks:manage": "scheduled_tasks:manage";
@@ -96,6 +176,8 @@ declare const Permission: z.ZodEnum<{
96
176
  "environments:manage": "environments:manage";
97
177
  "environments:use": "environments:use";
98
178
  "goals:manage": "goals:manage";
179
+ "enrollments:read": "enrollments:read";
180
+ "enrollments:manage": "enrollments:manage";
99
181
  }>;
100
182
  type Permission = z.infer<typeof Permission>;
101
183
  declare const ProductAccessMode: z.ZodEnum<{
@@ -169,8 +251,13 @@ declare const AccountGrant: z.ZodObject<{
169
251
  "sessions:create": "sessions:create";
170
252
  "sessions:read": "sessions:read";
171
253
  "sessions:control": "sessions:control";
254
+ "stream:view": "stream:view";
255
+ "stream:control": "stream:control";
256
+ "stream:acknowledge": "stream:acknowledge";
172
257
  "files:upload": "files:upload";
173
258
  "files:read": "files:read";
259
+ "files:write": "files:write";
260
+ "terminal:attach": "terminal:attach";
174
261
  "documents:manage": "documents:manage";
175
262
  "documents:search": "documents:search";
176
263
  "scheduled_tasks:manage": "scheduled_tasks:manage";
@@ -181,6 +268,8 @@ declare const AccountGrant: z.ZodObject<{
181
268
  "environments:manage": "environments:manage";
182
269
  "environments:use": "environments:use";
183
270
  "goals:manage": "goals:manage";
271
+ "enrollments:read": "enrollments:read";
272
+ "enrollments:manage": "enrollments:manage";
184
273
  }>>;
185
274
  metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
186
275
  }, z.core.$strip>;
@@ -202,8 +291,13 @@ declare const AccessGrant: z.ZodObject<{
202
291
  "sessions:create": "sessions:create";
203
292
  "sessions:read": "sessions:read";
204
293
  "sessions:control": "sessions:control";
294
+ "stream:view": "stream:view";
295
+ "stream:control": "stream:control";
296
+ "stream:acknowledge": "stream:acknowledge";
205
297
  "files:upload": "files:upload";
206
298
  "files:read": "files:read";
299
+ "files:write": "files:write";
300
+ "terminal:attach": "terminal:attach";
207
301
  "documents:manage": "documents:manage";
208
302
  "documents:search": "documents:search";
209
303
  "scheduled_tasks:manage": "scheduled_tasks:manage";
@@ -214,6 +308,8 @@ declare const AccessGrant: z.ZodObject<{
214
308
  "environments:manage": "environments:manage";
215
309
  "environments:use": "environments:use";
216
310
  "goals:manage": "goals:manage";
311
+ "enrollments:read": "enrollments:read";
312
+ "enrollments:manage": "enrollments:manage";
217
313
  }>>;
218
314
  metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
219
315
  }, z.core.$strip>;
@@ -247,8 +343,13 @@ declare const AccessContext: z.ZodObject<{
247
343
  "sessions:create": "sessions:create";
248
344
  "sessions:read": "sessions:read";
249
345
  "sessions:control": "sessions:control";
346
+ "stream:view": "stream:view";
347
+ "stream:control": "stream:control";
348
+ "stream:acknowledge": "stream:acknowledge";
250
349
  "files:upload": "files:upload";
251
350
  "files:read": "files:read";
351
+ "files:write": "files:write";
352
+ "terminal:attach": "terminal:attach";
252
353
  "documents:manage": "documents:manage";
253
354
  "documents:search": "documents:search";
254
355
  "scheduled_tasks:manage": "scheduled_tasks:manage";
@@ -259,6 +360,8 @@ declare const AccessContext: z.ZodObject<{
259
360
  "environments:manage": "environments:manage";
260
361
  "environments:use": "environments:use";
261
362
  "goals:manage": "goals:manage";
363
+ "enrollments:read": "enrollments:read";
364
+ "enrollments:manage": "enrollments:manage";
262
365
  }>>;
263
366
  metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
264
367
  }, z.core.$strip>>;
@@ -279,8 +382,13 @@ declare const AccessContext: z.ZodObject<{
279
382
  "sessions:create": "sessions:create";
280
383
  "sessions:read": "sessions:read";
281
384
  "sessions:control": "sessions:control";
385
+ "stream:view": "stream:view";
386
+ "stream:control": "stream:control";
387
+ "stream:acknowledge": "stream:acknowledge";
282
388
  "files:upload": "files:upload";
283
389
  "files:read": "files:read";
390
+ "files:write": "files:write";
391
+ "terminal:attach": "terminal:attach";
284
392
  "documents:manage": "documents:manage";
285
393
  "documents:search": "documents:search";
286
394
  "scheduled_tasks:manage": "scheduled_tasks:manage";
@@ -291,6 +399,8 @@ declare const AccessContext: z.ZodObject<{
291
399
  "environments:manage": "environments:manage";
292
400
  "environments:use": "environments:use";
293
401
  "goals:manage": "goals:manage";
402
+ "enrollments:read": "enrollments:read";
403
+ "enrollments:manage": "enrollments:manage";
294
404
  }>>;
295
405
  metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
296
406
  }, z.core.$strip>>;
@@ -315,8 +425,13 @@ declare const DelegatedAccessTokenPayload: z.ZodObject<{
315
425
  "sessions:create": "sessions:create";
316
426
  "sessions:read": "sessions:read";
317
427
  "sessions:control": "sessions:control";
428
+ "stream:view": "stream:view";
429
+ "stream:control": "stream:control";
430
+ "stream:acknowledge": "stream:acknowledge";
318
431
  "files:upload": "files:upload";
319
432
  "files:read": "files:read";
433
+ "files:write": "files:write";
434
+ "terminal:attach": "terminal:attach";
320
435
  "documents:manage": "documents:manage";
321
436
  "documents:search": "documents:search";
322
437
  "scheduled_tasks:manage": "scheduled_tasks:manage";
@@ -327,6 +442,8 @@ declare const DelegatedAccessTokenPayload: z.ZodObject<{
327
442
  "environments:manage": "environments:manage";
328
443
  "environments:use": "environments:use";
329
444
  "goals:manage": "goals:manage";
445
+ "enrollments:read": "enrollments:read";
446
+ "enrollments:manage": "enrollments:manage";
330
447
  }>>;
331
448
  sessionId: z.ZodOptional<z.ZodString>;
332
449
  exp: z.ZodNumber;
@@ -334,6 +451,77 @@ declare const DelegatedAccessTokenPayload: z.ZodObject<{
334
451
  type DelegatedAccessTokenPayload = z.infer<typeof DelegatedAccessTokenPayload>;
335
452
  declare function signDelegatedAccessToken(secret: string, payload: DelegatedAccessTokenPayload): Promise<string>;
336
453
  declare function verifyDelegatedAccessToken(secret: string, token: string, nowSeconds?: number): Promise<DelegatedAccessTokenPayload | null>;
454
+ declare const EnrollmentBearerPayload: z.ZodObject<{
455
+ workspaceId: z.ZodString;
456
+ agentId: z.ZodString;
457
+ enrollmentId: z.ZodString;
458
+ subjectPrefix: z.ZodString;
459
+ exp: z.ZodNumber;
460
+ }, z.core.$strip>;
461
+ type EnrollmentBearerPayload = z.infer<typeof EnrollmentBearerPayload>;
462
+ declare function signEnrollmentBearer(secret: string, payload: EnrollmentBearerPayload): Promise<string>;
463
+ declare function verifyEnrollmentBearer(secret: string, token: string, nowSeconds?: number): Promise<EnrollmentBearerPayload | null>;
464
+ declare const EnrollTokenPayload: z.ZodObject<{
465
+ typ: z.ZodLiteral<"enroll">;
466
+ workspaceId: z.ZodString;
467
+ accountId: z.ZodString;
468
+ allowScreenControl: z.ZodBoolean;
469
+ iat: z.ZodNumber;
470
+ exp: z.ZodNumber;
471
+ }, z.core.$strip>;
472
+ type EnrollTokenPayload = z.infer<typeof EnrollTokenPayload>;
473
+ declare function signEnrollToken(secret: string, payload: EnrollTokenPayload): Promise<string>;
474
+ /**
475
+ * Verify an enroll token: rejects (returns null) on a bad prefix (NOT `oget_`),
476
+ * a malformed envelope, a bad HMAC signature (constant-time), schema-invalid
477
+ * claims (which includes `typ !== "enroll"` — the `z.literal` rejects it), or an
478
+ * expired token (`exp < now`). Mirrors verifyEnrollmentBearer exactly. An `oge_`
479
+ * bearer fails the prefix gate; a same-secret token that lacks the typ claim fails
480
+ * the schema gate — both halves of the domain separation are enforced here.
481
+ */
482
+ declare function verifyEnrollToken(secret: string, token: string, nowSeconds?: number): Promise<EnrollTokenPayload | null>;
483
+ declare const StreamTokenPayload: z.ZodObject<{
484
+ workspaceId: z.ZodString;
485
+ sessionId: z.ZodString;
486
+ viewerId: z.ZodString;
487
+ leaseEpoch: z.ZodNumber;
488
+ mode: z.ZodEnum<{
489
+ view: "view";
490
+ control: "control";
491
+ }>;
492
+ port: z.ZodNumber;
493
+ exp: z.ZodNumber;
494
+ }, z.core.$strip>;
495
+ type StreamTokenPayload = z.infer<typeof StreamTokenPayload>;
496
+ declare function signStreamToken(secret: string, payload: StreamTokenPayload): Promise<string>;
497
+ /**
498
+ * Verify a stream token: rejects (returns null) on a bad prefix, malformed
499
+ * envelope, bad HMAC signature (constant-time), schema-invalid claims, or an
500
+ * expired token (`exp < now`). Mirrors verifyDelegatedAccessToken exactly.
501
+ *
502
+ * The epoch fence (claim.leaseEpoch vs the LIVE lease epoch) and the
503
+ * workspace/session scope are checked by the CALLER at use against the live
504
+ * lease + route params — verify proves the token is authentic + unexpired, the
505
+ * caller proves it is for THIS box's current epoch and THIS workspace+session.
506
+ */
507
+ declare function verifyStreamToken(secret: string, token: string, nowSeconds?: number): Promise<StreamTokenPayload | null>;
508
+ declare const RelayTokenPayload: z.ZodObject<{
509
+ workspaceId: z.ZodString;
510
+ agentId: z.ZodString;
511
+ exp: z.ZodNumber;
512
+ }, z.core.$strip>;
513
+ type RelayTokenPayload = z.infer<typeof RelayTokenPayload>;
514
+ declare function signRelayToken(secret: string, payload: RelayTokenPayload): Promise<string>;
515
+ /**
516
+ * Verify a relay producer token: rejects (returns null) on a bad prefix, malformed
517
+ * envelope, bad HMAC signature (constant-time), schema-invalid claims, or expiry.
518
+ * Mirrors verifyStreamToken exactly. The relay (Rust) re-implements this verify;
519
+ * the TS verify here proves the format for the cross-stack fixture + any TS caller.
520
+ *
521
+ * The channel-key scope (claim.workspaceId/agentId vs the StreamOpen channel key)
522
+ * is enforced by the relay at USE — verify proves authenticity + freshness only.
523
+ */
524
+ declare function verifyRelayToken(secret: string, token: string, nowSeconds?: number): Promise<RelayTokenPayload | null>;
337
525
  declare const CreateWorkspaceRequest: z.ZodObject<{
338
526
  accountId: z.ZodOptional<z.ZodString>;
339
527
  name: z.ZodString;
@@ -367,8 +555,13 @@ declare const ApiKey: z.ZodObject<{
367
555
  "sessions:create": "sessions:create";
368
556
  "sessions:read": "sessions:read";
369
557
  "sessions:control": "sessions:control";
558
+ "stream:view": "stream:view";
559
+ "stream:control": "stream:control";
560
+ "stream:acknowledge": "stream:acknowledge";
370
561
  "files:upload": "files:upload";
371
562
  "files:read": "files:read";
563
+ "files:write": "files:write";
564
+ "terminal:attach": "terminal:attach";
372
565
  "documents:manage": "documents:manage";
373
566
  "documents:search": "documents:search";
374
567
  "scheduled_tasks:manage": "scheduled_tasks:manage";
@@ -379,6 +572,8 @@ declare const ApiKey: z.ZodObject<{
379
572
  "environments:manage": "environments:manage";
380
573
  "environments:use": "environments:use";
381
574
  "goals:manage": "goals:manage";
575
+ "enrollments:read": "enrollments:read";
576
+ "enrollments:manage": "enrollments:manage";
382
577
  }>>;
383
578
  expiresAt: z.ZodNullable<z.ZodString>;
384
579
  revokedAt: z.ZodNullable<z.ZodString>;
@@ -402,8 +597,13 @@ declare const CreateApiKeyRequest: z.ZodObject<{
402
597
  "sessions:create": "sessions:create";
403
598
  "sessions:read": "sessions:read";
404
599
  "sessions:control": "sessions:control";
600
+ "stream:view": "stream:view";
601
+ "stream:control": "stream:control";
602
+ "stream:acknowledge": "stream:acknowledge";
405
603
  "files:upload": "files:upload";
406
604
  "files:read": "files:read";
605
+ "files:write": "files:write";
606
+ "terminal:attach": "terminal:attach";
407
607
  "documents:manage": "documents:manage";
408
608
  "documents:search": "documents:search";
409
609
  "scheduled_tasks:manage": "scheduled_tasks:manage";
@@ -414,6 +614,8 @@ declare const CreateApiKeyRequest: z.ZodObject<{
414
614
  "environments:manage": "environments:manage";
415
615
  "environments:use": "environments:use";
416
616
  "goals:manage": "goals:manage";
617
+ "enrollments:read": "enrollments:read";
618
+ "enrollments:manage": "enrollments:manage";
417
619
  }>>;
418
620
  expiresAt: z.ZodOptional<z.ZodString>;
419
621
  }, z.core.$strip>;
@@ -437,8 +639,13 @@ declare const CreateApiKeyResponse: z.ZodObject<{
437
639
  "sessions:create": "sessions:create";
438
640
  "sessions:read": "sessions:read";
439
641
  "sessions:control": "sessions:control";
642
+ "stream:view": "stream:view";
643
+ "stream:control": "stream:control";
644
+ "stream:acknowledge": "stream:acknowledge";
440
645
  "files:upload": "files:upload";
441
646
  "files:read": "files:read";
647
+ "files:write": "files:write";
648
+ "terminal:attach": "terminal:attach";
442
649
  "documents:manage": "documents:manage";
443
650
  "documents:search": "documents:search";
444
651
  "scheduled_tasks:manage": "scheduled_tasks:manage";
@@ -449,6 +656,8 @@ declare const CreateApiKeyResponse: z.ZodObject<{
449
656
  "environments:manage": "environments:manage";
450
657
  "environments:use": "environments:use";
451
658
  "goals:manage": "goals:manage";
659
+ "enrollments:read": "enrollments:read";
660
+ "enrollments:manage": "enrollments:manage";
452
661
  }>>;
453
662
  expiresAt: z.ZodNullable<z.ZodString>;
454
663
  revokedAt: z.ZodNullable<z.ZodString>;
@@ -459,6 +668,159 @@ declare const CreateApiKeyResponse: z.ZodObject<{
459
668
  token: z.ZodString;
460
669
  }, z.core.$strip>;
461
670
  type CreateApiKeyResponse = z.infer<typeof CreateApiKeyResponse>;
671
+ declare const WorkspaceMember: z.ZodObject<{
672
+ subjectId: z.ZodString;
673
+ subjectLabel: z.ZodNullable<z.ZodString>;
674
+ role: z.ZodString;
675
+ permissions: z.ZodArray<z.ZodEnum<{
676
+ "account:read": "account:read";
677
+ "account:admin": "account:admin";
678
+ "members:manage": "members:manage";
679
+ "workspace:create": "workspace:create";
680
+ "billing:read": "billing:read";
681
+ "billing:manage": "billing:manage";
682
+ "workspace:read": "workspace:read";
683
+ "workspace:admin": "workspace:admin";
684
+ "sessions:create": "sessions:create";
685
+ "sessions:read": "sessions:read";
686
+ "sessions:control": "sessions:control";
687
+ "stream:view": "stream:view";
688
+ "stream:control": "stream:control";
689
+ "stream:acknowledge": "stream:acknowledge";
690
+ "files:upload": "files:upload";
691
+ "files:read": "files:read";
692
+ "files:write": "files:write";
693
+ "terminal:attach": "terminal:attach";
694
+ "documents:manage": "documents:manage";
695
+ "documents:search": "documents:search";
696
+ "scheduled_tasks:manage": "scheduled_tasks:manage";
697
+ "scheduled_tasks:run": "scheduled_tasks:run";
698
+ "github:manage": "github:manage";
699
+ "github:use": "github:use";
700
+ "api_keys:manage": "api_keys:manage";
701
+ "environments:manage": "environments:manage";
702
+ "environments:use": "environments:use";
703
+ "goals:manage": "goals:manage";
704
+ "enrollments:read": "enrollments:read";
705
+ "enrollments:manage": "enrollments:manage";
706
+ }>>;
707
+ createdAt: z.ZodString;
708
+ }, z.core.$strip>;
709
+ type WorkspaceMember = z.infer<typeof WorkspaceMember>;
710
+ declare const ListWorkspaceMembersResponse: z.ZodObject<{
711
+ members: z.ZodArray<z.ZodObject<{
712
+ subjectId: z.ZodString;
713
+ subjectLabel: z.ZodNullable<z.ZodString>;
714
+ role: z.ZodString;
715
+ permissions: z.ZodArray<z.ZodEnum<{
716
+ "account:read": "account:read";
717
+ "account:admin": "account:admin";
718
+ "members:manage": "members:manage";
719
+ "workspace:create": "workspace:create";
720
+ "billing:read": "billing:read";
721
+ "billing:manage": "billing:manage";
722
+ "workspace:read": "workspace:read";
723
+ "workspace:admin": "workspace:admin";
724
+ "sessions:create": "sessions:create";
725
+ "sessions:read": "sessions:read";
726
+ "sessions:control": "sessions:control";
727
+ "stream:view": "stream:view";
728
+ "stream:control": "stream:control";
729
+ "stream:acknowledge": "stream:acknowledge";
730
+ "files:upload": "files:upload";
731
+ "files:read": "files:read";
732
+ "files:write": "files:write";
733
+ "terminal:attach": "terminal:attach";
734
+ "documents:manage": "documents:manage";
735
+ "documents:search": "documents:search";
736
+ "scheduled_tasks:manage": "scheduled_tasks:manage";
737
+ "scheduled_tasks:run": "scheduled_tasks:run";
738
+ "github:manage": "github:manage";
739
+ "github:use": "github:use";
740
+ "api_keys:manage": "api_keys:manage";
741
+ "environments:manage": "environments:manage";
742
+ "environments:use": "environments:use";
743
+ "goals:manage": "goals:manage";
744
+ "enrollments:read": "enrollments:read";
745
+ "enrollments:manage": "enrollments:manage";
746
+ }>>;
747
+ createdAt: z.ZodString;
748
+ }, z.core.$strip>>;
749
+ }, z.core.$strip>;
750
+ type ListWorkspaceMembersResponse = z.infer<typeof ListWorkspaceMembersResponse>;
751
+ declare const AddWorkspaceMemberRequest: z.ZodObject<{
752
+ email: z.ZodString;
753
+ role: z.ZodOptional<z.ZodString>;
754
+ permissions: z.ZodArray<z.ZodEnum<{
755
+ "account:read": "account:read";
756
+ "account:admin": "account:admin";
757
+ "members:manage": "members:manage";
758
+ "workspace:create": "workspace:create";
759
+ "billing:read": "billing:read";
760
+ "billing:manage": "billing:manage";
761
+ "workspace:read": "workspace:read";
762
+ "workspace:admin": "workspace:admin";
763
+ "sessions:create": "sessions:create";
764
+ "sessions:read": "sessions:read";
765
+ "sessions:control": "sessions:control";
766
+ "stream:view": "stream:view";
767
+ "stream:control": "stream:control";
768
+ "stream:acknowledge": "stream:acknowledge";
769
+ "files:upload": "files:upload";
770
+ "files:read": "files:read";
771
+ "files:write": "files:write";
772
+ "terminal:attach": "terminal:attach";
773
+ "documents:manage": "documents:manage";
774
+ "documents:search": "documents:search";
775
+ "scheduled_tasks:manage": "scheduled_tasks:manage";
776
+ "scheduled_tasks:run": "scheduled_tasks:run";
777
+ "github:manage": "github:manage";
778
+ "github:use": "github:use";
779
+ "api_keys:manage": "api_keys:manage";
780
+ "environments:manage": "environments:manage";
781
+ "environments:use": "environments:use";
782
+ "goals:manage": "goals:manage";
783
+ "enrollments:read": "enrollments:read";
784
+ "enrollments:manage": "enrollments:manage";
785
+ }>>;
786
+ }, z.core.$strip>;
787
+ type AddWorkspaceMemberRequest = z.infer<typeof AddWorkspaceMemberRequest>;
788
+ declare const UpdateWorkspaceMemberRequest: z.ZodObject<{
789
+ role: z.ZodOptional<z.ZodString>;
790
+ permissions: z.ZodArray<z.ZodEnum<{
791
+ "account:read": "account:read";
792
+ "account:admin": "account:admin";
793
+ "members:manage": "members:manage";
794
+ "workspace:create": "workspace:create";
795
+ "billing:read": "billing:read";
796
+ "billing:manage": "billing:manage";
797
+ "workspace:read": "workspace:read";
798
+ "workspace:admin": "workspace:admin";
799
+ "sessions:create": "sessions:create";
800
+ "sessions:read": "sessions:read";
801
+ "sessions:control": "sessions:control";
802
+ "stream:view": "stream:view";
803
+ "stream:control": "stream:control";
804
+ "stream:acknowledge": "stream:acknowledge";
805
+ "files:upload": "files:upload";
806
+ "files:read": "files:read";
807
+ "files:write": "files:write";
808
+ "terminal:attach": "terminal:attach";
809
+ "documents:manage": "documents:manage";
810
+ "documents:search": "documents:search";
811
+ "scheduled_tasks:manage": "scheduled_tasks:manage";
812
+ "scheduled_tasks:run": "scheduled_tasks:run";
813
+ "github:manage": "github:manage";
814
+ "github:use": "github:use";
815
+ "api_keys:manage": "api_keys:manage";
816
+ "environments:manage": "environments:manage";
817
+ "environments:use": "environments:use";
818
+ "goals:manage": "goals:manage";
819
+ "enrollments:read": "enrollments:read";
820
+ "enrollments:manage": "enrollments:manage";
821
+ }>>;
822
+ }, z.core.$strip>;
823
+ type UpdateWorkspaceMemberRequest = z.infer<typeof UpdateWorkspaceMemberRequest>;
462
824
  declare const UsageEventType: z.ZodEnum<{
463
825
  "agent_run.created": "agent_run.created";
464
826
  "agent_run.completed": "agent_run.completed";
@@ -469,6 +831,8 @@ declare const UsageEventType: z.ZodEnum<{
469
831
  "document.indexed": "document.indexed";
470
832
  "scheduled_task.fired": "scheduled_task.fired";
471
833
  "api_key.request": "api_key.request";
834
+ "sandbox.warm_seconds": "sandbox.warm_seconds";
835
+ "sandbox.warm_cost": "sandbox.warm_cost";
472
836
  }>;
473
837
  type UsageEventType = z.infer<typeof UsageEventType>;
474
838
  declare const UsageEvent: z.ZodObject<{
@@ -486,6 +850,8 @@ declare const UsageEvent: z.ZodObject<{
486
850
  "document.indexed": "document.indexed";
487
851
  "scheduled_task.fired": "scheduled_task.fired";
488
852
  "api_key.request": "api_key.request";
853
+ "sandbox.warm_seconds": "sandbox.warm_seconds";
854
+ "sandbox.warm_cost": "sandbox.warm_cost";
489
855
  }>;
490
856
  quantity: z.ZodNumber;
491
857
  unit: z.ZodString;
@@ -531,6 +897,70 @@ declare const LimitDecision: z.ZodDiscriminatedUnion<[z.ZodObject<{
531
897
  message: z.ZodString;
532
898
  }, z.core.$strip>], "allowed">;
533
899
  type LimitDecision = z.infer<typeof LimitDecision>;
900
+ declare const EntitlementDecision: z.ZodDiscriminatedUnion<[z.ZodObject<{
901
+ allowed: z.ZodLiteral<true>;
902
+ quantity: z.ZodOptional<z.ZodNumber>;
903
+ }, z.core.$strip>, z.ZodObject<{
904
+ allowed: z.ZodLiteral<false>;
905
+ reason: z.ZodString;
906
+ code: z.ZodOptional<z.ZodString>;
907
+ quantity: z.ZodOptional<z.ZodNumber>;
908
+ }, z.core.$strip>], "allowed">;
909
+ type EntitlementDecision = z.infer<typeof EntitlementDecision>;
910
+ type AdmitRunInput = {
911
+ accountId: string;
912
+ workspaceId: string;
913
+ action: string;
914
+ quantity: number;
915
+ };
916
+ type EntitlementsPort = {
917
+ admitRun(input: AdmitRunInput): Promise<EntitlementDecision>;
918
+ };
919
+ type GitCredentialsRequest = {
920
+ accountId: string;
921
+ workspaceId: string;
922
+ installationId: number;
923
+ repositoryIds: number[];
924
+ };
925
+ type GitCredentials = {
926
+ token: string;
927
+ workspaceId: string;
928
+ identity?: {
929
+ name: string;
930
+ email: string;
931
+ } | null;
932
+ };
933
+ type SandboxSecretsRequest = {
934
+ accountId: string;
935
+ workspaceId: string;
936
+ environmentId: string;
937
+ };
938
+ type SandboxSecrets = {
939
+ values: Record<string, string>;
940
+ workspaceId: string;
941
+ id?: string;
942
+ name?: string;
943
+ description?: string | null;
944
+ };
945
+ type ConnectionCredentialsPort = {
946
+ gitCredentials?: (input: GitCredentialsRequest) => Promise<GitCredentials>;
947
+ sandboxSecrets?: (input: SandboxSecretsRequest) => Promise<SandboxSecrets>;
948
+ };
949
+ type GitHubInstallationSummary = {
950
+ installationId: number;
951
+ accountLogin: string | null;
952
+ accountType: string | null;
953
+ suspended: boolean;
954
+ };
955
+ type GitHubAppApiPort = {
956
+ verifyInstallationAccessForUser?: (input: {
957
+ code: string;
958
+ installationId: number;
959
+ }) => Promise<GitHubInstallationSummary>;
960
+ listRepositories?: (input: {
961
+ installationIds?: number[];
962
+ }) => Promise<GitHubRepository[]>;
963
+ };
534
964
  declare const BillingBalance: z.ZodObject<{
535
965
  accountId: z.ZodString;
536
966
  balanceMicros: z.ZodNumber;
@@ -725,6 +1155,7 @@ type DocumentSearchRequest = z.infer<typeof DocumentSearchRequest>;
725
1155
  declare const ToolRef: z.ZodObject<{
726
1156
  kind: z.ZodLiteral<"mcp">;
727
1157
  id: z.ZodString;
1158
+ optional: z.ZodOptional<z.ZodBoolean>;
728
1159
  }, z.core.$strip>;
729
1160
  type ToolRef = z.infer<typeof ToolRef>;
730
1161
  declare class ResourceRefConflictError extends Error {
@@ -817,6 +1248,10 @@ declare const UpdateSessionGoalRequest: z.ZodObject<{
817
1248
  rationale: z.ZodOptional<z.ZodString>;
818
1249
  }, z.core.$strip>;
819
1250
  type UpdateSessionGoalRequest = z.infer<typeof UpdateSessionGoalRequest>;
1251
+ declare const UpdateSessionRequest: z.ZodObject<{
1252
+ title: z.ZodString;
1253
+ }, z.core.$strip>;
1254
+ type UpdateSessionRequest = z.infer<typeof UpdateSessionRequest>;
820
1255
  /**
821
1256
  * Clear a session's conversation context. `confirm` must be the literal `true`
822
1257
  * so an accidental/empty POST cannot wipe context — the destructive intent is
@@ -897,6 +1332,7 @@ declare const SessionTurn: z.ZodObject<{
897
1332
  tools: z.ZodArray<z.ZodObject<{
898
1333
  kind: z.ZodLiteral<"mcp">;
899
1334
  id: z.ZodString;
1335
+ optional: z.ZodOptional<z.ZodBoolean>;
900
1336
  }, z.core.$strip>>;
901
1337
  model: z.ZodString;
902
1338
  reasoningEffort: z.ZodEnum<{
@@ -912,7 +1348,19 @@ declare const SessionTurn: z.ZodObject<{
912
1348
  modal: "modal";
913
1349
  local: "local";
914
1350
  none: "none";
1351
+ daytona: "daytona";
1352
+ runloop: "runloop";
1353
+ e2b: "e2b";
1354
+ blaxel: "blaxel";
1355
+ cloudflare: "cloudflare";
1356
+ vercel: "vercel";
1357
+ selfhosted: "selfhosted";
915
1358
  }>;
1359
+ sandboxOs: z.ZodNullable<z.ZodEnum<{
1360
+ linux: "linux";
1361
+ macos: "macos";
1362
+ windows: "windows";
1363
+ }>>;
916
1364
  metadata: z.ZodRecord<z.ZodString, z.ZodUnknown>;
917
1365
  startedAt: z.ZodNullable<z.ZodString>;
918
1366
  finishedAt: z.ZodNullable<z.ZodString>;
@@ -938,6 +1386,7 @@ declare const UpdateSessionTurnRequest: z.ZodObject<{
938
1386
  tools: z.ZodOptional<z.ZodArray<z.ZodObject<{
939
1387
  kind: z.ZodLiteral<"mcp">;
940
1388
  id: z.ZodString;
1389
+ optional: z.ZodOptional<z.ZodBoolean>;
941
1390
  }, z.core.$strip>>>;
942
1391
  model: z.ZodOptional<z.ZodString>;
943
1392
  reasoningEffort: z.ZodOptional<z.ZodEnum<{
@@ -953,6 +1402,13 @@ declare const UpdateSessionTurnRequest: z.ZodObject<{
953
1402
  modal: "modal";
954
1403
  local: "local";
955
1404
  none: "none";
1405
+ daytona: "daytona";
1406
+ runloop: "runloop";
1407
+ e2b: "e2b";
1408
+ blaxel: "blaxel";
1409
+ cloudflare: "cloudflare";
1410
+ vercel: "vercel";
1411
+ selfhosted: "selfhosted";
956
1412
  }>>;
957
1413
  metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
958
1414
  }, z.core.$strip>;
@@ -1074,6 +1530,7 @@ declare const ScheduledTaskAgentConfig: z.ZodObject<{
1074
1530
  tools: z.ZodDefault<z.ZodArray<z.ZodObject<{
1075
1531
  kind: z.ZodLiteral<"mcp">;
1076
1532
  id: z.ZodString;
1533
+ optional: z.ZodOptional<z.ZodBoolean>;
1077
1534
  }, z.core.$strip>>>;
1078
1535
  metadata: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1079
1536
  model: z.ZodOptional<z.ZodString>;
@@ -1090,6 +1547,13 @@ declare const ScheduledTaskAgentConfig: z.ZodObject<{
1090
1547
  modal: "modal";
1091
1548
  local: "local";
1092
1549
  none: "none";
1550
+ daytona: "daytona";
1551
+ runloop: "runloop";
1552
+ e2b: "e2b";
1553
+ blaxel: "blaxel";
1554
+ cloudflare: "cloudflare";
1555
+ vercel: "vercel";
1556
+ selfhosted: "selfhosted";
1093
1557
  }>>;
1094
1558
  goal: z.ZodOptional<z.ZodObject<{
1095
1559
  text: z.ZodString;
@@ -1159,6 +1623,7 @@ declare const ScheduledTask: z.ZodObject<{
1159
1623
  tools: z.ZodDefault<z.ZodArray<z.ZodObject<{
1160
1624
  kind: z.ZodLiteral<"mcp">;
1161
1625
  id: z.ZodString;
1626
+ optional: z.ZodOptional<z.ZodBoolean>;
1162
1627
  }, z.core.$strip>>>;
1163
1628
  metadata: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1164
1629
  model: z.ZodOptional<z.ZodString>;
@@ -1175,6 +1640,13 @@ declare const ScheduledTask: z.ZodObject<{
1175
1640
  modal: "modal";
1176
1641
  local: "local";
1177
1642
  none: "none";
1643
+ daytona: "daytona";
1644
+ runloop: "runloop";
1645
+ e2b: "e2b";
1646
+ blaxel: "blaxel";
1647
+ cloudflare: "cloudflare";
1648
+ vercel: "vercel";
1649
+ selfhosted: "selfhosted";
1178
1650
  }>>;
1179
1651
  goal: z.ZodOptional<z.ZodObject<{
1180
1652
  text: z.ZodString;
@@ -1265,6 +1737,7 @@ declare const CreateScheduledTaskRequest: z.ZodObject<{
1265
1737
  tools: z.ZodDefault<z.ZodArray<z.ZodObject<{
1266
1738
  kind: z.ZodLiteral<"mcp">;
1267
1739
  id: z.ZodString;
1740
+ optional: z.ZodOptional<z.ZodBoolean>;
1268
1741
  }, z.core.$strip>>>;
1269
1742
  metadata: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1270
1743
  model: z.ZodOptional<z.ZodString>;
@@ -1281,6 +1754,13 @@ declare const CreateScheduledTaskRequest: z.ZodObject<{
1281
1754
  modal: "modal";
1282
1755
  local: "local";
1283
1756
  none: "none";
1757
+ daytona: "daytona";
1758
+ runloop: "runloop";
1759
+ e2b: "e2b";
1760
+ blaxel: "blaxel";
1761
+ cloudflare: "cloudflare";
1762
+ vercel: "vercel";
1763
+ selfhosted: "selfhosted";
1284
1764
  }>>;
1285
1765
  goal: z.ZodOptional<z.ZodObject<{
1286
1766
  text: z.ZodString;
@@ -1349,6 +1829,7 @@ declare const UpdateScheduledTaskRequest: z.ZodObject<{
1349
1829
  tools: z.ZodDefault<z.ZodArray<z.ZodObject<{
1350
1830
  kind: z.ZodLiteral<"mcp">;
1351
1831
  id: z.ZodString;
1832
+ optional: z.ZodOptional<z.ZodBoolean>;
1352
1833
  }, z.core.$strip>>>;
1353
1834
  metadata: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1354
1835
  model: z.ZodOptional<z.ZodString>;
@@ -1365,6 +1846,13 @@ declare const UpdateScheduledTaskRequest: z.ZodObject<{
1365
1846
  modal: "modal";
1366
1847
  local: "local";
1367
1848
  none: "none";
1849
+ daytona: "daytona";
1850
+ runloop: "runloop";
1851
+ e2b: "e2b";
1852
+ blaxel: "blaxel";
1853
+ cloudflare: "cloudflare";
1854
+ vercel: "vercel";
1855
+ selfhosted: "selfhosted";
1368
1856
  }>>;
1369
1857
  goal: z.ZodOptional<z.ZodObject<{
1370
1858
  text: z.ZodString;
@@ -1493,6 +1981,7 @@ declare const CapabilityPack: z.ZodObject<{
1493
1981
  tools: z.ZodDefault<z.ZodArray<z.ZodObject<{
1494
1982
  kind: z.ZodLiteral<"mcp">;
1495
1983
  id: z.ZodString;
1984
+ optional: z.ZodOptional<z.ZodBoolean>;
1496
1985
  }, z.core.$strip>>>;
1497
1986
  connectors: z.ZodDefault<z.ZodArray<z.ZodObject<{
1498
1987
  id: z.ZodString;
@@ -1582,6 +2071,7 @@ declare const RegisterCapabilityPackRequest: z.ZodObject<{
1582
2071
  tools: z.ZodDefault<z.ZodArray<z.ZodObject<{
1583
2072
  kind: z.ZodLiteral<"mcp">;
1584
2073
  id: z.ZodString;
2074
+ optional: z.ZodOptional<z.ZodBoolean>;
1585
2075
  }, z.core.$strip>>>;
1586
2076
  connectors: z.ZodDefault<z.ZodArray<z.ZodObject<{
1587
2077
  id: z.ZodString;
@@ -1674,6 +2164,7 @@ declare const WorkspaceRegisteredPack: z.ZodObject<{
1674
2164
  tools: z.ZodDefault<z.ZodArray<z.ZodObject<{
1675
2165
  kind: z.ZodLiteral<"mcp">;
1676
2166
  id: z.ZodString;
2167
+ optional: z.ZodOptional<z.ZodBoolean>;
1677
2168
  }, z.core.$strip>>>;
1678
2169
  connectors: z.ZodDefault<z.ZodArray<z.ZodObject<{
1679
2170
  id: z.ZodString;
@@ -1953,6 +2444,7 @@ declare const CapabilityCatalogItem: z.ZodObject<{
1953
2444
  tools: z.ZodDefault<z.ZodArray<z.ZodObject<{
1954
2445
  kind: z.ZodLiteral<"mcp">;
1955
2446
  id: z.ZodString;
2447
+ optional: z.ZodOptional<z.ZodBoolean>;
1956
2448
  }, z.core.$strip>>>;
1957
2449
  runtime: z.ZodDefault<z.ZodObject<{
1958
2450
  available: z.ZodDefault<z.ZodBoolean>;
@@ -2050,6 +2542,7 @@ declare const CapabilityCatalogResponse: z.ZodObject<{
2050
2542
  tools: z.ZodDefault<z.ZodArray<z.ZodObject<{
2051
2543
  kind: z.ZodLiteral<"mcp">;
2052
2544
  id: z.ZodString;
2545
+ optional: z.ZodOptional<z.ZodBoolean>;
2053
2546
  }, z.core.$strip>>>;
2054
2547
  runtime: z.ZodDefault<z.ZodObject<{
2055
2548
  available: z.ZodDefault<z.ZodBoolean>;
@@ -2115,6 +2608,7 @@ declare const DiscoverMcpCapabilitiesResponse: z.ZodObject<{
2115
2608
  tools: z.ZodDefault<z.ZodArray<z.ZodObject<{
2116
2609
  kind: z.ZodLiteral<"mcp">;
2117
2610
  id: z.ZodString;
2611
+ optional: z.ZodOptional<z.ZodBoolean>;
2118
2612
  }, z.core.$strip>>>;
2119
2613
  runtime: z.ZodDefault<z.ZodObject<{
2120
2614
  available: z.ZodDefault<z.ZodBoolean>;
@@ -2145,6 +2639,11 @@ declare const Session: z.ZodObject<{
2145
2639
  cancelled: "cancelled";
2146
2640
  }>;
2147
2641
  initialMessage: z.ZodString;
2642
+ title: z.ZodNullable<z.ZodString>;
2643
+ titleSource: z.ZodNullable<z.ZodEnum<{
2644
+ user: "user";
2645
+ agent: "agent";
2646
+ }>>;
2148
2647
  resources: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
2149
2648
  kind: z.ZodLiteral<"repository">;
2150
2649
  uri: z.ZodString;
@@ -2161,6 +2660,7 @@ declare const Session: z.ZodObject<{
2161
2660
  tools: z.ZodArray<z.ZodObject<{
2162
2661
  kind: z.ZodLiteral<"mcp">;
2163
2662
  id: z.ZodString;
2663
+ optional: z.ZodOptional<z.ZodBoolean>;
2164
2664
  }, z.core.$strip>>;
2165
2665
  metadata: z.ZodRecord<z.ZodString, z.ZodUnknown>;
2166
2666
  model: z.ZodString;
@@ -2169,7 +2669,22 @@ declare const Session: z.ZodObject<{
2169
2669
  modal: "modal";
2170
2670
  local: "local";
2171
2671
  none: "none";
2672
+ daytona: "daytona";
2673
+ runloop: "runloop";
2674
+ e2b: "e2b";
2675
+ blaxel: "blaxel";
2676
+ cloudflare: "cloudflare";
2677
+ vercel: "vercel";
2678
+ selfhosted: "selfhosted";
2172
2679
  }>;
2680
+ sandboxOs: z.ZodEnum<{
2681
+ linux: "linux";
2682
+ macos: "macos";
2683
+ windows: "windows";
2684
+ }>;
2685
+ sandboxGroupId: z.ZodString;
2686
+ activeSandboxId: z.ZodNullable<z.ZodString>;
2687
+ activeEpoch: z.ZodNumber;
2173
2688
  environmentId: z.ZodNullable<z.ZodString>;
2174
2689
  firstPartyMcpPermissions: z.ZodNullable<z.ZodArray<z.ZodEnum<{
2175
2690
  "account:read": "account:read";
@@ -2183,8 +2698,13 @@ declare const Session: z.ZodObject<{
2183
2698
  "sessions:create": "sessions:create";
2184
2699
  "sessions:read": "sessions:read";
2185
2700
  "sessions:control": "sessions:control";
2701
+ "stream:view": "stream:view";
2702
+ "stream:control": "stream:control";
2703
+ "stream:acknowledge": "stream:acknowledge";
2186
2704
  "files:upload": "files:upload";
2187
2705
  "files:read": "files:read";
2706
+ "files:write": "files:write";
2707
+ "terminal:attach": "terminal:attach";
2188
2708
  "documents:manage": "documents:manage";
2189
2709
  "documents:search": "documents:search";
2190
2710
  "scheduled_tasks:manage": "scheduled_tasks:manage";
@@ -2195,6 +2715,8 @@ declare const Session: z.ZodObject<{
2195
2715
  "environments:manage": "environments:manage";
2196
2716
  "environments:use": "environments:use";
2197
2717
  "goals:manage": "goals:manage";
2718
+ "enrollments:read": "enrollments:read";
2719
+ "enrollments:manage": "enrollments:manage";
2198
2720
  }>>>;
2199
2721
  parentSessionId: z.ZodNullable<z.ZodString>;
2200
2722
  createIdempotencyKey: z.ZodNullable<z.ZodString>;
@@ -2202,6 +2724,8 @@ declare const Session: z.ZodObject<{
2202
2724
  activeTurnId: z.ZodNullable<z.ZodString>;
2203
2725
  lastInputTokens: z.ZodNullable<z.ZodNumber>;
2204
2726
  lastSequence: z.ZodNumber;
2727
+ codexPinnedCredentialId: z.ZodNullable<z.ZodString>;
2728
+ codexLastCredentialId: z.ZodNullable<z.ZodString>;
2205
2729
  createdAt: z.ZodString;
2206
2730
  updatedAt: z.ZodString;
2207
2731
  }, z.core.$strip>;
@@ -2239,8 +2763,725 @@ declare const SessionEventType: z.ZodEnum<{
2239
2763
  "goal.paused": "goal.paused";
2240
2764
  "goal.resumed": "goal.resumed";
2241
2765
  "goal.continuation": "goal.continuation";
2766
+ "stream.url.rotated": "stream.url.rotated";
2767
+ "stream.opened": "stream.opened";
2768
+ "stream.closed": "stream.closed";
2769
+ "stream.revoked": "stream.revoked";
2770
+ "recording.started": "recording.started";
2771
+ "recording.available": "recording.available";
2772
+ "recording.failed": "recording.failed";
2773
+ "fs.changed": "fs.changed";
2774
+ "git.changed": "git.changed";
2775
+ "terminal.pty.started": "terminal.pty.started";
2776
+ "terminal.pty.output.delta": "terminal.pty.output.delta";
2777
+ "terminal.pty.exited": "terminal.pty.exited";
2778
+ "session.title_set": "session.title_set";
2779
+ "codex.account.switched": "codex.account.switched";
2242
2780
  }>;
2243
2781
  type SessionEventType = z.infer<typeof SessionEventType>;
2782
+ declare const StreamUrlRotatedPayload: z.ZodObject<{
2783
+ url: z.ZodString;
2784
+ token: z.ZodNullable<z.ZodString>;
2785
+ expiresAt: z.ZodNullable<z.ZodString>;
2786
+ leaseEpoch: z.ZodNumber;
2787
+ transport: z.ZodLiteral<"vnc-ws">;
2788
+ viewerId: z.ZodDefault<z.ZodNullable<z.ZodString>>;
2789
+ }, z.core.$strip>;
2790
+ type StreamUrlRotatedPayload = z.infer<typeof StreamUrlRotatedPayload>;
2791
+ declare const StreamOpenedPayload: z.ZodObject<{
2792
+ viewerId: z.ZodString;
2793
+ shared: z.ZodDefault<z.ZodBoolean>;
2794
+ viewerCount: z.ZodNumber;
2795
+ }, z.core.$strip>;
2796
+ type StreamOpenedPayload = z.infer<typeof StreamOpenedPayload>;
2797
+ declare const StreamClosedPayload: z.ZodObject<{
2798
+ viewerId: z.ZodString;
2799
+ reason: z.ZodEnum<{
2800
+ "client-disconnect": "client-disconnect";
2801
+ reaped: "reaped";
2802
+ revoked: "revoked";
2803
+ "box-rollover": "box-rollover";
2804
+ }>;
2805
+ viewerCount: z.ZodNumber;
2806
+ }, z.core.$strip>;
2807
+ type StreamClosedPayload = z.infer<typeof StreamClosedPayload>;
2808
+ declare const StreamRevokedPayload: z.ZodObject<{
2809
+ viewerId: z.ZodDefault<z.ZodNullable<z.ZodString>>;
2810
+ reason: z.ZodEnum<{
2811
+ admin: "admin";
2812
+ "grant-revoked": "grant-revoked";
2813
+ "session-failed": "session-failed";
2814
+ }>;
2815
+ }, z.core.$strip>;
2816
+ type StreamRevokedPayload = z.infer<typeof StreamRevokedPayload>;
2817
+ declare const RecordingMode: z.ZodEnum<{
2818
+ manual: "manual";
2819
+ "on-turn": "on-turn";
2820
+ "on-verify": "on-verify";
2821
+ }>;
2822
+ type RecordingMode = z.infer<typeof RecordingMode>;
2823
+ declare const RecordingCodec: z.ZodEnum<{
2824
+ "h264-mp4": "h264-mp4";
2825
+ "vp9-webm": "vp9-webm";
2826
+ }>;
2827
+ type RecordingCodec = z.infer<typeof RecordingCodec>;
2828
+ declare const RecordingContentType: z.ZodEnum<{
2829
+ "video/mp4": "video/mp4";
2830
+ "video/webm": "video/webm";
2831
+ }>;
2832
+ type RecordingContentType = z.infer<typeof RecordingContentType>;
2833
+ declare const RecordingStartedPayload: z.ZodObject<{
2834
+ recordingId: z.ZodString;
2835
+ turnId: z.ZodNullable<z.ZodString>;
2836
+ mode: z.ZodEnum<{
2837
+ manual: "manual";
2838
+ "on-turn": "on-turn";
2839
+ "on-verify": "on-verify";
2840
+ }>;
2841
+ codec: z.ZodEnum<{
2842
+ "h264-mp4": "h264-mp4";
2843
+ "vp9-webm": "vp9-webm";
2844
+ }>;
2845
+ dimensions: z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>;
2846
+ framerate: z.ZodNumber;
2847
+ startedAt: z.ZodString;
2848
+ reason: z.ZodOptional<z.ZodNullable<z.ZodString>>;
2849
+ }, z.core.$strip>;
2850
+ type RecordingStartedPayload = z.infer<typeof RecordingStartedPayload>;
2851
+ declare const RecordingAvailablePayload: z.ZodObject<{
2852
+ recordingId: z.ZodString;
2853
+ turnId: z.ZodNullable<z.ZodString>;
2854
+ codec: z.ZodEnum<{
2855
+ "h264-mp4": "h264-mp4";
2856
+ "vp9-webm": "vp9-webm";
2857
+ }>;
2858
+ contentType: z.ZodEnum<{
2859
+ "video/mp4": "video/mp4";
2860
+ "video/webm": "video/webm";
2861
+ }>;
2862
+ storageKey: z.ZodString;
2863
+ durationSeconds: z.ZodNullable<z.ZodNumber>;
2864
+ sizeBytes: z.ZodNumber;
2865
+ dimensions: z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>;
2866
+ }, z.core.$strip>;
2867
+ type RecordingAvailablePayload = z.infer<typeof RecordingAvailablePayload>;
2868
+ declare const RecordingFailedReason: z.ZodEnum<{
2869
+ "box-rollover": "box-rollover";
2870
+ "ffmpeg-error": "ffmpeg-error";
2871
+ "box-death": "box-death";
2872
+ "upload-failed": "upload-failed";
2873
+ "max-bytes-exceeded": "max-bytes-exceeded";
2874
+ "display-unavailable": "display-unavailable";
2875
+ }>;
2876
+ type RecordingFailedReason = z.infer<typeof RecordingFailedReason>;
2877
+ declare const RecordingFailedPayload: z.ZodObject<{
2878
+ recordingId: z.ZodString;
2879
+ turnId: z.ZodNullable<z.ZodString>;
2880
+ reason: z.ZodEnum<{
2881
+ "box-rollover": "box-rollover";
2882
+ "ffmpeg-error": "ffmpeg-error";
2883
+ "box-death": "box-death";
2884
+ "upload-failed": "upload-failed";
2885
+ "max-bytes-exceeded": "max-bytes-exceeded";
2886
+ "display-unavailable": "display-unavailable";
2887
+ }>;
2888
+ detail: z.ZodOptional<z.ZodNullable<z.ZodString>>;
2889
+ }, z.core.$strip>;
2890
+ type RecordingFailedPayload = z.infer<typeof RecordingFailedPayload>;
2891
+ declare const SandboxCommandOutputDeltaPayload: z.ZodObject<{
2892
+ stream: z.ZodDefault<z.ZodEnum<{
2893
+ stdout: "stdout";
2894
+ stderr: "stderr";
2895
+ }>>;
2896
+ chunk: z.ZodString;
2897
+ commandId: z.ZodOptional<z.ZodString>;
2898
+ seq: z.ZodOptional<z.ZodNumber>;
2899
+ }, z.core.$strip>;
2900
+ type SandboxCommandOutputDeltaPayload = z.infer<typeof SandboxCommandOutputDeltaPayload>;
2901
+ declare const FsChangeKind: z.ZodEnum<{
2902
+ deleted: "deleted";
2903
+ created: "created";
2904
+ modified: "modified";
2905
+ renamed: "renamed";
2906
+ }>;
2907
+ type FsChangeKind = z.infer<typeof FsChangeKind>;
2908
+ declare const FsChangedPayload: z.ZodObject<{
2909
+ changes: z.ZodArray<z.ZodObject<{
2910
+ path: z.ZodString;
2911
+ kind: z.ZodEnum<{
2912
+ deleted: "deleted";
2913
+ created: "created";
2914
+ modified: "modified";
2915
+ renamed: "renamed";
2916
+ }>;
2917
+ isDir: z.ZodDefault<z.ZodBoolean>;
2918
+ sizeBytes: z.ZodDefault<z.ZodNullable<z.ZodNumber>>;
2919
+ oldPath: z.ZodOptional<z.ZodString>;
2920
+ }, z.core.$strip>>;
2921
+ source: z.ZodDefault<z.ZodEnum<{
2922
+ agent: "agent";
2923
+ write: "write";
2924
+ watch: "watch";
2925
+ }>>;
2926
+ revision: z.ZodNumber;
2927
+ leaseEpoch: z.ZodDefault<z.ZodNumber>;
2928
+ }, z.core.$strip>;
2929
+ type FsChangedPayload = z.infer<typeof FsChangedPayload>;
2930
+ declare const GitChangedPayload: z.ZodObject<{
2931
+ head: z.ZodNullable<z.ZodString>;
2932
+ dirty: z.ZodBoolean;
2933
+ ahead: z.ZodDefault<z.ZodNumber>;
2934
+ behind: z.ZodDefault<z.ZodNumber>;
2935
+ changedFileCount: z.ZodNumber;
2936
+ reason: z.ZodDefault<z.ZodEnum<{
2937
+ unknown: "unknown";
2938
+ commit: "commit";
2939
+ checkout: "checkout";
2940
+ stage: "stage";
2941
+ worktree: "worktree";
2942
+ fetch: "fetch";
2943
+ }>>;
2944
+ revision: z.ZodDefault<z.ZodNumber>;
2945
+ leaseEpoch: z.ZodDefault<z.ZodNumber>;
2946
+ }, z.core.$strip>;
2947
+ type GitChangedPayload = z.infer<typeof GitChangedPayload>;
2948
+ declare const TerminalPtyStartedPayload: z.ZodObject<{
2949
+ ptyId: z.ZodString;
2950
+ cols: z.ZodNumber;
2951
+ rows: z.ZodNumber;
2952
+ shell: z.ZodString;
2953
+ cwd: z.ZodString;
2954
+ }, z.core.$strip>;
2955
+ type TerminalPtyStartedPayload = z.infer<typeof TerminalPtyStartedPayload>;
2956
+ declare const TerminalPtyOutputDeltaPayload: z.ZodObject<{
2957
+ ptyId: z.ZodString;
2958
+ stream: z.ZodDefault<z.ZodEnum<{
2959
+ stdout: "stdout";
2960
+ stderr: "stderr";
2961
+ }>>;
2962
+ chunk: z.ZodString;
2963
+ seq: z.ZodNumber;
2964
+ }, z.core.$strip>;
2965
+ type TerminalPtyOutputDeltaPayload = z.infer<typeof TerminalPtyOutputDeltaPayload>;
2966
+ declare const TerminalPtyExitedPayload: z.ZodObject<{
2967
+ ptyId: z.ZodString;
2968
+ exitCode: z.ZodNullable<z.ZodNumber>;
2969
+ reason: z.ZodEnum<{
2970
+ exit: "exit";
2971
+ killed: "killed";
2972
+ owner_gone: "owner_gone";
2973
+ timeout: "timeout";
2974
+ }>;
2975
+ }, z.core.$strip>;
2976
+ type TerminalPtyExitedPayload = z.infer<typeof TerminalPtyExitedPayload>;
2977
+ declare const FsNodeType: z.ZodEnum<{
2978
+ file: "file";
2979
+ dir: "dir";
2980
+ symlink: "symlink";
2981
+ other: "other";
2982
+ }>;
2983
+ type FsNodeType = z.infer<typeof FsNodeType>;
2984
+ interface FsTreeNode {
2985
+ name: string;
2986
+ path: string;
2987
+ type: z.infer<typeof FsNodeType>;
2988
+ sizeBytes: number | null;
2989
+ mtimeMs: number | null;
2990
+ mode: number | null;
2991
+ children?: FsTreeNode[] | undefined;
2992
+ truncated: boolean;
2993
+ }
2994
+ declare const FsTreeNode: z.ZodType<FsTreeNode>;
2995
+ declare const FsListRequest: z.ZodObject<{
2996
+ path: z.ZodDefault<z.ZodString>;
2997
+ depth: z.ZodDefault<z.ZodNumber>;
2998
+ maxEntries: z.ZodDefault<z.ZodNumber>;
2999
+ includeHidden: z.ZodDefault<z.ZodBoolean>;
3000
+ }, z.core.$strip>;
3001
+ type FsListRequest = z.infer<typeof FsListRequest>;
3002
+ declare const FsListResponse: z.ZodObject<{
3003
+ root: z.ZodType<FsTreeNode, unknown, z.core.$ZodTypeInternals<FsTreeNode, unknown>>;
3004
+ revision: z.ZodNumber;
3005
+ truncated: z.ZodBoolean;
3006
+ }, z.core.$strip>;
3007
+ type FsListResponse = z.infer<typeof FsListResponse>;
3008
+ declare const FsEncoding: z.ZodEnum<{
3009
+ utf8: "utf8";
3010
+ base64: "base64";
3011
+ }>;
3012
+ type FsEncoding = z.infer<typeof FsEncoding>;
3013
+ declare const FsReadRequest: z.ZodObject<{
3014
+ path: z.ZodString;
3015
+ encoding: z.ZodDefault<z.ZodEnum<{
3016
+ utf8: "utf8";
3017
+ base64: "base64";
3018
+ }>>;
3019
+ maxBytes: z.ZodDefault<z.ZodNumber>;
3020
+ }, z.core.$strip>;
3021
+ type FsReadRequest = z.infer<typeof FsReadRequest>;
3022
+ declare const FsReadResponse: z.ZodObject<{
3023
+ path: z.ZodString;
3024
+ encoding: z.ZodEnum<{
3025
+ utf8: "utf8";
3026
+ base64: "base64";
3027
+ }>;
3028
+ content: z.ZodString;
3029
+ sizeBytes: z.ZodNumber;
3030
+ truncated: z.ZodBoolean;
3031
+ isBinary: z.ZodBoolean;
3032
+ revision: z.ZodNumber;
3033
+ }, z.core.$strip>;
3034
+ type FsReadResponse = z.infer<typeof FsReadResponse>;
3035
+ declare const FsWriteRequest: z.ZodObject<{
3036
+ path: z.ZodString;
3037
+ encoding: z.ZodDefault<z.ZodEnum<{
3038
+ utf8: "utf8";
3039
+ base64: "base64";
3040
+ }>>;
3041
+ content: z.ZodString;
3042
+ overwrite: z.ZodDefault<z.ZodBoolean>;
3043
+ createParents: z.ZodDefault<z.ZodBoolean>;
3044
+ }, z.core.$strip>;
3045
+ type FsWriteRequest = z.infer<typeof FsWriteRequest>;
3046
+ declare const FsWriteResponse: z.ZodObject<{
3047
+ path: z.ZodString;
3048
+ sizeBytes: z.ZodNumber;
3049
+ revision: z.ZodNumber;
3050
+ }, z.core.$strip>;
3051
+ type FsWriteResponse = z.infer<typeof FsWriteResponse>;
3052
+ declare const FsDeleteRequest: z.ZodObject<{
3053
+ path: z.ZodString;
3054
+ recursive: z.ZodDefault<z.ZodBoolean>;
3055
+ }, z.core.$strip>;
3056
+ type FsDeleteRequest = z.infer<typeof FsDeleteRequest>;
3057
+ declare const FsDeleteResponse: z.ZodObject<{
3058
+ revision: z.ZodNumber;
3059
+ }, z.core.$strip>;
3060
+ type FsDeleteResponse = z.infer<typeof FsDeleteResponse>;
3061
+ declare const FsMoveRequest: z.ZodObject<{
3062
+ path: z.ZodString;
3063
+ newPath: z.ZodString;
3064
+ overwrite: z.ZodDefault<z.ZodBoolean>;
3065
+ createParents: z.ZodDefault<z.ZodBoolean>;
3066
+ }, z.core.$strip>;
3067
+ type FsMoveRequest = z.infer<typeof FsMoveRequest>;
3068
+ declare const FsMoveResponse: z.ZodObject<{
3069
+ path: z.ZodString;
3070
+ newPath: z.ZodString;
3071
+ revision: z.ZodNumber;
3072
+ }, z.core.$strip>;
3073
+ type FsMoveResponse = z.infer<typeof FsMoveResponse>;
3074
+ declare const FsMkdirRequest: z.ZodObject<{
3075
+ path: z.ZodString;
3076
+ recursive: z.ZodDefault<z.ZodBoolean>;
3077
+ }, z.core.$strip>;
3078
+ type FsMkdirRequest = z.infer<typeof FsMkdirRequest>;
3079
+ declare const FsMkdirResponse: z.ZodObject<{
3080
+ path: z.ZodString;
3081
+ revision: z.ZodNumber;
3082
+ }, z.core.$strip>;
3083
+ type FsMkdirResponse = z.infer<typeof FsMkdirResponse>;
3084
+ declare const GitFileStatusCode: z.ZodEnum<{
3085
+ deleted: "deleted";
3086
+ modified: "modified";
3087
+ renamed: "renamed";
3088
+ added: "added";
3089
+ copied: "copied";
3090
+ untracked: "untracked";
3091
+ ignored: "ignored";
3092
+ conflicted: "conflicted";
3093
+ typechange: "typechange";
3094
+ }>;
3095
+ type GitFileStatusCode = z.infer<typeof GitFileStatusCode>;
3096
+ declare const GitFileStatus: z.ZodObject<{
3097
+ path: z.ZodString;
3098
+ oldPath: z.ZodNullable<z.ZodString>;
3099
+ index: z.ZodNullable<z.ZodEnum<{
3100
+ deleted: "deleted";
3101
+ modified: "modified";
3102
+ renamed: "renamed";
3103
+ added: "added";
3104
+ copied: "copied";
3105
+ untracked: "untracked";
3106
+ ignored: "ignored";
3107
+ conflicted: "conflicted";
3108
+ typechange: "typechange";
3109
+ }>>;
3110
+ worktree: z.ZodNullable<z.ZodEnum<{
3111
+ deleted: "deleted";
3112
+ modified: "modified";
3113
+ renamed: "renamed";
3114
+ added: "added";
3115
+ copied: "copied";
3116
+ untracked: "untracked";
3117
+ ignored: "ignored";
3118
+ conflicted: "conflicted";
3119
+ typechange: "typechange";
3120
+ }>>;
3121
+ isConflicted: z.ZodDefault<z.ZodBoolean>;
3122
+ }, z.core.$strip>;
3123
+ type GitFileStatus = z.infer<typeof GitFileStatus>;
3124
+ declare const GitStatusRequest: z.ZodObject<{
3125
+ path: z.ZodDefault<z.ZodString>;
3126
+ }, z.core.$strip>;
3127
+ type GitStatusRequest = z.infer<typeof GitStatusRequest>;
3128
+ declare const GitStatusResponse: z.ZodObject<{
3129
+ isRepo: z.ZodBoolean;
3130
+ head: z.ZodNullable<z.ZodString>;
3131
+ detached: z.ZodDefault<z.ZodBoolean>;
3132
+ upstream: z.ZodNullable<z.ZodString>;
3133
+ ahead: z.ZodDefault<z.ZodNumber>;
3134
+ behind: z.ZodDefault<z.ZodNumber>;
3135
+ files: z.ZodArray<z.ZodObject<{
3136
+ path: z.ZodString;
3137
+ oldPath: z.ZodNullable<z.ZodString>;
3138
+ index: z.ZodNullable<z.ZodEnum<{
3139
+ deleted: "deleted";
3140
+ modified: "modified";
3141
+ renamed: "renamed";
3142
+ added: "added";
3143
+ copied: "copied";
3144
+ untracked: "untracked";
3145
+ ignored: "ignored";
3146
+ conflicted: "conflicted";
3147
+ typechange: "typechange";
3148
+ }>>;
3149
+ worktree: z.ZodNullable<z.ZodEnum<{
3150
+ deleted: "deleted";
3151
+ modified: "modified";
3152
+ renamed: "renamed";
3153
+ added: "added";
3154
+ copied: "copied";
3155
+ untracked: "untracked";
3156
+ ignored: "ignored";
3157
+ conflicted: "conflicted";
3158
+ typechange: "typechange";
3159
+ }>>;
3160
+ isConflicted: z.ZodDefault<z.ZodBoolean>;
3161
+ }, z.core.$strip>>;
3162
+ revision: z.ZodNumber;
3163
+ }, z.core.$strip>;
3164
+ type GitStatusResponse = z.infer<typeof GitStatusResponse>;
3165
+ declare const GitDiffLineType: z.ZodEnum<{
3166
+ context: "context";
3167
+ add: "add";
3168
+ del: "del";
3169
+ meta: "meta";
3170
+ }>;
3171
+ type GitDiffLineType = z.infer<typeof GitDiffLineType>;
3172
+ declare const GitDiffLine: z.ZodObject<{
3173
+ type: z.ZodEnum<{
3174
+ context: "context";
3175
+ add: "add";
3176
+ del: "del";
3177
+ meta: "meta";
3178
+ }>;
3179
+ oldNo: z.ZodNullable<z.ZodNumber>;
3180
+ newNo: z.ZodNullable<z.ZodNumber>;
3181
+ text: z.ZodString;
3182
+ }, z.core.$strip>;
3183
+ type GitDiffLine = z.infer<typeof GitDiffLine>;
3184
+ declare const GitDiffHunk: z.ZodObject<{
3185
+ oldStart: z.ZodNumber;
3186
+ oldLines: z.ZodNumber;
3187
+ newStart: z.ZodNumber;
3188
+ newLines: z.ZodNumber;
3189
+ header: z.ZodString;
3190
+ lines: z.ZodArray<z.ZodObject<{
3191
+ type: z.ZodEnum<{
3192
+ context: "context";
3193
+ add: "add";
3194
+ del: "del";
3195
+ meta: "meta";
3196
+ }>;
3197
+ oldNo: z.ZodNullable<z.ZodNumber>;
3198
+ newNo: z.ZodNullable<z.ZodNumber>;
3199
+ text: z.ZodString;
3200
+ }, z.core.$strip>>;
3201
+ }, z.core.$strip>;
3202
+ type GitDiffHunk = z.infer<typeof GitDiffHunk>;
3203
+ declare const GitFileDiff: z.ZodObject<{
3204
+ path: z.ZodString;
3205
+ oldPath: z.ZodNullable<z.ZodString>;
3206
+ status: z.ZodEnum<{
3207
+ deleted: "deleted";
3208
+ modified: "modified";
3209
+ renamed: "renamed";
3210
+ added: "added";
3211
+ copied: "copied";
3212
+ untracked: "untracked";
3213
+ ignored: "ignored";
3214
+ conflicted: "conflicted";
3215
+ typechange: "typechange";
3216
+ }>;
3217
+ isBinary: z.ZodDefault<z.ZodBoolean>;
3218
+ isImage: z.ZodDefault<z.ZodBoolean>;
3219
+ additions: z.ZodNumber;
3220
+ deletions: z.ZodNumber;
3221
+ hunks: z.ZodArray<z.ZodObject<{
3222
+ oldStart: z.ZodNumber;
3223
+ oldLines: z.ZodNumber;
3224
+ newStart: z.ZodNumber;
3225
+ newLines: z.ZodNumber;
3226
+ header: z.ZodString;
3227
+ lines: z.ZodArray<z.ZodObject<{
3228
+ type: z.ZodEnum<{
3229
+ context: "context";
3230
+ add: "add";
3231
+ del: "del";
3232
+ meta: "meta";
3233
+ }>;
3234
+ oldNo: z.ZodNullable<z.ZodNumber>;
3235
+ newNo: z.ZodNullable<z.ZodNumber>;
3236
+ text: z.ZodString;
3237
+ }, z.core.$strip>>;
3238
+ }, z.core.$strip>>;
3239
+ truncated: z.ZodDefault<z.ZodBoolean>;
3240
+ }, z.core.$strip>;
3241
+ type GitFileDiff = z.infer<typeof GitFileDiff>;
3242
+ declare const GitDiffRequest: z.ZodObject<{
3243
+ path: z.ZodDefault<z.ZodString>;
3244
+ staged: z.ZodDefault<z.ZodBoolean>;
3245
+ fromRef: z.ZodOptional<z.ZodString>;
3246
+ toRef: z.ZodOptional<z.ZodString>;
3247
+ pathspec: z.ZodDefault<z.ZodArray<z.ZodString>>;
3248
+ contextLines: z.ZodDefault<z.ZodNumber>;
3249
+ maxBytesPerFile: z.ZodDefault<z.ZodNumber>;
3250
+ }, z.core.$strip>;
3251
+ type GitDiffRequest = z.infer<typeof GitDiffRequest>;
3252
+ declare const GitDiffResponse: z.ZodObject<{
3253
+ files: z.ZodArray<z.ZodObject<{
3254
+ path: z.ZodString;
3255
+ oldPath: z.ZodNullable<z.ZodString>;
3256
+ status: z.ZodEnum<{
3257
+ deleted: "deleted";
3258
+ modified: "modified";
3259
+ renamed: "renamed";
3260
+ added: "added";
3261
+ copied: "copied";
3262
+ untracked: "untracked";
3263
+ ignored: "ignored";
3264
+ conflicted: "conflicted";
3265
+ typechange: "typechange";
3266
+ }>;
3267
+ isBinary: z.ZodDefault<z.ZodBoolean>;
3268
+ isImage: z.ZodDefault<z.ZodBoolean>;
3269
+ additions: z.ZodNumber;
3270
+ deletions: z.ZodNumber;
3271
+ hunks: z.ZodArray<z.ZodObject<{
3272
+ oldStart: z.ZodNumber;
3273
+ oldLines: z.ZodNumber;
3274
+ newStart: z.ZodNumber;
3275
+ newLines: z.ZodNumber;
3276
+ header: z.ZodString;
3277
+ lines: z.ZodArray<z.ZodObject<{
3278
+ type: z.ZodEnum<{
3279
+ context: "context";
3280
+ add: "add";
3281
+ del: "del";
3282
+ meta: "meta";
3283
+ }>;
3284
+ oldNo: z.ZodNullable<z.ZodNumber>;
3285
+ newNo: z.ZodNullable<z.ZodNumber>;
3286
+ text: z.ZodString;
3287
+ }, z.core.$strip>>;
3288
+ }, z.core.$strip>>;
3289
+ truncated: z.ZodDefault<z.ZodBoolean>;
3290
+ }, z.core.$strip>>;
3291
+ revision: z.ZodNumber;
3292
+ }, z.core.$strip>;
3293
+ type GitDiffResponse = z.infer<typeof GitDiffResponse>;
3294
+ declare const GitLogRequest: z.ZodObject<{
3295
+ path: z.ZodDefault<z.ZodString>;
3296
+ ref: z.ZodDefault<z.ZodString>;
3297
+ maxCount: z.ZodDefault<z.ZodNumber>;
3298
+ skip: z.ZodDefault<z.ZodNumber>;
3299
+ pathspec: z.ZodDefault<z.ZodArray<z.ZodString>>;
3300
+ }, z.core.$strip>;
3301
+ type GitLogRequest = z.infer<typeof GitLogRequest>;
3302
+ declare const GitCommit: z.ZodObject<{
3303
+ sha: z.ZodString;
3304
+ shortSha: z.ZodString;
3305
+ parents: z.ZodArray<z.ZodString>;
3306
+ author: z.ZodObject<{
3307
+ name: z.ZodString;
3308
+ email: z.ZodString;
3309
+ timestamp: z.ZodNumber;
3310
+ }, z.core.$strip>;
3311
+ committer: z.ZodObject<{
3312
+ name: z.ZodString;
3313
+ email: z.ZodString;
3314
+ timestamp: z.ZodNumber;
3315
+ }, z.core.$strip>;
3316
+ subject: z.ZodString;
3317
+ body: z.ZodString;
3318
+ refs: z.ZodDefault<z.ZodArray<z.ZodString>>;
3319
+ }, z.core.$strip>;
3320
+ type GitCommit = z.infer<typeof GitCommit>;
3321
+ declare const GitLogResponse: z.ZodObject<{
3322
+ commits: z.ZodArray<z.ZodObject<{
3323
+ sha: z.ZodString;
3324
+ shortSha: z.ZodString;
3325
+ parents: z.ZodArray<z.ZodString>;
3326
+ author: z.ZodObject<{
3327
+ name: z.ZodString;
3328
+ email: z.ZodString;
3329
+ timestamp: z.ZodNumber;
3330
+ }, z.core.$strip>;
3331
+ committer: z.ZodObject<{
3332
+ name: z.ZodString;
3333
+ email: z.ZodString;
3334
+ timestamp: z.ZodNumber;
3335
+ }, z.core.$strip>;
3336
+ subject: z.ZodString;
3337
+ body: z.ZodString;
3338
+ refs: z.ZodDefault<z.ZodArray<z.ZodString>>;
3339
+ }, z.core.$strip>>;
3340
+ hasMore: z.ZodBoolean;
3341
+ }, z.core.$strip>;
3342
+ type GitLogResponse = z.infer<typeof GitLogResponse>;
3343
+ declare const GitShowRequest: z.ZodObject<{
3344
+ path: z.ZodDefault<z.ZodString>;
3345
+ ref: z.ZodString;
3346
+ filePath: z.ZodOptional<z.ZodString>;
3347
+ encoding: z.ZodDefault<z.ZodEnum<{
3348
+ utf8: "utf8";
3349
+ base64: "base64";
3350
+ }>>;
3351
+ maxBytesPerFile: z.ZodDefault<z.ZodNumber>;
3352
+ }, z.core.$strip>;
3353
+ type GitShowRequest = z.infer<typeof GitShowRequest>;
3354
+ declare const GitShowResponse: z.ZodObject<{
3355
+ commit: z.ZodNullable<z.ZodObject<{
3356
+ sha: z.ZodString;
3357
+ shortSha: z.ZodString;
3358
+ parents: z.ZodArray<z.ZodString>;
3359
+ author: z.ZodObject<{
3360
+ name: z.ZodString;
3361
+ email: z.ZodString;
3362
+ timestamp: z.ZodNumber;
3363
+ }, z.core.$strip>;
3364
+ committer: z.ZodObject<{
3365
+ name: z.ZodString;
3366
+ email: z.ZodString;
3367
+ timestamp: z.ZodNumber;
3368
+ }, z.core.$strip>;
3369
+ subject: z.ZodString;
3370
+ body: z.ZodString;
3371
+ refs: z.ZodDefault<z.ZodArray<z.ZodString>>;
3372
+ }, z.core.$strip>>;
3373
+ files: z.ZodArray<z.ZodObject<{
3374
+ path: z.ZodString;
3375
+ oldPath: z.ZodNullable<z.ZodString>;
3376
+ status: z.ZodEnum<{
3377
+ deleted: "deleted";
3378
+ modified: "modified";
3379
+ renamed: "renamed";
3380
+ added: "added";
3381
+ copied: "copied";
3382
+ untracked: "untracked";
3383
+ ignored: "ignored";
3384
+ conflicted: "conflicted";
3385
+ typechange: "typechange";
3386
+ }>;
3387
+ isBinary: z.ZodDefault<z.ZodBoolean>;
3388
+ isImage: z.ZodDefault<z.ZodBoolean>;
3389
+ additions: z.ZodNumber;
3390
+ deletions: z.ZodNumber;
3391
+ hunks: z.ZodArray<z.ZodObject<{
3392
+ oldStart: z.ZodNumber;
3393
+ oldLines: z.ZodNumber;
3394
+ newStart: z.ZodNumber;
3395
+ newLines: z.ZodNumber;
3396
+ header: z.ZodString;
3397
+ lines: z.ZodArray<z.ZodObject<{
3398
+ type: z.ZodEnum<{
3399
+ context: "context";
3400
+ add: "add";
3401
+ del: "del";
3402
+ meta: "meta";
3403
+ }>;
3404
+ oldNo: z.ZodNullable<z.ZodNumber>;
3405
+ newNo: z.ZodNullable<z.ZodNumber>;
3406
+ text: z.ZodString;
3407
+ }, z.core.$strip>>;
3408
+ }, z.core.$strip>>;
3409
+ truncated: z.ZodDefault<z.ZodBoolean>;
3410
+ }, z.core.$strip>>;
3411
+ blob: z.ZodNullable<z.ZodObject<{
3412
+ content: z.ZodString;
3413
+ encoding: z.ZodEnum<{
3414
+ utf8: "utf8";
3415
+ base64: "base64";
3416
+ }>;
3417
+ sizeBytes: z.ZodNumber;
3418
+ truncated: z.ZodBoolean;
3419
+ }, z.core.$strip>>;
3420
+ revision: z.ZodNumber;
3421
+ }, z.core.$strip>;
3422
+ type GitShowResponse = z.infer<typeof GitShowResponse>;
3423
+ declare const TerminalExecRequest: z.ZodObject<{
3424
+ command: z.ZodString;
3425
+ cwd: z.ZodDefault<z.ZodString>;
3426
+ timeoutMs: z.ZodDefault<z.ZodNumber>;
3427
+ emitStream: z.ZodDefault<z.ZodBoolean>;
3428
+ }, z.core.$strip>;
3429
+ type TerminalExecRequest = z.infer<typeof TerminalExecRequest>;
3430
+ declare const TerminalExecResponse: z.ZodObject<{
3431
+ stdout: z.ZodString;
3432
+ stderr: z.ZodString;
3433
+ exitCode: z.ZodNullable<z.ZodNumber>;
3434
+ running: z.ZodBoolean;
3435
+ wallTimeSeconds: z.ZodNumber;
3436
+ }, z.core.$strip>;
3437
+ type TerminalExecResponse = z.infer<typeof TerminalExecResponse>;
3438
+ declare const PtyOpenRequest: z.ZodObject<{
3439
+ cols: z.ZodDefault<z.ZodNumber>;
3440
+ rows: z.ZodDefault<z.ZodNumber>;
3441
+ cwd: z.ZodDefault<z.ZodString>;
3442
+ shell: z.ZodOptional<z.ZodString>;
3443
+ }, z.core.$strip>;
3444
+ type PtyOpenRequest = z.infer<typeof PtyOpenRequest>;
3445
+ declare const PtyOpenResponse: z.ZodObject<{
3446
+ ptyId: z.ZodString;
3447
+ streamVia: z.ZodLiteral<"sse-events">;
3448
+ supportsInput: z.ZodBoolean;
3449
+ }, z.core.$strip>;
3450
+ type PtyOpenResponse = z.infer<typeof PtyOpenResponse>;
3451
+ declare const PtyWriteRequest: z.ZodObject<{
3452
+ ptyId: z.ZodString;
3453
+ data: z.ZodString;
3454
+ }, z.core.$strip>;
3455
+ type PtyWriteRequest = z.infer<typeof PtyWriteRequest>;
3456
+ declare const PtyResizeRequest: z.ZodObject<{
3457
+ ptyId: z.ZodString;
3458
+ cols: z.ZodNumber;
3459
+ rows: z.ZodNumber;
3460
+ }, z.core.$strip>;
3461
+ type PtyResizeRequest = z.infer<typeof PtyResizeRequest>;
3462
+ declare const PtyCloseRequest: z.ZodObject<{
3463
+ ptyId: z.ZodString;
3464
+ }, z.core.$strip>;
3465
+ type PtyCloseRequest = z.infer<typeof PtyCloseRequest>;
3466
+ declare const SessionStructuredCapabilities: z.ZodObject<{
3467
+ FileSystem: z.ZodObject<{
3468
+ available: z.ZodBoolean;
3469
+ readOnly: z.ZodBoolean;
3470
+ root: z.ZodString;
3471
+ }, z.core.$strip>;
3472
+ Terminal: z.ZodObject<{
3473
+ events: z.ZodBoolean;
3474
+ exec: z.ZodBoolean;
3475
+ pty: z.ZodObject<{
3476
+ available: z.ZodBoolean;
3477
+ }, z.core.$strip>;
3478
+ }, z.core.$strip>;
3479
+ Git: z.ZodObject<{
3480
+ available: z.ZodBoolean;
3481
+ repos: z.ZodArray<z.ZodString>;
3482
+ }, z.core.$strip>;
3483
+ }, z.core.$strip>;
3484
+ type SessionStructuredCapabilities = z.infer<typeof SessionStructuredCapabilities>;
2244
3485
  declare const SessionEvent: z.ZodObject<{
2245
3486
  id: z.ZodString;
2246
3487
  workspaceId: z.ZodString;
@@ -2279,6 +3520,20 @@ declare const SessionEvent: z.ZodObject<{
2279
3520
  "goal.paused": "goal.paused";
2280
3521
  "goal.resumed": "goal.resumed";
2281
3522
  "goal.continuation": "goal.continuation";
3523
+ "stream.url.rotated": "stream.url.rotated";
3524
+ "stream.opened": "stream.opened";
3525
+ "stream.closed": "stream.closed";
3526
+ "stream.revoked": "stream.revoked";
3527
+ "recording.started": "recording.started";
3528
+ "recording.available": "recording.available";
3529
+ "recording.failed": "recording.failed";
3530
+ "fs.changed": "fs.changed";
3531
+ "git.changed": "git.changed";
3532
+ "terminal.pty.started": "terminal.pty.started";
3533
+ "terminal.pty.output.delta": "terminal.pty.output.delta";
3534
+ "terminal.pty.exited": "terminal.pty.exited";
3535
+ "session.title_set": "session.title_set";
3536
+ "codex.account.switched": "codex.account.switched";
2282
3537
  }>;
2283
3538
  payload: z.ZodDefault<z.ZodUnknown>;
2284
3539
  occurredAt: z.ZodString;
@@ -2304,6 +3559,7 @@ declare const CreateSessionRequest: z.ZodObject<{
2304
3559
  tools: z.ZodDefault<z.ZodArray<z.ZodObject<{
2305
3560
  kind: z.ZodLiteral<"mcp">;
2306
3561
  id: z.ZodString;
3562
+ optional: z.ZodOptional<z.ZodBoolean>;
2307
3563
  }, z.core.$strip>>>;
2308
3564
  metadata: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
2309
3565
  model: z.ZodOptional<z.ZodString>;
@@ -2320,7 +3576,16 @@ declare const CreateSessionRequest: z.ZodObject<{
2320
3576
  modal: "modal";
2321
3577
  local: "local";
2322
3578
  none: "none";
3579
+ daytona: "daytona";
3580
+ runloop: "runloop";
3581
+ e2b: "e2b";
3582
+ blaxel: "blaxel";
3583
+ cloudflare: "cloudflare";
3584
+ vercel: "vercel";
3585
+ selfhosted: "selfhosted";
2323
3586
  }>>;
3587
+ targetSandboxId: z.ZodOptional<z.ZodString>;
3588
+ workingDir: z.ZodOptional<z.ZodString>;
2324
3589
  environmentId: z.ZodOptional<z.ZodString>;
2325
3590
  goal: z.ZodOptional<z.ZodObject<{
2326
3591
  text: z.ZodString;
@@ -2341,8 +3606,13 @@ declare const CreateSessionRequest: z.ZodObject<{
2341
3606
  "sessions:create": "sessions:create";
2342
3607
  "sessions:read": "sessions:read";
2343
3608
  "sessions:control": "sessions:control";
3609
+ "stream:view": "stream:view";
3610
+ "stream:control": "stream:control";
3611
+ "stream:acknowledge": "stream:acknowledge";
2344
3612
  "files:upload": "files:upload";
2345
3613
  "files:read": "files:read";
3614
+ "files:write": "files:write";
3615
+ "terminal:attach": "terminal:attach";
2346
3616
  "documents:manage": "documents:manage";
2347
3617
  "documents:search": "documents:search";
2348
3618
  "scheduled_tasks:manage": "scheduled_tasks:manage";
@@ -2353,7 +3623,12 @@ declare const CreateSessionRequest: z.ZodObject<{
2353
3623
  "environments:manage": "environments:manage";
2354
3624
  "environments:use": "environments:use";
2355
3625
  "goals:manage": "goals:manage";
3626
+ "enrollments:read": "enrollments:read";
3627
+ "enrollments:manage": "enrollments:manage";
2356
3628
  }>>>;
3629
+ sandbox: z.ZodOptional<z.ZodUnion<readonly [z.ZodLiteral<"shared">, z.ZodLiteral<"new">, z.ZodObject<{
3630
+ groupId: z.ZodString;
3631
+ }, z.core.$strip>]>>;
2357
3632
  }, z.core.$strip>;
2358
3633
  type CreateSessionRequest = z.infer<typeof CreateSessionRequest>;
2359
3634
  declare const ClientSessionEvent: z.ZodDiscriminatedUnion<[z.ZodObject<{
@@ -2377,6 +3652,7 @@ declare const ClientSessionEvent: z.ZodDiscriminatedUnion<[z.ZodObject<{
2377
3652
  tools: z.ZodDefault<z.ZodArray<z.ZodObject<{
2378
3653
  kind: z.ZodLiteral<"mcp">;
2379
3654
  id: z.ZodString;
3655
+ optional: z.ZodOptional<z.ZodBoolean>;
2380
3656
  }, z.core.$strip>>>;
2381
3657
  model: z.ZodOptional<z.ZodString>;
2382
3658
  reasoningEffort: z.ZodOptional<z.ZodEnum<{
@@ -2448,6 +3724,20 @@ declare const SessionBusMessage: z.ZodObject<{
2448
3724
  "goal.paused": "goal.paused";
2449
3725
  "goal.resumed": "goal.resumed";
2450
3726
  "goal.continuation": "goal.continuation";
3727
+ "stream.url.rotated": "stream.url.rotated";
3728
+ "stream.opened": "stream.opened";
3729
+ "stream.closed": "stream.closed";
3730
+ "stream.revoked": "stream.revoked";
3731
+ "recording.started": "recording.started";
3732
+ "recording.available": "recording.available";
3733
+ "recording.failed": "recording.failed";
3734
+ "fs.changed": "fs.changed";
3735
+ "git.changed": "git.changed";
3736
+ "terminal.pty.started": "terminal.pty.started";
3737
+ "terminal.pty.output.delta": "terminal.pty.output.delta";
3738
+ "terminal.pty.exited": "terminal.pty.exited";
3739
+ "session.title_set": "session.title_set";
3740
+ "codex.account.switched": "codex.account.switched";
2451
3741
  }>;
2452
3742
  payload: z.ZodDefault<z.ZodUnknown>;
2453
3743
  occurredAt: z.ZodString;
@@ -2490,10 +3780,676 @@ declare const ClientAuthConfig: z.ZodDiscriminatedUnion<[z.ZodObject<{
2490
3780
  session: z.ZodLiteral<"cookie">;
2491
3781
  }, z.core.$strip>], "mode">;
2492
3782
  type ClientAuthConfig = z.infer<typeof ClientAuthConfig>;
3783
+ declare const CapabilityUnavailableReason: z.ZodEnum<{
3784
+ backend_unsupported: "backend_unsupported";
3785
+ os_unsupported: "os_unsupported";
3786
+ not_provisioned: "not_provisioned";
3787
+ disabled_by_policy: "disabled_by_policy";
3788
+ lease_cold: "lease_cold";
3789
+ tier_headless: "tier_headless";
3790
+ agent_offline: "agent_offline";
3791
+ agent_reconnecting: "agent_reconnecting";
3792
+ consent_required: "consent_required";
3793
+ display_unavailable: "display_unavailable";
3794
+ }>;
3795
+ type CapabilityUnavailableReason = z.infer<typeof CapabilityUnavailableReason>;
3796
+ declare const SessionCapabilities: z.ZodObject<{
3797
+ sessionId: z.ZodString;
3798
+ backend: z.ZodEnum<{
3799
+ docker: "docker";
3800
+ modal: "modal";
3801
+ local: "local";
3802
+ none: "none";
3803
+ daytona: "daytona";
3804
+ runloop: "runloop";
3805
+ e2b: "e2b";
3806
+ blaxel: "blaxel";
3807
+ cloudflare: "cloudflare";
3808
+ vercel: "vercel";
3809
+ selfhosted: "selfhosted";
3810
+ }>;
3811
+ os: z.ZodEnum<{
3812
+ linux: "linux";
3813
+ macos: "macos";
3814
+ windows: "windows";
3815
+ }>;
3816
+ liveness: z.ZodEnum<{
3817
+ cold: "cold";
3818
+ warming: "warming";
3819
+ warm: "warm";
3820
+ draining: "draining";
3821
+ }>;
3822
+ leaseEpoch: z.ZodNumber;
3823
+ viewerHeartbeatIntervalMs: z.ZodDefault<z.ZodNumber>;
3824
+ FileSystem: z.ZodObject<{
3825
+ available: z.ZodBoolean;
3826
+ readOnly: z.ZodBoolean;
3827
+ root: z.ZodString;
3828
+ pathSep: z.ZodEnum<{
3829
+ "/": "/";
3830
+ "\\": "\\";
3831
+ }>;
3832
+ treeMode: z.ZodEnum<{
3833
+ lazy: "lazy";
3834
+ snapshot: "snapshot";
3835
+ }>;
3836
+ reason: z.ZodNullable<z.ZodEnum<{
3837
+ backend_unsupported: "backend_unsupported";
3838
+ os_unsupported: "os_unsupported";
3839
+ not_provisioned: "not_provisioned";
3840
+ disabled_by_policy: "disabled_by_policy";
3841
+ lease_cold: "lease_cold";
3842
+ tier_headless: "tier_headless";
3843
+ agent_offline: "agent_offline";
3844
+ agent_reconnecting: "agent_reconnecting";
3845
+ consent_required: "consent_required";
3846
+ display_unavailable: "display_unavailable";
3847
+ }>>;
3848
+ }, z.core.$strip>;
3849
+ Terminal: z.ZodObject<{
3850
+ transport: z.ZodNullable<z.ZodEnum<{
3851
+ "sse-events": "sse-events";
3852
+ "pty-ws": "pty-ws";
3853
+ }>>;
3854
+ ptyCapable: z.ZodBoolean;
3855
+ shell: z.ZodString;
3856
+ url: z.ZodNullable<z.ZodString>;
3857
+ token: z.ZodNullable<z.ZodString>;
3858
+ expiresAt: z.ZodNullable<z.ZodString>;
3859
+ reason: z.ZodNullable<z.ZodEnum<{
3860
+ backend_unsupported: "backend_unsupported";
3861
+ os_unsupported: "os_unsupported";
3862
+ not_provisioned: "not_provisioned";
3863
+ disabled_by_policy: "disabled_by_policy";
3864
+ lease_cold: "lease_cold";
3865
+ tier_headless: "tier_headless";
3866
+ agent_offline: "agent_offline";
3867
+ agent_reconnecting: "agent_reconnecting";
3868
+ consent_required: "consent_required";
3869
+ display_unavailable: "display_unavailable";
3870
+ }>>;
3871
+ }, z.core.$strip>;
3872
+ Git: z.ZodObject<{
3873
+ available: z.ZodBoolean;
3874
+ repos: z.ZodArray<z.ZodString>;
3875
+ reason: z.ZodNullable<z.ZodEnum<{
3876
+ backend_unsupported: "backend_unsupported";
3877
+ os_unsupported: "os_unsupported";
3878
+ not_provisioned: "not_provisioned";
3879
+ disabled_by_policy: "disabled_by_policy";
3880
+ lease_cold: "lease_cold";
3881
+ tier_headless: "tier_headless";
3882
+ agent_offline: "agent_offline";
3883
+ agent_reconnecting: "agent_reconnecting";
3884
+ consent_required: "consent_required";
3885
+ display_unavailable: "display_unavailable";
3886
+ }>>;
3887
+ }, z.core.$strip>;
3888
+ DesktopStream: z.ZodObject<{
3889
+ transport: z.ZodNullable<z.ZodEnum<{
3890
+ "vnc-ws": "vnc-ws";
3891
+ "rdp-ws": "rdp-ws";
3892
+ webrtc: "webrtc";
3893
+ "relay-frames": "relay-frames";
3894
+ }>>;
3895
+ client: z.ZodNullable<z.ZodEnum<{
3896
+ novnc: "novnc";
3897
+ "web-rdp": "web-rdp";
3898
+ frames: "frames";
3899
+ }>>;
3900
+ mode: z.ZodDefault<z.ZodEnum<{
3901
+ "read-only": "read-only";
3902
+ interactive: "interactive";
3903
+ }>>;
3904
+ url: z.ZodNullable<z.ZodString>;
3905
+ token: z.ZodNullable<z.ZodString>;
3906
+ expiresAt: z.ZodNullable<z.ZodString>;
3907
+ resolution: z.ZodDefault<z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>>;
3908
+ unredacted: z.ZodBoolean;
3909
+ requiresAcknowledgment: z.ZodBoolean;
3910
+ acknowledged: z.ZodBoolean;
3911
+ shared: z.ZodDefault<z.ZodBoolean>;
3912
+ sharedSessionIds: z.ZodDefault<z.ZodArray<z.ZodString>>;
3913
+ reason: z.ZodNullable<z.ZodEnum<{
3914
+ backend_unsupported: "backend_unsupported";
3915
+ os_unsupported: "os_unsupported";
3916
+ not_provisioned: "not_provisioned";
3917
+ disabled_by_policy: "disabled_by_policy";
3918
+ lease_cold: "lease_cold";
3919
+ tier_headless: "tier_headless";
3920
+ agent_offline: "agent_offline";
3921
+ agent_reconnecting: "agent_reconnecting";
3922
+ consent_required: "consent_required";
3923
+ display_unavailable: "display_unavailable";
3924
+ }>>;
3925
+ }, z.core.$strip>;
3926
+ Recording: z.ZodObject<{
3927
+ available: z.ZodBoolean;
3928
+ modes: z.ZodArray<z.ZodEnum<{
3929
+ manual: "manual";
3930
+ "on-turn": "on-turn";
3931
+ "on-verify": "on-verify";
3932
+ }>>;
3933
+ codecs: z.ZodArray<z.ZodEnum<{
3934
+ "h264-mp4": "h264-mp4";
3935
+ "vp9-webm": "vp9-webm";
3936
+ }>>;
3937
+ reason: z.ZodNullable<z.ZodEnum<{
3938
+ backend_unsupported: "backend_unsupported";
3939
+ os_unsupported: "os_unsupported";
3940
+ not_provisioned: "not_provisioned";
3941
+ disabled_by_policy: "disabled_by_policy";
3942
+ lease_cold: "lease_cold";
3943
+ tier_headless: "tier_headless";
3944
+ agent_offline: "agent_offline";
3945
+ agent_reconnecting: "agent_reconnecting";
3946
+ consent_required: "consent_required";
3947
+ display_unavailable: "display_unavailable";
3948
+ }>>;
3949
+ }, z.core.$strip>;
3950
+ ComputerUse: z.ZodObject<{
3951
+ available: z.ZodBoolean;
3952
+ readOnly: z.ZodBoolean;
3953
+ reason: z.ZodNullable<z.ZodEnum<{
3954
+ backend_unsupported: "backend_unsupported";
3955
+ os_unsupported: "os_unsupported";
3956
+ not_provisioned: "not_provisioned";
3957
+ disabled_by_policy: "disabled_by_policy";
3958
+ lease_cold: "lease_cold";
3959
+ tier_headless: "tier_headless";
3960
+ agent_offline: "agent_offline";
3961
+ agent_reconnecting: "agent_reconnecting";
3962
+ consent_required: "consent_required";
3963
+ display_unavailable: "display_unavailable";
3964
+ }>>;
3965
+ }, z.core.$strip>;
3966
+ negotiatedAt: z.ZodString;
3967
+ }, z.core.$strip>;
3968
+ type SessionCapabilities = z.infer<typeof SessionCapabilities>;
3969
+ declare const AttachViewerRequest: z.ZodObject<{
3970
+ viewerId: z.ZodOptional<z.ZodString>;
3971
+ desktop: z.ZodOptional<z.ZodBoolean>;
3972
+ }, z.core.$strip>;
3973
+ type AttachViewerRequest = z.infer<typeof AttachViewerRequest>;
3974
+ declare const ViewerHolder: z.ZodObject<{
3975
+ viewerId: z.ZodString;
3976
+ sandboxGroupId: z.ZodString;
3977
+ liveness: z.ZodEnum<{
3978
+ cold: "cold";
3979
+ warming: "warming";
3980
+ warm: "warm";
3981
+ draining: "draining";
3982
+ }>;
3983
+ leaseEpoch: z.ZodNumber;
3984
+ viewerHeartbeatIntervalMs: z.ZodNumber;
3985
+ dataPlaneUrl: z.ZodNullable<z.ZodString>;
3986
+ }, z.core.$strip>;
3987
+ type ViewerHolder = z.infer<typeof ViewerHolder>;
3988
+ declare const AcknowledgeStreamRequest: z.ZodObject<{
3989
+ acknowledgeUnredacted: z.ZodDefault<z.ZodBoolean>;
3990
+ acknowledgeShared: z.ZodDefault<z.ZodBoolean>;
3991
+ }, z.core.$strip>;
3992
+ type AcknowledgeStreamRequest = z.infer<typeof AcknowledgeStreamRequest>;
3993
+ declare const AcknowledgeStreamResponse: z.ZodObject<{
3994
+ acknowledged: z.ZodBoolean;
3995
+ acknowledgedShared: z.ZodBoolean;
3996
+ }, z.core.$strip>;
3997
+ type AcknowledgeStreamResponse = z.infer<typeof AcknowledgeStreamResponse>;
3998
+ declare const ViewerHeartbeatRequest: z.ZodObject<{
3999
+ leaseEpoch: z.ZodNumber;
4000
+ }, z.core.$strip>;
4001
+ type ViewerHeartbeatRequest = z.infer<typeof ViewerHeartbeatRequest>;
4002
+ declare const ViewerHeartbeatResponse: z.ZodObject<{
4003
+ alive: z.ZodBoolean;
4004
+ }, z.core.$strip>;
4005
+ type ViewerHeartbeatResponse = z.infer<typeof ViewerHeartbeatResponse>;
4006
+ declare const EnrollmentOs: z.ZodEnum<{
4007
+ linux: "linux";
4008
+ macos: "macos";
4009
+ windows: "windows";
4010
+ }>;
4011
+ type EnrollmentOs = z.infer<typeof EnrollmentOs>;
4012
+ declare const EnrollmentArch: z.ZodEnum<{
4013
+ x86_64: "x86_64";
4014
+ aarch64: "aarch64";
4015
+ }>;
4016
+ type EnrollmentArch = z.infer<typeof EnrollmentArch>;
4017
+ declare const DeviceEnrollmentStartRequest: z.ZodObject<{
4018
+ publicKey: z.ZodString;
4019
+ os: z.ZodDefault<z.ZodEnum<{
4020
+ linux: "linux";
4021
+ macos: "macos";
4022
+ windows: "windows";
4023
+ }>>;
4024
+ arch: z.ZodDefault<z.ZodEnum<{
4025
+ x86_64: "x86_64";
4026
+ aarch64: "aarch64";
4027
+ }>>;
4028
+ machineName: z.ZodOptional<z.ZodString>;
4029
+ exposure: z.ZodDefault<z.ZodLiteral<"whole-machine">>;
4030
+ canOfferDisplay: z.ZodDefault<z.ZodBoolean>;
4031
+ requestsScreenControl: z.ZodDefault<z.ZodBoolean>;
4032
+ workspaceId: z.ZodString;
4033
+ }, z.core.$strip>;
4034
+ type DeviceEnrollmentStartRequest = z.infer<typeof DeviceEnrollmentStartRequest>;
4035
+ declare const DeviceEnrollmentStartResponse: z.ZodObject<{
4036
+ deviceCode: z.ZodString;
4037
+ userCode: z.ZodString;
4038
+ verificationUri: z.ZodString;
4039
+ verificationUriComplete: z.ZodString;
4040
+ intervalSeconds: z.ZodNumber;
4041
+ expiresInSeconds: z.ZodNumber;
4042
+ }, z.core.$strip>;
4043
+ type DeviceEnrollmentStartResponse = z.infer<typeof DeviceEnrollmentStartResponse>;
4044
+ declare const DeviceEnrollmentApproveRequest: z.ZodObject<{
4045
+ userCode: z.ZodString;
4046
+ allowScreenControl: z.ZodDefault<z.ZodBoolean>;
4047
+ }, z.core.$strip>;
4048
+ type DeviceEnrollmentApproveRequest = z.infer<typeof DeviceEnrollmentApproveRequest>;
4049
+ declare const DeviceEnrollmentApproveResponse: z.ZodObject<{
4050
+ approved: z.ZodBoolean;
4051
+ enrollmentId: z.ZodString;
4052
+ sandboxId: z.ZodString;
4053
+ allowScreenControl: z.ZodBoolean;
4054
+ }, z.core.$strip>;
4055
+ type DeviceEnrollmentApproveResponse = z.infer<typeof DeviceEnrollmentApproveResponse>;
4056
+ declare const DeviceEnrollmentPollRequest: z.ZodObject<{
4057
+ deviceCode: z.ZodString;
4058
+ }, z.core.$strip>;
4059
+ type DeviceEnrollmentPollRequest = z.infer<typeof DeviceEnrollmentPollRequest>;
4060
+ declare const DeviceEnrollmentState: z.ZodEnum<{
4061
+ disabled: "disabled";
4062
+ expired: "expired";
4063
+ pending: "pending";
4064
+ authorized: "authorized";
4065
+ denied: "denied";
4066
+ }>;
4067
+ type DeviceEnrollmentState = z.infer<typeof DeviceEnrollmentState>;
4068
+ declare const EnrollmentCredentialsResponse: z.ZodObject<{
4069
+ agentId: z.ZodString;
4070
+ workspaceId: z.ZodString;
4071
+ bearer: z.ZodString;
4072
+ subjectPrefix: z.ZodString;
4073
+ natsUrls: z.ZodArray<z.ZodString>;
4074
+ relayUrl: z.ZodString;
4075
+ relayToken: z.ZodString;
4076
+ natsAccountCreds: z.ZodString;
4077
+ updatePublicKey: z.ZodString;
4078
+ consentedWholeMachine: z.ZodBoolean;
4079
+ consentedScreenControl: z.ZodBoolean;
4080
+ }, z.core.$strip>;
4081
+ type EnrollmentCredentialsResponse = z.infer<typeof EnrollmentCredentialsResponse>;
4082
+ declare const DeviceEnrollmentPollResponse: z.ZodObject<{
4083
+ state: z.ZodEnum<{
4084
+ disabled: "disabled";
4085
+ expired: "expired";
4086
+ pending: "pending";
4087
+ authorized: "authorized";
4088
+ denied: "denied";
4089
+ }>;
4090
+ credentials: z.ZodOptional<z.ZodObject<{
4091
+ agentId: z.ZodString;
4092
+ workspaceId: z.ZodString;
4093
+ bearer: z.ZodString;
4094
+ subjectPrefix: z.ZodString;
4095
+ natsUrls: z.ZodArray<z.ZodString>;
4096
+ relayUrl: z.ZodString;
4097
+ relayToken: z.ZodString;
4098
+ natsAccountCreds: z.ZodString;
4099
+ updatePublicKey: z.ZodString;
4100
+ consentedWholeMachine: z.ZodBoolean;
4101
+ consentedScreenControl: z.ZodBoolean;
4102
+ }, z.core.$strip>>;
4103
+ }, z.core.$strip>;
4104
+ type DeviceEnrollmentPollResponse = z.infer<typeof DeviceEnrollmentPollResponse>;
4105
+ declare const EnrollmentSummary: z.ZodObject<{
4106
+ id: z.ZodString;
4107
+ pubkey: z.ZodString;
4108
+ exposure: z.ZodLiteral<"whole-machine">;
4109
+ hasDisplay: z.ZodBoolean;
4110
+ allowScreenControl: z.ZodBoolean;
4111
+ status: z.ZodEnum<{
4112
+ active: "active";
4113
+ revoked: "revoked";
4114
+ }>;
4115
+ os: z.ZodEnum<{
4116
+ linux: "linux";
4117
+ macos: "macos";
4118
+ windows: "windows";
4119
+ }>;
4120
+ arch: z.ZodString;
4121
+ lastSeenAt: z.ZodNullable<z.ZodString>;
4122
+ createdAt: z.ZodString;
4123
+ revokedAt: z.ZodNullable<z.ZodString>;
4124
+ }, z.core.$strip>;
4125
+ type EnrollmentSummary = z.infer<typeof EnrollmentSummary>;
4126
+ declare const ListEnrollmentsResponse: z.ZodObject<{
4127
+ enrollments: z.ZodArray<z.ZodObject<{
4128
+ id: z.ZodString;
4129
+ pubkey: z.ZodString;
4130
+ exposure: z.ZodLiteral<"whole-machine">;
4131
+ hasDisplay: z.ZodBoolean;
4132
+ allowScreenControl: z.ZodBoolean;
4133
+ status: z.ZodEnum<{
4134
+ active: "active";
4135
+ revoked: "revoked";
4136
+ }>;
4137
+ os: z.ZodEnum<{
4138
+ linux: "linux";
4139
+ macos: "macos";
4140
+ windows: "windows";
4141
+ }>;
4142
+ arch: z.ZodString;
4143
+ lastSeenAt: z.ZodNullable<z.ZodString>;
4144
+ createdAt: z.ZodString;
4145
+ revokedAt: z.ZodNullable<z.ZodString>;
4146
+ }, z.core.$strip>>;
4147
+ }, z.core.$strip>;
4148
+ type ListEnrollmentsResponse = z.infer<typeof ListEnrollmentsResponse>;
4149
+ declare const RevokeEnrollmentResponse: z.ZodObject<{
4150
+ revoked: z.ZodBoolean;
4151
+ }, z.core.$strip>;
4152
+ type RevokeEnrollmentResponse = z.infer<typeof RevokeEnrollmentResponse>;
4153
+ declare const DeviceEnrollmentLookupRequest: z.ZodObject<{
4154
+ userCode: z.ZodString;
4155
+ }, z.core.$strip>;
4156
+ type DeviceEnrollmentLookupRequest = z.infer<typeof DeviceEnrollmentLookupRequest>;
4157
+ declare const DeviceEnrollmentLookupMachine: z.ZodObject<{
4158
+ machineName: z.ZodNullable<z.ZodString>;
4159
+ os: z.ZodEnum<{
4160
+ linux: "linux";
4161
+ macos: "macos";
4162
+ windows: "windows";
4163
+ }>;
4164
+ arch: z.ZodString;
4165
+ canOfferDisplay: z.ZodBoolean;
4166
+ requestsScreenControl: z.ZodBoolean;
4167
+ }, z.core.$strip>;
4168
+ type DeviceEnrollmentLookupMachine = z.infer<typeof DeviceEnrollmentLookupMachine>;
4169
+ declare const DeviceEnrollmentLookupResponse: z.ZodObject<{
4170
+ workspaceId: z.ZodString;
4171
+ userCode: z.ZodString;
4172
+ machine: z.ZodObject<{
4173
+ machineName: z.ZodNullable<z.ZodString>;
4174
+ os: z.ZodEnum<{
4175
+ linux: "linux";
4176
+ macos: "macos";
4177
+ windows: "windows";
4178
+ }>;
4179
+ arch: z.ZodString;
4180
+ canOfferDisplay: z.ZodBoolean;
4181
+ requestsScreenControl: z.ZodBoolean;
4182
+ }, z.core.$strip>;
4183
+ expiresAt: z.ZodString;
4184
+ }, z.core.$strip>;
4185
+ type DeviceEnrollmentLookupResponse = z.infer<typeof DeviceEnrollmentLookupResponse>;
4186
+ declare const DeviceEnrollmentDenyRequest: z.ZodObject<{
4187
+ userCode: z.ZodString;
4188
+ }, z.core.$strip>;
4189
+ type DeviceEnrollmentDenyRequest = z.infer<typeof DeviceEnrollmentDenyRequest>;
4190
+ declare const DeviceEnrollmentDenyResponse: z.ZodObject<{
4191
+ denied: z.ZodBoolean;
4192
+ }, z.core.$strip>;
4193
+ type DeviceEnrollmentDenyResponse = z.infer<typeof DeviceEnrollmentDenyResponse>;
4194
+ declare const MintEnrollTokenRequest: z.ZodObject<{
4195
+ allowScreenControl: z.ZodDefault<z.ZodBoolean>;
4196
+ }, z.core.$strip>;
4197
+ type MintEnrollTokenRequest = z.infer<typeof MintEnrollTokenRequest>;
4198
+ declare const MintEnrollTokenResponse: z.ZodObject<{
4199
+ token: z.ZodString;
4200
+ expiresAt: z.ZodString;
4201
+ expiresInSeconds: z.ZodNumber;
4202
+ }, z.core.$strip>;
4203
+ type MintEnrollTokenResponse = z.infer<typeof MintEnrollTokenResponse>;
4204
+ declare const EnrollTokenExchangeRequest: z.ZodObject<{
4205
+ token: z.ZodString;
4206
+ publicKey: z.ZodString;
4207
+ os: z.ZodDefault<z.ZodEnum<{
4208
+ linux: "linux";
4209
+ macos: "macos";
4210
+ windows: "windows";
4211
+ }>>;
4212
+ arch: z.ZodDefault<z.ZodEnum<{
4213
+ x86_64: "x86_64";
4214
+ aarch64: "aarch64";
4215
+ }>>;
4216
+ machineName: z.ZodOptional<z.ZodString>;
4217
+ exposure: z.ZodDefault<z.ZodLiteral<"whole-machine">>;
4218
+ canOfferDisplay: z.ZodDefault<z.ZodBoolean>;
4219
+ requestsScreenControl: z.ZodDefault<z.ZodBoolean>;
4220
+ }, z.core.$strip>;
4221
+ type EnrollTokenExchangeRequest = z.infer<typeof EnrollTokenExchangeRequest>;
4222
+ declare const EnrollTokenExchangeResponse: z.ZodObject<{
4223
+ credentials: z.ZodObject<{
4224
+ agentId: z.ZodString;
4225
+ workspaceId: z.ZodString;
4226
+ bearer: z.ZodString;
4227
+ subjectPrefix: z.ZodString;
4228
+ natsUrls: z.ZodArray<z.ZodString>;
4229
+ relayUrl: z.ZodString;
4230
+ relayToken: z.ZodString;
4231
+ natsAccountCreds: z.ZodString;
4232
+ updatePublicKey: z.ZodString;
4233
+ consentedWholeMachine: z.ZodBoolean;
4234
+ consentedScreenControl: z.ZodBoolean;
4235
+ }, z.core.$strip>;
4236
+ }, z.core.$strip>;
4237
+ type EnrollTokenExchangeResponse = z.infer<typeof EnrollTokenExchangeResponse>;
4238
+ /**
4239
+ * A point-in-time machine metrics sample as the dashboard reads it. `cpuPct` and
4240
+ * the load averages are 0..N doubles; the byte figures are integers; `gpuUtilPct`
4241
+ * / `gpuMemBytes` are null when no GPU was present at sample time (the wire
4242
+ * contract: absence == not-reported, NEVER a real zero). `runQueue` is the
4243
+ * runnable-count contention signal. `sampledAt` is an ISO-8601 instant.
4244
+ */
4245
+ declare const MetricSample: z.ZodObject<{
4246
+ cpuPct: z.ZodNumber;
4247
+ load1: z.ZodNumber;
4248
+ load5: z.ZodNumber;
4249
+ load15: z.ZodNumber;
4250
+ memUsedBytes: z.ZodNumber;
4251
+ memTotalBytes: z.ZodNumber;
4252
+ diskUsedBytes: z.ZodNumber;
4253
+ diskTotalBytes: z.ZodNumber;
4254
+ gpuUtilPct: z.ZodNullable<z.ZodNumber>;
4255
+ gpuMemBytes: z.ZodNullable<z.ZodNumber>;
4256
+ runQueue: z.ZodNumber;
4257
+ sampledAt: z.ZodString;
4258
+ }, z.core.$strip>;
4259
+ type MetricSample = z.infer<typeof MetricSample>;
4260
+ /** The derived dashboard state of a machine. The M3 liveness
4261
+ * (online/reconnecting/offline) plus the enrollment-derived consent/display
4262
+ * reasons (consent_required / display_unavailable) and the in-flight device-flow
4263
+ * (enrolling). */
4264
+ declare const MachineState: z.ZodEnum<{
4265
+ consent_required: "consent_required";
4266
+ display_unavailable: "display_unavailable";
4267
+ online: "online";
4268
+ reconnecting: "reconnecting";
4269
+ offline: "offline";
4270
+ enrolling: "enrolling";
4271
+ }>;
4272
+ type MachineState = z.infer<typeof MachineState>;
4273
+ declare const MachineKind: z.ZodEnum<{
4274
+ modal: "modal";
4275
+ selfhosted: "selfhosted";
4276
+ }>;
4277
+ type MachineKind = z.infer<typeof MachineKind>;
4278
+ /**
4279
+ * A machine as the Machines dashboard renders it. The workspace's enrolled
4280
+ * selfhosted machines PLUS the session's synthetic Modal group box
4281
+ * (`isSessionGroup: true`). `active` marks the session's currently-active
4282
+ * routing target. `sharedSessionCount` is the lease refcount (how many sessions
4283
+ * share this whole machine). `metrics` is the latest sample, or null when none
4284
+ * has landed yet (just enrolled / offline before a first heartbeat).
4285
+ */
4286
+ declare const MachineView: z.ZodObject<{
4287
+ sandboxId: z.ZodString;
4288
+ enrollmentId: z.ZodNullable<z.ZodString>;
4289
+ name: z.ZodString;
4290
+ kind: z.ZodEnum<{
4291
+ modal: "modal";
4292
+ selfhosted: "selfhosted";
4293
+ }>;
4294
+ state: z.ZodEnum<{
4295
+ consent_required: "consent_required";
4296
+ display_unavailable: "display_unavailable";
4297
+ online: "online";
4298
+ reconnecting: "reconnecting";
4299
+ offline: "offline";
4300
+ enrolling: "enrolling";
4301
+ }>;
4302
+ active: z.ZodBoolean;
4303
+ isSessionGroup: z.ZodBoolean;
4304
+ os: z.ZodString;
4305
+ arch: z.ZodString;
4306
+ hasDisplay: z.ZodBoolean;
4307
+ allowScreenControl: z.ZodBoolean;
4308
+ sharedSessionCount: z.ZodNumber;
4309
+ lastSeenAt: z.ZodNullable<z.ZodString>;
4310
+ metrics: z.ZodNullable<z.ZodObject<{
4311
+ cpuPct: z.ZodNumber;
4312
+ load1: z.ZodNumber;
4313
+ load5: z.ZodNumber;
4314
+ load15: z.ZodNumber;
4315
+ memUsedBytes: z.ZodNumber;
4316
+ memTotalBytes: z.ZodNumber;
4317
+ diskUsedBytes: z.ZodNumber;
4318
+ diskTotalBytes: z.ZodNumber;
4319
+ gpuUtilPct: z.ZodNullable<z.ZodNumber>;
4320
+ gpuMemBytes: z.ZodNullable<z.ZodNumber>;
4321
+ runQueue: z.ZodNumber;
4322
+ sampledAt: z.ZodString;
4323
+ }, z.core.$strip>>;
4324
+ }, z.core.$strip>;
4325
+ type MachineView = z.infer<typeof MachineView>;
4326
+ /**
4327
+ * GET /v1/workspaces/:ws/machines — the dashboard list. `activeSandboxId` /
4328
+ * `activeEpoch` echo the session's epoch-fenced active-sandbox pointer (null
4329
+ * activeSandboxId == the session's own group box is active).
4330
+ */
4331
+ declare const MachinesResponse: z.ZodObject<{
4332
+ activeSandboxId: z.ZodNullable<z.ZodString>;
4333
+ activeEpoch: z.ZodNumber;
4334
+ machines: z.ZodArray<z.ZodObject<{
4335
+ sandboxId: z.ZodString;
4336
+ enrollmentId: z.ZodNullable<z.ZodString>;
4337
+ name: z.ZodString;
4338
+ kind: z.ZodEnum<{
4339
+ modal: "modal";
4340
+ selfhosted: "selfhosted";
4341
+ }>;
4342
+ state: z.ZodEnum<{
4343
+ consent_required: "consent_required";
4344
+ display_unavailable: "display_unavailable";
4345
+ online: "online";
4346
+ reconnecting: "reconnecting";
4347
+ offline: "offline";
4348
+ enrolling: "enrolling";
4349
+ }>;
4350
+ active: z.ZodBoolean;
4351
+ isSessionGroup: z.ZodBoolean;
4352
+ os: z.ZodString;
4353
+ arch: z.ZodString;
4354
+ hasDisplay: z.ZodBoolean;
4355
+ allowScreenControl: z.ZodBoolean;
4356
+ sharedSessionCount: z.ZodNumber;
4357
+ lastSeenAt: z.ZodNullable<z.ZodString>;
4358
+ metrics: z.ZodNullable<z.ZodObject<{
4359
+ cpuPct: z.ZodNumber;
4360
+ load1: z.ZodNumber;
4361
+ load5: z.ZodNumber;
4362
+ load15: z.ZodNumber;
4363
+ memUsedBytes: z.ZodNumber;
4364
+ memTotalBytes: z.ZodNumber;
4365
+ diskUsedBytes: z.ZodNumber;
4366
+ diskTotalBytes: z.ZodNumber;
4367
+ gpuUtilPct: z.ZodNullable<z.ZodNumber>;
4368
+ gpuMemBytes: z.ZodNullable<z.ZodNumber>;
4369
+ runQueue: z.ZodNumber;
4370
+ sampledAt: z.ZodString;
4371
+ }, z.core.$strip>>;
4372
+ }, z.core.$strip>>;
4373
+ }, z.core.$strip>;
4374
+ type MachinesResponse = z.infer<typeof MachinesResponse>;
4375
+ /**
4376
+ * POST /v1/workspaces/:ws/sessions/:sessionId/active-sandbox — the user-
4377
+ * authenticated swap of a session's active sandbox (the same epoch-fenced
4378
+ * mechanic the M7 `sandbox_swap` MCP tool exposes to the agent). `target` is a
4379
+ * `MachinesResponse` machine's `sandboxId`, or "session"/"default" to swap back
4380
+ * to the session's own group box.
4381
+ */
4382
+ declare const SwapActiveSandboxRequest: z.ZodObject<{
4383
+ target: z.ZodString;
4384
+ }, z.core.$strip>;
4385
+ type SwapActiveSandboxRequest = z.infer<typeof SwapActiveSandboxRequest>;
4386
+ /**
4387
+ * The swap outcome (mirrors the server `FleetSwapResult`). `swapped` is true on a
4388
+ * successful repoint OR a no-op (already pointed there); `reason` carries the
4389
+ * failure detail (unowned/offline target, or a lost epoch fence) when false.
4390
+ */
4391
+ declare const SwapActiveSandboxResponse: z.ZodObject<{
4392
+ swapped: z.ZodBoolean;
4393
+ activeSandboxId: z.ZodNullable<z.ZodString>;
4394
+ activeEpoch: z.ZodNumber;
4395
+ reason: z.ZodOptional<z.ZodString>;
4396
+ }, z.core.$strip>;
4397
+ type SwapActiveSandboxResponse = z.infer<typeof SwapActiveSandboxResponse>;
4398
+ /**
4399
+ * GET /v1/workspaces/:ws/machines/:enrollmentId/metrics/series?window=1h — the
4400
+ * downsampled (~1/min) history the dashboard time-range reads.
4401
+ */
4402
+ declare const MachineMetricsSeriesResponse: z.ZodObject<{
4403
+ samples: z.ZodArray<z.ZodObject<{
4404
+ cpuPct: z.ZodNumber;
4405
+ load1: z.ZodNumber;
4406
+ load5: z.ZodNumber;
4407
+ load15: z.ZodNumber;
4408
+ memUsedBytes: z.ZodNumber;
4409
+ memTotalBytes: z.ZodNumber;
4410
+ diskUsedBytes: z.ZodNumber;
4411
+ diskTotalBytes: z.ZodNumber;
4412
+ gpuUtilPct: z.ZodNullable<z.ZodNumber>;
4413
+ gpuMemBytes: z.ZodNullable<z.ZodNumber>;
4414
+ runQueue: z.ZodNumber;
4415
+ sampledAt: z.ZodString;
4416
+ }, z.core.$strip>>;
4417
+ }, z.core.$strip>;
4418
+ type MachineMetricsSeriesResponse = z.infer<typeof MachineMetricsSeriesResponse>;
4419
+ /**
4420
+ * A single host-exposed model + the provider that serves it, as surfaced to
4421
+ * clients (SDK + React composer) by GET /v1/config/client. The wire `api`
4422
+ * ("responses" | "chat") lets a client reason about provider capabilities; the
4423
+ * provider id/label drive the picker's grouping. This mirrors the runtime's
4424
+ * ConfiguredModel (packages/config) projected to the client-safe fields.
4425
+ */
4426
+ declare const ClientModel: z.ZodObject<{
4427
+ id: z.ZodString;
4428
+ label: z.ZodString;
4429
+ provider: z.ZodString;
4430
+ providerLabel: z.ZodString;
4431
+ api: z.ZodEnum<{
4432
+ responses: "responses";
4433
+ chat: "chat";
4434
+ }>;
4435
+ contextWindowTokens: z.ZodOptional<z.ZodNumber>;
4436
+ }, z.core.$strip>;
4437
+ type ClientModel = z.infer<typeof ClientModel>;
2493
4438
  declare const ClientConfig: z.ZodObject<{
2494
4439
  deploymentRevision: z.ZodString;
2495
4440
  defaultModel: z.ZodString;
2496
4441
  allowedModels: z.ZodArray<z.ZodString>;
4442
+ models: z.ZodDefault<z.ZodArray<z.ZodObject<{
4443
+ id: z.ZodString;
4444
+ label: z.ZodString;
4445
+ provider: z.ZodString;
4446
+ providerLabel: z.ZodString;
4447
+ api: z.ZodEnum<{
4448
+ responses: "responses";
4449
+ chat: "chat";
4450
+ }>;
4451
+ contextWindowTokens: z.ZodOptional<z.ZodNumber>;
4452
+ }, z.core.$strip>>>;
2497
4453
  defaultReasoningEffort: z.ZodEnum<{
2498
4454
  none: "none";
2499
4455
  minimal: "minimal";
@@ -2536,6 +4492,11 @@ declare const ClientConfig: z.ZodObject<{
2536
4492
  mode: z.ZodLiteral<"managedSession">;
2537
4493
  session: z.ZodLiteral<"cookie">;
2538
4494
  }, z.core.$strip>], "mode">>;
4495
+ structuredServices: z.ZodDefault<z.ZodObject<{
4496
+ fileSystem: z.ZodBoolean;
4497
+ git: z.ZodBoolean;
4498
+ terminalEvents: z.ZodBoolean;
4499
+ }, z.core.$strip>>;
2539
4500
  }, z.core.$strip>;
2540
4501
  type ClientConfig = z.infer<typeof ClientConfig>;
2541
4502
  type HealthResponse = {
@@ -2544,4 +4505,4 @@ type HealthResponse = {
2544
4505
  ok: boolean;
2545
4506
  };
2546
4507
 
2547
- export { AccessContext, AccessGrant, AccountGrant, AccountRole, AddDocumentRequest, ApiKey, BillingBalance, BillingMode, CLEARED_RUN_STATE_BLOB, CLEARED_RUN_STATE_MARKER, CapabilityCatalogItem, CapabilityCatalogResponse, CapabilityInstallation, CapabilityInstallationStatus, CapabilityKind, CapabilityPack, CapabilityPackConnector, CapabilityPackConnectorAuthModel, CapabilityPackKnowledge, CapabilityPackScheduledTaskTemplate, CapabilityPackSkill, CapabilityPackSkillFile, CapabilityRuntime, CapabilitySource, ClearSessionContextRequest, ClientAuthConfig, ClientConfig, ClientSessionEvent, CompactSessionContextRequest, CompactSessionContextResult, CompleteFileUploadResponse, CreateApiKeyRequest, CreateApiKeyResponse, CreateCapabilityCatalogItemRequest, CreateCheckoutRequest, CreateCheckoutResponse, CreateDocumentBaseRequest, CreateFileUploadRequest, CreateFileUploadResponse, CreateScheduledTaskRequest, CreateSessionRequest, CreateSocialConnectionRequest, CreateSocialPostRequest, CreateWorkspaceEnvironmentRequest, CreateWorkspaceRequest, DelegatedAccessTokenPayload, DiscoverMcpCapabilitiesResponse, Document, DocumentBase, DocumentSearchRequest, DocumentSearchResult, DocumentStatus, EnableCapabilityRequest, EnablePackRequest, EntitlementValue, Entitlements, EntitlementsMode, ErrorCode, ErrorEnvelope, FileAsset, FileDownloadUrlResponse, FileResourceRef, FileStatus, FileUploadStatus, GitHubAppManifestCreate, GitHubRepository, GoalSpec, type HealthResponse, LimitAction, LimitDecision, ManagedAccount, MarketingDailyAnalysisTaskRequest, PackInstallation, PackInstallationStatus, PageInfo, Permission, ProductAccessMode, ReasoningEffort, RegisterCapabilityPackRequest, ReorderSessionTurnsRequest, RepositoryResourceRef, ResourceRef, ResourceRefConflictError, SandboxBackend, ScheduledTask, ScheduledTaskAgentConfig, ScheduledTaskOverlapPolicy, ScheduledTaskRun, ScheduledTaskRunMode, ScheduledTaskRunStatus, ScheduledTaskScheduleSpec, ScheduledTaskStatus, ScheduledTaskTriggerType, Session, SessionBusMessage, SessionEvent, SessionEventType, SessionGoal, SessionGoalCreatedBy, SessionGoalPausedReason, SessionGoalStatus, SessionStatus, SessionTurn, SessionTurnSource, SessionTurnStatus, SetWorkspaceEnvironmentVariableRequest, SocialConnection, SocialConnectionStatus, SocialPost, SocialProvider, StaticUsageLimits, ToolRef, TriggerScheduledTaskRequest, UpdateScheduledTaskRequest, UpdateSessionGoalRequest, UpdateSessionTurnRequest, UpdateWorkspaceEnvironmentRequest, UpdateWorkspaceRequest, UsageEvent, UsageEventType, UsageLimitsMode, Workspace, WorkspaceEnvironment, WorkspaceEnvironmentVariableMetadata, WorkspaceEnvironmentVariableName, WorkspaceRegisteredPack, isClearedRunStateBlob, mergeResourceRefs, mergeToolRefs, paginated, reasoningEffortForMetadata, resourceIdentityKey, signDelegatedAccessToken, stableJson, verifyDelegatedAccessToken };
4508
+ export { AccessContext, AccessGrant, AccountGrant, AccountRole, AcknowledgeStreamRequest, AcknowledgeStreamResponse, AddDocumentRequest, AddWorkspaceMemberRequest, type AdmitRunInput, ApiKey, AttachViewerRequest, BillingBalance, BillingMode, CAPABILITY_DESCRIPTORS, CLEARED_RUN_STATE_BLOB, CLEARED_RUN_STATE_MARKER, CapabilityCatalogItem, CapabilityCatalogResponse, type CapabilityDescriptor, CapabilityInstallation, CapabilityInstallationStatus, CapabilityKind, CapabilityPack, CapabilityPackConnector, CapabilityPackConnectorAuthModel, CapabilityPackKnowledge, CapabilityPackScheduledTaskTemplate, CapabilityPackSkill, CapabilityPackSkillFile, CapabilityRuntime, CapabilitySource, CapabilityUnavailableReason, ClearSessionContextRequest, ClientAuthConfig, ClientConfig, ClientModel, ClientSessionEvent, CompactSessionContextRequest, CompactSessionContextResult, CompleteFileUploadResponse, type ConnectionCredentialsPort, CreateApiKeyRequest, CreateApiKeyResponse, CreateCapabilityCatalogItemRequest, CreateCheckoutRequest, CreateCheckoutResponse, CreateDocumentBaseRequest, CreateFileUploadRequest, CreateFileUploadResponse, CreateScheduledTaskRequest, CreateSessionRequest, CreateSocialConnectionRequest, CreateSocialPostRequest, CreateWorkspaceEnvironmentRequest, CreateWorkspaceRequest, DESKTOP_STREAM_PORT, DelegatedAccessTokenPayload, DeviceEnrollmentApproveRequest, DeviceEnrollmentApproveResponse, DeviceEnrollmentDenyRequest, DeviceEnrollmentDenyResponse, DeviceEnrollmentLookupMachine, DeviceEnrollmentLookupRequest, DeviceEnrollmentLookupResponse, DeviceEnrollmentPollRequest, DeviceEnrollmentPollResponse, DeviceEnrollmentStartRequest, DeviceEnrollmentStartResponse, DeviceEnrollmentState, DiscoverMcpCapabilitiesResponse, Document, DocumentBase, DocumentSearchRequest, DocumentSearchResult, DocumentStatus, EnableCapabilityRequest, EnablePackRequest, EnrollTokenExchangeRequest, EnrollTokenExchangeResponse, EnrollTokenPayload, EnrollmentArch, EnrollmentBearerPayload, EnrollmentCredentialsResponse, EnrollmentOs, EnrollmentSummary, EntitlementDecision, EntitlementValue, Entitlements, EntitlementsMode, type EntitlementsPort, ErrorCode, ErrorEnvelope, FileAsset, FileDownloadUrlResponse, FileResourceRef, FileStatus, FileUploadStatus, FsChangeKind, FsChangedPayload, FsDeleteRequest, FsDeleteResponse, FsEncoding, FsListRequest, FsListResponse, FsMkdirRequest, FsMkdirResponse, FsMoveRequest, FsMoveResponse, FsNodeType, FsReadRequest, FsReadResponse, FsTreeNode, FsWriteRequest, FsWriteResponse, GitChangedPayload, GitCommit, type GitCredentials, type GitCredentialsRequest, GitDiffHunk, GitDiffLine, GitDiffLineType, GitDiffRequest, GitDiffResponse, GitFileDiff, GitFileStatus, GitFileStatusCode, type GitHubAppApiPort, GitHubAppManifestCreate, type GitHubInstallationSummary, GitHubRepository, GitLogRequest, GitLogResponse, GitShowRequest, GitShowResponse, GitStatusRequest, GitStatusResponse, GoalSpec, type HealthResponse, LimitAction, LimitDecision, ListEnrollmentsResponse, ListWorkspaceMembersResponse, MachineKind, MachineMetricsSeriesResponse, MachineState, MachineView, MachinesResponse, ManagedAccount, MarketingDailyAnalysisTaskRequest, MetricSample, MintEnrollTokenRequest, MintEnrollTokenResponse, PackInstallation, PackInstallationStatus, PageInfo, Permission, type PortExposureKind, ProductAccessMode, PtyCloseRequest, PtyOpenRequest, PtyOpenResponse, PtyResizeRequest, PtyWriteRequest, ReasoningEffort, RecordingAvailablePayload, RecordingCodec, RecordingContentType, RecordingFailedPayload, RecordingFailedReason, RecordingMode, RecordingStartedPayload, RegisterCapabilityPackRequest, RelayTokenPayload, ReorderSessionTurnsRequest, RepositoryResourceRef, ResourceRef, ResourceRefConflictError, RevokeEnrollmentResponse, SandboxBackend, SandboxCapabilityName, SandboxCommandOutputDeltaPayload, SandboxOs, type SandboxSecrets, type SandboxSecretsRequest, ScheduledTask, ScheduledTaskAgentConfig, ScheduledTaskOverlapPolicy, ScheduledTaskRun, ScheduledTaskRunMode, ScheduledTaskRunStatus, ScheduledTaskScheduleSpec, ScheduledTaskStatus, ScheduledTaskTriggerType, Session, SessionBusMessage, SessionCapabilities, SessionEvent, SessionEventType, SessionGoal, SessionGoalCreatedBy, SessionGoalPausedReason, SessionGoalStatus, SessionStatus, SessionStructuredCapabilities, SessionTurn, SessionTurnSource, SessionTurnStatus, SetWorkspaceEnvironmentVariableRequest, SocialConnection, SocialConnectionStatus, SocialPost, SocialProvider, StaticUsageLimits, StreamClosedPayload, StreamOpenedPayload, StreamRevokedPayload, StreamTokenPayload, StreamUrlRotatedPayload, SwapActiveSandboxRequest, SwapActiveSandboxResponse, TERMINAL_STREAM_PORT, TerminalExecRequest, TerminalExecResponse, TerminalPtyExitedPayload, TerminalPtyOutputDeltaPayload, TerminalPtyStartedPayload, ToolRef, TriggerScheduledTaskRequest, UpdateScheduledTaskRequest, UpdateSessionGoalRequest, UpdateSessionRequest, UpdateSessionTurnRequest, UpdateWorkspaceEnvironmentRequest, UpdateWorkspaceMemberRequest, UpdateWorkspaceRequest, UsageEvent, UsageEventType, UsageLimitsMode, ViewerHeartbeatRequest, ViewerHeartbeatResponse, ViewerHolder, Workspace, WorkspaceEnvironment, WorkspaceEnvironmentVariableMetadata, WorkspaceEnvironmentVariableName, WorkspaceMember, WorkspaceRegisteredPack, isClearedRunStateBlob, mergeResourceRefs, mergeToolRefs, paginated, reasoningEffortForMetadata, resourceIdentityKey, signDelegatedAccessToken, signEnrollToken, signEnrollmentBearer, signRelayToken, signStreamToken, stableJson, verifyDelegatedAccessToken, verifyEnrollToken, verifyEnrollmentBearer, verifyRelayToken, verifyStreamToken };