nexus-toolkit 2.0.0

Rust framework for building and serving Nexus Tools.
Documentation
//! # Nexus Toolkit
//!
//! The Nexus Toolkit is a Rust library that provides a trait to define a Nexus
//! Tool. A Nexus Tool is a service that can be invoked over HTTP. The Toolkit
//! automatically generates the necessary endpoints for the Tool.
//!
//! See more documentation at <https://github.com/Talus-Network/gitbook-docs/blob/production/nexus-sdk/toolkit-rust.md>

mod config;

/// Shared test utilities
#[cfg(test)]
pub(crate) mod test_utils {
    /// Serialize tests that use ENV_TOOLKIT_CONFIG_PATH to avoid race conditions
    pub static ENV_VAR_LOCK: std::sync::Mutex<()> = std::sync::Mutex::new(());
}
mod nexus_tool;
#[doc(hidden)]
pub mod runtime;
mod serde_tracked;
mod signed_http_warp;

pub use {
    anyhow::Result as AnyResult,
    config::{SignedHttpMode, ToolkitRuntimeConfig, ENV_TOOLKIT_CONFIG_PATH},
    env_logger,
    log::debug,
    nexus_tool::{AuthContext, NexusTool},
    serde_tracked::*,
    warp::{self, http::StatusCode},
};
// Re-exported for use by the `bootstrap!` macro. Not part of the public API.
#[doc(hidden)]
pub use {reqwest, serde_json};