RPC - Add getmerkleblocks (#146)

* RPC - Add getmerkleblocks

* Fix xref issue

* Add missing link
This commit is contained in:
thephez 2019-08-15 13:07:22 -04:00 committed by GitHub
parent 9e953be7b5
commit 47783eb41f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 96 additions and 0 deletions

View file

@ -399,6 +399,8 @@ DIP8:
'`getmempoolentry` RPC': rpc getmempoolentry
'`getmempoolinfo`': rpc getmempoolinfo
'`getmempoolinfo` RPC': rpc getmempoolinfo
'`getmerkleblocks`': rpc getmerkleblocks
'`getmerkleblocks` RPC': rpc getmerkleblocks
'`getmininginfo`': rpc getmininginfo
'`getmininginfo` RPC': rpc getmininginfo
'`getnettotals`': rpc getnettotals

View file

@ -221,6 +221,7 @@ devsearches:
- 'GetMempoolDescendants': "/en/developer-reference#getmempooldescendants"
- 'GetMempoolEntry': "/en/developer-reference#getmempoolentry"
- 'GetMempoolInfo': "/en/developer-reference#getmempoolinfo"
- 'GetMerkleBlocks': "/en/developer-reference#getmerkleblocks"
- 'GetMiningInfo': "/en/developer-reference#getmininginfo"
- 'GetNetTotals': "/en/developer-reference#getnettotals"
- 'GetNetworkHashPS': "/en/developer-reference#getnetworkhashps"

View file

@ -127,6 +127,7 @@ These RPCs are all Dash-specific and not found in Bitcoin Core
* [GetMemPoolEntry][rpc getmempoolentry]: {{summary_getMemPoolEntry}} {{DASH_NEW0_12_3}} {{NEW0_13_0}}
* [GetMemPoolInfo][rpc getmempoolinfo]: {{summary_getMemPoolInfo}} {{UPDATED0_12_0}}
* [GetRawMemPool][rpc getrawmempool]: {{summary_getRawMemPool}} {{DASH_UPDATED0_12_3}} {{UPDATED0_13_0}}
* [GetMerkleBlocks][rpc getmerkleblocks]: {{summary_getMerkleBlocks}} {{DASH_NEW0_14_1}}
* [GetSpecialTxes][rpc getspecialtxes]: {{summary_getSpecialTxes}} {{DASH_NEW0_13_1}}
* [GetSpentInfo][rpc getspentinfo]: {{summary_getSpentInfo}} {{DASH_NEW0_12_1}}
* [GetTxOut][rpc gettxout]: {{summary_getTxOut}}

View file

@ -0,0 +1,82 @@
{% comment %}
This file is licensed under the MIT License (MIT) available on
http://opensource.org/licenses/MIT.
{% endcomment %}
{% assign filename="_includes/devdoc/dash-core/rpcs/rpcs/getmerkleblocks.md" %}
<!--__-->
##### GetMerkleBlocks
{% include helpers/subhead-links.md %}
{% assign summary_getMerkleBlocks="returns an array of hex-encoded merkleblocks for <count> blocks<!--noref--> starting from <hash> which match <filter>." %}
{% autocrossref %}
*Added in Dash Core 0.14.1*
The `getmerkleblocks` RPC {{summary_getMerkleBlocks}}
*Parameter #1---filter*
{% itemplate ntpd1 %}
- n: "filter"
t: "string"
p: "Required<br>(exactly 1)"
d: "The hex encoded bloom filter"
{% enditemplate %}
*Parameter #2---hash*
{% itemplate ntpd1 %}
- n: "hash"
t: "string"
p: "Required<br>(exactly 1)"
d: "The block hash"
{% enditemplate %}
*Parameter #3---count*
{% itemplate ntpd1 %}
- n: "count"
t: "number (int)"
p: "Optional<br>Default/max=2000"
d: ""
{% enditemplate %}
*Result---the list of merkleblocks*
{% itemplate ntpd1 %}
- n: "`result`"
t: "array"
p: "Required<br>(exactly 1)"
d: "An array of merkleblocks"
- n: "→<br>Merkle Block"
t: "string (hex)"
p: "Optional<br>(1 or more)"
d: "A serialized, hex-encoded merkleblock"
{% enditemplate %}
*Example from Dash Core 0.14.1*
{% highlight bash %}
dash-cli getmerkleblocks \
"2303028005802040100040000008008400048141010000f8400420800080025004000004130000000000000001" \
"00000000007e1432d2af52e8463278bf556b55cf5049262f25634557e2e91202"
2000
{% endhighlight %}
Result (truncated):
{% highlight json %}
[
"000000202c...aefc440107",
"0000002058...9a17830103"
]
{% endhighlight %}
*See also: none*
{% endautocrossref %}

View file

@ -57,6 +57,7 @@ This file is licensed under the terms of its source texts{%endcomment%}
{% assign summary_getMemPoolEntry="returns mempool data for given transaction (must be in mempool)." %}
{% assign summary_getMemPoolInfo="returns information about the node's current transaction memory pool." %}
{% assign summary_getMemoryInfo="returns information about memory usage." %}
{% assign summary_getMerkleBlocks="returns an array of hex-encoded merkleblocks for <count> blocks<!--noref--> starting from <hash> which match <filter>." %}
{% assign summary_getMiningInfo="returns various mining-related information." %}
{% assign summary_getNetTotals="returns information about network traffic, including bytes in, bytes out, and the current time." %}
{% assign summary_getNetworkHashPS="returns the estimated network hashes per second based on the last n blocks." %}

View file

@ -145,6 +145,12 @@ th.tg-sort-header::-moz-selection { background:transparent; }th.tg-sort-header::
<td class="tg-dzk6">Y</td>
<td class="tg-dzk6"></td>
</tr>
<tr>
<td class="tg-b7b8">Blockchain</td>
<td class="tg-b7b8"><a href="#getmerkleblocks">GetMerkleBlocks</a></td>
<td class="tg-dzk6">Y</td>
<td class="tg-dzk6">Add in 0.14.1.0</td>
</tr>
<tr>
<td class="tg-yw4l">Blockchain</td>
<td class="tg-yw4l"><a href="#getrawmempool">GetRawMemPool</a></td>

View file

@ -124,6 +124,7 @@ http://opensource.org/licenses/MIT.
[rpc getmempooldescendants]: /en/developer-reference#getmempooldescendants
[rpc getmempoolentry]: /en/developer-reference#getmempoolentry
[rpc getmempoolinfo]: /en/developer-reference#getmempoolinfo
[rpc getmerkleblocks]: /en/developer-reference#getmerkleblocks
[rpc getmininginfo]: /en/developer-reference#getmininginfo
[rpc getnettotals]: /en/developer-reference#getnettotals
[rpc getnetworkhashps]: /en/developer-reference#getnetworkhashps

View file

@ -182,6 +182,8 @@ untrusted source.
{% include devdoc/dash-core/rpcs/rpcs/getmempoolinfo.md %}
{% include devdoc/dash-core/rpcs/rpcs/getmerkleblocks.md %}
{% include devdoc/dash-core/rpcs/rpcs/getmininginfo.md %}
{% include devdoc/dash-core/rpcs/rpcs/getnettotals.md %}