apex_sdk/lib.rs
1//! # Apex SDK
2//!
3//! The industry's first unified Rust SDK for Substrate & EVM blockchain development.
4//!
5//! ## Features
6//!
7//! - **Unified Interface**: Single API for both Substrate and EVM blockchains
8//! - **Compile-Time Type Safety**: Catch errors before deployment
9//! - **Native Performance**: Rust-based implementation
10//! - **Cross-Chain Ready**: Built-in cross-chain communication support
11//!
12//! ## Example
13//!
14//! ```rust,no_run
15//! use apex_sdk::prelude::*;
16//!
17//! #[tokio::main]
18//! async fn main() -> anyhow::Result<()> {
19//! let sdk = ApexSDK::builder()
20//! .with_substrate_endpoint("wss://polkadot.api.onfinality.io/public-ws")
21//! .with_evm_endpoint("https://mainnet.infura.io/v3/YOUR_KEY")
22//! .build()
23//! .await?;
24//!
25//! Ok(())
26//! }
27//! ```
28
29pub mod builder;
30pub mod error;
31pub mod sdk;
32pub mod transaction;
33
34pub use apex_sdk_core as core;
35pub use apex_sdk_evm as evm;
36pub use apex_sdk_substrate as substrate;
37pub use apex_sdk_types as types;
38
39pub use builder::ApexSDKBuilder;
40pub use error::{Error, Result};
41pub use sdk::ApexSDK;
42pub use transaction::{Transaction, TransactionBuilder, TransactionResult};
43
44/// Common imports for convenience
45pub mod prelude {
46 pub use crate::builder::ApexSDKBuilder;
47 pub use crate::error::{Error, Result};
48 pub use crate::sdk::ApexSDK;
49 pub use crate::transaction::{Transaction, TransactionBuilder, TransactionResult};
50 pub use apex_sdk_types::{Address, Chain, ChainType, TransactionStatus};
51}