mirror of
https://github.com/bitcoinresearchkit/brk.git
synced 2026-06-14 16:53:35 -07:00
brk
Bitcoin Research Kit (BRK) is a high-performance toolchain for parsing, indexing, computing, and serving Bitcoin blockchain data. It provides an alternative to services like Glassnode and mempool.space with a focus on self-hosting and open-source transparency.
This is the main wrapper crate that re-exports all workspace crates through feature flags.
Crates
brk: A wrapper around all otherbrk-*cratesbrk_bundler: A thin wrapper aroundrolldownbrk_cli: A command line interface to run a BRK instancebrk_computer: A Bitcoin dataset computer built on top ofbrk_indexerbrk_error: Errors used throughout BRKbrk_fetcher: A Bitcoin price fetcherbrk_indexer: A Bitcoin indexer built on top ofbrk_parserbrk_interface: An interface to find and format data from BRKbrk_logger: A thin wrapper aroundenv_loggerbrk_mcp: A bridge for LLMs to access BRKbrk_parser: A very fast Bitcoin block parser and iterator built on top ofbitcoin-rustbrk_server: A server with an API for anything from BRKbrk_store: A thin wrapper aroundfjallbrk_structs: Structs used throughout BRK
Features
full- Enable all workspace cratesbundler- Re-exportbrk_bundlercli- Re-exportbrk_cli(always enabled)computer- Re-exportbrk_computererror- Re-exportbrk_errorfetcher- Re-exportbrk_fetcherindexer- Re-exportbrk_indexerinterface- Re-exportbrk_interfacelogger- Re-exportbrk_loggermcp- Re-exportbrk_mcpparser- Re-exportbrk_parserserver- Re-exportbrk_serverstore- Re-exportbrk_storestructs- Re-exportbrk_structs
Usage
Add to your Cargo.toml:
[dependencies]
brk = { version = "0.1", features = ["full"] }
Or enable specific components:
[dependencies]
brk = { version = "0.1", features = ["parser", "indexer", "computer"] }
Example
use brk::{cli, parser, indexer, computer};
// Use individual crates as needed
let config = cli::Config::load()?;
let blocks = parser::BlockIterator::new(&config.bitcoin_path)?;
// ...