wicked-crew-api-types 0.102.0 → 0.104.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/index.d.ts +101 -0
- package/package.json +1 -1
package/index.d.ts
CHANGED
|
@@ -322,6 +322,19 @@ export interface AgentSession {
|
|
|
322
322
|
* in-run delivery (its receipt is `deliverLiftEvaluated.assurance`) and for an undelivered run.
|
|
323
323
|
*/
|
|
324
324
|
delivery_assurance?: DeliveryAssurance;
|
|
325
|
+
/**
|
|
326
|
+
* (crew#720) The zip of the run's FINAL codebase, taken for every delivery whatever its outcome
|
|
327
|
+
* (delivered, push refused, credentials missing, wrong account, lift conflict, a run that failed
|
|
328
|
+
* after building, a cancel): `GET codebase_archive.url` downloads it. ABSENT when the run had no
|
|
329
|
+
* repository, no archive has been taken yet, or the daemon predates the field.
|
|
330
|
+
*/
|
|
331
|
+
codebase_archive?: CodebaseArchive;
|
|
332
|
+
/**
|
|
333
|
+
* (crew#720) Present when the run's deliver phase REFUSED for want of the provider credential
|
|
334
|
+
* (`status: 'missing'`): the run waits at the deliver gate with its work kept, and `message` /
|
|
335
|
+
* `missing` say what to set before approving the retry. ABSENT otherwise.
|
|
336
|
+
*/
|
|
337
|
+
deliver_credentials?: DeliverCredentials;
|
|
325
338
|
/**
|
|
326
339
|
* The project this run is filed into (DES-UX-001 §8.2, CREW-UX-2; api-types 0.8.0) —
|
|
327
340
|
* populated by the crew server from the membership record at DTO assembly on BOTH
|
|
@@ -2815,6 +2828,38 @@ export type AdviceDeliveredEvent = {
|
|
|
2815
2828
|
detail: string | null;
|
|
2816
2829
|
};
|
|
2817
2830
|
|
|
2831
|
+
/**
|
|
2832
|
+
* (wicked-core#762) The engine ended an ACP turn itself: the worker's final message was followed by
|
|
2833
|
+
* `quietSecs` of silence (`WICKED_ACP_SETTLE_SECS`, default 600) with no tool call open, so the turn
|
|
2834
|
+
* is settled `Ok` with its `outputBytes` of output as the attempt's result and the wedged process is
|
|
2835
|
+
* dropped. Crew's stall watchdog reads it as a returned worker (never a reassign). Spelled as
|
|
2836
|
+
* wicked-core's `CoreEvent::to_json` emits it.
|
|
2837
|
+
*/
|
|
2838
|
+
export type AcpTurnSettledEvent = {
|
|
2839
|
+
type: 'acpTurnSettled';
|
|
2840
|
+
session: string;
|
|
2841
|
+
ord: number;
|
|
2842
|
+
attempt: number;
|
|
2843
|
+
cliKey: string;
|
|
2844
|
+
quietSecs: number;
|
|
2845
|
+
outputBytes: number;
|
|
2846
|
+
};
|
|
2847
|
+
|
|
2848
|
+
/**
|
|
2849
|
+
* (wicked-core#418) An ACP session opened to replace a process the engine closed itself, and what
|
|
2850
|
+
* the cold start cost (`ms`, to the opened session): `reason` is `posture_switch`,
|
|
2851
|
+
* `fenced_unit_quiesced` or `turn_settled` (read an unknown token as a reason, never an error).
|
|
2852
|
+
*/
|
|
2853
|
+
export type AcpProcessRestartedEvent = {
|
|
2854
|
+
type: 'acpProcessRestarted';
|
|
2855
|
+
session: string;
|
|
2856
|
+
ord: number;
|
|
2857
|
+
attempt: number;
|
|
2858
|
+
cliKey: string;
|
|
2859
|
+
reason: 'posture_switch' | 'fenced_unit_quiesced' | 'turn_settled' | (string & {});
|
|
2860
|
+
ms: number;
|
|
2861
|
+
};
|
|
2862
|
+
|
|
2818
2863
|
/**
|
|
2819
2864
|
* DES-TEAMING-001 §5.3 / §7 (wicked-core#602, S3; api-types 0.40.0) — the worker's answer to one
|
|
2820
2865
|
* DELIVERED finding, read from its final output line `ADVICE <id>: ACCEPT|DECLINE — <reason>` (the
|
|
@@ -4602,8 +4647,51 @@ export interface SetGuidanceResult {
|
|
|
4602
4647
|
* — the body's `error` carries the script's own words, e.g. the rebase-conflict message), 500
|
|
4603
4648
|
* (the script produced no verifiable PR URL, or could not be spawned).
|
|
4604
4649
|
*/
|
|
4650
|
+
/**
|
|
4651
|
+
* (crew#720) The deliver phase's provider credential preflight — ONE shape for GitHub and Azure
|
|
4652
|
+
* DevOps. Presence only: no value is ever read into a crew record.
|
|
4653
|
+
* - GitHub: `GH_TOKEN` exported (`source: 'gh_token'`), else a gh login for github.com
|
|
4654
|
+
* (`'gh_login'`); gh absent or signed out is `missing` (`missing: ['gh auth login', 'GH_TOKEN']`).
|
|
4655
|
+
* - Azure DevOps: the service principal `CREW_ADO_TENANT_ID` + `CREW_ADO_CLIENT_ID` +
|
|
4656
|
+
* `CREW_ADO_CLIENT_SECRET` (`'service_principal'`), else `AZURE_DEVOPS_EXT_PAT` (`'pat'`).
|
|
4657
|
+
* `unknown` = the probe could not answer (gh timed out) — never read it as missing.
|
|
4658
|
+
*/
|
|
4659
|
+
export interface DeliverCredentials {
|
|
4660
|
+
provider: 'github' | 'azure_devops';
|
|
4661
|
+
status: 'configured' | 'missing' | 'unknown';
|
|
4662
|
+
source: 'gh_token' | 'gh_login' | 'service_principal' | 'pat' | null;
|
|
4663
|
+
/** What to set when `missing` (env var names, commands), in the order the phase tries them. */
|
|
4664
|
+
missing: string[];
|
|
4665
|
+
/** One sentence, for the gate card and the run record. */
|
|
4666
|
+
message: string;
|
|
4667
|
+
}
|
|
4668
|
+
|
|
4669
|
+
/** (crew#720) A run's final-codebase zip (`AgentSession.codebase_archive`). */
|
|
4670
|
+
export interface CodebaseArchive {
|
|
4671
|
+
/** Daemon-relative: `/api/v1/runs/<id>/artifacts/codebase.zip` (also answers `X-Content-SHA256`). */
|
|
4672
|
+
url: string;
|
|
4673
|
+
/** Hex sha256 of the zip's bytes. */
|
|
4674
|
+
sha256: string;
|
|
4675
|
+
bytes: number;
|
|
4676
|
+
/** The git tree the zip was written from (`git archive --format=zip <tree>`): HEAD plus the
|
|
4677
|
+
* worktree's tracked changes plus the untracked files the deliver phase ships — never `.git`,
|
|
4678
|
+
* gitignored files, or untracked `.env*` / key material. */
|
|
4679
|
+
tree: string;
|
|
4680
|
+
/** The commit the tree was taken on; `null` on an unborn branch. */
|
|
4681
|
+
commit: string | null;
|
|
4682
|
+
/** Unix millis. */
|
|
4683
|
+
created_at: number;
|
|
4684
|
+
/** `deliver`: the deliver phase's output landed (or a post-hoc deliver ran); `run_end`: the run ended. */
|
|
4685
|
+
trigger: 'deliver' | 'run_end';
|
|
4686
|
+
/** `worktree`: read from the live run worktree; `branch`: from the retained `wicked/<run>` branch. */
|
|
4687
|
+
source: 'worktree' | 'branch';
|
|
4688
|
+
}
|
|
4689
|
+
|
|
4605
4690
|
export interface DeliverRunResult {
|
|
4606
4691
|
prUrl: string;
|
|
4692
|
+
/** (crew#720) The final-codebase zip taken for this delivery (also on `AgentSession.codebase_archive`).
|
|
4693
|
+
* ABSENT when no archive could be taken, and on an idempotent replay. */
|
|
4694
|
+
codebase?: CodebaseArchive;
|
|
4607
4695
|
/** (crew ≥ 0.9.0, EX-04) Always `verified: false, via: 'post_hoc'` here: nothing re-verified the
|
|
4608
4696
|
* delivered tree. ABSENT on an idempotent replay of a delivery recorded before crew 0.9.0. */
|
|
4609
4697
|
assurance?: DeliveryAssurance;
|
|
@@ -4758,6 +4846,13 @@ export interface WorkflowDef {
|
|
|
4758
4846
|
* Gated at intake: a launch whose snapshot lacks the skill is refused before any unit is planned.
|
|
4759
4847
|
*/
|
|
4760
4848
|
base_skill_ref?: string | null;
|
|
4849
|
+
/**
|
|
4850
|
+
* (api-types 0.102.0; wicked-core#850, core-ts ≥ 0.7.46) The instruments a run of this workflow
|
|
4851
|
+
* REQUIRES: `distinct_evaluator`, `judge`, `qe_acceptance`. ABSENT ⇒ the first two. An unknown or
|
|
4852
|
+
* repeated token refuses the def at load. `qe_acceptance` is enforced by crew at delivery (an
|
|
4853
|
+
* attributed QE PASS, or no push) and is never waived by `reducedAssurance`.
|
|
4854
|
+
*/
|
|
4855
|
+
required_instruments?: string[] | null;
|
|
4761
4856
|
}
|
|
4762
4857
|
|
|
4763
4858
|
/** A drop-in workflow definition the ENGINE refused, with the engine's own reason (wicked-crew#718). */
|
|
@@ -4894,6 +4989,12 @@ export interface DeliverTargetResponse {
|
|
|
4894
4989
|
origin: 'github' | 'local' | 'other' | 'none' | 'unknown';
|
|
4895
4990
|
githubRepo: string | null;
|
|
4896
4991
|
sentence: string;
|
|
4992
|
+
/** (crew#720) Where the pull request opens when the origin is Azure DevOps: `org/project/repo`;
|
|
4993
|
+
* `null` otherwise. ABSENT on an older daemon. */
|
|
4994
|
+
adoRepo?: string | null;
|
|
4995
|
+
/** (crew#720) The provider credential preflight for this origin — `missing` says what to set
|
|
4996
|
+
* BEFORE launching. `null` when no provider applies (a local or other origin); ABSENT on an older daemon. */
|
|
4997
|
+
credentials?: DeliverCredentials | null;
|
|
4897
4998
|
}
|
|
4898
4999
|
|
|
4899
5000
|
/**
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "wicked-crew-api-types",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.104.0",
|
|
4
4
|
"description": "The wire contract of the wicked-crew daemon's /api/v1 REST surface and /ws CoreEvent frames \u2014 types only, zero runtime",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"types": "./index.d.ts",
|