@maycombhq/sdk 2.0.0-beta.10 → 2.0.0-beta.11

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.
@@ -0,0 +1,180 @@
1
+ import type { FactEnd, FactsJoinResult, JoinRepo } from "./facts-join.js";
2
+ import type { TermsResult, TermSeen } from "./facts-terms.js";
3
+ import type { Conventions } from "./schema/conventions.js";
4
+ import type { QuestionDraft } from "./schema/question.js";
5
+ import type { RepoType } from "./schema/repo-type.js";
6
+ import type { ChecklistRule } from "./schema/review.js";
7
+ /**
8
+ * Org notes (ADR 0163): what the organisation's terms mean in a kind of repo, and what must hold
9
+ * there, in its own words. Atticus never parses a note: it hands the notes of a repo's type, and
10
+ * the org-wide ones, to the assistant as data, numbered, and the assistant cites the one a term
11
+ * fact relies on. Everything that follows from them here is deterministic: the notes a read is
12
+ * given, the rule drafts offered for a person to review, the check an accepted rule runs, and the
13
+ * question an unknown term becomes.
14
+ */
15
+ /** A note as a read is handed it: its number (from 1), its key, its words and where it is written. */
16
+ export interface NumberedNote {
17
+ n: number;
18
+ /**
19
+ * A short hash of its words (`noteKey`): what a term fact's `note` and a rule draft's id name,
20
+ * so reordering the notes points nothing at another note, and a changed note is told apart.
21
+ */
22
+ key: string;
23
+ text: string;
24
+ /** `repo-types/<type>/type.yaml` or `conventions.yaml`, relative to the org pack. */
25
+ source: string;
26
+ /** The note's place in that file's `notes`, from 0. */
27
+ index: number;
28
+ }
29
+ /** A note's key: 8 hex digits of the sha256 of its words, spacing and letter case aside. */
30
+ export declare const noteKey: (text: string) => string;
31
+ /**
32
+ * The notes a read of a repo is handed: its repo type's first, then the org-wide ones, numbered
33
+ * from 1 in that order. Empty when neither has any, which is how a read without notes goes.
34
+ */
35
+ export declare function notesFor(type: Pick<RepoType, "id" | "notes"> | undefined, conventions: Pick<Conventions, "notes"> | undefined): NumberedNote[];
36
+ /**
37
+ * The notes as the prompt gives them (review 6): one data block, each note one line, its number,
38
+ * its key and its words JSON-quoted, after the sentence that they are data, never instructions.
39
+ */
40
+ export declare function notesText(notes: readonly NumberedNote[], repoType?: string): string;
41
+ /** The fewest words a term fact quotes a note by: fewer could be found in any note. */
42
+ export declare const NOTE_QUOTE_WORDS = 4;
43
+ /**
44
+ * Whether a term fact's `note` is one of the notes the read was given: a key one of them has, or
45
+ * at least four words found in one of them (spacing and letter case aside). Undefined when it is.
46
+ * `term-note-stale`: a key none of them has now, the note having been changed or removed since
47
+ * the read, so the term is read again by the notes as they are.
48
+ */
49
+ export declare function noteProblem(note: string, notes: readonly NumberedNote[]): {
50
+ code: "term-meaning" | "term-note-stale";
51
+ message: string;
52
+ } | undefined;
53
+ /** A note reads as a rule when it says all, every or must. A draft only: a person decides. */
54
+ export declare const RULE_WORDS: RegExp;
55
+ /** The deterministic check a call rule runs (ADR 0163). */
56
+ export declare const CALL_SECURITY_CHECK = "call-security";
57
+ /** What a person says is done outside the repos, for a call the check would find. */
58
+ export interface DeclaredOutside {
59
+ repo: string;
60
+ /** The call's fact id; left out, every call of the repo the rule covers. */
61
+ call?: string;
62
+ why: string;
63
+ by: string;
64
+ }
65
+ /** The params of a `call-security` rule, as a person sets them. */
66
+ export interface CallSecurityParams {
67
+ /**
68
+ * The calls it covers: those to a system the profile gives boundary `vendor` (`vendor`), those
69
+ * to any system outside the estate, another team's included (`outside`), or every call.
70
+ */
71
+ to: "vendor" | "outside" | "any";
72
+ /** The transport security the call that reaches the target must show. */
73
+ tls?: "mtls" | "tls";
74
+ /** Whether an auth must be shown on the call that reaches the target. */
75
+ auth?: boolean;
76
+ /** What a person says is done outside the repos: recorded as their word, never verified. */
77
+ declared?: DeclaredOutside[];
78
+ }
79
+ /** A rule's params read as `call-security` params, or why they can't be. */
80
+ export declare function callSecurityParams(params: Record<string, unknown>): CallSecurityParams | {
81
+ problem: string;
82
+ };
83
+ /**
84
+ * A checklist rule draft (C3, `status: draft`) for each note that reads as a rule, for a person
85
+ * to review and accept in a pull request. A note about calls and mTLS, TLS or auth is drafted as
86
+ * the deterministic `call-security` check with its params filled from the words it uses; any
87
+ * other as an AI check that quotes the note. The words only fill a draft: a person sets what the
88
+ * accepted rule checks, and the check itself reads facts, never the note.
89
+ */
90
+ export declare function noteRuleDrafts(notes: readonly NumberedNote[]): ChecklistRule[];
91
+ /** What a call shows, and the line each rests on. */
92
+ interface Shown {
93
+ tls?: {
94
+ value: string;
95
+ at: string;
96
+ };
97
+ auth?: {
98
+ value: string;
99
+ at: string;
100
+ };
101
+ }
102
+ export interface CallSecurityResult {
103
+ /** The call the rule judges: the one that reaches the target (a gateway's forwarding call, or a service's own). */
104
+ call: FactEnd;
105
+ /** The gateway route it forwards from, when it does, then the call itself. */
106
+ chain: FactEnd[];
107
+ /** The calls of other repos that land on that route: the legs in front, never judged. */
108
+ callers: FactEnd[];
109
+ target?: string;
110
+ outcome: "pass" | "finding" | "declared";
111
+ /** What the call shows, cited. */
112
+ shown: Shown;
113
+ /** For a finding: what it doesn't show. */
114
+ missing?: ("tls" | "auth")[];
115
+ /** What its code cites as none, for what the rule asks: a finding no person's word covers. */
116
+ none?: Shown;
117
+ /** For a declared one: the person's word, never verified. */
118
+ declared?: DeclaredOutside;
119
+ message: string;
120
+ }
121
+ /** A system of the profiles, as `checkCallSecurity` tells a vendor from another team's system. */
122
+ export interface CallSecuritySystem {
123
+ id: string;
124
+ name?: string;
125
+ boundary: string;
126
+ aliases?: readonly string[];
127
+ }
128
+ /**
129
+ * Every call a `call-security` rule covers, checked on the facts (ADR 0163, review 5): for
130
+ * `to: vendor`, each call the join leaves to a system the profiles give boundary `vendor`; for
131
+ * `to: outside`, each it leaves outside the estate (another team's system too); for `to: any`,
132
+ * every call. The leg judged is the one that reaches the target: the call itself, which for a
133
+ * gateway is its forwarding call. The legs in front of it (a caller's mTLS to the gateway, the
134
+ * route's own client-certificate check) are listed in `callers` and `chain`, never counted. It
135
+ * passes when the call shows the TLS asked for (`tls` with its `tlsCite`) and, if asked, an auth
136
+ * other than none (`auth` with its `authCite`); otherwise it is a finding for the call's repo.
137
+ * A person's word that it is done outside the repos is recorded as declared, theirs, never
138
+ * verified, except where the call's code cites `none` for what is asked: the code is right.
139
+ */
140
+ export declare function checkCallSecurity(params: CallSecurityParams, input: {
141
+ repos: readonly JoinRepo[];
142
+ join: FactsJoinResult;
143
+ /** The profiles' systems, for each outside target's boundary. */
144
+ systems?: readonly CallSecuritySystem[];
145
+ }): CallSecurityResult[];
146
+ /** The step a term question is asked by. */
147
+ export declare const TERM_STEP = "term-meaning";
148
+ export interface TermQuestionDraft {
149
+ draft: QuestionDraft;
150
+ /** The repo the question is raised for (the group's first, by id). */
151
+ repo: string;
152
+ term: string;
153
+ file: string;
154
+ repoType?: string;
155
+ /** Every term fact the answer is about, by repo. */
156
+ terms: TermSeen[];
157
+ }
158
+ /**
159
+ * One question per term, file and repo type for the terms whose role is unknown (ADR 0163):
160
+ * "What does `cmdb` mean in userAccess.json across 3 forge-apigee-proxy repos?". The answer is
161
+ * meant to be saved as a note on the repo type (`atticus repo-type note`), so the next read of
162
+ * every repo of the type records the role, cited. A repo with no type is asked on its own.
163
+ */
164
+ export declare function termQuestionDrafts(result: Pick<TermsResult, "terms">, typeOf: (repo: string) => string | undefined): TermQuestionDraft[];
165
+ /**
166
+ * The note an answered term question offers to save on its repo type: the person's own words,
167
+ * or the option they picked put as a plain sentence about the term and the file.
168
+ */
169
+ export declare function termAnswerNote(o: {
170
+ term: string;
171
+ file: string;
172
+ option?: "owner" | "consumer" | "none";
173
+ text?: string;
174
+ }): string;
175
+ /** The term and file a term question asks about, read back from its words. */
176
+ export declare function termOfQuestion(question: string): {
177
+ term: string;
178
+ file: string;
179
+ } | undefined;
180
+ export {};
@@ -139,7 +139,7 @@ export declare const DEFAULT_RUNTIME: {
139
139
  } | undefined;
140
140
  };
141
141
  export declare const DEFAULT_SOURCES: {
142
- schemaVersion: 3 | 1 | 2;
142
+ schemaVersion: 1 | 2 | 3;
143
143
  layout: {
144
144
  openspec: string;
145
145
  catalog: string;
@@ -0,0 +1,11 @@
1
+ /**
2
+ * profile.yaml version 1 → 2 (ADR 0162 amendment). Version 2 adds a system's `topics`; a file
3
+ * without them names no topic, as version 1 did, so the step writes the new number only and keeps
4
+ * the file's comments, order and line layout. Nothing is moved from `aliases` to `topics`: which
5
+ * alias is a topic is a person's call. A version-1 profile stays valid, so `atticus upgrade` has no
6
+ * step for it; `addProfileSystem` applies this when it writes a topic.
7
+ */
8
+ export declare function migrateProfileText(text: string): {
9
+ text: string;
10
+ changed: boolean;
11
+ };
@@ -226,6 +226,15 @@ export declare function retireQuestion(root: string, id: string, o: {
226
226
  replacedBy?: string[];
227
227
  at: string;
228
228
  }): Promise<Question>;
229
+ /**
230
+ * ADR 0162 (F8): open an answered targets question again, because the code read since disagrees
231
+ * with its answer (the repo it named has no route that serves the call). The answer it had is
232
+ * kept under `reopened` with why, so the person sees what they said and what the code says.
233
+ */
234
+ export declare function reopenQuestion(root: string, id: string, o: {
235
+ why: string;
236
+ at: string;
237
+ }): Promise<Question>;
229
238
  export declare function answerWords(q: Question): string | undefined;
230
239
  /**
231
240
  * An answer as a step's next prompt gives it (B-run2-fixes 8): the option picked with what it
@@ -251,6 +260,12 @@ export interface AnswerInput {
251
260
  match?: string;
252
261
  /** ADR 0153 (Q5): the assistant's proposal this answer accepts (acceptProposal sets it). */
253
262
  proposal?: NonNullable<Question["answer"]>["proposal"];
263
+ /**
264
+ * Review item 14: a file change the answer brings (a system written into the profile, ADR
265
+ * 0162), made only once the answer is checked and just before it is written. When it throws,
266
+ * nothing is answered (a `bad-answer` with its first line).
267
+ */
268
+ beforeWrite?: () => Promise<void>;
254
269
  by: string;
255
270
  at: string;
256
271
  }
@@ -3,15 +3,15 @@ import { SCHEMA_VERSION } from "./version.js";
3
3
  /** Current catalog schema version (defined in ./version.js, which loads no schema). */
4
4
  export { SCHEMA_VERSION };
5
5
  /** Every catalog schema version a reader accepts, oldest first. */
6
- export declare const SUPPORTED_SCHEMA_VERSIONS: readonly [1, 2, 3];
6
+ export declare const SUPPORTED_SCHEMA_VERSIONS: readonly [1, 2, 3, 4];
7
7
  /**
8
- * A record's schema version. Version-1 and version-2 files differ from version 3 only in this
9
- * number (nothing they hold changed meaning), so they are read as they are and come back as
10
- * version 3 in memory; writers always write the current version, and `migrateCatalog` rewrites
11
- * old files. The type stays `1 | 2 | 3` so code that builds older records in memory keeps
12
- * compiling until it is updated.
8
+ * A record's schema version. Version-1, -2 and -3 files differ from version 4 only in this
9
+ * number (nothing they hold changed meaning: version 4, ADR 0164, only added `protobuf` to a
10
+ * Schema's formats), so they are read as they are and come back as version 4 in memory; writers
11
+ * always write the current version, and `migrateCatalog` rewrites old files. The type stays
12
+ * `1 | 2 | 3 | 4` so code that builds older records in memory keeps compiling until it is updated.
13
13
  */
14
- export declare const SchemaVersion: z.ZodUnion<readonly [z.ZodLiteral<1>, z.ZodLiteral<2>, z.ZodLiteral<3>]>;
14
+ export declare const SchemaVersion: z.ZodUnion<readonly [z.ZodLiteral<1>, z.ZodLiteral<2>, z.ZodLiteral<3>, z.ZodLiteral<4>]>;
15
15
  /**
16
16
  * Stable record id. Lowercase slug, safe as a file name on Linux, macOS and Windows
17
17
  * (no ":" or "/"), so every record can live in its own file named by its id.
@@ -85,7 +85,7 @@ export declare const IsoDate: z.ZodISODate;
85
85
  export declare const IsoDateTime: z.ZodISODateTime;
86
86
  /** Fields every record carries. `kind` is added per record type. */
87
87
  export declare const commonFields: {
88
- schemaVersion: z.ZodUnion<readonly [z.ZodLiteral<1>, z.ZodLiteral<2>, z.ZodLiteral<3>]>;
88
+ schemaVersion: z.ZodUnion<readonly [z.ZodLiteral<1>, z.ZodLiteral<2>, z.ZodLiteral<3>, z.ZodLiteral<4>]>;
89
89
  id: z.ZodString;
90
90
  status: z.ZodEnum<{
91
91
  current: "current";
@@ -6,7 +6,11 @@ import { z } from "zod";
6
6
  * Every key is optional; a key given replaces its default list whole (it doesn't add to it), so
7
7
  * an organisation can take a word out as well as put one in.
8
8
  */
9
- export declare const CONVENTIONS_SCHEMA_VERSION: 1;
9
+ /**
10
+ * Version 2 (ADR 0163) adds `notes`, the organisation-wide notes every read is handed beside its
11
+ * repo type's. A version-1 file reads as it is and comes back as version 2 in memory.
12
+ */
13
+ export declare const CONVENTIONS_SCHEMA_VERSION: 2;
10
14
  /** The folders an API spec is kept in, as a gateway's repo keeps its proxy's spec. */
11
15
  export declare const DEFAULT_API_SPEC_FOLDERS: readonly ["oas", "openapi", "swagger", "asyncapi", "api-spec", "api-specs", "apispec", "apispecs"];
12
16
  /** The folders of a gateway's proxy bundles: an entry under one is a gateway route, whatever the repo. */
@@ -38,7 +42,7 @@ export declare const ConventionFramework: z.ZodObject<{
38
42
  }, z.core.$strict>;
39
43
  export type ConventionFramework = z.infer<typeof ConventionFramework>;
40
44
  export declare const Conventions: z.ZodObject<{
41
- schemaVersion: z.ZodLiteral<1>;
45
+ schemaVersion: z.ZodUnion<readonly [z.ZodLiteral<1>, z.ZodLiteral<2>]>;
42
46
  apiSpecFolders: z.ZodDefault<z.ZodArray<z.ZodString>>;
43
47
  gatewayBundleFolders: z.ZodDefault<z.ZodArray<z.ZodString>>;
44
48
  facing: z.ZodDefault<z.ZodObject<{
@@ -59,6 +63,7 @@ export declare const Conventions: z.ZodObject<{
59
63
  notProductFolders: z.ZodDefault<z.ZodArray<z.ZodString>>;
60
64
  notReadFolders: z.ZodDefault<z.ZodArray<z.ZodString>>;
61
65
  housePrefixes: z.ZodDefault<z.ZodArray<z.ZodString>>;
66
+ notes: z.ZodOptional<z.ZodArray<z.ZodString>>;
62
67
  }, z.core.$strict>;
63
68
  export type Conventions = z.infer<typeof Conventions>;
64
69
  /** The conventions of a pack without conventions.yaml: the built-in lists. */
@@ -21,6 +21,7 @@ export declare const FactCorrection: z.ZodObject<{
21
21
  kind: z.ZodEnum<{
22
22
  config: "config";
23
23
  field: "field";
24
+ term: "term";
24
25
  framework: "framework";
25
26
  entry: "entry";
26
27
  store: "store";
@@ -1,5 +1,5 @@
1
1
  import { z } from "zod";
2
- export declare const FACT_KINDS: readonly ["entry", "call", "store", "field", "deploy", "config", "framework", "flow"];
2
+ export declare const FACT_KINDS: readonly ["entry", "call", "store", "field", "deploy", "config", "framework", "flow", "term"];
3
3
  export type FactKind = (typeof FACT_KINDS)[number];
4
4
  /** A fact's id: any slug the assistant chooses; the projection makes catalog ids from the claim. */
5
5
  export declare const FactId: z.ZodString;
@@ -13,6 +13,21 @@ export declare const CitePart: z.ZodObject<{
13
13
  line: z.ZodNumber;
14
14
  value: z.ZodString;
15
15
  }, z.core.$strict>;
16
+ /**
17
+ * The line a call's `auth` or `tls` rests on (ADR 0163), with the other lines it is set from
18
+ * (`with`, as a claim's): the line that builds the client certificate's context the cited line
19
+ * passes. Each part names its own value, as a `cite.with` part does.
20
+ */
21
+ export declare const SecurityCite: z.ZodObject<{
22
+ file: z.ZodString;
23
+ line: z.ZodNumber;
24
+ value: z.ZodString;
25
+ with: z.ZodOptional<z.ZodArray<z.ZodObject<{
26
+ file: z.ZodString;
27
+ line: z.ZodNumber;
28
+ value: z.ZodString;
29
+ }, z.core.$strict>>>;
30
+ }, z.core.$strict>;
16
31
  /**
17
32
  * Where a fact rests. `value` is what the verifier looks for on the line (the route, the topic,
18
33
  * the table, the field, the host or the key); `quote` is the line's text, or enough of it, as a
@@ -171,6 +186,9 @@ export declare const EntryFact: z.ZodObject<{
171
186
  kind: z.ZodLiteral<"entry">;
172
187
  }, z.core.$strict>;
173
188
  export declare const CALL_TYPES: readonly ["rest", "grpc", "soap", "graphql", "event-topic", "mq-queue", "sftp", "webhook"];
189
+ /** A call's transport security (ADR 0163). */
190
+ export declare const CALL_TLS: readonly ["mtls", "tls", "none"];
191
+ export type CallTls = (typeof CALL_TLS)[number];
174
192
  export declare const CallFact: z.ZodObject<{
175
193
  callType: z.ZodEnum<{
176
194
  rest: "rest";
@@ -192,6 +210,39 @@ export declare const CallFact: z.ZodObject<{
192
210
  sync: "sync";
193
211
  async: "async";
194
212
  }>>;
213
+ auth: z.ZodOptional<z.ZodEnum<{
214
+ none: "none";
215
+ oauth2: "oauth2";
216
+ mtls: "mtls";
217
+ "api-key": "api-key";
218
+ basic: "basic";
219
+ other: "other";
220
+ }>>;
221
+ authCite: z.ZodOptional<z.ZodObject<{
222
+ file: z.ZodString;
223
+ line: z.ZodNumber;
224
+ value: z.ZodString;
225
+ with: z.ZodOptional<z.ZodArray<z.ZodObject<{
226
+ file: z.ZodString;
227
+ line: z.ZodNumber;
228
+ value: z.ZodString;
229
+ }, z.core.$strict>>>;
230
+ }, z.core.$strict>>;
231
+ tls: z.ZodOptional<z.ZodEnum<{
232
+ none: "none";
233
+ mtls: "mtls";
234
+ tls: "tls";
235
+ }>>;
236
+ tlsCite: z.ZodOptional<z.ZodObject<{
237
+ file: z.ZodString;
238
+ line: z.ZodNumber;
239
+ value: z.ZodString;
240
+ with: z.ZodOptional<z.ZodArray<z.ZodObject<{
241
+ file: z.ZodString;
242
+ line: z.ZodNumber;
243
+ value: z.ZodString;
244
+ }, z.core.$strict>>>;
245
+ }, z.core.$strict>>;
195
246
  id: z.ZodString;
196
247
  repo: z.ZodString;
197
248
  commit: z.ZodString;
@@ -369,9 +420,15 @@ export declare const DeployFact: z.ZodObject<{
369
420
  * The facts file's shape version (ADR 0143). No line carries it: a file written before has no
370
421
  * number, reads as version 1 and parses unchanged, every field added since being optional.
371
422
  * 1: the shapes of ADR 0124 and its addenda. 2: a deploy fact's `host`, `basePath` and `exposes`.
423
+ * 3 (ADR 0163): the `term` kind, and a call's `auth`, `authCite`, `tls` and `tlsCite`.
372
424
  */
373
- export declare const FACTS_SCHEMA_VERSION: 2;
425
+ export declare const FACTS_SCHEMA_VERSION: 3;
374
426
  export declare const SETTING_KINDS: readonly ["timeout", "retry", "circuit-breaker", "rate-limit", "pool", "cache-ttl", "feature-flag", "config", "schedule"];
427
+ /**
428
+ * Whether a key and its value look like a secret: the key's last part ends in a secret word,
429
+ * and the value is neither a reference to where the secret lives nor a flag or a mode.
430
+ */
431
+ export declare function looksLikeSecret(key: string, value: string | undefined): boolean;
375
432
  export declare const ConfigFact: z.ZodObject<{
376
433
  settingKind: z.ZodDefault<z.ZodEnum<{
377
434
  config: "config";
@@ -468,6 +525,73 @@ export declare const FrameworkFact: z.ZodObject<{
468
525
  }>>;
469
526
  kind: z.ZodLiteral<"framework">;
470
527
  }, z.core.$strict>;
528
+ /**
529
+ * What a term the organisation uses says about the repo that writes it (ADR 0163): `owner`, the
530
+ * value names this repo's own system (an owner block, an `appId` of its own); `consumer`, it names
531
+ * a system let in or served (an entry of a `consumers` list); `none`, it names neither (a
532
+ * cost centre, a support group); `unknown`, nothing says yet, which becomes a question.
533
+ */
534
+ export declare const TERM_ROLES: readonly ["owner", "consumer", "none", "unknown"];
535
+ export type TermRole = (typeof TERM_ROLES)[number];
536
+ /**
537
+ * A term of the organisation's, as a repo writes it (ADR 0163): an identifier such as an
538
+ * application id in an access list, a CMDB id, a cost centre. Atticus knows no term itself: what
539
+ * one means comes from the notes the organisation writes on a repo type (or org-wide), in its own
540
+ * words, which the reader is handed; with no note, the reader records the identifiers it meets
541
+ * with `role: unknown`, and they are asked about once per term and repo type.
542
+ *
543
+ * `cite` is the value's line (the verifier looks for `value` there). `meaning` is the line that
544
+ * gives it its role (the `"consumers": [` line, an owner block's key), in the same file, at or
545
+ * above the value's line; an owner or consumer needs one. A kind of its own: its subject is an
546
+ * identifier no other kind holds, and the joins read it across repos.
547
+ */
548
+ export declare const TermFact: z.ZodObject<{
549
+ term: z.ZodString;
550
+ value: z.ZodString;
551
+ role: z.ZodEnum<{
552
+ unknown: "unknown";
553
+ owner: "owner";
554
+ none: "none";
555
+ consumer: "consumer";
556
+ }>;
557
+ note: z.ZodOptional<z.ZodString>;
558
+ meaning: z.ZodOptional<z.ZodObject<{
559
+ file: z.ZodString;
560
+ line: z.ZodNumber;
561
+ value: z.ZodString;
562
+ }, z.core.$strict>>;
563
+ id: z.ZodString;
564
+ repo: z.ZodString;
565
+ commit: z.ZodString;
566
+ component: z.ZodOptional<z.ZodString>;
567
+ cite: z.ZodObject<{
568
+ file: z.ZodString;
569
+ line: z.ZodNumber;
570
+ value: z.ZodString;
571
+ quote: z.ZodOptional<z.ZodString>;
572
+ with: z.ZodOptional<z.ZodArray<z.ZodObject<{
573
+ file: z.ZodString;
574
+ line: z.ZodNumber;
575
+ value: z.ZodString;
576
+ }, z.core.$strict>>>;
577
+ }, z.core.$strict>;
578
+ verified: z.ZodDefault<z.ZodEnum<{
579
+ line: "line";
580
+ none: "none";
581
+ person: "person";
582
+ sample: "sample";
583
+ }>>;
584
+ by: z.ZodDefault<z.ZodEnum<{
585
+ person: "person";
586
+ assistant: "assistant";
587
+ reader: "reader";
588
+ }>>;
589
+ conf: z.ZodDefault<z.ZodEnum<{
590
+ inferred: "inferred";
591
+ declared: "declared";
592
+ }>>;
593
+ kind: z.ZodLiteral<"term">;
594
+ }, z.core.$strict>;
471
595
  export declare const FlowFactStep: z.ZodObject<{
472
596
  kind: z.ZodEnum<{
473
597
  transform: "transform";
@@ -707,6 +831,39 @@ export declare const Fact: z.ZodDiscriminatedUnion<[z.ZodObject<{
707
831
  sync: "sync";
708
832
  async: "async";
709
833
  }>>;
834
+ auth: z.ZodOptional<z.ZodEnum<{
835
+ none: "none";
836
+ oauth2: "oauth2";
837
+ mtls: "mtls";
838
+ "api-key": "api-key";
839
+ basic: "basic";
840
+ other: "other";
841
+ }>>;
842
+ authCite: z.ZodOptional<z.ZodObject<{
843
+ file: z.ZodString;
844
+ line: z.ZodNumber;
845
+ value: z.ZodString;
846
+ with: z.ZodOptional<z.ZodArray<z.ZodObject<{
847
+ file: z.ZodString;
848
+ line: z.ZodNumber;
849
+ value: z.ZodString;
850
+ }, z.core.$strict>>>;
851
+ }, z.core.$strict>>;
852
+ tls: z.ZodOptional<z.ZodEnum<{
853
+ none: "none";
854
+ mtls: "mtls";
855
+ tls: "tls";
856
+ }>>;
857
+ tlsCite: z.ZodOptional<z.ZodObject<{
858
+ file: z.ZodString;
859
+ line: z.ZodNumber;
860
+ value: z.ZodString;
861
+ with: z.ZodOptional<z.ZodArray<z.ZodObject<{
862
+ file: z.ZodString;
863
+ line: z.ZodNumber;
864
+ value: z.ZodString;
865
+ }, z.core.$strict>>>;
866
+ }, z.core.$strict>>;
710
867
  id: z.ZodString;
711
868
  repo: z.ZodString;
712
869
  commit: z.ZodString;
@@ -1038,6 +1195,52 @@ export declare const Fact: z.ZodDiscriminatedUnion<[z.ZodObject<{
1038
1195
  declared: "declared";
1039
1196
  }>>;
1040
1197
  kind: z.ZodLiteral<"flow">;
1198
+ }, z.core.$strict>, z.ZodObject<{
1199
+ term: z.ZodString;
1200
+ value: z.ZodString;
1201
+ role: z.ZodEnum<{
1202
+ unknown: "unknown";
1203
+ owner: "owner";
1204
+ none: "none";
1205
+ consumer: "consumer";
1206
+ }>;
1207
+ note: z.ZodOptional<z.ZodString>;
1208
+ meaning: z.ZodOptional<z.ZodObject<{
1209
+ file: z.ZodString;
1210
+ line: z.ZodNumber;
1211
+ value: z.ZodString;
1212
+ }, z.core.$strict>>;
1213
+ id: z.ZodString;
1214
+ repo: z.ZodString;
1215
+ commit: z.ZodString;
1216
+ component: z.ZodOptional<z.ZodString>;
1217
+ cite: z.ZodObject<{
1218
+ file: z.ZodString;
1219
+ line: z.ZodNumber;
1220
+ value: z.ZodString;
1221
+ quote: z.ZodOptional<z.ZodString>;
1222
+ with: z.ZodOptional<z.ZodArray<z.ZodObject<{
1223
+ file: z.ZodString;
1224
+ line: z.ZodNumber;
1225
+ value: z.ZodString;
1226
+ }, z.core.$strict>>>;
1227
+ }, z.core.$strict>;
1228
+ verified: z.ZodDefault<z.ZodEnum<{
1229
+ line: "line";
1230
+ none: "none";
1231
+ person: "person";
1232
+ sample: "sample";
1233
+ }>>;
1234
+ by: z.ZodDefault<z.ZodEnum<{
1235
+ person: "person";
1236
+ assistant: "assistant";
1237
+ reader: "reader";
1238
+ }>>;
1239
+ conf: z.ZodDefault<z.ZodEnum<{
1240
+ inferred: "inferred";
1241
+ declared: "declared";
1242
+ }>>;
1243
+ kind: z.ZodLiteral<"term">;
1041
1244
  }, z.core.$strict>], "kind">;
1042
1245
  export type Fact = z.infer<typeof Fact>;
1043
1246
  export type FactOf<K extends FactKind> = Extract<Fact, {
@@ -1157,6 +1360,39 @@ export declare const FactsFile: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<
1157
1360
  sync: "sync";
1158
1361
  async: "async";
1159
1362
  }>>;
1363
+ auth: z.ZodOptional<z.ZodEnum<{
1364
+ none: "none";
1365
+ oauth2: "oauth2";
1366
+ mtls: "mtls";
1367
+ "api-key": "api-key";
1368
+ basic: "basic";
1369
+ other: "other";
1370
+ }>>;
1371
+ authCite: z.ZodOptional<z.ZodObject<{
1372
+ file: z.ZodString;
1373
+ line: z.ZodNumber;
1374
+ value: z.ZodString;
1375
+ with: z.ZodOptional<z.ZodArray<z.ZodObject<{
1376
+ file: z.ZodString;
1377
+ line: z.ZodNumber;
1378
+ value: z.ZodString;
1379
+ }, z.core.$strict>>>;
1380
+ }, z.core.$strict>>;
1381
+ tls: z.ZodOptional<z.ZodEnum<{
1382
+ none: "none";
1383
+ mtls: "mtls";
1384
+ tls: "tls";
1385
+ }>>;
1386
+ tlsCite: z.ZodOptional<z.ZodObject<{
1387
+ file: z.ZodString;
1388
+ line: z.ZodNumber;
1389
+ value: z.ZodString;
1390
+ with: z.ZodOptional<z.ZodArray<z.ZodObject<{
1391
+ file: z.ZodString;
1392
+ line: z.ZodNumber;
1393
+ value: z.ZodString;
1394
+ }, z.core.$strict>>>;
1395
+ }, z.core.$strict>>;
1160
1396
  id: z.ZodString;
1161
1397
  repo: z.ZodString;
1162
1398
  commit: z.ZodString;
@@ -1488,4 +1724,50 @@ export declare const FactsFile: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<
1488
1724
  declared: "declared";
1489
1725
  }>>;
1490
1726
  kind: z.ZodLiteral<"flow">;
1727
+ }, z.core.$strict>, z.ZodObject<{
1728
+ term: z.ZodString;
1729
+ value: z.ZodString;
1730
+ role: z.ZodEnum<{
1731
+ unknown: "unknown";
1732
+ owner: "owner";
1733
+ none: "none";
1734
+ consumer: "consumer";
1735
+ }>;
1736
+ note: z.ZodOptional<z.ZodString>;
1737
+ meaning: z.ZodOptional<z.ZodObject<{
1738
+ file: z.ZodString;
1739
+ line: z.ZodNumber;
1740
+ value: z.ZodString;
1741
+ }, z.core.$strict>>;
1742
+ id: z.ZodString;
1743
+ repo: z.ZodString;
1744
+ commit: z.ZodString;
1745
+ component: z.ZodOptional<z.ZodString>;
1746
+ cite: z.ZodObject<{
1747
+ file: z.ZodString;
1748
+ line: z.ZodNumber;
1749
+ value: z.ZodString;
1750
+ quote: z.ZodOptional<z.ZodString>;
1751
+ with: z.ZodOptional<z.ZodArray<z.ZodObject<{
1752
+ file: z.ZodString;
1753
+ line: z.ZodNumber;
1754
+ value: z.ZodString;
1755
+ }, z.core.$strict>>>;
1756
+ }, z.core.$strict>;
1757
+ verified: z.ZodDefault<z.ZodEnum<{
1758
+ line: "line";
1759
+ none: "none";
1760
+ person: "person";
1761
+ sample: "sample";
1762
+ }>>;
1763
+ by: z.ZodDefault<z.ZodEnum<{
1764
+ person: "person";
1765
+ assistant: "assistant";
1766
+ reader: "reader";
1767
+ }>>;
1768
+ conf: z.ZodDefault<z.ZodEnum<{
1769
+ inferred: "inferred";
1770
+ declared: "declared";
1771
+ }>>;
1772
+ kind: z.ZodLiteral<"term">;
1491
1773
  }, z.core.$strict>], "kind">>;