Get recommended bitcoin fees from a variety of endpoints
bitcoin-best-fee aggregates the recommended Bitcoin fees from a variety of endpoints.
npm install bitcoin-best-fee
const bestFee = require('bitcoin-best-fee')
All methods return a Promise that resolves to the fee in satoshi/byte as a Number.
Fetch the highest fee from any of the endpoints.
bestFee.fetchHigh() .then(fee => console.log(fee)) // -> 240
Fetch the lowest fee from any of the endpoints.
Fetch the mean average fee from all the endpoints.
Fetch the median average fee from all the endpoints.
npm test to run the linter and basic test suite.
npm run test-slow to run additional slow tests. The slow tests are contained in
test/slow/. Warning: This takes 2-3m to run; be patient.