#![cfg_attr(docsrs, feature(doc_cfg))]
#![allow(
clippy::error_impl_error,
reason = "`Error` is the idiomatic name for the crate's top-level error enum, matching the `thiserror` convention used pervasively in the Rust ecosystem"
)]
#![cfg_attr(
test,
allow(
clippy::indexing_slicing,
reason = "JSON field indexing via `Value[\"key\"]` is ergonomic inside tests and its panic-on-missing behaviour is the desired failure mode when fixtures are wrong"
)
)]
#[cfg(feature = "client")]
#[cfg_attr(docsrs, doc(cfg(feature = "client")))]
mod client;
mod discovery;
mod error;
mod schema;
#[cfg(feature = "client")]
#[cfg_attr(docsrs, doc(cfg(feature = "client")))]
pub use self::client::{fetch, fetch_discovery};
pub use self::discovery::{Discovery, DiscoveryLink, SCHEMA_REL_PREFIX};
pub use self::error::Error;
pub use self::schema::{
InboundService, NodeInfo, NodeInfoBuilder, OutboundService, Protocol, Services, Software,
Usage, UserCount, Version,
};
pub type Result<T, E = Error> = core::result::Result<T, E>;
pub const WELL_KNOWN_PATH: &str = "/.well-known/nodeinfo";