@wjarka/cezarion 0.17.0-pr2391.3621 → 0.17.0-pr2396.3622

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (45) hide show
  1. package/dist/ci-wait/controller.d.ts +42 -42
  2. package/dist/contract/index.js +2 -7
  3. package/dist/contract/preview.d.ts +2 -9
  4. package/dist/delegation/routes.d.ts +77 -77
  5. package/dist/delegation/transport.d.ts +11 -11
  6. package/dist/preview/session.d.ts +3 -19
  7. package/dist/preview/session.js +25 -96
  8. package/dist/preview/session.js.map +1 -1
  9. package/dist/server/live-routes.d.ts +6 -6
  10. package/dist/server/server.d.ts +1231 -1231
  11. package/dist/voice/routes.d.ts +19 -19
  12. package/package.json +3 -3
  13. package/web/dist/assets/{agent-accounts-_aC68j-5.js → agent-accounts-CXUB94Nk.js} +1 -1
  14. package/web/dist/assets/{centered-state-BVBjQLQm.js → centered-state-rppISApp.js} +1 -1
  15. package/web/dist/assets/{commit-diff-panel-CquwF9pv.js → commit-diff-panel-BtXAsphd.js} +1 -1
  16. package/web/dist/assets/{diff-DZAxICzU2.js → diff-C_G-5ozx2.js} +2 -2
  17. package/web/dist/assets/{diff-controls-DpAFi2OG.js → diff-controls-veMEC_wZ.js} +1 -1
  18. package/web/dist/assets/{diff-view-Sx74D__f.js → diff-view-Ap7dGjJK.js} +1 -1
  19. package/web/dist/assets/{dropdown-menu-CHD9N0ti.js → dropdown-menu-C9tx2nTz.js} +3 -3
  20. package/web/dist/assets/{git-toolbar-B1ene046.js → git-toolbar-rG6DxhU4.js} +1 -1
  21. package/web/dist/assets/{github-MhKbeUXP.js → github-mkUHI_g6.js} +1 -1
  22. package/web/dist/assets/{github-sidebar-model-y_2P3Gq3.js → github-sidebar-model-B75WMpur.js} +1 -1
  23. package/web/dist/assets/{index-B8YVUAvv.js → index-COBiWqxh.js} +4 -4
  24. package/web/dist/assets/{popover-BG9maDeF.js → popover-BeKRpvPp.js} +1 -1
  25. package/web/dist/assets/preview-pane-connected-CyvLLKZZ.js +3 -0
  26. package/web/dist/assets/{reference-chip-BUTbjtH7.js → reference-chip-BPF__zTN.js} +1 -1
  27. package/web/dist/assets/{repo-git-BwkrUBrM.js → repo-git-BO51xvqQ.js} +1 -1
  28. package/web/dist/assets/{run-header-3IyqK0WG.js → run-header-CTSVePYj.js} +1 -1
  29. package/web/dist/assets/{skills-B61XRHmE.js → skills-BkfHLJei.js} +1 -1
  30. package/web/dist/assets/{status-dot-mUY8weo6.js → status-dot-CIG1okXN.js} +1 -1
  31. package/web/dist/assets/{tab-link-Cw-qvOgA.js → tab-link-C6ZFD3uU.js} +1 -1
  32. package/web/dist/assets/{task-changes-CRWsIgNm.js → task-changes-Ezm7fhfP.js} +1 -1
  33. package/web/dist/assets/{task-commits-_tCsqYWm.js → task-commits-TJnbOqhM.js} +1 -1
  34. package/web/dist/assets/{task-files-W8xWutR3.js → task-files-130LX6zW.js} +1 -1
  35. package/web/dist/assets/{task-github-item-_nZurwrZ.js → task-github-item-Bic5A6Th.js} +1 -1
  36. package/web/dist/assets/{task-thread-8xPCDj6J.js → task-thread-D6tdBMlg.js} +1 -1
  37. package/web/dist/assets/{textarea-DJr06oAl.js → textarea-BNHDI_mu.js} +1 -1
  38. package/web/dist/assets/{thread-state-D6p0lMua.js → thread-state-B5blI3Ly.js} +1 -1
  39. package/web/dist/assets/{use-hand-to-agent-state-DNtAv0k6.js → use-hand-to-agent-state-BfHlRUYr.js} +1 -1
  40. package/web/dist/assets/{workflows-DP9PRstR.js → workflows-BlwwAVqT.js} +1 -1
  41. package/web/dist/index.html +9 -9
  42. package/dist/preview/density.d.ts +0 -17
  43. package/dist/preview/density.js +0 -62
  44. package/dist/preview/density.js.map +0 -1
  45. package/web/dist/assets/preview-pane-connected-CnedlAUk.js +0 -3
@@ -85,12 +85,11 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
85
85
  "/api/v1/tools/wait": {
86
86
  $post: {
87
87
  output: {
88
- ok: false;
89
- code: "authentication" | "capability_revoked" | "capacity" | "command_failed" | "finish_requested" | "generation_mismatch" | "gh_missing" | "inaccessible_pr" | "invalid_request" | "malformed_data" | "manager_disposed" | "output_limit" | "persistence" | "query_timeout" | "registration_aborted" | "root_finish_pending" | "run_cancelled" | "run_missing" | "run_not_running" | "run_stopping" | "session_closed" | "session_replaced" | "turn_changed" | "unauthorized" | "unavailable" | "unsupported_host" | "wait_conflict" | "worker_execution_stopped" | "worker_wait_pending";
88
+ code: 'capability_revoked';
90
89
  message: string;
91
90
  };
92
91
  outputFormat: "json";
93
- status: import("hono/utils/http-status").ContentfulStatusCode;
92
+ status: 401;
94
93
  input: {
95
94
  json: {
96
95
  pr: string;
@@ -126,11 +125,12 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
126
125
  };
127
126
  } | {
128
127
  output: {
129
- code: 'capability_revoked';
128
+ ok: false;
129
+ code: "authentication" | "capability_revoked" | "capacity" | "command_failed" | "finish_requested" | "generation_mismatch" | "gh_missing" | "inaccessible_pr" | "invalid_request" | "malformed_data" | "manager_disposed" | "output_limit" | "persistence" | "query_timeout" | "registration_aborted" | "root_finish_pending" | "run_cancelled" | "run_missing" | "run_not_running" | "run_stopping" | "session_closed" | "session_replaced" | "turn_changed" | "unauthorized" | "unavailable" | "unsupported_host" | "wait_conflict" | "worker_execution_stopped" | "worker_wait_pending";
130
130
  message: string;
131
131
  };
132
132
  outputFormat: "json";
133
- status: 401;
133
+ status: import("hono/utils/http-status").ContentfulStatusCode;
134
134
  input: {
135
135
  json: {
136
136
  pr: string;
@@ -236,12 +236,11 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
236
236
  "/api/v1/tools/ask": {
237
237
  $post: {
238
238
  output: {
239
- ok: false;
240
- code: 'unavailable';
239
+ code: 'capability_revoked';
241
240
  message: string;
242
241
  };
243
242
  outputFormat: "json";
244
- status: import("hono/utils/http-status").ContentfulStatusCode;
243
+ status: 401;
245
244
  input: {
246
245
  json: {
247
246
  questions: {
@@ -259,11 +258,12 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
259
258
  };
260
259
  } | {
261
260
  output: {
262
- code: 'capability_revoked';
261
+ ok: false;
262
+ code: 'unavailable';
263
263
  message: string;
264
264
  };
265
265
  outputFormat: "json";
266
- status: 401;
266
+ status: import("hono/utils/http-status").ContentfulStatusCode;
267
267
  input: {
268
268
  json: {
269
269
  questions: {
@@ -331,12 +331,11 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
331
331
  "/api/v1/tools/cancel-wait": {
332
332
  $post: {
333
333
  output: {
334
- cancelled: false;
335
- code: 'unavailable';
334
+ code: 'capability_revoked';
336
335
  message: string;
337
336
  };
338
337
  outputFormat: "json";
339
- status: import("hono/utils/http-status").ContentfulStatusCode;
338
+ status: 401;
340
339
  input: {
341
340
  json: {
342
341
  wait_id: string;
@@ -344,11 +343,12 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
344
343
  };
345
344
  } | {
346
345
  output: {
347
- code: 'capability_revoked';
346
+ cancelled: false;
347
+ code: 'unavailable';
348
348
  message: string;
349
349
  };
350
350
  outputFormat: "json";
351
- status: 401;
351
+ status: import("hono/utils/http-status").ContentfulStatusCode;
352
352
  input: {
353
353
  json: {
354
354
  wait_id: string;
@@ -396,12 +396,11 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
396
396
  "/api/v1/tools/done": {
397
397
  $post: {
398
398
  output: {
399
- ok: false;
400
- code: 'unavailable';
399
+ code: 'capability_revoked';
401
400
  message: string;
402
401
  };
403
402
  outputFormat: "json";
404
- status: import("hono/utils/http-status").ContentfulStatusCode;
403
+ status: 401;
405
404
  input: {
406
405
  json: {
407
406
  summary?: string | undefined;
@@ -409,11 +408,12 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
409
408
  };
410
409
  } | {
411
410
  output: {
412
- code: 'capability_revoked';
411
+ ok: false;
412
+ code: 'unavailable';
413
413
  message: string;
414
414
  };
415
415
  outputFormat: "json";
416
- status: 401;
416
+ status: import("hono/utils/http-status").ContentfulStatusCode;
417
417
  input: {
418
418
  json: {
419
419
  summary?: string | undefined;
@@ -481,13 +481,11 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
481
481
  "/api/v1/tools/preview-stop": {
482
482
  $post: {
483
483
  output: {
484
- ok: boolean;
485
- code: "adopted" | "approval_required" | "headless" | "invalid_input" | "not_registered" | "port_held" | "port_in_use" | "preview_disabled" | "restarted" | "stopped" | "unavailable" | "worktree_missing";
484
+ code: 'capability_revoked';
486
485
  message: string;
487
- hint: string;
488
486
  };
489
487
  outputFormat: "json";
490
- status: import("hono/utils/http-status").ContentfulStatusCode;
488
+ status: 401;
491
489
  input: {
492
490
  json: {
493
491
  port: number;
@@ -496,11 +494,13 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
496
494
  };
497
495
  } | {
498
496
  output: {
499
- code: 'capability_revoked';
497
+ ok: boolean;
498
+ code: "adopted" | "approval_required" | "headless" | "invalid_input" | "not_registered" | "port_held" | "port_in_use" | "preview_disabled" | "restarted" | "stopped" | "unavailable" | "worktree_missing";
500
499
  message: string;
500
+ hint: string;
501
501
  };
502
502
  outputFormat: "json";
503
- status: 401;
503
+ status: import("hono/utils/http-status").ContentfulStatusCode;
504
504
  input: {
505
505
  json: {
506
506
  port: number;
@@ -513,13 +513,11 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
513
513
  "/api/v1/tools/preview-serve": {
514
514
  $post: {
515
515
  output: {
516
- ok: boolean;
517
- code: "cezar_port" | "cwd_outside_worktree" | "headless" | "invalid_input" | "port_held" | "preview_disabled" | "registered" | "replaced" | "too_many" | "unavailable" | "worktree_missing";
516
+ code: 'capability_revoked';
518
517
  message: string;
519
- hint: string;
520
518
  };
521
519
  outputFormat: "json";
522
- status: import("hono/utils/http-status").ContentfulStatusCode;
520
+ status: 401;
523
521
  input: {
524
522
  json: {
525
523
  command: string;
@@ -531,11 +529,13 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
531
529
  };
532
530
  } | {
533
531
  output: {
534
- code: 'capability_revoked';
532
+ ok: boolean;
533
+ code: "cezar_port" | "cwd_outside_worktree" | "headless" | "invalid_input" | "port_held" | "preview_disabled" | "registered" | "replaced" | "too_many" | "unavailable" | "worktree_missing";
535
534
  message: string;
535
+ hint: string;
536
536
  };
537
537
  outputFormat: "json";
538
- status: 401;
538
+ status: import("hono/utils/http-status").ContentfulStatusCode;
539
539
  input: {
540
540
  json: {
541
541
  command: string;
@@ -551,12 +551,11 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
551
551
  "/api/v1/tools/schedule-task": {
552
552
  $post: {
553
553
  output: {
554
- ok: false;
555
- code: import('../contract/index.js').ScheduledTaskRefusalCode;
554
+ code: 'capability_revoked';
556
555
  message: string;
557
556
  };
558
557
  outputFormat: "json";
559
- status: import("hono/utils/http-status").ContentfulStatusCode;
558
+ status: 401;
560
559
  input: {
561
560
  json: {
562
561
  at?: string | undefined;
@@ -574,11 +573,12 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
574
573
  };
575
574
  } | {
576
575
  output: {
577
- code: 'capability_revoked';
576
+ ok: false;
577
+ code: import('../contract/index.js').ScheduledTaskRefusalCode;
578
578
  message: string;
579
579
  };
580
580
  outputFormat: "json";
581
- status: 401;
581
+ status: import("hono/utils/http-status").ContentfulStatusCode;
582
582
  input: {
583
583
  json: {
584
584
  at?: string | undefined;
@@ -637,12 +637,11 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
637
637
  "/api/v1/tools/scheduled-tasks": {
638
638
  $post: {
639
639
  output: {
640
- ok: false;
641
- code: import('../contract/index.js').ScheduledTaskRefusalCode;
640
+ code: 'capability_revoked';
642
641
  message: string;
643
642
  };
644
643
  outputFormat: "json";
645
- status: import("hono/utils/http-status").ContentfulStatusCode;
644
+ status: 401;
646
645
  input: {
647
646
  json: {
648
647
  at?: string | undefined;
@@ -676,11 +675,12 @@ export declare function ciToolRoutes(capabilities: Map<string, Capability>): imp
676
675
  };
677
676
  } | {
678
677
  output: {
679
- code: 'capability_revoked';
678
+ ok: false;
679
+ code: import('../contract/index.js').ScheduledTaskRefusalCode;
680
680
  message: string;
681
681
  };
682
682
  outputFormat: "json";
683
- status: 401;
683
+ status: import("hono/utils/http-status").ContentfulStatusCode;
684
684
  input: {
685
685
  json: {
686
686
  at?: string | undefined;
@@ -1495,9 +1495,7 @@ var previewAgentBrowserEventSchema = z13.object({
1495
1495
  });
1496
1496
  var port = z13.number().int().min(1).max(65535);
1497
1497
  var clampViewport = (value) => Math.min(4e3, Math.max(100, Math.round(value)));
1498
- var PREVIEW_MAX_PIXEL_RATIO = 2;
1499
- var clampPixelRatio = (value) => Math.min(PREVIEW_MAX_PIXEL_RATIO, Math.max(1, value));
1500
- var previewQualitySchema = z13.enum(["normal", "high", "ultra"]);
1498
+ var previewQualitySchema = z13.enum(["normal", "high"]);
1501
1499
  var previewMouseTypeSchema = z13.enum(["mousePressed", "mouseReleased", "mouseMoved", "mouseWheel"]);
1502
1500
  var previewMouseButtonSchema = z13.enum(["left", "middle", "right", "none"]);
1503
1501
  var previewKeyTypeSchema = z13.enum(["keyDown", "rawKeyDown", "keyUp"]);
@@ -1522,9 +1520,7 @@ var previewClientMessageSchema = z13.discriminatedUnion("t", [
1522
1520
  z13.object({
1523
1521
  t: z13.literal("resize"),
1524
1522
  w: z13.number().finite().transform(clampViewport),
1525
- h: z13.number().finite().transform(clampViewport),
1526
- /** The viewer's `devicePixelRatio`, read only in `ultra`. Absent from an older cockpit, which means 1. */
1527
- dpr: z13.number().finite().transform(clampPixelRatio).optional()
1523
+ h: z13.number().finite().transform(clampViewport)
1528
1524
  }),
1529
1525
  z13.object({
1530
1526
  t: z13.literal("mouse"),
@@ -5567,7 +5563,6 @@ export {
5567
5563
  PARALLEL_VARIANTS_REMOVED,
5568
5564
  PEER_WAIT_DEFAULT_SECONDS,
5569
5565
  PEER_WAIT_MAX_SECONDS,
5570
- PREVIEW_MAX_PIXEL_RATIO,
5571
5566
  PROCESS_EXIT_FILE_MAX,
5572
5567
  PROCESS_TIMEOUT_DEFAULT_SECONDS,
5573
5568
  PROCESS_TIMEOUT_MAX_SECONDS,
@@ -112,17 +112,13 @@ export declare const previewAgentBrowserEventSchema: z.ZodObject<{
112
112
  }>;
113
113
  }, z.core.$strip>;
114
114
  export type PreviewAgentBrowserEvent = z.infer<typeof previewAgentBrowserEventSchema>;
115
- /** The highest pixel ratio Ultra renders at (hearsay-tools/cezarion#2069): 2 keeps a frame at four times the pixels. */
116
- export declare const PREVIEW_MAX_PIXEL_RATIO = 2;
117
115
  /**
118
- * The stream's mode. `normal` is the original JPEG quality 60; `high` is quality 100, still lossy
119
- * JPEG (hearsay-tools/cezarion#2066). Both render one page pixel per CSS pixel. `ultra` is quality
120
- * 100 at the viewer's pixel ratio, capped at `PREVIEW_MAX_PIXEL_RATIO` (hearsay-tools/cezarion#2069).
116
+ * The stream's JPEG quality (hearsay-tools/cezarion#2066). `normal` is the original quality 60;
117
+ * `high` is quality 100, still lossy JPEG. Neither changes the page's pixel density.
121
118
  */
122
119
  export declare const previewQualitySchema: z.ZodEnum<{
123
120
  high: "high";
124
121
  normal: "normal";
125
- ultra: "ultra";
126
122
  }>;
127
123
  export type PreviewQuality = z.infer<typeof previewQualitySchema>;
128
124
  /** Mouse and key vocabularies are the prototype's: CDP's own names, nothing else gets through. */
@@ -158,14 +154,12 @@ export declare const previewClientMessageSchema: z.ZodDiscriminatedUnion<[z.ZodO
158
154
  quality: z.ZodOptional<z.ZodEnum<{
159
155
  high: "high";
160
156
  normal: "normal";
161
- ultra: "ultra";
162
157
  }>>;
163
158
  }, z.core.$strip>, z.ZodObject<{
164
159
  t: z.ZodLiteral<"quality">;
165
160
  quality: z.ZodEnum<{
166
161
  high: "high";
167
162
  normal: "normal";
168
- ultra: "ultra";
169
163
  }>;
170
164
  }, z.core.$strip>, z.ZodObject<{
171
165
  t: z.ZodLiteral<"run">;
@@ -180,7 +174,6 @@ export declare const previewClientMessageSchema: z.ZodDiscriminatedUnion<[z.ZodO
180
174
  t: z.ZodLiteral<"resize">;
181
175
  w: z.ZodPipe<z.ZodNumber, z.ZodTransform<number, number>>;
182
176
  h: z.ZodPipe<z.ZodNumber, z.ZodTransform<number, number>>;
183
- dpr: z.ZodOptional<z.ZodPipe<z.ZodNumber, z.ZodTransform<number, number>>>;
184
177
  }, z.core.$strip>, z.ZodObject<{
185
178
  t: z.ZodLiteral<"mouse">;
186
179
  type: z.ZodEnum<{
@@ -27,18 +27,6 @@ export declare function delegationFailure(error: unknown): {
27
27
  export declare function createDelegationRoutes(service: DelegationService, credentials: CredentialRegistry): import("hono/hono-base").HonoBase<Env, {
28
28
  "/list": {
29
29
  $get: {
30
- output: {
31
- error: string;
32
- code?: "invalid_input" | undefined;
33
- };
34
- outputFormat: "json";
35
- status: 400;
36
- input: {
37
- query: {
38
- offset?: string | undefined;
39
- };
40
- };
41
- } | {
42
30
  output: {
43
31
  workers: {
44
32
  workerId: string;
@@ -76,23 +64,24 @@ export declare function createDelegationRoutes(service: DelegationService, crede
76
64
  offset?: string | undefined;
77
65
  };
78
66
  };
67
+ } | {
68
+ output: {
69
+ error: string;
70
+ code?: "invalid_input" | undefined;
71
+ };
72
+ outputFormat: "json";
73
+ status: 400;
74
+ input: {
75
+ query: {
76
+ offset?: string | undefined;
77
+ };
78
+ };
79
79
  };
80
80
  };
81
81
  } & {
82
82
  "/discover": {
83
83
  $post: {
84
84
  output: {
85
- runner: "claude" | "codex" | "cursor" | "omp" | "opencode" | "pi";
86
- models: {
87
- id: string;
88
- label: string;
89
- description: string;
90
- effortLevels?: ("high" | "low" | "max" | "medium" | "xhigh")[] | undefined;
91
- }[];
92
- source: "cache" | "live" | "unavailable";
93
- stale: boolean;
94
- reason?: string | undefined;
95
- } | {
96
85
  tasks: {
97
86
  id: string;
98
87
  title: string;
@@ -113,6 +102,17 @@ export declare function createDelegationRoutes(service: DelegationService, crede
113
102
  authFailureId?: string | undefined;
114
103
  runner: "claude" | "codex" | "cursor" | "omp" | "opencode" | "pi";
115
104
  }[];
105
+ } | {
106
+ runner: "claude" | "codex" | "cursor" | "omp" | "opencode" | "pi";
107
+ models: {
108
+ id: string;
109
+ label: string;
110
+ description: string;
111
+ effortLevels?: ("high" | "low" | "max" | "medium" | "xhigh")[] | undefined;
112
+ }[];
113
+ source: "cache" | "live" | "unavailable";
114
+ stale: boolean;
115
+ reason?: string | undefined;
116
116
  };
117
117
  outputFormat: "json";
118
118
  status: 200;
@@ -221,13 +221,13 @@ export declare function createDelegationRoutes(service: DelegationService, crede
221
221
  status: 200;
222
222
  input: {
223
223
  json: {
224
- workerIds: string[];
225
- timeoutSeconds?: number | undefined;
226
- mode?: "all" | "any" | "one" | undefined;
227
- } | {
228
224
  requestIds: string[];
229
225
  mode?: "all" | "any" | "one" | undefined;
230
226
  timeoutSeconds?: number | undefined;
227
+ } | {
228
+ workerIds: string[];
229
+ timeoutSeconds?: number | undefined;
230
+ mode?: "all" | "any" | "one" | undefined;
231
231
  } | {
232
232
  peerIds: string[];
233
233
  timeoutSeconds?: number | undefined;
@@ -610,18 +610,6 @@ export declare function createDelegationRoutes(service: DelegationService, crede
610
610
  } & {
611
611
  "/:workerId": {
612
612
  $get: {
613
- output: {
614
- error: string;
615
- code?: "invalid_input" | undefined;
616
- };
617
- outputFormat: "json";
618
- status: 400;
619
- input: {
620
- param: {
621
- workerId: string;
622
- };
623
- };
624
- } | {
625
613
  output: {
626
614
  workerId: string;
627
615
  parentRunId: string;
@@ -725,11 +713,7 @@ export declare function createDelegationRoutes(service: DelegationService, crede
725
713
  workerId: string;
726
714
  };
727
715
  };
728
- };
729
- };
730
- } & {
731
- "/:workerId/collect": {
732
- $post: {
716
+ } | {
733
717
  output: {
734
718
  error: string;
735
719
  code?: "invalid_input" | undefined;
@@ -740,10 +724,12 @@ export declare function createDelegationRoutes(service: DelegationService, crede
740
724
  param: {
741
725
  workerId: string;
742
726
  };
743
- } & {
744
- json: Record<string, never>;
745
727
  };
746
- } | {
728
+ };
729
+ };
730
+ } & {
731
+ "/:workerId/collect": {
732
+ $post: {
747
733
  output: {
748
734
  workerId: string;
749
735
  parentRunId: string;
@@ -845,11 +831,7 @@ export declare function createDelegationRoutes(service: DelegationService, crede
845
831
  } & {
846
832
  json: Record<string, never>;
847
833
  };
848
- };
849
- };
850
- } & {
851
- "/:workerId/steer": {
852
- $post: {
834
+ } | {
853
835
  output: {
854
836
  error: string;
855
837
  code?: "invalid_input" | undefined;
@@ -861,11 +843,13 @@ export declare function createDelegationRoutes(service: DelegationService, crede
861
843
  workerId: string;
862
844
  };
863
845
  } & {
864
- json: {
865
- text: string;
866
- };
846
+ json: Record<string, never>;
867
847
  };
868
- } | {
848
+ };
849
+ };
850
+ } & {
851
+ "/:workerId/steer": {
852
+ $post: {
869
853
  output: {
870
854
  workerId: string;
871
855
  state: "delivered" | "queued";
@@ -881,11 +865,7 @@ export declare function createDelegationRoutes(service: DelegationService, crede
881
865
  text: string;
882
866
  };
883
867
  };
884
- };
885
- };
886
- } & {
887
- "/:workerId/stop": {
888
- $post: {
868
+ } | {
889
869
  output: {
890
870
  error: string;
891
871
  code?: "invalid_input" | undefined;
@@ -897,9 +877,15 @@ export declare function createDelegationRoutes(service: DelegationService, crede
897
877
  workerId: string;
898
878
  };
899
879
  } & {
900
- json: Record<string, never>;
880
+ json: {
881
+ text: string;
882
+ };
901
883
  };
902
- } | {
884
+ };
885
+ };
886
+ } & {
887
+ "/:workerId/stop": {
888
+ $post: {
903
889
  output: {
904
890
  workerId: string;
905
891
  state: "stopping" | "terminated";
@@ -913,11 +899,7 @@ export declare function createDelegationRoutes(service: DelegationService, crede
913
899
  } & {
914
900
  json: Record<string, never>;
915
901
  };
916
- };
917
- };
918
- } & {
919
- "/:workerId/destroy": {
920
- $post: {
902
+ } | {
921
903
  output: {
922
904
  error: string;
923
905
  code?: "invalid_input" | undefined;
@@ -931,7 +913,11 @@ export declare function createDelegationRoutes(service: DelegationService, crede
931
913
  } & {
932
914
  json: Record<string, never>;
933
915
  };
934
- } | {
916
+ };
917
+ };
918
+ } & {
919
+ "/:workerId/destroy": {
920
+ $post: {
935
921
  output: {
936
922
  workerId: string;
937
923
  state: "complete" | "incomplete";
@@ -954,6 +940,20 @@ export declare function createDelegationRoutes(service: DelegationService, crede
954
940
  } & {
955
941
  json: Record<string, never>;
956
942
  };
943
+ } | {
944
+ output: {
945
+ error: string;
946
+ code?: "invalid_input" | undefined;
947
+ };
948
+ outputFormat: "json";
949
+ status: 400;
950
+ input: {
951
+ param: {
952
+ workerId: string;
953
+ };
954
+ } & {
955
+ json: Record<string, never>;
956
+ };
957
957
  } | {
958
958
  output: {
959
959
  workerId: string;
@@ -983,11 +983,13 @@ export declare function createDelegationRoutes(service: DelegationService, crede
983
983
  "/:workerId/diff": {
984
984
  $get: {
985
985
  output: {
986
- error: string;
987
- code?: "invalid_input" | undefined;
986
+ workerId: string;
987
+ baselineSha: string;
988
+ diff: string;
989
+ truncated: boolean;
988
990
  };
989
991
  outputFormat: "json";
990
- status: 400;
992
+ status: 200;
991
993
  input: {
992
994
  param: {
993
995
  workerId: string;
@@ -995,13 +997,11 @@ export declare function createDelegationRoutes(service: DelegationService, crede
995
997
  };
996
998
  } | {
997
999
  output: {
998
- workerId: string;
999
- baselineSha: string;
1000
- diff: string;
1001
- truncated: boolean;
1000
+ error: string;
1001
+ code?: "invalid_input" | undefined;
1002
1002
  };
1003
1003
  outputFormat: "json";
1004
- status: 200;
1004
+ status: 400;
1005
1005
  input: {
1006
1006
  param: {
1007
1007
  workerId: string;
@@ -57,6 +57,17 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
57
57
  "/discover": {
58
58
  $post: {
59
59
  output: {
60
+ runner: "claude" | "codex" | "cursor" | "omp" | "opencode" | "pi";
61
+ models: {
62
+ id: string;
63
+ label: string;
64
+ description: string;
65
+ effortLevels?: ("high" | "low" | "max" | "medium" | "xhigh")[] | undefined;
66
+ }[];
67
+ source: "cache" | "live" | "unavailable";
68
+ stale: boolean;
69
+ reason?: string | undefined;
70
+ } | {
60
71
  scope: "host-default-account";
61
72
  runners: {
62
73
  status: "connected" | "disconnected" | "not-installed" | "unknown";
@@ -77,17 +88,6 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
77
88
  reason?: string | undefined;
78
89
  }[];
79
90
  nextOffset?: number | undefined;
80
- } | {
81
- runner: "claude" | "codex" | "cursor" | "omp" | "opencode" | "pi";
82
- models: {
83
- id: string;
84
- label: string;
85
- description: string;
86
- effortLevels?: ("high" | "low" | "max" | "medium" | "xhigh")[] | undefined;
87
- }[];
88
- source: "cache" | "live" | "unavailable";
89
- stale: boolean;
90
- reason?: string | undefined;
91
91
  };
92
92
  outputFormat: "json";
93
93
  status: 200;
@@ -35,15 +35,9 @@ export declare class PreviewSession {
35
35
  private held?;
36
36
  private announced;
37
37
  private viewport;
38
- private readonly density;
39
- /** The device scale factor the page renders at now. */
40
- private rendered;
41
38
  /** Viewport changes and screencast stops run one at a time: overlapping stop/start pairs can leave Chromium without a first frame. */
42
39
  private queue;
43
- /**
44
- * The size and mode the running screencast was started at; unset while stopped. `scale` is the
45
- * pixel ratio asked for, `rendered` the one Chromium renders at: frames are `rendered` times the size.
46
- */
40
+ /** The size and mode the running screencast was started at; unset while stopped. */
47
41
  private streaming?;
48
42
  private watchdog?;
49
43
  private silentStarts;
@@ -57,27 +51,17 @@ export declare class PreviewSession {
57
51
  /** Makes `viewer` the one the page streams to and starts the screencast at the current viewport. */
58
52
  attach(viewer: Viewer): void;
59
53
  detach(viewer: Viewer): void;
60
- /** Ultra's density lasts while a viewer watches: with none, the page goes back to scale 1, at the same CSS size. */
61
- private leaveDensity;
62
54
  /**
63
55
  * The chosen mode changed: a running stream restarts at it, at the same size. The page is not
64
- * navigated or reloaded, so its URL, form state and scroll stay. A change of pixel density (to or
65
- * from Ultra) also moves the window and renders the page at the new ratio. A stream that is not
66
- * running picks the mode up at its next start.
56
+ * touched (no navigation, no new viewport), so its URL, form state and scroll stay. A stream that
57
+ * is not running picks the mode up at its next start.
67
58
  */
68
59
  refreshQuality(): Promise<void>;
69
60
  navigate(url: string): Promise<void>;
70
- /**
71
- * Closes the page session. The window position outlives it (screens belong to the browser), so a
72
- * page Ultra moved goes back to the primary screen first. The close waits behind viewport work
73
- * already queued: a first Ultra resize still waiting on Chromium has not recorded its ratio yet,
74
- * and would otherwise move the window after the connection closed. At scale 1 nothing moves.
75
- */
76
61
  close(): void;
77
62
  /** The whole browser-facing surface. Everything else in CDP stays unreachable. */
78
63
  handle(msg: PreviewClientMessage): Promise<void>;
79
64
  private enqueue;
80
- /** `dpr` is the viewer's pixel ratio; an older cockpit sends none, and streams at 1 as before. */
81
65
  private setViewport;
82
66
  private quality;
83
67
  private applyViewport;