Skip to main content

Module output

Module output 

Source
Expand description

Success envelope rendering — the LOCKED Phase-1 output shape.

Success: {"ok":true,"profile":<name|null>,"data":{...}} with exactly those top-level fields (the failure twin lives in crate::error). Field order is declaration order and part of the golden-file contract.

Core NEVER prints — these functions return Strings; the binary owns stdout/stderr (ARCHITECTURE.md layering invariant).

Structs§

JsonEnvelope
LOCKED success envelope: exactly the top-level fields ok, profile, data — changing the set is a breaking change for agents.

Functions§

render_failure
Render a failure envelope: pretty or compact. The caller routes the result to stderr in both modes.
render_success
Render a success envelope: pretty (default --json) or one-line compact (--compact). Field order: ok, profile, data.