Commit graph

80 commits

Author SHA1 Message Date
Torkel Rogstad
57d44d022e Try both TX serialization formats 2020-03-27 16:59:23 -04:00
Ivan Kuznetsov
cfcf4fb762 Implement 'getblockstats' JSON-RPC command 2020-03-25 05:51:42 -04:00
Torkel Rogstad
8b1be46463 Add generatetoaddress and estimatesmartfee RPCs 2020-03-17 09:29:41 -04:00
Iskander Sharipov
d9ce6b037f btcjson,rpcclient: use proper Deprecated comment format
This makes godoc and other Go tools understand deprecation notice.

Found using https://go-critic.github.io/overview#deprecatedComment-ref
2020-03-10 11:00:24 -04:00
Jake Sylvestre
c4f39996ac
Refactor GetBlockVerboseTx to reflect correct getblock RPC call… (#1529)
Refactor GetBlockVerboseResult into two separate types: one type for getblock "hash" verbosity=1,
and a second type for getblock "hash" verbosity=2. This is necessary due to how getblock returns
a block's transaction data based on the provided verbosity parameter.

If verbosity=1, then getblock.Tx is an array of a block's transaction ids (txids) as strings.
If verbosity=2, then getblock.Tx is an array of raw transaction data.

Due to differences in how getblock returns data based on the provided verbosity parameter, it's necessary
to have two separate return types based on verbosity. This necessitates a separate unmarshalling function
(represented throughout rpcclient/chain.go as Result.Receive()) to ensure that data is correctly unmarshalled
and returned to the user.
2020-03-09 14:47:11 -04:00
John C. Vernaleo
e9f15eda7e
rpcclient: Add net params to Client (#1467)
* rpcclient: replace futures mainnet with params

Adds a chaincfg.Params to the Client

rpcclient: parse config to assign params

* rpcclient: change address commands to Address

 * Change address future struct to contain a network field, so futures
   can return the correct type for Receive
2020-03-05 16:46:29 -05:00
jalavosus
57cb8e4b11 Refactor FutureGetBlockVerboseResult into two types: FutureGetBlockVerboseResult, and FutureGetBlockVerboseTxResult.
Due to differences in how getblock returns data based on the provided verbosity parameter, it's necessary
to have two separate return types based on verbosity. This necessitates a separate unmarshalling function
(represented throughout rpcclient/chain.go as Result.Receive()) to ensure that data is correctly unmarshalled
and returned to the user.
2020-03-05 06:48:19 -05:00
shuai.qi
46461dc84a btcjson, rpclient: Fix typo 2020-03-04 09:23:11 -05:00
Wilmer Paulino
e2e5cc694d
btcjson+rpcclient: support new bitcoind sendrawtransaction request 2019-11-08 17:53:46 -08:00
Wilmer Paulino
266851e329
btcjson+rpcclient: support new unified softfork bitcoind format 2019-11-05 16:28:33 -08:00
Wilmer Paulino
e89d4fca24
rpcclient: allow retrieval of backend version 2019-11-04 17:44:29 -08:00
Wilmer Paulino
a46f7b45ab
rpcclient: add GetNetworkInfo method 2019-10-29 18:49:37 -07:00
Olaoluwa Osuntokun
d2b1a06d93
Merge pull request #1129 from gracenoah/fix-rescan
fix NewImportAddressCmd rescan wrong parameters
2018-10-12 17:34:25 -07:00
Johan T. Halseth
085a2b96e9
rpcclient: expose the Node command for RPC API. 2018-09-04 09:40:08 +02:00
Tzu-Jung Lee
98769ddbdf docs: Update example links in README 2018-07-06 14:41:20 -05:00
Olaoluwa Osuntokun
b72e16f0d6 multi: correct all import paths 2018-05-23 16:46:15 -07:00
Jim Posen
7b67f61fa6 rpcclient: Put CFHeader in PrevFilterHeader field in RPC response. 2018-05-23 16:46:15 -07:00
Daniel Krawisz
4fd446028f Enable estimatefee rpc command. 2018-05-23 16:46:15 -07:00
Alex
c7e7acc7fd multi: use hidden varint for cftypes count; make filter type enum, not uint8 2018-05-23 16:46:15 -07:00
Alex
5c93ca639a rpcclient: change "bool" to "uint8" for cfilter/cfheader type 2018-05-23 16:46:15 -07:00
Olaoluwa Osuntokun
c8fdf8bf59 rpcclient: add GetCFilterHeader and GetCFilter 2018-05-23 16:46:15 -07:00
Olaoluwa Osuntokun
3d1caa2f83 multi: update to point to roasbeef forks 2018-05-23 16:46:15 -07:00
Grace Noah
ea82dfdee1 fix NewImportAddressCmd rescan wrong parameters
fix #1126
2018-03-05 19:25:40 +00:00
Dave Collins
2be2f12b35 rpcclient: Update for go1.10 breaking changes.
Go 1.10 made some changes such that json.Unmarshal can no longer
unmarshal into exported fields that are themselves embedded via an
uninitialized unexported pointer.

Since rpcclient previously relied on this behavior, this updates the
client to create the pointers before unmarshalling into the struct.
2018-02-19 18:56:35 -06:00
Jeremiah Goyette
fe786c93b6 rpcclient: implement addwitnessaddress 2018-01-26 01:20:40 -06:00
nakagawa
e4a6228752 rpcclient: Add decodescript support. 2018-01-26 00:20:33 -06:00
Nicola 'tekNico' Larosa
11fcd83963 btcd/multi: fix a number of typos in comments. 2018-01-25 23:23:59 -06:00
Alok Menghrajani
3cb87afa2f rpcclient: fix links in README.md 2017-08-28 01:50:25 -07:00
Janus Troelsen
45ea940039 docs: Correct rpcclient link. 2017-08-21 15:56:57 -05:00
Dave Collins
074b2374b8
Import btcrpcclient repo into rpcclient directory.
This commit contains the entire btcrpcclient repository along with
several changes needed to move all of the files into the rpcclient
directory in order to prepare it for merging.  This does NOT update btcd
or any of the other packages to use the new location as that will be
done separately.

- All import paths in the old btcrpcclient files have been changed to
  the new location
- All references to btcrpcclient as the package name have been changed to
  rpcclient
2017-08-15 19:51:58 -05:00