@hearsay-tools/squawk 0.19.0-pr4599.9140 → 0.19.0-pr4601.9144
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/contract/hosts.d.ts +254 -0
- package/dist/contract/index.js +35 -0
- package/dist/core/http-route-registry.d.ts +7 -4
- package/dist/core/http-route-registry.js +6 -0
- package/dist/core/http-route-registry.js.map +1 -1
- package/dist/delegation/transport.d.ts +78 -78
- package/dist/features/automations/automations-routes.d.ts +150 -150
- package/dist/features/automations/server-plugin.js.map +1 -1
- package/dist/features/hosts/bootstrap.d.ts +1 -0
- package/dist/features/hosts/bootstrap.js +18 -6
- package/dist/features/hosts/bootstrap.js.map +1 -1
- package/dist/features/hosts/gateway-routes.d.ts +14 -0
- package/dist/features/hosts/gateway-routes.js +20 -0
- package/dist/features/hosts/gateway-routes.js.map +1 -0
- package/dist/features/hosts/gateway.d.ts +105 -0
- package/dist/features/hosts/gateway.js +800 -0
- package/dist/features/hosts/gateway.js.map +1 -0
- package/dist/features/hosts/index.d.ts +7 -1
- package/dist/features/hosts/index.js +23 -16
- package/dist/features/hosts/index.js.map +1 -1
- package/dist/features/hosts/routes.d.ts +91 -2
- package/dist/features/hosts/routes.js +142 -11
- package/dist/features/hosts/routes.js.map +1 -1
- package/dist/features/hosts/supervisor.d.ts +22 -8
- package/dist/features/hosts/supervisor.js +94 -37
- package/dist/features/hosts/supervisor.js.map +1 -1
- package/dist/features/webhooks/server-plugin.js.map +1 -1
- package/dist/plugin/index.d.ts +1 -1
- package/dist/plugin/index.js.map +1 -1
- package/dist/server/checkout.d.ts +10 -0
- package/dist/server/checkout.js +1 -1
- package/dist/server/checkout.js.map +1 -1
- package/dist/server/create-project.d.ts +6 -0
- package/dist/server/create-project.js +1 -1
- package/dist/server/create-project.js.map +1 -1
- package/dist/server/plugin-http-routes.d.ts +18 -6
- package/dist/server/plugin-http-routes.js +30 -14
- package/dist/server/plugin-http-routes.js.map +1 -1
- package/dist/server/project-settings-routes.d.ts +107 -107
- package/dist/server/provider-sign-in-routes.d.ts +2 -2
- package/dist/server/repo-routes.d.ts +52 -52
- package/dist/server/runner-install-routes.d.ts +10 -10
- package/dist/server/server.d.ts +1170 -1170
- package/dist/server/server.js +10 -8
- package/dist/server/server.js.map +1 -1
- package/dist/server/workspace-identity-routes.d.ts +5 -5
- package/package.json +4 -4
- package/web/dist/assets/{accounts-section-BXIfRpqn.js → accounts-section-BsgnDmow.js} +1 -1
- package/web/dist/assets/{activity-motion-CiMnzmaL.js → activity-motion-Ckq9kC3I.js} +1 -1
- package/web/dist/assets/{activity-route-7rgwez-p.js → activity-route-5S9WhN9U.js} +1 -1
- package/web/dist/assets/{agent-config-section-D35Gh915.js → agent-config-section-D8pxNy2V.js} +1 -1
- package/web/dist/assets/{agent-defaults-section-qela9Lh0.js → agent-defaults-section-et5LHv9W.js} +1 -1
- package/web/dist/assets/{appearance-PSBR-L16.js → appearance-D_t3wCjY.js} +1 -1
- package/web/dist/assets/{archive-on-merge-field-BJFWDQ73.js → archive-on-merge-field-C63xRNFZ.js} +1 -1
- package/web/dist/assets/ask-card-kqWOqKIc.js +9 -0
- package/web/dist/assets/{automations-route-DvhHg4fm.js → automations-route-B5YBpGMc.js} +1 -1
- package/web/dist/assets/{commit-list-DebGaysy.js → commit-list-Bjc-pQxv.js} +1 -1
- package/web/dist/assets/{diff-controls-BBgyFS1R.js → diff-controls-CaCUSyxs.js} +1 -1
- package/web/dist/assets/{diff-BSfVn71B.js → diff-lwWO-At7.js} +2 -2
- package/web/dist/assets/{diff-view-CmGMWIlZ.js → diff-view-4wxDvYXE.js} +1 -1
- package/web/dist/assets/{discard-changes-dialog-C6sD9mz8.js → discard-changes-dialog-B3gvm7lX.js} +1 -1
- package/web/dist/assets/{file-preview-Clm9psfR.js → file-preview-98pJhZJj.js} +1 -1
- package/web/dist/assets/{git-toolbar-G_q1J1Qo.js → git-toolbar-CepvG0Ng.js} +1 -1
- package/web/dist/assets/{github-S25ca8_M.js → github-4Jhl7lLG.js} +1 -1
- package/web/dist/assets/{global-activity-route-C6wsa2VH.js → global-activity-route-DhmrWj31.js} +1 -1
- package/web/dist/assets/index-BK1FcZrA.css +1 -0
- package/web/dist/assets/{index-n7br_LJj.js → index-DJB0lid-.js} +4 -4
- package/web/dist/assets/{markdown-DBTrMXVS.js → markdown-BAPhDASs.js} +1 -1
- package/web/dist/assets/{option-select-lxOL23-m.js → option-select-BwSkbCrQ.js} +1 -1
- package/web/dist/assets/{preferences-section-BjUffanB.js → preferences-section-Cvh644K0.js} +1 -1
- package/web/dist/assets/{preview-pane-connected-DzT-ebVU.js → preview-pane-connected-B08ZdGux.js} +1 -1
- package/web/dist/assets/{project-location-BEdaj_mZ.js → project-location-DR8go8oL.js} +1 -1
- package/web/dist/assets/{projects-section-DBfKeeqR.js → projects-section-XDboHBFP.js} +1 -1
- package/web/dist/assets/{prompt-templates-section-D7SvCECE.js → prompt-templates-section-DcxD28iA.js} +1 -1
- package/web/dist/assets/{remote-settings-notice-BFW5hckZ.js → remote-settings-notice-Dtaa3ovl.js} +1 -1
- package/web/dist/assets/{repo-git-DufonnxZ.js → repo-git-Dp9R2TuI.js} +1 -1
- package/web/dist/assets/{report-reader-BNeaSf9l.js → report-reader-mbkd2DKt.js} +1 -1
- package/web/dist/assets/{reports-Dg96OgK_.js → reports-ya2OW-iR.js} +1 -1
- package/web/dist/assets/{resources-section-mlWGic7N.js → resources-section-g5XRlefz.js} +1 -1
- package/web/dist/assets/{review-notes-drafts-B8XEe0To.js → review-notes-drafts-BdBvLP6E.js} +1 -1
- package/web/dist/assets/{review-panel-DeGoLgcB.js → review-panel-Ba8yb8Fu.js} +1 -1
- package/web/dist/assets/{review-strip-B0dxLGVX.js → review-strip-CdlMeV2i.js} +1 -1
- package/web/dist/assets/{run-header-CO7X2ksL.js → run-header-BTRXYB4W.js} +1 -1
- package/web/dist/assets/{select-BCP0bQL_.js → select-DdH25sWT.js} +1 -1
- package/web/dist/assets/{session-context-section-DNHeVwaW.js → session-context-section-BqEdLdTv.js} +1 -1
- package/web/dist/assets/{settings-agent-picker-DpNZjBNf.js → settings-agent-picker-b4M6fQ8m.js} +1 -1
- package/web/dist/assets/{settings-save-bar-DTuXtrOh.js → settings-save-bar-DFY_Km4X.js} +1 -1
- package/web/dist/assets/{settings-shell-DA8Ljpv9.js → settings-shell-BUwdvhI9.js} +1 -1
- package/web/dist/assets/{sidebar-section-CXPEyE4l.js → sidebar-section-CcucfASN.js} +1 -1
- package/web/dist/assets/{skills-CNCCc6b5.js → skills-BLkPhZO8.js} +1 -1
- package/web/dist/assets/{task-changes-BIdArX0Y.js → task-changes-Drvnew5P.js} +1 -1
- package/web/dist/assets/{task-commits-BMEqcu53.js → task-commits-1MJHuX1i.js} +1 -1
- package/web/dist/assets/{task-file-scope-DHm_aCX9.js → task-file-scope-CB3L3KQl.js} +1 -1
- package/web/dist/assets/{task-files-Dmc9mysp.js → task-files-B9okW1TC.js} +1 -1
- package/web/dist/assets/{task-github-item-BVQHPtmd.js → task-github-item-CMNk7FxR.js} +1 -1
- package/web/dist/assets/task-thread-_2ch8BRt.js +2 -0
- package/web/dist/assets/{task-thread-BObu0KsD.css → task-thread-a6CXLxwn.css} +1 -1
- package/web/dist/assets/{thread-state-qIdHMY4r.js → thread-state-qNczqxZQ.js} +1 -1
- package/web/dist/assets/{use-finish-run-BRlt2Xcp.js → use-finish-run-Dvm4JnAH.js} +1 -1
- package/web/dist/assets/{use-hand-to-agent-state-DA5WLXGY.js → use-hand-to-agent-state-CBJvP-US.js} +1 -1
- package/web/dist/assets/use-path-bases-C9yvZF5B.js +1 -0
- package/web/dist/assets/{workflows-BGZZkVU_.js → workflows-BUcx-n8J.js} +1 -1
- package/web/dist/assets/{workspace-tools-DIcwDrFd.js → workspace-tools-dbiR1fzO.js} +1 -1
- package/web/dist/assets/{worktrees-section-BTKs5R9c.js → worktrees-section-Dyb_QkSd.js} +1 -1
- package/web/dist/index.html +2 -2
- package/web/dist/assets/ask-card-BOsa7Rhk.js +0 -9
- package/web/dist/assets/index-QckSsk-V.css +0 -1
- package/web/dist/assets/task-thread-DonhRFPP.js +0 -2
- package/web/dist/assets/use-path-bases-DJciTjQE.js +0 -1
package/dist/contract/hosts.d.ts
CHANGED
|
@@ -342,3 +342,257 @@ export declare const hostServerActiveTasksResultSchema: z.ZodObject<{
|
|
|
342
342
|
activeCount: z.ZodNumber;
|
|
343
343
|
}, z.core.$strip>;
|
|
344
344
|
export type HostServerActiveTasksResult = z.infer<typeof hostServerActiveTasksResultSchema>;
|
|
345
|
+
/**
|
|
346
|
+
* Machine-readable error codes returned by the main server's host gateway
|
|
347
|
+
* (`ALL /api/v1/hosts/:hostId/api/v1/*`, spec § Architecture 3 & § 6, hearsay-tools/squawk#4540).
|
|
348
|
+
*/
|
|
349
|
+
export declare const HOST_GATEWAY_ERROR_CODES: readonly ['host-unreachable', 'host-version-mismatch', 'host-not-hosted', 'host-identity-changed', 'host-several-servers', 'host-paused', 'host-upgrade-unsupported', 'host-unexpected-redirect', 'host-nested-gateway-unsupported'];
|
|
350
|
+
export declare const hostGatewayErrorCodeSchema: z.ZodEnum<{
|
|
351
|
+
"host-identity-changed": "host-identity-changed";
|
|
352
|
+
"host-nested-gateway-unsupported": "host-nested-gateway-unsupported";
|
|
353
|
+
"host-not-hosted": "host-not-hosted";
|
|
354
|
+
"host-paused": "host-paused";
|
|
355
|
+
"host-several-servers": "host-several-servers";
|
|
356
|
+
"host-unexpected-redirect": "host-unexpected-redirect";
|
|
357
|
+
"host-unreachable": "host-unreachable";
|
|
358
|
+
"host-upgrade-unsupported": "host-upgrade-unsupported";
|
|
359
|
+
"host-version-mismatch": "host-version-mismatch";
|
|
360
|
+
}>;
|
|
361
|
+
export type HostGatewayErrorCode = z.infer<typeof hostGatewayErrorCodeSchema>;
|
|
362
|
+
/** Error body returned by the host gateway on 400 / 409 / 502 refusals and the 404 nested-gateway refusal (`host-nested-gateway-unsupported`). */
|
|
363
|
+
export declare const hostGatewayErrorResponseSchema: z.ZodObject<{
|
|
364
|
+
code: z.ZodEnum<{
|
|
365
|
+
"host-identity-changed": "host-identity-changed";
|
|
366
|
+
"host-nested-gateway-unsupported": "host-nested-gateway-unsupported";
|
|
367
|
+
"host-not-hosted": "host-not-hosted";
|
|
368
|
+
"host-paused": "host-paused";
|
|
369
|
+
"host-several-servers": "host-several-servers";
|
|
370
|
+
"host-unexpected-redirect": "host-unexpected-redirect";
|
|
371
|
+
"host-unreachable": "host-unreachable";
|
|
372
|
+
"host-upgrade-unsupported": "host-upgrade-unsupported";
|
|
373
|
+
"host-version-mismatch": "host-version-mismatch";
|
|
374
|
+
}>;
|
|
375
|
+
error: z.ZodString;
|
|
376
|
+
}, z.core.$strip>;
|
|
377
|
+
export type HostGatewayErrorResponse = z.infer<typeof hostGatewayErrorResponseSchema>;
|
|
378
|
+
/**
|
|
379
|
+
* Per-host project listing in `GET /api/v1/hosts/projects` (spec § Architecture 4,
|
|
380
|
+
* hearsay-tools/squawk#4540). Every session may read it, so it carries ONLY `id`, `label`,
|
|
381
|
+
* `state`, and `projects` (never `reason`, `sshAlias`, or other admin-only host fields).
|
|
382
|
+
*
|
|
383
|
+
* `projects` is:
|
|
384
|
+
* - `[...]` when the host is connected and its project list was read (`[]` = no projects),
|
|
385
|
+
* - `[]` when the host is not connected,
|
|
386
|
+
* - `null` when the host was connected but reading its projects failed (timeout, non-2xx,
|
|
387
|
+
* malformed JSON, or response > 1 MiB), so the rail can distinguish "no projects" from
|
|
388
|
+
* "could not read".
|
|
389
|
+
*/
|
|
390
|
+
export declare const hostProjectsEntrySchema: z.ZodObject<{
|
|
391
|
+
id: z.ZodString;
|
|
392
|
+
label: z.ZodString;
|
|
393
|
+
state: z.ZodEnum<{
|
|
394
|
+
"cannot-persist": "cannot-persist";
|
|
395
|
+
connected: "connected";
|
|
396
|
+
connecting: "connecting";
|
|
397
|
+
"identity-changed": "identity-changed";
|
|
398
|
+
"needs-node": "needs-node";
|
|
399
|
+
"not-hosted": "not-hosted";
|
|
400
|
+
paused: "paused";
|
|
401
|
+
"several-servers": "several-servers";
|
|
402
|
+
unreachable: "unreachable";
|
|
403
|
+
"version-mismatch": "version-mismatch";
|
|
404
|
+
}>;
|
|
405
|
+
projects: z.ZodNullable<z.ZodArray<z.ZodObject<{
|
|
406
|
+
id: z.ZodString;
|
|
407
|
+
name: z.ZodString;
|
|
408
|
+
root: z.ZodString;
|
|
409
|
+
addedAt: z.ZodString;
|
|
410
|
+
lastOpenedAt: z.ZodString;
|
|
411
|
+
source: z.ZodEnum<{
|
|
412
|
+
checkout: "checkout";
|
|
413
|
+
local: "local";
|
|
414
|
+
}>;
|
|
415
|
+
status: z.ZodEnum<{
|
|
416
|
+
missing: "missing";
|
|
417
|
+
"not-git": "not-git";
|
|
418
|
+
ok: "ok";
|
|
419
|
+
}>;
|
|
420
|
+
branch: z.ZodOptional<z.ZodString>;
|
|
421
|
+
forge: z.ZodOptional<z.ZodString>;
|
|
422
|
+
repoUrl: z.ZodOptional<z.ZodString>;
|
|
423
|
+
maxParallel: z.ZodOptional<z.ZodNumber>;
|
|
424
|
+
tags: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
425
|
+
webhook: z.ZodOptional<z.ZodObject<{
|
|
426
|
+
url: z.ZodString;
|
|
427
|
+
tokenSet: z.ZodBoolean;
|
|
428
|
+
triggers: z.ZodOptional<z.ZodArray<z.ZodEnum<{
|
|
429
|
+
cancelled: "cancelled";
|
|
430
|
+
done: "done";
|
|
431
|
+
failed: "failed";
|
|
432
|
+
"needs-you": "needs-you";
|
|
433
|
+
running: "running";
|
|
434
|
+
"waiting-ci": "waiting-ci";
|
|
435
|
+
"waiting-other": "waiting-other";
|
|
436
|
+
"waiting-timer": "waiting-timer";
|
|
437
|
+
"waiting-workers": "waiting-workers";
|
|
438
|
+
}>>>;
|
|
439
|
+
}, z.core.$strip>>;
|
|
440
|
+
webhooks: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
441
|
+
id: z.ZodString;
|
|
442
|
+
name: z.ZodString;
|
|
443
|
+
description: z.ZodOptional<z.ZodString>;
|
|
444
|
+
url: z.ZodString;
|
|
445
|
+
tokenSet: z.ZodBoolean;
|
|
446
|
+
tasks: z.ZodBoolean;
|
|
447
|
+
triggers: z.ZodOptional<z.ZodArray<z.ZodEnum<{
|
|
448
|
+
cancelled: "cancelled";
|
|
449
|
+
done: "done";
|
|
450
|
+
failed: "failed";
|
|
451
|
+
"needs-you": "needs-you";
|
|
452
|
+
running: "running";
|
|
453
|
+
"waiting-ci": "waiting-ci";
|
|
454
|
+
"waiting-other": "waiting-other";
|
|
455
|
+
"waiting-timer": "waiting-timer";
|
|
456
|
+
"waiting-workers": "waiting-workers";
|
|
457
|
+
}>>>;
|
|
458
|
+
agent: z.ZodBoolean;
|
|
459
|
+
}, z.core.$strip>>>;
|
|
460
|
+
}, z.core.$strip>>>;
|
|
461
|
+
}, z.core.$strip>;
|
|
462
|
+
export type HostProjectsEntry = z.infer<typeof hostProjectsEntrySchema>;
|
|
463
|
+
/** `GET /api/v1/hosts/projects` response: local projects plus every saved host's state and projects. */
|
|
464
|
+
export declare const hostsProjectsResponseSchema: z.ZodObject<{
|
|
465
|
+
local: z.ZodObject<{
|
|
466
|
+
projects: z.ZodArray<z.ZodObject<{
|
|
467
|
+
id: z.ZodString;
|
|
468
|
+
name: z.ZodString;
|
|
469
|
+
root: z.ZodString;
|
|
470
|
+
addedAt: z.ZodString;
|
|
471
|
+
lastOpenedAt: z.ZodString;
|
|
472
|
+
source: z.ZodEnum<{
|
|
473
|
+
checkout: "checkout";
|
|
474
|
+
local: "local";
|
|
475
|
+
}>;
|
|
476
|
+
status: z.ZodEnum<{
|
|
477
|
+
missing: "missing";
|
|
478
|
+
"not-git": "not-git";
|
|
479
|
+
ok: "ok";
|
|
480
|
+
}>;
|
|
481
|
+
branch: z.ZodOptional<z.ZodString>;
|
|
482
|
+
forge: z.ZodOptional<z.ZodString>;
|
|
483
|
+
repoUrl: z.ZodOptional<z.ZodString>;
|
|
484
|
+
maxParallel: z.ZodOptional<z.ZodNumber>;
|
|
485
|
+
tags: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
486
|
+
webhook: z.ZodOptional<z.ZodObject<{
|
|
487
|
+
url: z.ZodString;
|
|
488
|
+
tokenSet: z.ZodBoolean;
|
|
489
|
+
triggers: z.ZodOptional<z.ZodArray<z.ZodEnum<{
|
|
490
|
+
cancelled: "cancelled";
|
|
491
|
+
done: "done";
|
|
492
|
+
failed: "failed";
|
|
493
|
+
"needs-you": "needs-you";
|
|
494
|
+
running: "running";
|
|
495
|
+
"waiting-ci": "waiting-ci";
|
|
496
|
+
"waiting-other": "waiting-other";
|
|
497
|
+
"waiting-timer": "waiting-timer";
|
|
498
|
+
"waiting-workers": "waiting-workers";
|
|
499
|
+
}>>>;
|
|
500
|
+
}, z.core.$strip>>;
|
|
501
|
+
webhooks: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
502
|
+
id: z.ZodString;
|
|
503
|
+
name: z.ZodString;
|
|
504
|
+
description: z.ZodOptional<z.ZodString>;
|
|
505
|
+
url: z.ZodString;
|
|
506
|
+
tokenSet: z.ZodBoolean;
|
|
507
|
+
tasks: z.ZodBoolean;
|
|
508
|
+
triggers: z.ZodOptional<z.ZodArray<z.ZodEnum<{
|
|
509
|
+
cancelled: "cancelled";
|
|
510
|
+
done: "done";
|
|
511
|
+
failed: "failed";
|
|
512
|
+
"needs-you": "needs-you";
|
|
513
|
+
running: "running";
|
|
514
|
+
"waiting-ci": "waiting-ci";
|
|
515
|
+
"waiting-other": "waiting-other";
|
|
516
|
+
"waiting-timer": "waiting-timer";
|
|
517
|
+
"waiting-workers": "waiting-workers";
|
|
518
|
+
}>>>;
|
|
519
|
+
agent: z.ZodBoolean;
|
|
520
|
+
}, z.core.$strip>>>;
|
|
521
|
+
}, z.core.$strip>>;
|
|
522
|
+
bootProject: z.ZodNullable<z.ZodString>;
|
|
523
|
+
}, z.core.$strip>;
|
|
524
|
+
hosts: z.ZodArray<z.ZodObject<{
|
|
525
|
+
id: z.ZodString;
|
|
526
|
+
label: z.ZodString;
|
|
527
|
+
state: z.ZodEnum<{
|
|
528
|
+
"cannot-persist": "cannot-persist";
|
|
529
|
+
connected: "connected";
|
|
530
|
+
connecting: "connecting";
|
|
531
|
+
"identity-changed": "identity-changed";
|
|
532
|
+
"needs-node": "needs-node";
|
|
533
|
+
"not-hosted": "not-hosted";
|
|
534
|
+
paused: "paused";
|
|
535
|
+
"several-servers": "several-servers";
|
|
536
|
+
unreachable: "unreachable";
|
|
537
|
+
"version-mismatch": "version-mismatch";
|
|
538
|
+
}>;
|
|
539
|
+
projects: z.ZodNullable<z.ZodArray<z.ZodObject<{
|
|
540
|
+
id: z.ZodString;
|
|
541
|
+
name: z.ZodString;
|
|
542
|
+
root: z.ZodString;
|
|
543
|
+
addedAt: z.ZodString;
|
|
544
|
+
lastOpenedAt: z.ZodString;
|
|
545
|
+
source: z.ZodEnum<{
|
|
546
|
+
checkout: "checkout";
|
|
547
|
+
local: "local";
|
|
548
|
+
}>;
|
|
549
|
+
status: z.ZodEnum<{
|
|
550
|
+
missing: "missing";
|
|
551
|
+
"not-git": "not-git";
|
|
552
|
+
ok: "ok";
|
|
553
|
+
}>;
|
|
554
|
+
branch: z.ZodOptional<z.ZodString>;
|
|
555
|
+
forge: z.ZodOptional<z.ZodString>;
|
|
556
|
+
repoUrl: z.ZodOptional<z.ZodString>;
|
|
557
|
+
maxParallel: z.ZodOptional<z.ZodNumber>;
|
|
558
|
+
tags: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
559
|
+
webhook: z.ZodOptional<z.ZodObject<{
|
|
560
|
+
url: z.ZodString;
|
|
561
|
+
tokenSet: z.ZodBoolean;
|
|
562
|
+
triggers: z.ZodOptional<z.ZodArray<z.ZodEnum<{
|
|
563
|
+
cancelled: "cancelled";
|
|
564
|
+
done: "done";
|
|
565
|
+
failed: "failed";
|
|
566
|
+
"needs-you": "needs-you";
|
|
567
|
+
running: "running";
|
|
568
|
+
"waiting-ci": "waiting-ci";
|
|
569
|
+
"waiting-other": "waiting-other";
|
|
570
|
+
"waiting-timer": "waiting-timer";
|
|
571
|
+
"waiting-workers": "waiting-workers";
|
|
572
|
+
}>>>;
|
|
573
|
+
}, z.core.$strip>>;
|
|
574
|
+
webhooks: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
575
|
+
id: z.ZodString;
|
|
576
|
+
name: z.ZodString;
|
|
577
|
+
description: z.ZodOptional<z.ZodString>;
|
|
578
|
+
url: z.ZodString;
|
|
579
|
+
tokenSet: z.ZodBoolean;
|
|
580
|
+
tasks: z.ZodBoolean;
|
|
581
|
+
triggers: z.ZodOptional<z.ZodArray<z.ZodEnum<{
|
|
582
|
+
cancelled: "cancelled";
|
|
583
|
+
done: "done";
|
|
584
|
+
failed: "failed";
|
|
585
|
+
"needs-you": "needs-you";
|
|
586
|
+
running: "running";
|
|
587
|
+
"waiting-ci": "waiting-ci";
|
|
588
|
+
"waiting-other": "waiting-other";
|
|
589
|
+
"waiting-timer": "waiting-timer";
|
|
590
|
+
"waiting-workers": "waiting-workers";
|
|
591
|
+
}>>>;
|
|
592
|
+
agent: z.ZodBoolean;
|
|
593
|
+
}, z.core.$strip>>>;
|
|
594
|
+
}, z.core.$strip>>>;
|
|
595
|
+
}, z.core.$strip>>;
|
|
596
|
+
warning: z.ZodOptional<z.ZodString>;
|
|
597
|
+
}, z.core.$strip>;
|
|
598
|
+
export type HostsProjectsResponse = z.infer<typeof hostsProjectsResponseSchema>;
|
package/dist/contract/index.js
CHANGED
|
@@ -6722,6 +6722,36 @@ var hostServerActiveTasksResultSchema = z61.object({
|
|
|
6722
6722
|
port: hostPortSchema,
|
|
6723
6723
|
activeCount: z61.number().int().min(0)
|
|
6724
6724
|
});
|
|
6725
|
+
var HOST_GATEWAY_ERROR_CODES = [
|
|
6726
|
+
"host-unreachable",
|
|
6727
|
+
"host-version-mismatch",
|
|
6728
|
+
"host-not-hosted",
|
|
6729
|
+
"host-identity-changed",
|
|
6730
|
+
"host-several-servers",
|
|
6731
|
+
"host-paused",
|
|
6732
|
+
"host-upgrade-unsupported",
|
|
6733
|
+
"host-unexpected-redirect",
|
|
6734
|
+
"host-nested-gateway-unsupported"
|
|
6735
|
+
];
|
|
6736
|
+
var hostGatewayErrorCodeSchema = z61.enum(HOST_GATEWAY_ERROR_CODES);
|
|
6737
|
+
var hostGatewayErrorResponseSchema = z61.object({
|
|
6738
|
+
code: hostGatewayErrorCodeSchema,
|
|
6739
|
+
error: z61.string().min(1)
|
|
6740
|
+
});
|
|
6741
|
+
var hostProjectsEntrySchema = z61.object({
|
|
6742
|
+
id: hostIdSchema,
|
|
6743
|
+
label: hostLabelSchema,
|
|
6744
|
+
state: hostStateSchema,
|
|
6745
|
+
projects: z61.array(projectListEntrySchema).nullable()
|
|
6746
|
+
});
|
|
6747
|
+
var hostsProjectsResponseSchema = z61.object({
|
|
6748
|
+
local: z61.object({
|
|
6749
|
+
projects: z61.array(projectListEntrySchema),
|
|
6750
|
+
bootProject: z61.string().nullable()
|
|
6751
|
+
}),
|
|
6752
|
+
hosts: z61.array(hostProjectsEntrySchema),
|
|
6753
|
+
warning: z61.string().optional()
|
|
6754
|
+
});
|
|
6725
6755
|
export {
|
|
6726
6756
|
ACTIVITY_CHECKS_MAX,
|
|
6727
6757
|
ACTIVITY_CHECK_NAME_MAX,
|
|
@@ -6758,6 +6788,7 @@ export {
|
|
|
6758
6788
|
HANDOFF_AUTOSAVE_RECORDS_MAX,
|
|
6759
6789
|
HOME_FILE_PATTERN,
|
|
6760
6790
|
HOME_RECOVERY_REASONS,
|
|
6791
|
+
HOST_GATEWAY_ERROR_CODES,
|
|
6761
6792
|
HOST_ID_PATTERN,
|
|
6762
6793
|
HOST_NOT_CONNECTED_REASON,
|
|
6763
6794
|
HOST_STATES,
|
|
@@ -7079,9 +7110,12 @@ export {
|
|
|
7079
7110
|
homeRecoverySchema,
|
|
7080
7111
|
hostDiscoveryRequestSchema,
|
|
7081
7112
|
hostEntrySchema,
|
|
7113
|
+
hostGatewayErrorCodeSchema,
|
|
7114
|
+
hostGatewayErrorResponseSchema,
|
|
7082
7115
|
hostIdSchema,
|
|
7083
7116
|
hostLabelSchema,
|
|
7084
7117
|
hostPortSchema,
|
|
7118
|
+
hostProjectsEntrySchema,
|
|
7085
7119
|
hostResponseSchema,
|
|
7086
7120
|
hostRouteParamsSchema,
|
|
7087
7121
|
hostServerActiveTasksResultSchema,
|
|
@@ -7099,6 +7133,7 @@ export {
|
|
|
7099
7133
|
hostStateSchema,
|
|
7100
7134
|
hostSummarySchema,
|
|
7101
7135
|
hostsListResponseSchema,
|
|
7136
|
+
hostsProjectsResponseSchema,
|
|
7102
7137
|
hostsRegistryFileSchema,
|
|
7103
7138
|
humanAskClosedEventSchema,
|
|
7104
7139
|
humanInputDeliveredEventSchema,
|
|
@@ -18,9 +18,7 @@ export interface HttpRouteContext {
|
|
|
18
18
|
readonly isHostedMode: () => boolean;
|
|
19
19
|
/** Invoke the cockpit HTTP app in-process (synthetic loopback Host, no Origin). */
|
|
20
20
|
fetchApp(request: Request): Promise<Response>;
|
|
21
|
-
|
|
22
|
-
export interface HttpRouteBundleContext extends HttpRouteContext {
|
|
23
|
-
/** Shared cockpit server context for route bundles (hearsay-tools/squawk#4442). */
|
|
21
|
+
/** Shared cockpit server context (hearsay-tools/squawk#4442, hearsay-tools/squawk#4540). */
|
|
24
22
|
readonly server?: ServerPluginContext | undefined;
|
|
25
23
|
}
|
|
26
24
|
export interface HttpHandlerRouteDefinition {
|
|
@@ -34,6 +32,11 @@ export interface HttpHandlerRouteDefinition {
|
|
|
34
32
|
* enforces auth and its own streaming body cap before buffering request bytes.
|
|
35
33
|
*/
|
|
36
34
|
readonly managesBodyLimit?: boolean | undefined;
|
|
35
|
+
/**
|
|
36
|
+
* When true, the main server's response-compression middleware skips this route so streaming
|
|
37
|
+
* proxy responses are never buffered or re-compressed after the upstream applied `Accept-Encoding`.
|
|
38
|
+
*/
|
|
39
|
+
readonly skipCompression?: boolean | undefined;
|
|
37
40
|
handle(request: Request, context: HttpRouteContext): Response | Promise<Response>;
|
|
38
41
|
}
|
|
39
42
|
export interface HttpBundleRouteDefinition {
|
|
@@ -44,7 +47,7 @@ export interface HttpBundleRouteDefinition {
|
|
|
44
47
|
* Build the Hono sub-app mounted under `/api/v1/p/:projectId` and `/api/v1` (when `scope` is
|
|
45
48
|
* `'project'`) or under `/api/v1` only (when `scope` is `'workspace'`).
|
|
46
49
|
*/
|
|
47
|
-
createRoutes(context:
|
|
50
|
+
createRoutes(context: HttpRouteContext): Hono<any, any, any>;
|
|
48
51
|
}
|
|
49
52
|
export type HttpRouteDefinition = HttpHandlerRouteDefinition | HttpBundleRouteDefinition;
|
|
50
53
|
export declare function isHttpBundleRoute(route: HttpRouteDefinition): route is HttpBundleRouteDefinition;
|
|
@@ -17,9 +17,15 @@ function checkHandlerShape(route) {
|
|
|
17
17
|
if (typeof route.path !== 'string' || !route.path.startsWith(API_V1_PREFIX) || route.path.length <= API_V1_PREFIX.length) {
|
|
18
18
|
throw new Error(`HTTP routes: '${route.id}' path must start with '${API_V1_PREFIX}', got ${JSON.stringify(route.path)}.`);
|
|
19
19
|
}
|
|
20
|
+
if (route.path === `${API_V1_PREFIX}*`) {
|
|
21
|
+
throw new Error(`HTTP routes: '${route.id}' cannot register a root wildcard path ('${route.path}').`);
|
|
22
|
+
}
|
|
20
23
|
if (route.managesBodyLimit !== undefined && typeof route.managesBodyLimit !== 'boolean') {
|
|
21
24
|
throw new Error(`HTTP routes: '${route.id}' managesBodyLimit must be a boolean.`);
|
|
22
25
|
}
|
|
26
|
+
if (route.skipCompression !== undefined && typeof route.skipCompression !== 'boolean') {
|
|
27
|
+
throw new Error(`HTTP routes: '${route.id}' skipCompression must be a boolean.`);
|
|
28
|
+
}
|
|
23
29
|
if (typeof route.handle !== 'function')
|
|
24
30
|
throw new Error(`HTTP routes: '${route.id}' needs a handle function.`);
|
|
25
31
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"http-route-registry.js","sourceRoot":"","sources":["../../src/core/http-route-registry.ts"],"names":[],"mappings":"AAQA,OAAO,EAAE,mBAAmB,EAAE,MAAM,eAAe,CAAC;AAGpD,MAAM,CAAC,MAAM,kBAAkB,GAAG,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,EAAE,QAAQ,EAAE,KAAK,CAAU,CAAC;AAG5F,MAAM,CAAC,MAAM,iBAAiB,GAAG,CAAC,SAAS,EAAE,WAAW,CAAU,CAAC;
|
|
1
|
+
{"version":3,"file":"http-route-registry.js","sourceRoot":"","sources":["../../src/core/http-route-registry.ts"],"names":[],"mappings":"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"}
|
|
@@ -2,6 +2,18 @@ import type { DelegationRoutes } from './routes.ts';
|
|
|
2
2
|
export declare function createDelegationApp(routes: DelegationRoutes): import("hono/hono-base").HonoBase<import("hono/types").BlankEnv, import("hono/types").BlankSchema | import("hono/types").MergeSchemaPath<{
|
|
3
3
|
"/list": {
|
|
4
4
|
$get: {
|
|
5
|
+
output: {
|
|
6
|
+
error: string;
|
|
7
|
+
code?: "invalid_input" | undefined;
|
|
8
|
+
};
|
|
9
|
+
outputFormat: "json";
|
|
10
|
+
status: 400;
|
|
11
|
+
input: {
|
|
12
|
+
query: {
|
|
13
|
+
offset?: string | undefined;
|
|
14
|
+
};
|
|
15
|
+
};
|
|
16
|
+
} | {
|
|
5
17
|
output: {
|
|
6
18
|
workers: {
|
|
7
19
|
workerId: string;
|
|
@@ -54,18 +66,6 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
54
66
|
offset?: string | undefined;
|
|
55
67
|
};
|
|
56
68
|
};
|
|
57
|
-
} | {
|
|
58
|
-
output: {
|
|
59
|
-
error: string;
|
|
60
|
-
code?: "invalid_input" | undefined;
|
|
61
|
-
};
|
|
62
|
-
outputFormat: "json";
|
|
63
|
-
status: 400;
|
|
64
|
-
input: {
|
|
65
|
-
query: {
|
|
66
|
-
offset?: string | undefined;
|
|
67
|
-
};
|
|
68
|
-
};
|
|
69
69
|
};
|
|
70
70
|
};
|
|
71
71
|
} & {
|
|
@@ -652,6 +652,18 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
652
652
|
} & {
|
|
653
653
|
"/:workerId": {
|
|
654
654
|
$get: {
|
|
655
|
+
output: {
|
|
656
|
+
error: string;
|
|
657
|
+
code?: "invalid_input" | undefined;
|
|
658
|
+
};
|
|
659
|
+
outputFormat: "json";
|
|
660
|
+
status: 400;
|
|
661
|
+
input: {
|
|
662
|
+
param: {
|
|
663
|
+
workerId: string;
|
|
664
|
+
};
|
|
665
|
+
};
|
|
666
|
+
} | {
|
|
655
667
|
output: {
|
|
656
668
|
workerId: string;
|
|
657
669
|
settled: boolean;
|
|
@@ -776,7 +788,11 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
776
788
|
workerId: string;
|
|
777
789
|
};
|
|
778
790
|
};
|
|
779
|
-
}
|
|
791
|
+
};
|
|
792
|
+
};
|
|
793
|
+
} & {
|
|
794
|
+
"/:workerId/collect": {
|
|
795
|
+
$post: {
|
|
780
796
|
output: {
|
|
781
797
|
error: string;
|
|
782
798
|
code?: "invalid_input" | undefined;
|
|
@@ -787,12 +803,10 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
787
803
|
param: {
|
|
788
804
|
workerId: string;
|
|
789
805
|
};
|
|
806
|
+
} & {
|
|
807
|
+
json: Record<string, never>;
|
|
790
808
|
};
|
|
791
|
-
}
|
|
792
|
-
};
|
|
793
|
-
} & {
|
|
794
|
-
"/:workerId/collect": {
|
|
795
|
-
$post: {
|
|
809
|
+
} | {
|
|
796
810
|
output: {
|
|
797
811
|
workerId: string;
|
|
798
812
|
parentRunId: string;
|
|
@@ -917,7 +931,11 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
917
931
|
} & {
|
|
918
932
|
json: Record<string, never>;
|
|
919
933
|
};
|
|
920
|
-
}
|
|
934
|
+
};
|
|
935
|
+
};
|
|
936
|
+
} & {
|
|
937
|
+
"/:workerId/steer": {
|
|
938
|
+
$post: {
|
|
921
939
|
output: {
|
|
922
940
|
error: string;
|
|
923
941
|
code?: "invalid_input" | undefined;
|
|
@@ -929,13 +947,11 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
929
947
|
workerId: string;
|
|
930
948
|
};
|
|
931
949
|
} & {
|
|
932
|
-
json:
|
|
950
|
+
json: {
|
|
951
|
+
text: string;
|
|
952
|
+
};
|
|
933
953
|
};
|
|
934
|
-
}
|
|
935
|
-
};
|
|
936
|
-
} & {
|
|
937
|
-
"/:workerId/steer": {
|
|
938
|
-
$post: {
|
|
954
|
+
} | {
|
|
939
955
|
output: {
|
|
940
956
|
workerId: string;
|
|
941
957
|
state: "delivered" | "queued";
|
|
@@ -951,7 +967,11 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
951
967
|
text: string;
|
|
952
968
|
};
|
|
953
969
|
};
|
|
954
|
-
}
|
|
970
|
+
};
|
|
971
|
+
};
|
|
972
|
+
} & {
|
|
973
|
+
"/:workerId/stop": {
|
|
974
|
+
$post: {
|
|
955
975
|
output: {
|
|
956
976
|
error: string;
|
|
957
977
|
code?: "invalid_input" | undefined;
|
|
@@ -963,15 +983,9 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
963
983
|
workerId: string;
|
|
964
984
|
};
|
|
965
985
|
} & {
|
|
966
|
-
json:
|
|
967
|
-
text: string;
|
|
968
|
-
};
|
|
986
|
+
json: Record<string, never>;
|
|
969
987
|
};
|
|
970
|
-
}
|
|
971
|
-
};
|
|
972
|
-
} & {
|
|
973
|
-
"/:workerId/stop": {
|
|
974
|
-
$post: {
|
|
988
|
+
} | {
|
|
975
989
|
output: {
|
|
976
990
|
workerId: string;
|
|
977
991
|
state: "stopping" | "terminated";
|
|
@@ -985,7 +999,11 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
985
999
|
} & {
|
|
986
1000
|
json: Record<string, never>;
|
|
987
1001
|
};
|
|
988
|
-
}
|
|
1002
|
+
};
|
|
1003
|
+
};
|
|
1004
|
+
} & {
|
|
1005
|
+
"/:workerId/destroy": {
|
|
1006
|
+
$post: {
|
|
989
1007
|
output: {
|
|
990
1008
|
error: string;
|
|
991
1009
|
code?: "invalid_input" | undefined;
|
|
@@ -997,13 +1015,11 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
997
1015
|
workerId: string;
|
|
998
1016
|
};
|
|
999
1017
|
} & {
|
|
1000
|
-
json:
|
|
1018
|
+
json: {
|
|
1019
|
+
discardWork?: true | undefined;
|
|
1020
|
+
};
|
|
1001
1021
|
};
|
|
1002
|
-
}
|
|
1003
|
-
};
|
|
1004
|
-
} & {
|
|
1005
|
-
"/:workerId/destroy": {
|
|
1006
|
-
$post: {
|
|
1022
|
+
} | {
|
|
1007
1023
|
output: {
|
|
1008
1024
|
workerId: string;
|
|
1009
1025
|
state: "complete" | "incomplete";
|
|
@@ -1032,22 +1048,6 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
1032
1048
|
discardWork?: true | undefined;
|
|
1033
1049
|
};
|
|
1034
1050
|
};
|
|
1035
|
-
} | {
|
|
1036
|
-
output: {
|
|
1037
|
-
error: string;
|
|
1038
|
-
code?: "invalid_input" | undefined;
|
|
1039
|
-
};
|
|
1040
|
-
outputFormat: "json";
|
|
1041
|
-
status: 400;
|
|
1042
|
-
input: {
|
|
1043
|
-
param: {
|
|
1044
|
-
workerId: string;
|
|
1045
|
-
};
|
|
1046
|
-
} & {
|
|
1047
|
-
json: {
|
|
1048
|
-
discardWork?: true | undefined;
|
|
1049
|
-
};
|
|
1050
|
-
};
|
|
1051
1051
|
} | {
|
|
1052
1052
|
output: {
|
|
1053
1053
|
workerId: string;
|
|
@@ -1083,18 +1083,11 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
1083
1083
|
"/:workerId/summary": {
|
|
1084
1084
|
$post: {
|
|
1085
1085
|
output: {
|
|
1086
|
-
|
|
1087
|
-
|
|
1088
|
-
source: "assistant" | "failure";
|
|
1089
|
-
seq: number;
|
|
1090
|
-
totalLines: number;
|
|
1091
|
-
offset: number;
|
|
1092
|
-
lineCount: number;
|
|
1093
|
-
text: string;
|
|
1094
|
-
nextOffset?: number | undefined;
|
|
1086
|
+
error: string;
|
|
1087
|
+
code?: "invalid_input" | undefined;
|
|
1095
1088
|
};
|
|
1096
1089
|
outputFormat: "json";
|
|
1097
|
-
status:
|
|
1090
|
+
status: 400;
|
|
1098
1091
|
input: {
|
|
1099
1092
|
param: {
|
|
1100
1093
|
workerId: string;
|
|
@@ -1107,11 +1100,18 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
1107
1100
|
};
|
|
1108
1101
|
} | {
|
|
1109
1102
|
output: {
|
|
1110
|
-
|
|
1111
|
-
|
|
1103
|
+
workerId: string;
|
|
1104
|
+
revision: number;
|
|
1105
|
+
source: "assistant" | "failure";
|
|
1106
|
+
seq: number;
|
|
1107
|
+
totalLines: number;
|
|
1108
|
+
offset: number;
|
|
1109
|
+
lineCount: number;
|
|
1110
|
+
text: string;
|
|
1111
|
+
nextOffset?: number | undefined;
|
|
1112
1112
|
};
|
|
1113
1113
|
outputFormat: "json";
|
|
1114
|
-
status:
|
|
1114
|
+
status: 200;
|
|
1115
1115
|
input: {
|
|
1116
1116
|
param: {
|
|
1117
1117
|
workerId: string;
|
|
@@ -1128,13 +1128,11 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
1128
1128
|
"/:workerId/diff": {
|
|
1129
1129
|
$get: {
|
|
1130
1130
|
output: {
|
|
1131
|
-
|
|
1132
|
-
|
|
1133
|
-
diff: string;
|
|
1134
|
-
truncated: boolean;
|
|
1131
|
+
error: string;
|
|
1132
|
+
code?: "invalid_input" | undefined;
|
|
1135
1133
|
};
|
|
1136
1134
|
outputFormat: "json";
|
|
1137
|
-
status:
|
|
1135
|
+
status: 400;
|
|
1138
1136
|
input: {
|
|
1139
1137
|
param: {
|
|
1140
1138
|
workerId: string;
|
|
@@ -1142,11 +1140,13 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
1142
1140
|
};
|
|
1143
1141
|
} | {
|
|
1144
1142
|
output: {
|
|
1145
|
-
|
|
1146
|
-
|
|
1143
|
+
workerId: string;
|
|
1144
|
+
baselineSha: string;
|
|
1145
|
+
diff: string;
|
|
1146
|
+
truncated: boolean;
|
|
1147
1147
|
};
|
|
1148
1148
|
outputFormat: "json";
|
|
1149
|
-
status:
|
|
1149
|
+
status: 200;
|
|
1150
1150
|
input: {
|
|
1151
1151
|
param: {
|
|
1152
1152
|
workerId: string;
|