2.1.6 • Published 6 years ago

bitcoin-rpc-promise v2.1.6

Weekly downloads
23
License
MIT
Repository
github
Last release
6 years ago

bitcoin-rpc-promise

A modern promise based node.js library for communicating with Bitcoin daemon.

npm package

NPM version Dependency Status Known Vulnerabilities Downloads FOSSA Status

Install

npm install --save bitcoin-rpc-promise

Usage

Start bitcoin daemon with rpc support:

./bitcoind --server=1 --rpcuser=user --rpcpassword=password

Connect to daemon endpoint and send rpc commands:

const BitcoinRpc = require('bitcoin-rpc-promise');

let btc = new BitcoinRpc('http://user:password@localhost:8332');

// call named wrappers
btc.getBlockHash(100).then(result => {
  console.log(result);
});

// or call named wrappers with all lower case
btc.getblockhash(100).then(result => {
  console.log(result);
});

// or call raw commands
btc.call('getblockhash', 100).then(result => {
  console.log(result);
});

Documentation

Bitcoin Wiki

2.1.6

6 years ago

2.1.5

6 years ago

2.1.4

6 years ago

2.1.3

6 years ago

2.0.3

6 years ago

1.1.7

6 years ago

1.1.6

6 years ago

1.1.5

6 years ago

1.1.4

6 years ago

1.1.3

6 years ago

1.1.2

6 years ago

1.1.0

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago