Skip to main content

wire/
lib.rs

1//! wire — magic-wormhole for AI agents.
2//!
3//! v0.1 surface (this crate):
4//!   - [`canonical`] — sorted-key, no-whitespace JSON; the wire-byte form.
5//!   - [`signing`] — Ed25519 sign-over-event_id (Nostr NIP-01 style).
6//!   - [`agent_card`] — DID-anchored agent identity.
7//!   - [`trust`] — per-peer tier state machine (UNTRUSTED → VERIFIED).
8//!
9//! v0.2+ (NOT in this crate yet, see `BACKLOG.md`):
10//!   - relay client/server, SPAKE2 handshake, CLI, file_share/file_revoke kinds.
11
12pub mod adapters;
13pub mod agent_card;
14pub mod blocklist;
15pub mod canonical;
16pub mod character;
17pub mod cli;
18pub mod config;
19pub mod daemon_stream;
20pub mod daemon_supervisor;
21pub mod diag;
22pub mod enc;
23pub mod endpoints;
24pub mod enroll;
25pub mod ensure_up;
26pub mod group;
27pub mod identity;
28pub mod inbox_watch;
29pub mod init;
30pub mod macaroon;
31pub mod mcp;
32pub mod nuke;
33pub mod org_bind;
34pub mod org_membership;
35pub mod org_policy;
36pub mod os_notify;
37pub mod pair_decision;
38pub mod pair_invite;
39pub mod pair_profile;
40pub mod pending_inbound_pair;
41pub mod platform;
42pub mod pull;
43pub mod relay_client;
44pub mod relay_server;
45pub mod send;
46pub mod service;
47pub mod session;
48pub mod signing;
49pub mod sso_provider;
50pub mod tls;
51pub mod trust;
52
53// Curated re-exports for ergonomic call sites.
54pub use signing::{
55    KIND_RANGES, KindClass, SignError, VerifyError, b64decode, b64encode, compute_event_id,
56    fingerprint, generate_keypair, kind_class, kinds, make_key_id, sign_message_v31,
57    verify_message_v31,
58};
59
60pub use agent_card::{
61    AgentCard, CARD_SCHEMA_VERSION, CardError, DID_METHOD, build_agent_card, card_canonical,
62    compute_sas, sign_agent_card, verify_agent_card,
63};
64
65pub use trust::{
66    Tier, Trust, add_agent_card_pin, add_self_to_trust, empty_trust, get_tier, promote_to_verified,
67};