Skip to content
 
 

Latest commit

 

History

138 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

hdwallet

Build Status Coverage Status npm version

js-standard-style

Installation

$ npm i hdwallet

Constructor

var HDWallet = require('hdwallet')

var hd = new HDWallet({
  settings = settings || {}
  redisPort: 'optional',
  redisHost: 'optional',
  network: 'optional',
  mnemonic: 'optional',
  privateSeed: 'optional' // deprecated
})

API's

HDWallet.encryptPrivateKey(privateWif, password, progressCallback)	// BIP38
HDWallet.decryptPrivateKey(encryptedPrivKey, password, network, progressCallback)  // BIP38
HDWallet.createNewKey(network, password, progressCallback)
HDWallet.generateMnemonic()  // BIP39
HDWallet.validateMnemonic()  // BIP39
HDWallet.getInputAddresses(txHex, network)
HDWallet.sign(unsignedTxHex, privateKey)
HDWallet.prototype.init(cb)
HDWallet.prototype.afterRedisInit(cb)
HDWallet.prototype.getKeyPrefix()
HDWallet.prototype.getSavedKey(key, cb)
HDWallet.prototype.getNextAccount(cb)
HDWallet.prototype.setNextAccount(nextAccount)
HDWallet.prototype.registerAddress(address, accountIndex, addressIndex, change)
HDWallet.prototype.setDB(key, value)
HDWallet.prototype.getAddressPrivateKey(address, cb)
HDWallet.prototype.getAddressPath(address, cb)
HDWallet.prototype.discover(cb)
HDWallet.prototype.discoverAccount(accountIndex, cb)
HDWallet.prototype.discoverAddress(accountIndex, addressIndex, interval, cb)
HDWallet.prototype.registerAccount(account)
HDWallet.prototype.getPrivateSeed()
HDWallet.prototype.getMnemonic()
HDWallet.prototype.getPrivateKey(account, addressIndex)
HDWallet.prototype.getPublicKey(account, addressIndex)
HDWallet.prototype.isAddressActive(addresses, cb)
HDWallet.prototype.getAddress(account, addressIndex)
HDWallet.prototype.sign(unsignedTxHex, cb)

Testing

$ mocha

License

Apache-2.0

About

BIP32 & BIP44 Hierarchical Deterministic Wallet.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages