bitcoin-request
v1.0.2
Published
Do Bitcoin request on Bitcoin node
Downloads
12
Maintainers
Readme
bitcoin-request
bitcoin-request - Do Bitcoin Request on Bitcoin Node
About
Do Bitcoin request on a bitcoin node. Set process.env.BITCOIN_REQUEST_MODE
to the string livenet
to make livenet requests to your Bitcoin node. Here's a list of commands you can use on your bitcoin node: Chain Query list of commands.
Example
'use strict';
const bitcoinRequest = require( 'bitcoin-request' );
(async () => {
const balance = await bitcoinRequest({
command: [
'getbalance'
],
livenet: false, // overrides BITCOIN_REQUEST_MODE env setting
});
console.log( balance );
// logs 0
})();