Skip to main content

Crate cardanowall_cli

Crate cardanowall_cli 

Source
Expand description

The cardanowall CLI library crate.

A standalone CIP-309 Proof-of-Existence toolkit built on the cardanowall SDK. The binary (main.rs) is a thin shell; the command tree, argument parsing, gateway resolution, and output formatting live here so integration tests can drive run directly and assert on the resulting exit code.

§Commands

  • verify <tx-hash> — the standalone verifier; maps the verifier report’s exit code through verbatim.
  • submit — anchor a PoE via a gateway (hash / file / Merkle).
  • sign record|prepare|assemble — off-host COSE_Sign1 record signing.
  • identity — derive and print the public identity from a 32-byte seed.
  • merkle verify|build — off-chain Merkle tooling.
  • inbox sync|list|decrypt — sealed-PoE inbox over a raw recipient key.

§Exit codes

0 valid · 1 integrity · 2 network · 3 pending · 4 CLI input error. Clap parse failures and --help/--version are mapped by run.

Re-exports§

pub use cli::run;
pub use cli::Cli;
pub use util::CliError;

Modules§

cli
The clap command tree and the top-level dispatcher with the exit-code mapping.
commands
The subcommand handlers. Each module owns one top-level command’s argument struct(s) and its run entry, returning Result<(), CliError> so the dispatcher in crate::cli can map the error to a process exit code.
config
TOML config + multi-gateway resolution.
inbox
Inbox subsystem helpers: identity resolution, envelope projection, and the plaintext-hash recompute. The command handlers live in crate::commands::inbox.
output
Output rendering: the human-readable verify transcript and the inbox-list table. Machine output (--json) is emitted by the commands directly.
secret
The single shared secret + config resolution layer used by every command.
state
Local on-device state: the per-identity inbox bookmark.
util
Cross-cutting CLI utilities: the exit-code-bearing error type, hex helpers, and the build-stamped version string.