#![cfg_attr(docsrs, feature(doc_cfg))]
#![doc = include_str!("../README.md")]
#![cfg_attr(
test,
allow(
clippy::indexing_slicing,
clippy::panic,
reason = "tests rely on panic-on-failure for simpler assertions"
)
)]
#[cfg(feature = "telemetry")]
use tracing as _;
#[cfg(feature = "telemetry")]
use tracing_core as _;
pub mod amount;
pub mod chain;
pub mod client;
pub mod error;
pub mod extensions;
pub mod facilitator;
pub mod resource_server;
pub mod scheme;
pub mod wire;
pub use resource_server::{
AfterVerifyDecision, BeforeOpDecision, CancelReason, CancellationGuard, DynResourceServerHooks,
PaymentHookContext, ResourceServer, ResourceServerHooks, SettleResultContext,
SkipHandlerDirective, VerifiedPaymentCanceledContext, VerifyPaymentOutcome,
VerifyResultContext, WirePaymentPayload,
};
#[cfg(feature = "cache")]
#[cfg_attr(docsrs, doc(cfg(feature = "cache")))]
pub mod cache;
#[cfg(feature = "metrics")]
#[cfg_attr(docsrs, doc(cfg(feature = "metrics")))]
pub mod metrics;
pub use client::{
ClientHooks, CreatedPayment, DynClientHooks, PaymentClient, PaymentCreationContext,
PaymentResponseContext, PaymentResponseResult,
};
pub use error::{
AsPaymentProblem, ClientError, ErrorReason, FacilitatorError, PaymentProblem, SettlementError,
VerificationError,
};
pub use facilitator::{
BoxFuture, DynFacilitator, DynFacilitatorHooks, Facilitator, FacilitatorHooks, FailureRecovery,
HookDecision, HookedFacilitator,
};
#[cfg(test)]
use proptest as _;
pub use wire::{
DEFAULT_ASSET_DECIMALS, SettlementOverrideError, SettlementOverrides,
asset_decimals_from_extra, resolve_settlement_override_amount,
};