This crate is a collection of core structures for Bitcoin Dev Kit (alpha release).
The goal of this crate is to give wallets the mechanisms needed to:
- Figure out what data they need to fetch.
- Process the data in a way that never leads to inconsistent states.
- Fully index that data and expose it to be consumed without friction.
Our design goals for these mechanisms are:
- Data source agnostic – nothing in
bdk_chaincares about where you get data from or whether you do it synchronously or asynchronously. If you know a fact about the blockchain, you can just tell
bdk_chain’s APIs about it, and that information will be integrated, if it can be done consistently.
- Error-free APIs.
- Data persistence agnostic –
bdk_chaindoes not care where you cache on-chain data, what you cache or how you fetch it.
pub extern crate serde_crate as serde;
pub use bitcoin;
pub use indexed_tx_graph::IndexedTxGraph;
pub use tx_graph::TxGraph;
pub use miniscript;
Module for keychain related structures.
Module for structures that store and traverse transactions.
A reference to a block in the canonical chain.
Anchorimplementation that also records the exact confirmation height of the transaction.
Anchorimplementation that also records the exact confirmation time and height of the transaction.
TxOutwith as much data as we can retrieve about it
B) to create a convenient staging area for changes (
C) before they are persisted.
An iterator for derived script pubkeys.
Represents the observed position of some chain data.
Block height and timestamp at which a transaction is confirmed.
How many confirmations are needed f or a coinbase output to be spent.
Trait that “anchors” blockchain data to a specific block of height and hash.
Anchorthat can be constructed from a given block, block height and transaction position within the block.
Trait that makes an object appendable.
Represents a service that tracks the blockchain.
A trait to extend the functionality of a miniscript descriptor.