Expand description
Verdict + ancillary response types per Client spec rev1 §2.4 + App Rev 4 §4.1 Vector verdict shape.
All fields default-tolerant via #[serde(default)] so the SDK can
consume partial responses during cycle-3 → cycle-N spec evolution
without forcing a recompile-and-redeploy on every App-side schema
widening.
Structs§
- Audit
Entry - One audit log entry returned from
GET /v1/audit. - Audit
Response - Response from
GET /v1/audit. Mirrors the App-sideAuditResponseincleanlib-app::verbs. SeeAuditEntryfor the CLEANLIB-366 field-name alignment note. - Audit
Window - Query-window echo returned inside
AuditResponse::window. Mirrors the App-sideAuditWindow— echoes the caller’ssince/untilfilter values verbatim (orNonewhen the filter was omitted). - Availability
Block - Cycle-15 honesty signal block on the SDK Verdict shape. Mirrors the App
wire-shape
cleanlib_core::AvailabilityBlock.Option<bool>-style passthrough fordegraded_staleso pre-cycle-15 payloads (without the block) deserialize cleanly. - Finding
- CLEANLIB-613: one CVE finding inside
TopFindings. Only the fields the CLI consumes are typed; the App may add more (tolerated — nodeny_unknown_fields). - Package
Ref - One package identity for policy-preview / scan requests.
- Policy
Decision - Per-package decision returned from
/v1/policy/previewor embedded in audit entries. - Policy
Preview Request - Body of
POST /v1/policy/preview— packages + optional hypothetical policy override (JSON-shaped; YAML-source customers convert client-side). - Policy
Preview Response - Response from
POST /v1/policy/preview. - Previous
Verdict - Prior-verdict comparison. Surfaces when the CleanLibrary App has a
stored prior verdict for the same
(ecosystem, package, version)that differs from the current one — useful for AI agents and dashboards that want to flag verdict-state changes since the last fetch. Sister-shape withcleanlib_sdk_go::PreviousVerdictandcleanlib-core::PreviousVerdictin the App. - Rich
Data - CLEANLIB-601: typed subset of the App’s
rich_datablock. Carries therecommended_versionupgrade target for the CLIfixcommand.#[serde(default)] - Scan
Request - Body of
POST /v1/scan— a batch of package coordinates, no policy. - Scan
Response - Response from
POST /v1/scan. OneScanResultper requested package. - Scan
Result - One entry of the
POST /v1/scanresponse. Mirrors the App’sverbs::ScanResultwire shape: the package coordinate is flattened (ecosystem/package/version) alongside an optionalverdict(present on success) orerrorstring (per-package partial failure — the App resolves each package independently and never fails the whole batch on one miss). - TopFindings
- CLEANLIB-613: the App’s
top_findingsblock on a customer verdict — the per-CVE findings that back a VECTOR_VERDICT/DENY, plus the KEV / ransomware flags. Modeled so the CLIfixcommand can reach each finding’s structuredfixed_version(the App’s always-populated remediation target). Tolerant:#[serde(default)], all-optional, nodeny_unknown_fields. - Verdict