#[non_exhaustive]pub enum Method {
Show 28 variants
GetContent,
GetCapsule,
GetModule,
GetManifest,
GetMetadata,
ListCapsules,
GetProof,
GetProofStatus,
GetAnchoredRoot,
GetCollection,
ListCollectionItems,
Health,
Methods,
GetNetworkInfo,
GetPeers,
Announce,
GetAvailability,
ListInventory,
FetchRange,
Stage,
CacheGetConfig,
CacheSetCapBytes,
CacheClear,
CacheListCached,
CacheRemoveCached,
CacheFetchAndCache,
ControlPeerStatus,
RpcDiscover,
}Expand description
A DIG-node RPC method.
#[non_exhaustive] so adding a method in a minor release is additive.
Convert to/from the wire name with Method::name / Method::from_name.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
GetContent
dig.getContent — a verified resource-window read.
GetCapsule
dig.getCapsule — the whole .dig module for (store, root).
GetModule
dig.getModule — alias of GetCapsule.
GetManifest
dig.getManifest — the public discovery manifest resource.
GetMetadata
dig.getMetadata — the plaintext metadata manifest (never encrypted).
ListCapsules
dig.listCapsules — the confirmed capsule list (discovery metadata).
GetProof
dig.getProof — the real inclusion proof + execution-proof status.
GetProofStatus
dig.getProofStatus — poll a real execution-proof job by id.
GetAnchoredRoot
dig.getAnchoredRoot — resolve a store’s chain-anchored tip root.
(Also peer-reachable.)
GetCollection
dig.getCollection — collection-level facts for a set of NFT launchers.
(Also peer-reachable.)
ListCollectionItems
dig.listCollectionItems — a page of resolved collection items.
(Also peer-reachable.)
Health
dig.health — liveness + capability summary.
Methods
dig.methods — the implemented method names (agent self-describe).
GetNetworkInfo
dig.getNetworkInfo — this node’s peer-network posture.
GetPeers
dig.getPeers — the peers this node knows (peer exchange).
Announce
dig.announce — accept a peer announcement.
GetAvailability
dig.getAvailability — batch presence check across stores/roots/capsules.
ListInventory
dig.listInventory — enumerate what this node serves.
FetchRange
dig.fetchRange — a single verified range frame of a resource.
Stage
dig.stage — compile a local folder into a capsule .dig in-process.
CacheGetConfig
cache.getConfig — the local-cache config.
CacheSetCapBytes
cache.setCapBytes — set the cache size cap.
CacheClear
cache.clear — clear the cache.
CacheListCached
cache.listCached — the durable module inventory.
CacheRemoveCached
cache.removeCached — remove one cached capsule.
CacheFetchAndCache
cache.fetchAndCache — fetch + cache one capsule.
ControlPeerStatus
control.peerStatus — the peer-network status snapshot.
RpcDiscover
rpc.discover — the OpenRPC self-describe document.
Implementations§
Source§impl Method
impl Method
Sourcepub fn from_name(name: &str) -> Option<Method>
pub fn from_name(name: &str) -> Option<Method>
Parse a wire name into a Method, or None for an unknown method
(the caller answers -32601).
Sourcepub const fn tier(self) -> Tier
pub const fn tier(self) -> Tier
The method’s PRIMARY access Tier.
Note: a PublicRead method may still be peer-reachable — see
is_peer_reachable. The tier is the
method’s canonical home, the allowlist is the security boundary.
Sourcepub const fn is_peer_reachable(self) -> bool
pub const fn is_peer_reachable(self) -> bool
Whether this method is reachable over the mTLS peer surface.
This mirrors the canonical node’s is_peer_reachable_method byte-for-byte
(digstore dig-node peer.rs). It is an ALLOWLIST: adding a method here
is a deliberate security decision — it exposes the method to any remote
peer (the peer verifier authenticates a peer_id, it does NOT authorize).
Management/mutation methods (cache.*, control.*, dig.stage) are
NEVER peer-reachable.
Sourcepub const fn summary(self) -> &'static str
pub const fn summary(self) -> &'static str
A one-line human summary (drives the OpenRPC method summary).
Sourcepub fn peer_reachable_names() -> Vec<&'static str>
pub fn peer_reachable_names() -> Vec<&'static str>
The method names reachable over the peer surface, in catalogue order — the exact allowlist a server hands its peer responder.