Skip to main content

Module cli

Module cli 

Source
Expand description

wire CLI surface.

Every subcommand emits human-readable text by default and structured JSON when --json is passed. Stable JSON shape is part of the API contract — see docs/AGENT_INTEGRATION.md.

Subcommand split:

  • agent-safe: whoami, peers, verify, send, tail — pure message-layer ops, no trust establishment.
  • trust-establishing: init, dial, accept/reject, invite/accept-invite. The bilateral gate (operator-side accept) preserves the human-in-loop step — see docs/THREAT_MODEL.md T10/T14.

Structs§

Cli
Top-level CLI.

Enums§

Command
DiagAction
EnrollCommand
wire enroll … — mint the operator/org identities + certs the offline org-membership layer (RFC-001) consumes. Keys are stored 0600 alongside private.key. (Publishing these claims on the agent’s own card — the card-emit integration — is a separate follow-up.)
GroupCommand
v0.6.3: top-level wire mesh verbs. Each verb operates on the current session’s view of the pinned peer set. status is the read-only observability primitive (alias for wire session mesh-status); Group-chat verbs (v0.13.3). Membership is a creator-signed roster (src/group.rs); send fans a signed message over the member set.
IdentityCommand
MeshCommand
broadcast fans a signed event to every pinned peer in one call.
MeshRoleAction
v0.6.4: subcommands of wire mesh role.
OrgCommand
wire org … — trust organizations by their domain (RFC-001 §2 DNS-TXT floor). Binding resolves _wire-org.<domain> to an org_did and records a per-org inbound policy; a peer with a verified member_cert for a bound org then reaches ORG_VERIFIED under the chosen mode.
ProfileAction
QuietAction
ResponderCommand
ServiceAction
SessionCommand

Functions§

closest_candidates
Return up to max_results names from pool whose edit distance to needle is ≤ max_distance, sorted by distance ascending. Used for “did you mean” suggestions on resolution miss.
error_smells_like_slot_4xx
Issue #69 follow-up to #15: predicate “does this error smell like a 4xx slot rotation?” — used by try_reresolve_peer_on_slot_4xx to decide whether to spend a whois RTT on a re-resolve.
maybe_auto_init_cwd_session
v0.7.0-alpha.2: idempotent per-cwd session creation.
run
Entry point — parse and dispatch.
run_sync_pull
Programmatic pull. Same shape as wire pull --json.
run_sync_push
Programmatic push (no stdout, no exit on errors). Returns the same JSON shape wire push --json emits.