wicked-crew-api-types 0.96.0 → 0.97.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.
Files changed (2) hide show
  1. package/index.d.ts +81 -0
  2. package/package.json +1 -1
package/index.d.ts CHANGED
@@ -902,9 +902,46 @@ export interface RosterSeat {
902
902
  * fails the seat's ACP governance closed at every spawn.
903
903
  */
904
904
  version_pin?: SeatVersionPin;
905
+ /**
906
+ * (IG1-core-3, wicked-core-ts 0.7.41) The engine's governance class for the seat, derived from
907
+ * its record — passed through verbatim. `null`/absent on an engine before the field.
908
+ */
909
+ governance_class?: EngineGovernanceClass | null;
910
+ /**
911
+ * (api-types 0.97.0, IG1-crew-1) The governance mode the seat runs under per scope kind (the
912
+ * keys of `chat_admission`): what fences its tool calls. A crew reading — never handed to the
913
+ * engine (`clisJson` strips it).
914
+ */
915
+ governance_mode?: Record<GovernanceScopeKind, SeatGovernanceMode>;
905
916
  [k: string]: unknown;
906
917
  }
907
918
 
919
+ /** The engine's governance class names (IG1-core-3). */
920
+ export type EngineGovernanceClass = 'acp_input_governance' | 'os_sandbox' | 'none';
921
+
922
+ /** `unscoped` — no repository; `scoped` — several repositories or a project (the run binds none);
923
+ * `scoped_bound` — one repository (the run is bound to its worktree; every build run). */
924
+ export type GovernanceScopeKind = 'unscoped' | 'scoped' | 'scoped_bound';
925
+
926
+ /**
927
+ * (api-types 0.97.0, IG1-crew-1) The governance MODE a seat runs under — what fences its tool
928
+ * calls. `admitted`: an ACP adapter sends every tool call through the engine's per-call gate (and
929
+ * a pinned build verified); `os_sandbox`: an OS write floor contains it — `source` names the floor
930
+ * (`seat_record` = `acp.os_sandbox`, `self` = codex's own `--sandbox`, `repo_boundary` = the
931
+ * engine's boundary around a run bound to one repository) — not a per-call gate, not a read or
932
+ * network jail; `none`: only the command-text fences. `reason` says why in the operator's words
933
+ * (codex: no per-call adapter exists to admit).
934
+ */
935
+ export interface SeatGovernanceMode {
936
+ mode: 'admitted' | 'os_sandbox' | 'none';
937
+ class: EngineGovernanceClass | null;
938
+ source: 'acp_input_governance' | 'seat_record' | 'self' | 'repo_boundary' | 'none';
939
+ reason: string;
940
+ /** The roots the mode holds writes/reads to. On the roster these are labels (`<run worktree>`);
941
+ * on a run's record, paths. */
942
+ fence: { write_roots: string[]; read_roots: string[]; network: 'open' };
943
+ }
944
+
908
945
  /**
909
946
  * One pinned seat's `--version` reading (core#581): `RosterSeat.version_pin` and
910
947
  * `AcpCliDiagnostics.versionPin`. Read the way the engine's spawn-time check reads it: the pin
@@ -5653,6 +5690,12 @@ export interface ChatPathView {
5653
5690
  helpers: string[];
5654
5691
  /** The answer step the last message added (`answer-N`). */
5655
5692
  stepId: string;
5693
+ /**
5694
+ * (api-types 0.97.0, IG1-crew-1) The PA's governance mode for the ask's scope — what fences its
5695
+ * tool calls — derived from the engine's class as the run reports it (`path.started.governance`,
5696
+ * `member.joined.governance_class`). Absent until the PA is known, and on a daemon before it.
5697
+ */
5698
+ governance_mode?: SeatGovernanceMode;
5656
5699
  }
5657
5700
 
5658
5701
  // ── Project code graph (DES-PROJECT-001; the co-located multi-repo graph) ──────
@@ -6268,6 +6311,42 @@ export interface DiagnosticsResponse {
6268
6311
  stateHome?: DiagnosticsStateHome | null;
6269
6312
  /** The studio chat recorder's per-CLI format compliance (api-types 0.84.0, DC-S4b); `null` without the chat host. */
6270
6313
  decisions?: DiagnosticsDecisions | null;
6314
+ /** (api-types 0.97.0, crew#742) Per-seat governance standing before any run. */
6315
+ seatGovernance?: DiagnosticsSeatGovernance;
6316
+ /** (api-types 0.97.0, crew#740) The memory store this daemon reads and writes. */
6317
+ memoryStore?: MemoryStoreInfo;
6318
+ }
6319
+
6320
+ /** `DiagnosticsResponse.seatGovernance` (crew#742). Paths are for the local operator. */
6321
+ export interface DiagnosticsSeatGovernance {
6322
+ /** The engine's user registry overlay (`~/.config/wicked-council/clis.toml`) and whether it exists. */
6323
+ rosterFile: { path: string; present: boolean } | null;
6324
+ /** The OS launcher the repository boundary arms with on this host (`sandbox-exec` | `bwrap`),
6325
+ * found on PATH; `null` = none, so floor seats resting on it run advisory. */
6326
+ hostBoundary: string | null;
6327
+ seats: DiagnosticsSeatGovernanceEntry[];
6328
+ }
6329
+
6330
+ export interface DiagnosticsSeatGovernanceEntry {
6331
+ cli: string;
6332
+ enabled_for_council: boolean;
6333
+ transport: 'acp' | 'wrapped';
6334
+ /** The seat record arms the OS sandbox itself (`acp.os_sandbox`). */
6335
+ os_sandbox: boolean;
6336
+ class: EngineGovernanceClass | null;
6337
+ /** `enforced` — admitted and (if pinned) verified; `claimed` — admitted, pin not yet probed;
6338
+ * `unenforced` — no per-call gate holds the seat. */
6339
+ input_governance: 'enforced' | 'claimed' | 'unenforced';
6340
+ governance_mode: Record<GovernanceScopeKind, SeatGovernanceMode>;
6341
+ }
6342
+
6343
+ /** (api-types 0.97.0, crew#740) The daemon's memory store: `explicit` (`WICKED_MEMORY_DB`),
6344
+ * `state-home` (a non-default state home's own store), `global` (the operator-global one).
6345
+ * `notice` is the isolation notice when this daemon's own store is empty and a global one exists. */
6346
+ export interface MemoryStoreInfo {
6347
+ path: string;
6348
+ source: 'explicit' | 'state-home' | 'global';
6349
+ notice: string | null;
6271
6350
  }
6272
6351
 
6273
6352
  // ── Diagnostics — governance store + dead letters (api-types 0.31.0, crew#495 / F-022) ─────────
@@ -7220,6 +7299,8 @@ export interface ListMemoriesQuery {
7220
7299
  /** `GET /memory` → 200. */
7221
7300
  export interface ListMemoriesResponse {
7222
7301
  memories: MemoryItem[];
7302
+ /** (api-types 0.97.0, crew#740) The store the list was read from. Absent on a daemon before it. */
7303
+ store?: MemoryStoreInfo;
7223
7304
  }
7224
7305
 
7225
7306
  /** `GET /memory/coverage` query — an optional subtree filter (`""`/omitted = global totals). */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "wicked-crew-api-types",
3
- "version": "0.96.0",
3
+ "version": "0.97.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",