coined
coined is a high-level wrapper around BCoin, making it easy to send transactions and deal with wallets/accounts. Some of the original code was based on Fedor Indutny's BThread.
Install
$ npm install coined
Usage
The primary feature of Coined is a wallet similar to the way bitcoin-qt handles wallets (a collection of accounts, stored by label).
var coined = ;var utils = coinedutils;var bcoin = coinedbcoin;var bn = coinedbn; var coin = ; // Add a key+pair/account to our wallet, under the label "main".coin; // Sendcoin; // List our addresses and their associated labels.console;coinaccounts;
Example Wallet
"version": 1"ts": 1402363259"encrypted": false"compressed": true"balance": "0.10981134""accounts":"address": "1Lzcrow4haAm6j4vyKhMeFQdHcaE1VbjTc""label": "main""priv": "L2bka1uvakQDLabdoPuYEwtTd8a416fjhHyEq99nmaDYeuotsfeG""pub": "nFB3c1yquakfoEE1A98q1HX9hjCp3kAx3a5UHeNvfwMj""balance": "0.00993134""tx": 32"address": "1Q3tMMNWdu3pqqhc3Hdt3L5gS26P7FdtyD""label": "secondary""priv": "L2ACa1uvakQDLabdoPuaEwtTd8a416fjhHyEq99nmaDYeuotsfHf""pub": "hY29VUa4xfrs4vDUd4aF3cjkMoH5xegU6VzGNBqjTtCm""balance": "0.09488""tx": 10"address": "1BKrkLFuyM8BsS5DuwrhPXKc8uFYmsCAAn""label": "test""priv": "L2KEa1uvakQDLabdoPuuEwtTd8a416fjhHyEq99nmaDYeuotsEya""pub": "26srZooFArAzwtQiiQx9LZWTaCupwoVS6QTdQ7CX3QyGa""balance": "0.005""tx": 5"recipients":"195cjSkBUZtpw7ue7mTB6MheP8c3wLkaJe": "noodles""1RVx9Ezsa3zSMc1QteHnaiTXJ64foyAGe": "maxie"
Dislaimer and Note
It is your own responsibility to backup and keep your wallet/privkeys safe. The coined developer(s) will not be responsible if your coins are lost, deleted, or stolen.
Coined automatically makes a backup of your wallet every time you write to it. Keep this in mind when encrypting it.
Contribution and License Agreement
If you contribute code to this project, you are implicitly allowing your code
to be distributed under the MIT license. You are also implicitly verifying that
all code is your original work. </legalese>
License
Copyright (c) 2014, Christopher Jeffrey. (MIT License)
See LICENSE for more info.