Crates.io | barreleye |
lib.rs | barreleye |
version | 0.0.1 |
source | src |
created_at | 2023-01-03 17:56:41.523821 |
updated_at | 2023-01-03 17:56:41.523821 |
description | Open-source blockchain analytics tool. |
homepage | https://barreleye.com |
repository | https://github.com/barreleye/barreleye |
max_upload_size | |
id | 750291 |
size | 251,640 |
Barreleye is an open-source, multi-chain blockchain analytics tool. It's goal is to help answer the following questions:
What assets does an address hold?
Where did these assets come from?
What other wallets might be related?
Note: This is an actively developed work-in-progress and not yet ready for production. Use at your own risk
Requires Rust 1.65.0+:
git clone https://github.com/barreleye/barreleye
cd barreleye
cargo run
Notes:
A default config file will be generated on the first run. Optionally, rename barreleye.sample.toml
to barreleye.toml
Clickhouse is a requirement for warehouse data storage (default configs point to a locally running server)
Out of the box Barreleye is configured to use SQLite (MySQL and PostgreSQL are also supported)
Barreleye consists of two parts: the indexer and the server. The indexer will connect to specified RPC nodes and continuously process new blocks, and the server will handle requests for processed output. You can decouple the two using CLI params.
Running multiple indexers in parallel is supported, but only one will be active at a time. To start indexing without the server: cargo run -- --indexer
To run the server without indexing: cargo run -- --server
To run them all together: cargo run
A default API key is generated on the first run, so to get it:
select uuid from api_keys;
Add a Bitcoin RPC node:
curl -i -X POST \
-H "Content-Type: application/json" \
-H "Authorization: Bearer <API_KEY>" \
-d '{
"name": "Bitcoin",
"tag": "Bitcoin",
"env": "mainnet",
"blockchain": "bitcoin",
"chainId": 0,
"blockTimeMs": 600000,
"rpcEndpoints": ["http://username:password@127.0.0.1:8332"],
"rps": 100
}' \
http://localhost:22775/v0/networks
Add an Ethereum RPC node:
curl -i -X POST \
-H "Content-Type: application/json" \
-H "Authorization: Bearer <API_KEY>" \
-d '{
"name": "Ethereum",
"tag": "Ethereum",
"env": "mainnet",
"blockchain": "evm",
"chainId": 1,
"blockTimeMs": 12000,
"rpcEndpoints": ["http://127.0.0.1:8545"],
"rps": 100
}' \
http://localhost:22775/v0/networks
🚧 This project is a work-in-progress and not ready for prod use. Most APIs are under "v0/" and crate versions are "v0.x.x". A quick glance at the current todos:
max_server_memory_usage_to_ram_ratio
to 2
. Read moreSee CONTRIBUTING.
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
Mozilla Public License 2.0 (LICENSE or https://opensource.org/licenses/MPL-2.0)