@coderifts/sdk 3.0.0 → 3.1.1
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/cjs/client.d.ts +18 -4
- package/dist/cjs/client.d.ts.map +1 -1
- package/dist/cjs/client.js +28 -4
- package/dist/cjs/client.js.map +1 -1
- package/dist/cjs/generated/decision-result.v1.d.ts +81 -0
- package/dist/cjs/generated/decision-result.v1.d.ts.map +1 -1
- package/dist/cjs/generated/preflight-response.v2.d.ts +289 -0
- package/dist/cjs/generated/preflight-response.v2.d.ts.map +1 -0
- package/dist/cjs/generated/preflight-response.v2.js +20 -0
- package/dist/cjs/generated/preflight-response.v2.js.map +1 -0
- package/dist/cjs/index.d.ts +1 -1
- package/dist/cjs/index.d.ts.map +1 -1
- package/dist/cjs/types.d.ts +73 -73
- package/dist/cjs/types.d.ts.map +1 -1
- package/dist/esm/client.d.ts +18 -4
- package/dist/esm/client.d.ts.map +1 -1
- package/dist/esm/client.js +28 -4
- package/dist/esm/client.js.map +1 -1
- package/dist/esm/generated/decision-result.v1.d.ts +81 -0
- package/dist/esm/generated/decision-result.v1.d.ts.map +1 -1
- package/dist/esm/generated/preflight-response.v2.d.ts +289 -0
- package/dist/esm/generated/preflight-response.v2.d.ts.map +1 -0
- package/dist/esm/generated/preflight-response.v2.js +19 -0
- package/dist/esm/generated/preflight-response.v2.js.map +1 -0
- package/dist/esm/index.d.ts +1 -1
- package/dist/esm/index.d.ts.map +1 -1
- package/dist/esm/types.d.ts +73 -73
- package/dist/esm/types.d.ts.map +1 -1
- package/package.json +3 -2
|
@@ -0,0 +1,289 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* DO NOT EDIT — generated from schemas/preflight-response.v2.producer.json
|
|
3
|
+
*
|
|
4
|
+
* Source of truth: coderifts-app/schemas/preflight-response.v2.producer.json (shape)
|
|
5
|
+
* coderifts-app/schemas/preflight-response.v2.consumer.json (required-ness)
|
|
6
|
+
* Generator: coderifts-app/scripts/generate-preflight-response-types.js
|
|
7
|
+
*
|
|
8
|
+
* node scripts/generate-preflight-response-types.js --out <path>
|
|
9
|
+
* node scripts/generate-preflight-response-types.js --out <path> --check
|
|
10
|
+
*
|
|
11
|
+
* Hand-editing this file will be overwritten. To change types, update the v2 schemas and
|
|
12
|
+
* re-run the generator. This union was hand-maintained in src/types.ts until ID819 and drifted
|
|
13
|
+
* from the schema by hand (ID804 class); src/types.ts now re-exports these names.
|
|
14
|
+
*
|
|
15
|
+
* Required-ness follows the CONSUMER schema (the SDK is a reader — over-claiming presence is
|
|
16
|
+
* the bug this generation exists to prevent); the property set follows the PRODUCER schema.
|
|
17
|
+
*/
|
|
18
|
+
import type { Decision, ExecutionAction, DecisionEvidence, DecisionResultEnvelope } from './decision-result.v1.js';
|
|
19
|
+
import type { ChangeSetArtifactFinding } from '../types.js';
|
|
20
|
+
/**
|
|
21
|
+
* CodeRifts preflight-response.v2 — discriminated on preflight_mode. Narrow on preflight_mode before reading mode-specific fields. Canonical contract; do not hand-edit the generated .ts.
|
|
22
|
+
*/
|
|
23
|
+
export type PreflightChangeSetResponse = AnalyzeChangeSetResponse | AuthorizeChangeSetResponse;
|
|
24
|
+
export interface AnalyzeChangeSetResponse {
|
|
25
|
+
preflight_mode: 'analyze';
|
|
26
|
+
/**
|
|
27
|
+
* Closed analysis outcome set derived from engine-visible state only.
|
|
28
|
+
*/
|
|
29
|
+
analysis_outcome: 'NO_BREAK_DETECTED' | 'BREAKS_DETECTED' | 'ANALYSIS_FAILED';
|
|
30
|
+
/**
|
|
31
|
+
* Analyze never authorizes; always NONE.
|
|
32
|
+
*/
|
|
33
|
+
authorization_effect: 'NONE';
|
|
34
|
+
/**
|
|
35
|
+
* Analyze never grants execute permission.
|
|
36
|
+
*/
|
|
37
|
+
may_execute: false;
|
|
38
|
+
/**
|
|
39
|
+
* Analyze never mints a receipt.
|
|
40
|
+
*/
|
|
41
|
+
receipt_kind: 'NONE';
|
|
42
|
+
/**
|
|
43
|
+
* Decision Spec major for this response (typically '2.0').
|
|
44
|
+
*/
|
|
45
|
+
decision_spec_version: string;
|
|
46
|
+
risk_score?: number;
|
|
47
|
+
breaking_changes?: number;
|
|
48
|
+
requires_migration?: boolean;
|
|
49
|
+
evidence_quality?: string;
|
|
50
|
+
patterns?: string[];
|
|
51
|
+
pattern_sources?: unknown[];
|
|
52
|
+
bundle_fingerprint?: string;
|
|
53
|
+
verdict_fingerprint?: string;
|
|
54
|
+
artifacts?: ChangeSetArtifactFinding[];
|
|
55
|
+
evidence?: DecisionEvidence[];
|
|
56
|
+
meta?: {
|
|
57
|
+
[k: string]: unknown;
|
|
58
|
+
};
|
|
59
|
+
correlation_id?: string;
|
|
60
|
+
timestamp?: string;
|
|
61
|
+
operation?: unknown;
|
|
62
|
+
decision_basis?: unknown;
|
|
63
|
+
analysis_control?: {
|
|
64
|
+
[k: string]: unknown;
|
|
65
|
+
};
|
|
66
|
+
/**
|
|
67
|
+
* GOVERNANCE detector detail rows (src/change-patterns.js; validated by decision-spec-fields.js). Row shape measured live: name, severity, description, consequence, affected_path, af…
|
|
68
|
+
*/
|
|
69
|
+
detected_patterns?: {
|
|
70
|
+
/**
|
|
71
|
+
* Governance pattern name; appears in patterns when both are carried.
|
|
72
|
+
*/
|
|
73
|
+
name: string;
|
|
74
|
+
/**
|
|
75
|
+
* Row severity from the pattern catalog (observed set: CRITICAL, HIGH, MEDIUM). NOT a closed control enum — branch on execution_action, never on this.
|
|
76
|
+
*/
|
|
77
|
+
severity: string;
|
|
78
|
+
/**
|
|
79
|
+
* What the detector matched. Untrusted free text.
|
|
80
|
+
*/
|
|
81
|
+
description: string;
|
|
82
|
+
/**
|
|
83
|
+
* What breaks for a consumer if this ships. Untrusted free text.
|
|
84
|
+
*/
|
|
85
|
+
consequence: string;
|
|
86
|
+
/**
|
|
87
|
+
* Contract path this row is about. Empty string when the detector had none — the key is always emitted.
|
|
88
|
+
*/
|
|
89
|
+
affected_path: string;
|
|
90
|
+
/**
|
|
91
|
+
* Field within affected_path. Empty string when the detector had none — the key is always emitted.
|
|
92
|
+
*/
|
|
93
|
+
affected_field: string;
|
|
94
|
+
/**
|
|
95
|
+
* Optional; currently set on ENUM_NARROWING only. Request-side narrowing is agent-breaking (threaded so safe_for_agent can distinguish it). Absent when the detector did not set it.
|
|
96
|
+
*/
|
|
97
|
+
side?: 'request' | 'response';
|
|
98
|
+
}[];
|
|
99
|
+
/**
|
|
100
|
+
* Per-change IR/detail rows from the engine (src/blast/diff-to-change.js maps these). Measured row keys: type, path, method, field, severity, description. Distinct from breaking_chan…
|
|
101
|
+
*/
|
|
102
|
+
breaking_changes_details?: {
|
|
103
|
+
/**
|
|
104
|
+
* Change kind / IR type code (e.g. response.body.property.remove).
|
|
105
|
+
*/
|
|
106
|
+
type?: string;
|
|
107
|
+
path?: string;
|
|
108
|
+
method?: string;
|
|
109
|
+
field?: string;
|
|
110
|
+
severity?: string;
|
|
111
|
+
description?: string;
|
|
112
|
+
[k: string]: unknown;
|
|
113
|
+
}[];
|
|
114
|
+
/**
|
|
115
|
+
* Bundle severity axes (src/change-set.js severity_summary). Distinct axes, not contradictory. Measured keys: diff_severity, governance_severity, policy_effect, note.
|
|
116
|
+
*/
|
|
117
|
+
severity_summary?: {
|
|
118
|
+
/**
|
|
119
|
+
* Structural size of the schema change.
|
|
120
|
+
*/
|
|
121
|
+
diff_severity?: string;
|
|
122
|
+
/**
|
|
123
|
+
* How the rule engine rates the change.
|
|
124
|
+
*/
|
|
125
|
+
governance_severity?: string;
|
|
126
|
+
/**
|
|
127
|
+
* Resulting decision effect label.
|
|
128
|
+
*/
|
|
129
|
+
policy_effect?: string;
|
|
130
|
+
note?: string;
|
|
131
|
+
};
|
|
132
|
+
/**
|
|
133
|
+
* Tier-2 analysis mirror (src/response-envelope.js buildAnalysisTier / attachControlSurface). Dual-write of flat analysis fields present on the verdict plus remediations[]. ANALYSIS_…
|
|
134
|
+
*/
|
|
135
|
+
analysis?: {
|
|
136
|
+
[k: string]: unknown;
|
|
137
|
+
};
|
|
138
|
+
/**
|
|
139
|
+
* Human-readable report tier (src/response-envelope.js buildHumanReport / analyze v2 stub). Measured keys: summary, breaking_highlights, suggestions, next_steps_prose.
|
|
140
|
+
*/
|
|
141
|
+
human_report?: {
|
|
142
|
+
summary?: string;
|
|
143
|
+
breaking_highlights?: unknown[];
|
|
144
|
+
suggestions?: unknown[];
|
|
145
|
+
next_steps_prose?: string;
|
|
146
|
+
};
|
|
147
|
+
/**
|
|
148
|
+
* Gateway/request correlation id (attachControlSurface). Set when correlation_id is present; alias of the request id. Distinct from decision_correlation_id on authorize when the enve…
|
|
149
|
+
*/
|
|
150
|
+
request_correlation_id?: string;
|
|
151
|
+
}
|
|
152
|
+
export interface AuthorizeChangeSetResponse {
|
|
153
|
+
preflight_mode: 'authorize';
|
|
154
|
+
decision: Decision;
|
|
155
|
+
execution_action: ExecutionAction;
|
|
156
|
+
safe_for_agent: boolean;
|
|
157
|
+
/**
|
|
158
|
+
* operation_authorization when a chain receipt was issued; NONE if signer unconfigured.
|
|
159
|
+
*/
|
|
160
|
+
receipt_kind: 'operation_authorization' | 'NONE';
|
|
161
|
+
chain_receipt?: string;
|
|
162
|
+
chain_status?: string;
|
|
163
|
+
/**
|
|
164
|
+
* decision-result.v1 envelope when issuance path produced one (validate with decision-result.v1.producer.json).
|
|
165
|
+
*/
|
|
166
|
+
decision_result?: DecisionResultEnvelope;
|
|
167
|
+
/**
|
|
168
|
+
* Decision Spec major for this response (typically '2.0').
|
|
169
|
+
*/
|
|
170
|
+
decision_spec_version: string;
|
|
171
|
+
risk_score?: number;
|
|
172
|
+
breaking_changes?: number;
|
|
173
|
+
requires_migration?: boolean;
|
|
174
|
+
evidence_quality?: string;
|
|
175
|
+
patterns?: string[];
|
|
176
|
+
pattern_sources?: unknown[];
|
|
177
|
+
bundle_fingerprint?: string;
|
|
178
|
+
verdict_fingerprint?: string;
|
|
179
|
+
artifacts?: ChangeSetArtifactFinding[];
|
|
180
|
+
evidence?: DecisionEvidence[];
|
|
181
|
+
meta?: {
|
|
182
|
+
[k: string]: unknown;
|
|
183
|
+
};
|
|
184
|
+
correlation_id?: string;
|
|
185
|
+
timestamp?: string;
|
|
186
|
+
operation?: unknown;
|
|
187
|
+
decision_basis?: unknown;
|
|
188
|
+
coderifts_version?: string;
|
|
189
|
+
decision_semantic_hash?: unknown;
|
|
190
|
+
control_envelope?: {
|
|
191
|
+
[k: string]: unknown;
|
|
192
|
+
};
|
|
193
|
+
/**
|
|
194
|
+
* GOVERNANCE detector detail rows (src/change-patterns.js; validated by decision-spec-fields.js). Row shape measured live: name, severity, description, consequence, affected_path, af…
|
|
195
|
+
*/
|
|
196
|
+
detected_patterns?: {
|
|
197
|
+
/**
|
|
198
|
+
* Governance pattern name; appears in patterns when both are carried.
|
|
199
|
+
*/
|
|
200
|
+
name: string;
|
|
201
|
+
/**
|
|
202
|
+
* Row severity from the pattern catalog (observed set: CRITICAL, HIGH, MEDIUM). NOT a closed control enum — branch on execution_action, never on this.
|
|
203
|
+
*/
|
|
204
|
+
severity: string;
|
|
205
|
+
/**
|
|
206
|
+
* What the detector matched. Untrusted free text.
|
|
207
|
+
*/
|
|
208
|
+
description: string;
|
|
209
|
+
/**
|
|
210
|
+
* What breaks for a consumer if this ships. Untrusted free text.
|
|
211
|
+
*/
|
|
212
|
+
consequence: string;
|
|
213
|
+
/**
|
|
214
|
+
* Contract path this row is about. Empty string when the detector had none — the key is always emitted.
|
|
215
|
+
*/
|
|
216
|
+
affected_path: string;
|
|
217
|
+
/**
|
|
218
|
+
* Field within affected_path. Empty string when the detector had none — the key is always emitted.
|
|
219
|
+
*/
|
|
220
|
+
affected_field: string;
|
|
221
|
+
/**
|
|
222
|
+
* Optional; currently set on ENUM_NARROWING only. Request-side narrowing is agent-breaking (threaded so safe_for_agent can distinguish it). Absent when the detector did not set it.
|
|
223
|
+
*/
|
|
224
|
+
side?: 'request' | 'response';
|
|
225
|
+
}[];
|
|
226
|
+
/**
|
|
227
|
+
* Per-change IR/detail rows from the engine (src/blast/diff-to-change.js maps these). Measured row keys: type, path, method, field, severity, description. Distinct from breaking_chan…
|
|
228
|
+
*/
|
|
229
|
+
breaking_changes_details?: {
|
|
230
|
+
/**
|
|
231
|
+
* Change kind / IR type code (e.g. response.body.property.remove).
|
|
232
|
+
*/
|
|
233
|
+
type?: string;
|
|
234
|
+
path?: string;
|
|
235
|
+
method?: string;
|
|
236
|
+
field?: string;
|
|
237
|
+
severity?: string;
|
|
238
|
+
description?: string;
|
|
239
|
+
[k: string]: unknown;
|
|
240
|
+
}[];
|
|
241
|
+
/**
|
|
242
|
+
* Bundle severity axes (src/change-set.js severity_summary). Distinct axes, not contradictory. Measured keys: diff_severity, governance_severity, policy_effect, note.
|
|
243
|
+
*/
|
|
244
|
+
severity_summary?: {
|
|
245
|
+
/**
|
|
246
|
+
* Structural size of the schema change.
|
|
247
|
+
*/
|
|
248
|
+
diff_severity?: string;
|
|
249
|
+
/**
|
|
250
|
+
* How the rule engine rates the change.
|
|
251
|
+
*/
|
|
252
|
+
governance_severity?: string;
|
|
253
|
+
/**
|
|
254
|
+
* Resulting decision effect label.
|
|
255
|
+
*/
|
|
256
|
+
policy_effect?: string;
|
|
257
|
+
note?: string;
|
|
258
|
+
};
|
|
259
|
+
/**
|
|
260
|
+
* Tier-2 analysis mirror (src/response-envelope.js buildAnalysisTier / attachControlSurface). Dual-write of flat analysis fields present on the verdict plus remediations[]. ANALYSIS_…
|
|
261
|
+
*/
|
|
262
|
+
analysis?: {
|
|
263
|
+
[k: string]: unknown;
|
|
264
|
+
};
|
|
265
|
+
/**
|
|
266
|
+
* Human-readable report tier (src/response-envelope.js buildHumanReport / analyze v2 stub). Measured keys: summary, breaking_highlights, suggestions, next_steps_prose.
|
|
267
|
+
*/
|
|
268
|
+
human_report?: {
|
|
269
|
+
summary?: string;
|
|
270
|
+
breaking_highlights?: unknown[];
|
|
271
|
+
suggestions?: unknown[];
|
|
272
|
+
next_steps_prose?: string;
|
|
273
|
+
};
|
|
274
|
+
/**
|
|
275
|
+
* Gateway/request correlation id (attachControlSurface). Set when correlation_id is present; alias of the request id. Distinct from decision_correlation_id on authorize when the enve…
|
|
276
|
+
*/
|
|
277
|
+
request_correlation_id?: string;
|
|
278
|
+
/**
|
|
279
|
+
* Decision envelope correlation id (attachControlSurface). Present on authorize when decision_result.correlation_id is set. Distinct from request_correlation_id / correlation_id (req…
|
|
280
|
+
*/
|
|
281
|
+
decision_correlation_id?: string;
|
|
282
|
+
}
|
|
283
|
+
/** @public Closed analysis outcome set (analyze only; derived from engine-visible state). */
|
|
284
|
+
export type AnalysisOutcome = AnalyzeChangeSetResponse['analysis_outcome'];
|
|
285
|
+
/** @public Receipt kind on an authorize response (`operation_authorization` when a receipt was issued). */
|
|
286
|
+
export type AuthorizeReceiptKind = NonNullable<AuthorizeChangeSetResponse['receipt_kind']>;
|
|
287
|
+
/** @public The discriminator itself, as the response side declares it. */
|
|
288
|
+
export type PreflightResponseMode = PreflightChangeSetResponse['preflight_mode'];
|
|
289
|
+
//# sourceMappingURL=preflight-response.v2.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"preflight-response.v2.d.ts","sourceRoot":"","sources":["../../../src/generated/preflight-response.v2.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAKH,OAAO,KAAK,EACV,QAAQ,EACR,eAAe,EACf,gBAAgB,EAChB,sBAAsB,EACvB,MAAM,yBAAyB,CAAC;AACjC,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,aAAa,CAAC;AAC5D;;GAEG;AACH,MAAM,MAAM,0BAA0B,GAAG,wBAAwB,GAAG,0BAA0B,CAAC;AAE/F,MAAM,WAAW,wBAAwB;IACvC,cAAc,EAAE,SAAS,CAAC;IAC1B;;OAEG;IACH,gBAAgB,EAAE,mBAAmB,GAAG,iBAAiB,GAAG,iBAAiB,CAAC;IAC9E;;OAEG;IACH,oBAAoB,EAAE,MAAM,CAAC;IA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CAAC"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* DO NOT EDIT — generated from schemas/preflight-response.v2.producer.json
|
|
3
|
+
*
|
|
4
|
+
* Source of truth: coderifts-app/schemas/preflight-response.v2.producer.json (shape)
|
|
5
|
+
* coderifts-app/schemas/preflight-response.v2.consumer.json (required-ness)
|
|
6
|
+
* Generator: coderifts-app/scripts/generate-preflight-response-types.js
|
|
7
|
+
*
|
|
8
|
+
* node scripts/generate-preflight-response-types.js --out <path>
|
|
9
|
+
* node scripts/generate-preflight-response-types.js --out <path> --check
|
|
10
|
+
*
|
|
11
|
+
* Hand-editing this file will be overwritten. To change types, update the v2 schemas and
|
|
12
|
+
* re-run the generator. This union was hand-maintained in src/types.ts until ID819 and drifted
|
|
13
|
+
* from the schema by hand (ID804 class); src/types.ts now re-exports these names.
|
|
14
|
+
*
|
|
15
|
+
* Required-ness follows the CONSUMER schema (the SDK is a reader — over-claiming presence is
|
|
16
|
+
* the bug this generation exists to prevent); the property set follows the PRODUCER schema.
|
|
17
|
+
*/
|
|
18
|
+
export {};
|
|
19
|
+
//# sourceMappingURL=preflight-response.v2.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"preflight-response.v2.js","sourceRoot":"","sources":["../../../src/generated/preflight-response.v2.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG"}
|
package/dist/esm/index.d.ts
CHANGED
|
@@ -16,5 +16,5 @@ export { CodeRifts } from './client.js';
|
|
|
16
16
|
export { CodeRiftsError, ApiError, TimeoutError, RateLimitError, AuthError } from './errors.js';
|
|
17
17
|
export { readDecision } from './decision.js';
|
|
18
18
|
export type { ReadDecisionResult } from './decision.js';
|
|
19
|
-
export type { CodeRiftsOptions, ApiErrorBody, PreflightCheckRequest, PreflightCheckResponse, ReflexTrigger, AffectedTool, DiffRequest, DiffResponse, BreakingChange, ExplainDecisionRequest, ExplainDecisionResponse, ExplainComponent, HowToUnblockRequest, HowToUnblockResponse, UnblockAction, ScoreMcpRequest, ScoreMcpResponse, GetLedgerRequest, GetLedgerResponse, LedgerEntry, SimulatePolicyRequest, SimulatePolicyResponse, MatchedRule, Decision, ExecutionAction, ReceiptStatus, DecisionReason, NextAction, DecisionReceipt, DecisionEvidence, DecisionResultEnvelope, Artifact, PreflightMode, PreflightChangeSetContext, PreflightChangeSetRequest, PreflightChangeSetBody, ChangeSetArtifactFinding, AnalysisOutcome, AuthorizeReceiptKind, AnalyzeChangeSetResponse, AuthorizeChangeSetResponse, PreflightChangeSetResponse, VerifyReceiptResponse, DecisionLookupRequest, DecisionLookupResponse, } from './types.js';
|
|
19
|
+
export type { CodeRiftsOptions, ApiErrorBody, PreflightCheckRequest, PreflightCheckResponse, ReflexTrigger, AffectedTool, DiffRequest, DiffResponse, BreakingChange, ExplainDecisionRequest, ExplainDecisionResponse, ExplainComponent, HowToUnblockRequest, HowToUnblockResponse, UnblockAction, ScoreMcpRequest, ScoreMcpResponse, GetLedgerRequest, GetLedgerResponse, LedgerEntry, SimulatePolicyRequest, SimulatePolicyResponse, MatchedRule, Decision, ExecutionAction, ReceiptStatus, DecisionReason, NextAction, DecisionReceipt, DecisionEvidence, DecisionResultEnvelope, Artifact, PreflightMode, PreflightChangeSetContext, PreflightChangeSetRequest, PreflightChangeSetBody, ChangeSetArtifactFinding, AnalysisOutcome, AuthorizeReceiptKind, AnalyzeChangeSetResponse, AuthorizeChangeSetResponse, PreflightChangeSetResponse, VerifyReceiptIntendedContext, VerifyReceiptResponse, DecisionLookupRequest, DecisionLookupResponse, } from './types.js';
|
|
20
20
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/esm/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAEH,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,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Aa,EACb,YAAY,EACZ,WAAW,EACX,YAAY,EACZ,cAAc,EACd,sBAAsB,EACtB,uBAAuB,EACvB,gBAAgB,EAChB,mBAAmB,EACnB,oBAAoB,EACpB,aAAa,EACb,eAAe,EACf,gBAAgB,EAChB,gBAAgB,EAChB,iBAAiB,EACjB,WAAW,EACX,qBAAqB,EACrB,sBAAsB,EACtB,WAAW,EACX,QAAQ,EACR,eAAe,EACf,aAAa,EACb,cAAc,EACd,UAAU,EACV,eAAe,EACf,gBAAgB,EAChB,sBAAsB,EACtB,QAAQ,EACR,aAAa,EACb,yBAAyB,EACzB,yBAAyB,EACzB,sBAAsB,EACtB,wBAAwB,EACxB,eAAe,EACf,oBAAoB,EACpB,wBAAwB,EACxB,0BAA0B,EAC1B,0BAA0B,EAC1B,4BAA4B,EAC5B,qBAAqB,EACrB,qBAAqB,EACrB,sBAAsB,GACzB,MAAM,YAAY,CAAC"}
|
package/dist/esm/types.d.ts
CHANGED
|
@@ -174,7 +174,7 @@ export type { DecisionResultEnvelope, Decision, ExecutionAction, DecisionReason,
|
|
|
174
174
|
export type ReceiptStatus = 'VERIFIED_CURRENT' | 'VERIFIED_EXPIRED' | 'VERIFIED_WRONG_AUDIENCE' | 'VERIFIED_WRONG_ENVIRONMENT' | 'VERIFIED_SUPERSEDED' | 'VERIFIED_SCOPE_MISMATCH' | 'UNKNOWN_KEY' | 'RETIRED_KEY_VALID_AT_ISSUE' | 'INVALID_SIGNATURE' | 'MALFORMED' | 'UNSUPPORTED_VERSION' | 'REGISTRY_UNREACHABLE';
|
|
175
175
|
export interface Artifact {
|
|
176
176
|
id: string;
|
|
177
|
-
type: 'openapi' | 'graphql' | 'grpc' | 'asyncapi' | 'mcp_manifest';
|
|
177
|
+
type: 'openapi' | 'graphql' | 'grpc' | 'asyncapi' | 'mcp_manifest' | 'agent_tools';
|
|
178
178
|
before: string;
|
|
179
179
|
after: string;
|
|
180
180
|
}
|
|
@@ -218,84 +218,31 @@ export interface ChangeSetArtifactFinding {
|
|
|
218
218
|
error?: string;
|
|
219
219
|
reason?: string;
|
|
220
220
|
}
|
|
221
|
-
|
|
222
|
-
export type AnalysisOutcome
|
|
223
|
-
/** Receipt kind on an authorize response (`operation_authorization` when a chain receipt was issued). */
|
|
224
|
-
export type AuthorizeReceiptKind = 'operation_authorization' | 'NONE';
|
|
221
|
+
import type { AnalyzeChangeSetResponse as GeneratedAnalyzeChangeSetResponse, AuthorizeChangeSetResponse as GeneratedAuthorizeChangeSetResponse, PreflightChangeSetResponse as GeneratedPreflightChangeSetResponse } from './generated/preflight-response.v2.js';
|
|
222
|
+
export type { AnalysisOutcome, AuthorizeReceiptKind } from './generated/preflight-response.v2.js';
|
|
225
223
|
/**
|
|
226
224
|
* `preflight_mode: 'analyze'` — informational risk only. NOT permission: it never authorizes,
|
|
227
225
|
* never grants execute, and never mints a receipt (hence the three literal-typed constants).
|
|
226
|
+
*
|
|
227
|
+
* The two branches are NOT one shape with optional fields. `analyze` STRUCTURALLY omits
|
|
228
|
+
* decision / execution_action / safe_for_agent — the producer schema encodes this as
|
|
229
|
+
* `not: { anyOf: [required decision|execution_action|safe_for_agent] }`, so an analyze response
|
|
230
|
+
* never carries a decision and the type must not offer one. Reading `res.safe_for_agent`
|
|
231
|
+
* without first narrowing on `preflight_mode` is a compile error, which is the point.
|
|
228
232
|
*/
|
|
229
|
-
export
|
|
230
|
-
preflight_mode: 'analyze';
|
|
231
|
-
analysis_outcome: AnalysisOutcome;
|
|
232
|
-
/** Analyze never authorizes. */
|
|
233
|
-
authorization_effect: 'NONE';
|
|
234
|
-
/** Analyze never grants execute permission. */
|
|
235
|
-
may_execute: false;
|
|
236
|
-
/** Analyze never mints a receipt. */
|
|
237
|
-
receipt_kind: 'NONE';
|
|
238
|
-
/** Decision Spec major for this response (typically '2.0'). */
|
|
239
|
-
decision_spec_version: string;
|
|
240
|
-
risk_score?: number;
|
|
241
|
-
breaking_changes?: number;
|
|
242
|
-
requires_migration?: boolean;
|
|
243
|
-
evidence_quality?: string;
|
|
244
|
-
patterns?: string[];
|
|
245
|
-
pattern_sources?: unknown[];
|
|
246
|
-
bundle_fingerprint?: string;
|
|
247
|
-
verdict_fingerprint?: string;
|
|
248
|
-
artifacts?: ChangeSetArtifactFinding[];
|
|
249
|
-
evidence?: DecisionEvidence[];
|
|
250
|
-
correlation_id?: string;
|
|
251
|
-
timestamp?: string;
|
|
252
|
-
operation?: unknown;
|
|
253
|
-
decision_basis?: unknown;
|
|
254
|
-
analysis_control?: Record<string, unknown>;
|
|
255
|
-
meta?: Record<string, unknown>;
|
|
256
|
-
}
|
|
233
|
+
export type AnalyzeChangeSetResponse = GeneratedAnalyzeChangeSetResponse;
|
|
257
234
|
/**
|
|
258
235
|
* `preflight_mode: 'authorize'` — operation-bound may-proceed. Carries the decision, the machine
|
|
259
236
|
* directive (`execution_action`), and `safe_for_agent`; may carry a chain receipt.
|
|
260
237
|
*
|
|
261
|
-
*
|
|
262
|
-
* `
|
|
263
|
-
*
|
|
238
|
+
* Two caveats the schema cannot express in TypeScript:
|
|
239
|
+
* - `safe_for_agent` is DEPRECATED for control flow — branch on `execution_action`. It stays
|
|
240
|
+
* because the schema requires it on this branch.
|
|
241
|
+
* - `chain_receipt` is required by the schema *conditionally* (when
|
|
242
|
+
* `receipt_kind === 'operation_authorization'`). TypeScript has no if/then, so it is typed
|
|
243
|
+
* optional — check `receipt_kind` before relying on it.
|
|
264
244
|
*/
|
|
265
|
-
export
|
|
266
|
-
preflight_mode: 'authorize';
|
|
267
|
-
decision: Decision;
|
|
268
|
-
execution_action: ExecutionAction;
|
|
269
|
-
/**
|
|
270
|
-
* DEPRECATED for control flow — branch on `execution_action`. Kept because the schema
|
|
271
|
-
* requires it on this branch.
|
|
272
|
-
*/
|
|
273
|
-
safe_for_agent: boolean;
|
|
274
|
-
/** Decision Spec major for this response (typically '2.0'). */
|
|
275
|
-
decision_spec_version: string;
|
|
276
|
-
receipt_kind?: AuthorizeReceiptKind;
|
|
277
|
-
chain_receipt?: string;
|
|
278
|
-
chain_status?: string;
|
|
279
|
-
decision_result?: DecisionResultEnvelope;
|
|
280
|
-
risk_score?: number;
|
|
281
|
-
breaking_changes?: number;
|
|
282
|
-
requires_migration?: boolean;
|
|
283
|
-
evidence_quality?: string;
|
|
284
|
-
patterns?: string[];
|
|
285
|
-
pattern_sources?: unknown[];
|
|
286
|
-
bundle_fingerprint?: string;
|
|
287
|
-
verdict_fingerprint?: string;
|
|
288
|
-
artifacts?: ChangeSetArtifactFinding[];
|
|
289
|
-
evidence?: DecisionEvidence[];
|
|
290
|
-
correlation_id?: string;
|
|
291
|
-
timestamp?: string;
|
|
292
|
-
operation?: unknown;
|
|
293
|
-
decision_basis?: unknown;
|
|
294
|
-
coderifts_version?: string;
|
|
295
|
-
decision_semantic_hash?: unknown;
|
|
296
|
-
control_envelope?: Record<string, unknown>;
|
|
297
|
-
meta?: Record<string, unknown>;
|
|
298
|
-
}
|
|
245
|
+
export type AuthorizeChangeSetResponse = GeneratedAuthorizeChangeSetResponse;
|
|
299
246
|
/**
|
|
300
247
|
* Union of the two preflight branches, discriminated on `preflight_mode`. Narrow before reading
|
|
301
248
|
* mode-specific fields:
|
|
@@ -309,13 +256,57 @@ export interface AuthorizeChangeSetResponse {
|
|
|
309
256
|
* }
|
|
310
257
|
* ```
|
|
311
258
|
*/
|
|
312
|
-
export type PreflightChangeSetResponse =
|
|
259
|
+
export type PreflightChangeSetResponse = GeneratedPreflightChangeSetResponse;
|
|
260
|
+
/**
|
|
261
|
+
* Intended context for a verify-receipt call — the "what are you about to do?" half of the question.
|
|
262
|
+
*
|
|
263
|
+
* WITHOUT it the endpoint answers a signature question only: `valid` / `status` reflect
|
|
264
|
+
* authenticity and expiry, and `currently_authorized` comes back **null** — not authorized and not
|
|
265
|
+
* unauthorized, simply not evaluated. WITH it the server binds the receipt against the stated
|
|
266
|
+
* intent and `currently_authorized` becomes a real `true` / `false`.
|
|
267
|
+
*
|
|
268
|
+
* So: a valid signature is not authorization. If you are about to act on a receipt, supply the
|
|
269
|
+
* context you are about to act under — otherwise the only honest reading of the answer is
|
|
270
|
+
* "authentic token, authorization unknown".
|
|
271
|
+
*
|
|
272
|
+
* Every field is optional and any subset may be sent; the server evaluates what it was given.
|
|
273
|
+
* This list mirrors exactly what `POST /api/v1/verify-receipt` reads — nothing here is invented.
|
|
274
|
+
*/
|
|
275
|
+
export interface VerifyReceiptIntendedContext {
|
|
276
|
+
/** Operation the receipt must authorize (e.g. merge | deploy | publish | tool_call). */
|
|
277
|
+
operation?: string;
|
|
278
|
+
/** Apply-site target the receipt must bind. */
|
|
279
|
+
target_id?: string;
|
|
280
|
+
/** Environment the receipt must match (e.g. production). */
|
|
281
|
+
environment?: string;
|
|
282
|
+
/** Change fingerprint that must equal the receipt's. */
|
|
283
|
+
fingerprint?: string;
|
|
284
|
+
/** Audience the receipt must match. */
|
|
285
|
+
audience?: string;
|
|
286
|
+
/** Place binding: repository the receipt must be bound to. */
|
|
287
|
+
repository?: string;
|
|
288
|
+
/** Place binding: branch the receipt must be bound to. */
|
|
289
|
+
branch?: string;
|
|
290
|
+
/** Place binding: pull request the receipt must be bound to. */
|
|
291
|
+
pull_request?: string | number;
|
|
292
|
+
/**
|
|
293
|
+
* The body_hash-bound decision envelope. Required for a meaningful scope evaluation — with
|
|
294
|
+
* intent fields but no envelope the server fails closed (`currently_authorized: false`) rather
|
|
295
|
+
* than guessing.
|
|
296
|
+
*/
|
|
297
|
+
decision_result?: DecisionResultEnvelope | Record<string, unknown>;
|
|
298
|
+
/** Optional lifecycle indices (supersede / revocation) the server consults when provided. */
|
|
299
|
+
indices?: Record<string, unknown>;
|
|
300
|
+
}
|
|
313
301
|
export interface VerifyReceiptResponse {
|
|
314
302
|
valid: boolean;
|
|
315
303
|
reason: string | null;
|
|
316
304
|
status: ReceiptStatus;
|
|
317
|
-
/**
|
|
318
|
-
|
|
305
|
+
/**
|
|
306
|
+
* Signed receipt payload when the signature is authentic. Omitted when unverifiable
|
|
307
|
+
* (route omits the key; runtime may be undefined). Present on successful authentic verifies.
|
|
308
|
+
*/
|
|
309
|
+
payload?: Record<string, unknown>;
|
|
319
310
|
/**
|
|
320
311
|
* Whether this receipt is authorized right now for the evaluated context.
|
|
321
312
|
* `true` / `false` are answers; `null` means authorization could not be evaluated
|
|
@@ -323,11 +314,20 @@ export interface VerifyReceiptResponse {
|
|
|
323
314
|
*/
|
|
324
315
|
currently_authorized: boolean | null;
|
|
325
316
|
authz_note: string;
|
|
317
|
+
/**
|
|
318
|
+
* Request/trace correlation id. Always present: the verify-receipt route sets it via
|
|
319
|
+
* buildVerifyReceiptResponse from req.correlationId (ID828) — route-owned, not dependent
|
|
320
|
+
* on the global correlationId middleware body injection. Matches X-Correlation-ID when middleware runs.
|
|
321
|
+
*/
|
|
326
322
|
correlation_id: string;
|
|
327
323
|
/** Present when intent context (e.g. operation/environment) was supplied on the request. */
|
|
328
324
|
authz_status?: string;
|
|
329
325
|
/** Present when intent context (e.g. operation/environment) was supplied on the request. */
|
|
330
326
|
authz_reason?: string;
|
|
327
|
+
/** Lifecycle state from the authorization evaluation; omitted when currently_authorized is null. */
|
|
328
|
+
authz_state?: string;
|
|
329
|
+
/** How tightly the receipt was bound for this evaluation (e.g. content-only vs place-bound). */
|
|
330
|
+
binding_level?: string;
|
|
331
331
|
}
|
|
332
332
|
export interface DecisionLookupRequest {
|
|
333
333
|
decision_id?: string;
|
package/dist/esm/types.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/types.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,MAAM,WAAW,gBAAgB;IAC7B,2CAA2C;IAC3C,MAAM,EAAE,MAAM,CAAC;IACf,+DAA+D;IAC/D,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,yDAAyD;IACzD,OAAO,CAAC,EAAE,MAAM,CAAC;CACpB;AACD,MAAM,WAAW,YAAY;IACzB,KAAK,EAAE,MAAM,CAAC;IACd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
|
"description": "Agent Governance SDK — validate API changes before tool invocations. TypeScript client for the CodeRifts API.",
|
|
5
5
|
"main": "./dist/cjs/index.js",
|
|
6
6
|
"module": "./dist/esm/index.js",
|
|
@@ -28,7 +28,8 @@
|
|
|
28
28
|
"build:markers": "node scripts/write-dist-type-markers.mjs",
|
|
29
29
|
"build": "npm run clean && npm run build:cjs && npm run build:esm && npm run build:markers",
|
|
30
30
|
"pretest": "npm run build",
|
|
31
|
-
"test": "
|
|
31
|
+
"test:types": "tsc -p tsconfig.typetest.json",
|
|
32
|
+
"test": "npm run test:types && node --test test/*.test.js",
|
|
32
33
|
"prepublishOnly": "npm run build"
|
|
33
34
|
},
|
|
34
35
|
"keywords": [
|