Socket
Book a DemoInstallSign in
Socket

bitcoind-regtest

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

bitcoind-regtest

Run bitcoind in regtest mode for your own blockchain

latest
Source
npmnpm
Version
0.2.3
Version published
Maintainers
1
Created
Source

bitcoind-regtest

NPM Package build status Coverage Status Dependency status

js-standard-style

Example

import RegtestBitcoind from 'bitcoind-regtest'

setImmediate(async () => {
  let bitcoind = new RegtestBitcoind()
  await bitcoind.ready
  await bitcoind.generateBlocks(105)
  let preload = await bitcoind.getPreload()
  console.log(preload)
  // {
  //   txId: '757f53cee55b38e564b37b7a06bc8f0758338621015b7ff02001317af0fa3b14',
  //   outIndex: 0,
  //   value: 1000000000,
  //   script: <Script: OP_DUP OP_HASH160 20 0x5d1ecf7e16de5ff76368d709cde74bb52dc7f3c4 OP_EQUALVERIFY OP_CHECKSIG>,
  //   privKey: <PrivateKey: 294d6127bdc8b6cac4137f13cae854030ef544e595e41b8519d8f6d4966d3764, network: regtest>
  // }

  await bitcoind.terminate()
})

API

here

License

Code released under the MIT license.

Keywords

bitcoin

FAQs

Package last updated on 19 Nov 2015

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts