Module bdk::blockchain::rpc [−][src]
This is supported on crate feature
rpc
only.Expand description
Rpc Blockchain
Backend that gets blockchain data from Bitcoin Core RPC
This is an EXPERIMENTAL feature, API and other major changes are expected.
Example
let config = RpcConfig {
url: "127.0.0.1:18332".to_string(),
auth: Auth::Cookie {
file: "/home/user/.bitcoin/.cookie".into(),
},
network: bdk::bitcoin::Network::Testnet,
wallet_name: "wallet_name".to_string(),
skip_blocks: None,
};
let blockchain = RpcBlockchain::from_config(&config);
Structs
The main struct for RPC backend implementing the crate::blockchain::Blockchain trait
RpcBlockchain configuration options
Enums
This struct is equivalent to bitcoincore_rpc::Auth but it implements serde::Serialize To be removed once upstream equivalent is implementing Serialize (json serialization format should be the same), see rust-bitcoincore-rpc/pull/181