{"id":20668663,"url":"https://github.com/lepetitbloc/bitcoind-exporter","last_synced_at":"2025-10-31T18:02:26.433Z","repository":{"id":122726847,"uuid":"123960406","full_name":"LePetitBloc/bitcoind-exporter","owner":"LePetitBloc","description":":bar_chart: Bitcoind metrics Prometheus exporter in node js","archived":false,"fork":false,"pushed_at":"2018-05-04T14:05:48.000Z","size":51,"stargazers_count":26,"open_issues_count":2,"forks_count":6,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-10-25T21:33:12.337Z","etag":null,"topics":["bitcoin","bitcoind","metrics","monitoring","prometheus"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/LePetitBloc.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2018-03-05T18:23:52.000Z","updated_at":"2025-01-31T18:54:46.000Z","dependencies_parsed_at":"2023-05-02T15:00:58.318Z","dependency_job_id":null,"html_url":"https://github.com/LePetitBloc/bitcoind-exporter","commit_stats":null,"previous_names":["lepetitbloc/bitcoind-prometheus-exporter","lepetitbloc/dashd-prometheus-exporter","lepetitbloc/dash-wallet-exporter"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/LePetitBloc/bitcoind-exporter","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LePetitBloc%2Fbitcoind-exporter","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LePetitBloc%2Fbitcoind-exporter/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LePetitBloc%2Fbitcoind-exporter/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LePetitBloc%2Fbitcoind-exporter/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/LePetitBloc","download_url":"https://codeload.github.com/LePetitBloc/bitcoind-exporter/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LePetitBloc%2Fbitcoind-exporter/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":282033060,"owners_count":26602642,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-31T02:00:07.401Z","response_time":57,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bitcoin","bitcoind","metrics","monitoring","prometheus"],"created_at":"2024-11-16T20:10:38.505Z","updated_at":"2025-10-31T18:02:26.380Z","avatar_url":"https://github.com/LePetitBloc.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# bitcoind-exporter\n\n[![NPM package version][npm-svg]][npm-url]\n[![Docker Build Status][hub-svg]][hub-url]\n\nBitcoind metrics **Prometheus** exporter.\n\n\u003e `bitcoind-exporter` is compatible with most **bitcoin** forks.\n\nProduce **blockchain**, **wallet** and **addresses** metrics.\nMost relevant metrics are:\n* wallet total balance\n* wallet version\n* if the wallet is unlocked\n* available (spendable) balance for each managed addresses (and watched addresses)\n* best block time and index\n* ...\n\n## Usage\nEdit the `.env` environment file to suit your needs and run:\n```\nnpm start\n```\n\u003e `bitcoind-exporter` uses the `bitcoind` **JSON-RPC** API under the hood and need those credentials:\n\u003e ```\n\u003erpcuser=test\n\u003erpcpassword=1cf98b57-5i09-4fa1-9c07-2e28cb2cb47b\n\u003e```\n\n## Usage with other wallets\nThe following environment variables are available, that should be enough for *any* **bitcoin** forks:\n\u003e ```\n\u003eticker=DASH\n\u003erpcuser=test\n\u003erpcpassword=1cf98b57-5i09-4fa1-9c07-2e28cb2cb47b\n\u003erpchost=127.0.0.1\n\u003erpcport=9999\n\u003erpcscheme=http\n\u003e```\n\n### Docker\nUsing environment variables:\n```\ndocker run -d --restart always --name my-exporter -p 9439:9439 -e \"rpcuser=myrpcuser\" -e \"rpcpassword=myrpcpassword\" -e \"rpchost=my-wallet\" --link my-wallet lepetitbloc/bitcoind-exporter\n````\n\nUsing a `.env` file:\n```\ndocker run -d --restart always --name my-exporter -p 9439:9439 -v /path/to/my/conf:/app/.env --link my-wallet lepetitbloc/bitcoind-exporter\n```\n\n\u003eAn easy hack could be to directly use your wallet conf to feed your exporter `env`:\n\u003e```\n\u003edocker run --name my-exporter -p 9439:9439 -v /path/to/my/conf:/app/.env --link my-wallet lepetitbloc/bitcoind-exporter\n\u003e```\n\n## Example metrics\nWhen visiting the metrics URL http://localhost:9439/metrics the following **metrics** are produced:\n```\n# HELP bitcoind_best_block_index The block height or index\n# TYPE bitcoind_best_block_index gauge\nbitcoind_best_block_index 69019\n\n# HELP bitcoind_best_block_timestamp_seconds The block time in seconds since epoch (Jan 1 1970 GMT)\n# TYPE bitcoind_best_block_timestamp_seconds gauge\nbitcoind_best_block_timestamp_seconds 1522746083\n\n# HELP bitcoind_chain_difficulty The proof-of-work difficulty as a multiple of the minimum difficulty\n# TYPE bitcoind_chain_difficulty gauge\nbitcoind_chain_difficulty 3511060552899.72\n\n# HELP bitcoind_wallet_version the wallet version\n# TYPE bitcoind_wallet_version gauge\nbitcoind_wallet_version{ticker=\"BTC\"} 71000\n\n# HELP bitcoind_wallet_balance_total the total balance of the wallet\n# TYPE bitcoind_wallet_balance_total gauge\nbitcoind_wallet_balance_total{status=\"unconfirmed\"} 2.7345\nbitcoind_wallet_balance_total{status=\"immature\"} 0\nbitcoind_wallet_balance_total{status=\"confirmed\"} 42.73453501\n\n# HELP bitcoind_wallet_transactions_total the total number of transactions in the wallet\n# TYPE bitcoind_wallet_transactions_total gauge\nbitcoind_wallet_transactions_total 77\n\n# HELP bitcoind_wallet_key_pool_oldest_timestamp_seconds the timestamp of the oldest pre-generated key in the key pool\n# TYPE bitcoind_wallet_key_pool_oldest_timestamp_seconds gauge\nbitcoind_wallet_key_pool_oldest_timestamp_seconds 1516231938\n\n# HELP bitcoind_wallet_key_pool_size_total How many new keys are pre-generated.\n# TYPE bitcoind_wallet_key_pool_size_total gauge\nbitcoind_wallet_key_pool_size_total 1000\n\n# HELP bitcoind_wallet_unlocked_until_timestamp_seconds the timestamp that the wallet is unlocked for transfers, or 0 if the wallet is locked\n# TYPE bitcoind_wallet_unlocked_until_timestamp_seconds gauge\nbitcoind_wallet_unlocked_until_timestamp_seconds 0\n\n# HELP bitcoind_wallet_pay_tx_fee_per_kilo_bytes the transaction fee configuration, set in Unit/kB\n# TYPE bitcoind_wallet_pay_tx_fee_per_kilo_bytes gauge\nbitcoind_wallet_pay_tx_fee_per_kilo_bytes 0\n\n# HELP bitcoind_address_balance_total address balance\n# TYPE bitcoind_address_balance_total gauge\nbitcoind_address_balance_total{address=\"1FxZE15d8bt381EuDckdDdp7vw8FUiLzu6\"} 41.00683469\nbitcoind_address_balance_total{address=\"1QAm6J6jLmcm7ce87ujrSdmjPNX9fgRUYZ\"} 1.72770032\n```\n\n## Demo\nYou can test this exporter with `docker-compose`:\n```\ndocker-compose up\n```\n\n## Resources\n* https://prometheus.io/\n* https://en.bitcoin.it/wiki/API_reference_(JSON-RPC)\n\n## Licence\nMIT\n\n[npm-svg]: https://img.shields.io/npm/v/bitcoind-exporter.svg\n[npm-url]: https://npmjs.org/package/bitcoind-exporter\n[hub-url]: https://hub.docker.com/r/lepetitbloc/bitcoind-exporter/\n[hub-svg]: https://img.shields.io/docker/pulls/lepetitbloc/bitcoind-exporter.svg","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flepetitbloc%2Fbitcoind-exporter","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flepetitbloc%2Fbitcoind-exporter","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flepetitbloc%2Fbitcoind-exporter/lists"}