Commit graph

73 commits

Author SHA1 Message Date
Dave Collins
80aaecd8a2 Update btcjson import paths to new location. 2015-01-16 23:54:00 -06:00
Dave Collins
0ff8ea3848 Update btcws import paths to new location. 2015-01-16 23:35:26 -06:00
Dave Collins
923ca529bd Update btcwire import paths to new location. 2015-01-16 15:11:02 -06:00
Javed Khan
32205c5552 ListAllTransactions - allow nil for account name 2015-01-13 18:46:35 +05:30
Javed Khan
47d862e482 Added CreateNewAccount, RenameAccount commands 2015-01-13 18:46:34 +05:30
Josh Rickmar
67fc6fa645 Reference new subrepo paths in README. 2014-12-11 10:34:50 -05:00
Josh Rickmar
85cc323e34 Remove GetAddressBalanceCmd.
Support for this extension request has been removed from btcwallet and
will not be returning.
2014-07-26 17:53:35 -05:00
Josh Rickmar
de236d5395 Use hashes for rescan, add hash+time to ntfns.
ok @davecgh
2014-07-25 13:28:37 -05:00
Dave Collins
1acb4b8151 goimports -w . 2014-07-02 19:44:43 -05:00
Josh Rickmar
385201f9da Update test coverage report. 2014-06-16 14:47:11 -05:00
Josh Rickmar
160113d612 Add rescanfinished notification. 2014-06-16 14:46:25 -05:00
Josh Rickmar
5a01ac2ed8 Update test coverage report. 2014-06-11 12:05:15 -05:00
Josh Rickmar
b873e70c95 Remove SetId. 2014-06-11 12:04:51 -05:00
Dave Collins
c24be8b7bf Add reply parser for GetBestBlockCmd. 2014-05-11 02:32:24 -05:00
Josh Rickmar
e12673df11 Switch notifyspent to take an array of outpoints.
This allows a wallet process to request spent notifications for many
outpoints at once, rather than creating separate requests for each.
2014-05-06 10:49:46 -05:00
Dave Collins
ce48290169 Rename new transaction register/notifications.
This commit renames the notifyallnewtxs RPC to notifynewtransactions to be
more consistent with the standard RPC names and to more accurately
reflect its intention which is to register for new transactions as they
are accepted to the memory pool.  In addition, the notifications produced
have been renamed to txaccepted and txacceptedverbose depending on whether
or not the verbose flag was set when the client registered to receive the
notifications via notifynewtransactions.

This closes conformal/btcd#98.
2014-04-15 13:08:26 -05:00
Dave Collins
f389d39c43 Update tests for notifynewtxs -> notifyreceived. 2014-04-14 22:45:56 -05:00
Dave Collins
0b4401ddb6 Rename NotifyNewTXsCmd to NotifyReceivedCmd.
This commit renamed the notifynewtxs RPC to notifyreceived since it more
accurately reflects its intention which is to register addresses to be
notified about when they receive funds.

This is work towards conformal/btcd#98.

ok @jrick.
2014-04-14 22:18:54 -05:00
Dave Collins
db5bc2c77c Add reply parser for ListAddressTransactionCmd.
ok @jrick
2014-04-11 14:13:55 -05:00
Dave Collins
3208b7ae75 Update for btcjson RegisterCustomCmd API change. 2014-04-11 14:13:51 -05:00
Dave Collins
fdc49d6a30 Convert NewTxNtfn to use new concrete type.
The NewTxNtfn notification was previously using a map[string]interface.
This commit modifies it to use the new concrete type
btcjson.ListTransactionsResult instead which allows nicer marshalling and
unmarshalling.

ok @jrick
2014-04-11 10:02:16 -05:00
Dave Collins
fc07555ad3 Update for latest btcjson API changes.
This commit modifies the AllVerboseTxNtfn command to use a parser along
with the standard btcjson.RegisterCustomCmd instead of the now removed
RegisterCustomCmdGenerator function.  This is possible due to the recent
changes that defers the unmarshalling of the parameters of a RawCmd to the
parser.
2014-04-11 09:20:25 -05:00
Dave Collins
6f08ca8a8a Correct unmarshal for GetAddressBalanceCmd.
The unmarshaller for the GetAddressBalanceCmd was calling the wrong parse
function.  It wasn't caught by the tests because the error on
UnmarshalJSON was being ignored, so this commit also updates the tests to check the
error.
2014-04-11 09:04:53 -05:00
Dave Collins
bfcd7f6790 Update for latest btcjson.RawCmd changes.
This commit modifies all of the commands and notifications to work
properly with the latest btcjson.RawCmd Params field changes.

This new approach is superior to the old method of using a []interface{}
because it means that each parameter is now unmarshalled into the expected
concrete type directly instead of whatever it happens to be in the JSON.

Since it is now preferred to use full blown structs for individual
parameters, the RescanCmd type has been changed to use a new OutPoint
that can be used directly for marshalling and unmarshalling instead of a
*btcwire.OutPoint.

Also, all of the MarshalJSON functions now make use of the new
btcjson.NewRawCmd function rather than repeating the same common field
over and over and all of the MarshalJSON, UnmarshalJSON, and parseX
functions have been made more consistent.

ok @jrick
2014-04-10 21:10:16 -05:00
Josh Rickmar
b77de52d3d Move GetBestBlockResult struct from btcwallet. 2014-04-10 16:42:28 -05:00
Josh Rickmar
97439fa822 Implement rescanprogress notification. 2014-03-28 11:25:32 -05:00
Josh Rickmar
dd3813d811 Bootstrap unspent outpoints for rescan requests. 2014-03-21 15:54:15 -05:00
Josh Rickmar
bb4cba51cd Switch to new transaction notifications.
This change removes the processedtx notification, replacing it with
recvtx, and the spenttx notification, replacing it with redeemingtx.
Both new transactions return the full serialized transaction (encoded
in hexadecimal) rather than details about the transaction.

The old txmined notification has also been completely removed as it is
unreliable due to transaction malleability and no code should be
depending on it.
2014-02-24 14:52:09 -05:00
Josh Rickmar
5c66641735 Make tests build again. 2014-02-10 09:11:25 -05:00
Francis Lam
0821c583e5 Added explicit json key names to new tx notifications
Also added check for nil ID on AllVerboseTxNtfn.UnmarshalJSON to make it
consistent with other notification handling.
2014-02-09 13:43:02 -05:00
Francis Lam
bb9d3696b4 Changed NewNotifyAllNewTXsCmd to optionally accept verbose arg 2014-02-08 18:26:06 -05:00
Francis Lam
07c403efd0 Added commands to support notifyallnewtxs
Sending NotifyAllNewTXsCmd will register websocket client to receive
notifications on all new transactions.

Once registered the client will receive either AllTxNtfn or
AllVerboseTxNtfn based on the required verbose field in the
NotifyAllNewTXsCmd.
2014-02-08 17:03:22 -05:00
Josh Rickmar
3cba42282e Fill in missing comment; found by golint. 2014-02-04 17:04:05 -05:00
Josh Rickmar
f6c7cf92fd Make go vet happy. 2014-02-04 17:00:27 -05:00
David Hill
463029df76 gofmt 2014-02-04 16:02:45 -05:00
Josh Rickmar
0e8cbf71e8 Replace Error with Errorf, found by go vet. 2014-02-04 13:52:15 -05:00
Josh Rickmar
50a1c37317 Remove parameters for createencryptedwallet.
The createencryptedwallet extension RPC request should not be used to
create wallets for additional accounts.  Instead, all btcwallet
accounts should use the same passphrase as the default account's
wallet.  This change removes the account name and description
parameters from createencryptedwallet, as it will only be used to
create the default account.
2014-01-24 11:16:59 -05:00
Josh Rickmar
0f7f080f19 Move help texts into their own const group. 2014-01-24 10:55:36 -05:00
Josh Rickmar
413e028702 Add RecoverAddressesCmd. 2014-01-23 10:56:20 -05:00
Dave Collins
14dc8cee83 Add new authenticate command. 2014-01-22 14:12:08 -06:00
Owain G. Ainsworth
7e1c44369c Adapt to btcjson api changes.
Add placeholder help text for all the json types that btcws adds. Jrick will
fill them in when he adds documentation.
2014-01-22 16:19:39 +00:00
Josh Rickmar
e745fffb83 Fix slice index for parameter. 2014-01-22 10:13:34 -05:00
Josh Rickmar
e321b6bdc7 Rename exportwatchingwallet zip option to download. 2014-01-22 10:08:09 -05:00
Josh Rickmar
8fb5c9f0e6 Return the actual id value, not func. 2014-01-21 15:10:12 -05:00
Josh Rickmar
f471d2b336 Add ExportWatchingWalletCmd. 2014-01-21 14:23:36 -05:00
Josh Rickmar
b90c6c61ba Fix previous. 2014-01-17 18:38:26 -05:00
Josh Rickmar
ed8812f340 Add NotifyBlocksCmd. 2014-01-17 16:44:58 -05:00
Josh Rickmar
15f2ce4abd Fix a couple incorrect comments. 2014-01-13 17:16:58 -05:00
Josh Rickmar
05a0ba18b4 Kill GetBalancesCmd. 2014-01-09 13:14:53 -05:00
Josh Rickmar
33890d49e9 Fix a typo. 2014-01-09 11:51:51 -05:00