RPC - Add getprivatesendinfo

This commit is contained in:
thephez 2019-10-17 15:35:18 -04:00
parent 0b2e0319c7
commit 1c93147841
No known key found for this signature in database
GPG key ID: BBC8A06DBE236099
8 changed files with 212 additions and 1 deletions

View file

@ -421,6 +421,8 @@ DIP8:
'`getpeerinfo` RPC': rpc getpeerinfo '`getpeerinfo` RPC': rpc getpeerinfo
'`getpoolinfo`': rpc getpoolinfo '`getpoolinfo`': rpc getpoolinfo
'`getpoolinfo` RPC': rpc getpoolinfo '`getpoolinfo` RPC': rpc getpoolinfo
'`getprivatesendinfo`': rpc getprivatesendinfo
'`getprivatesendinfo` RPC': rpc getprivatesendinfo
'`getrawchangeaddress`': rpc getrawchangeaddress '`getrawchangeaddress`': rpc getrawchangeaddress
'`getrawchangeaddress` RPC': rpc getrawchangeaddress '`getrawchangeaddress` RPC': rpc getrawchangeaddress
'`getrawmempool`': rpc getrawmempool '`getrawmempool`': rpc getrawmempool

View file

@ -232,6 +232,7 @@ devsearches:
- 'GetNewAddress': "/en/developer-reference#getnewaddress" - 'GetNewAddress': "/en/developer-reference#getnewaddress"
- 'GetPeerInfo': "/en/developer-reference#getpeerinfo" - 'GetPeerInfo': "/en/developer-reference#getpeerinfo"
- 'GetPoolInfo': "/en/developer-reference#getpoolinfo" - 'GetPoolInfo': "/en/developer-reference#getpoolinfo"
- 'GetPrivateSendInfo': "/en/developer-reference#getprivatesendinfo"
- 'GetRawChangeAddress': "/en/developer-reference#getrawchangeaddress" - 'GetRawChangeAddress': "/en/developer-reference#getrawchangeaddress"
- 'GetRawMempool': "/en/developer-reference#getrawmempool" - 'GetRawMempool': "/en/developer-reference#getrawmempool"
- 'GetRawTransaction': "/en/developer-reference#getrawtransaction" - 'GetRawTransaction': "/en/developer-reference#getrawtransaction"

View file

@ -170,7 +170,8 @@ These RPCs are all Dash-specific and not found in Bitcoin Core
{% autocrossref %} {% autocrossref %}
* [GetGovernanceInfo][rpc getgovernanceinfo]: {{summary_getGovernanceInfo}} {{DASH_UPDATED0_14_0}} * [GetGovernanceInfo][rpc getgovernanceinfo]: {{summary_getGovernanceInfo}} {{DASH_UPDATED0_14_0}}
* [GetPoolInfo][rpc getpoolinfo]: {{summary_getPoolInfo}} * [GetPoolInfo][rpc getpoolinfo]: {{summary_getPoolInfo}} {{DEPRECATED}}
* [GetPrivateSendInfo][rpc getprivatesendinfo]: {{summary_getPrivateSend}} {{DASH_NEW0_14_1}}
* [GetSuperblockBudget][rpc getsuperblockbudget]: {{summary_getSuperblockBudget}} * [GetSuperblockBudget][rpc getsuperblockbudget]: {{summary_getSuperblockBudget}}
* [GObject][rpc gobject]: {{summary_gObject}} {{DASH_UPDATED0_14_1}} * [GObject][rpc gobject]: {{summary_gObject}} {{DASH_UPDATED0_14_1}}
* [Masternode][rpc masternode]: {{summary_masternode}} {{DASH_UPDATED0_14_0}} * [Masternode][rpc masternode]: {{summary_masternode}} {{DASH_UPDATED0_14_0}}

View file

@ -0,0 +1,197 @@
{% 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/getprivatesendinfo.md" %}
<!--__-->
##### GetPrivateSendInfo
{% include helpers/subhead-links.md %}
{% assign summary_getPrivateSendInfo="returns an object containing an information about PrivateSend settings and state." %}
{% autocrossref %}
The `getprivatesendinfo` RPC {{summary_getPrivateSendInfo}}
*Parameters: none*
*Result---(for regular nodes) information about the mixing pool*
{% itemplate ntpd1 %}
- n: "`result`"
t: "object"
p: "Required<br>(exactly 1)"
d: "Information about the mixing pool"
- n: "→<br>`enabled`"
t: "bool"
p: "Required<br>(exactly 1)"
d: "Whether mixing functionality is enabled"
- n: "→<br>`running`"
t: "bool"
p: "Required<br>(exactly 1)"
d: "Whether mixing is currently running"
- n: "→<br>`multisession`"
t: "bool"
p: "Required<br>(exactly 1)"
d: "Whether PrivateSend Multisession option is enabled"
- n: "→<br>`max_sessions`"
t: "number (int)"
p: "Required<br>(exactly 1)"
d: "How many parallel mixing sessions can there be at once"
- n: "→<br>`max_rounds`"
t: "number (int)"
p: "Required<br>(exactly 1)"
d: "How many rounds to mix"
- n: "→<br>`max_amount`"
t: "number (int)"
p: "Required<br>(exactly 1)"
d: "How many DASH to keep anonymized"
- n: "→<br>`max_denoms`"
t: "number (int)"
p: "Required<br>(exactly 1)"
d: "How many inputs of each denominated amount to create"
- n: "→<br>`queue_size`"
t: "number (int)"
p: "Required<br>(exactly 1)"
d: "How many queues there are currently on the network"
- n: "→<br>`sessions`"
t: "array of json objects"
p: "Required<br>(exactly 1)"
d: "Information about session(s)"
- n: "→ →<br>Session"
t: "object"
p: "Optional<br>(1 or more)"
d: "Information for a session"
- n: "→ → →<br>`protxhash`"
t: "string"
p: "Required<br>(exactly 1)"
d: "The ProTxHash of the masternode"
- n: "→ → →<br>`outpoint`"
t: "string (txid-index)"
p: "Required<br>(exactly 1)"
d: "The outpoint of the masternode"
- n: "→ → →<br>`service`"
t: "string (host:port)"
p: "Required<br>(exactly 1)"
d: "The IP address and port of the masternode"
- n: "→ → →<br>`denomination`"
t: "number (int)"
p: "Required<br>(exactly 1)"
d: "The denomination of the mixing session in DASH"
- n: "→ → →<br>`state`"
t: "string"
p: "Required<br>(exactly 1)"
d: "Current state of the mixing session"
- n: "→ → →<br>`entries_count`"
t: "number (int)"
p: "Required<br>(exactly 1)"
d: "The number of entries in the mixing session"
- n: "→<br>`keys_left`"
t: "number (int)"
p: "Required<br>(exactly 1)"
d: "How many new keys are left since last automatic backup"
- n: "→<br>`warnings`"
t: "string"
p: "Optional<br>(exactly 1)"
d: "Any warnings"
{% enditemplate %}
*Result---(for masternodes) information about the mixing pool*
{% itemplate ntpd1 %}
- n: "`result`"
t: "object"
p: "Required<br>(exactly 1)"
d: "Information about the mixing pool"
- n: "→<br>`queue_size`"
t: "number (int)"
p: "Required<br>(exactly 1)"
d: "How many queues there are currently on the network"
- n: "→<br>`denomination`"
t: "number (int)"
p: "Required<br>(exactly 1)"
d: "The denomination of the mixing session in DASH"
- n: "→<br>`state`"
t: "string"
p: "Required<br>(exactly 1)"
d: "Current state of the mixing session"
- n: "→<br>`entries_count`"
t: "number (int)"
p: "Required<br>(exactly 1)"
d: "The number of entries in the mixing session"
{% enditemplate %}
*Example from Dash Core 0.14.1*
{% highlight bash %}
dash-cli -testnet getprivatesendinfo
{% endhighlight %}
Result:
{% highlight json %}
{
"enabled": true,
"running": true,
"multisession": true,
"max_sessions": 4,
"max_rounds": 4,
"max_amount": 2000,
"max_denoms": 300,
"queue_size": 2,
"sessions": [
{
"denomination": 0.00000000,
"state": "ERROR",
"entries_count": 0
},
{
"protxhash": "7d336336b7e8910f518b2b270c6d72a2d7fc05aec3c6720108da80805ffc3aab",
"outpoint": "7d336336b7e8910f518b2b270c6d72a2d7fc05aec3c6720108da80805ffc3aab-1",
"service": "34.241.93.160:26039",
"denomination": 0.10000100,
"state": "QUEUE",
"entries_count": 0
},
{
"protxhash": "11eabc1e72394af02bbe86815975d054816fe69006fdc64c6d7a06b585e5c311",
"outpoint": "ee7741bac62cb468c09c00e7a78148064db9da781d183a8f23c7beef9ed569d6-0",
"service": "95.183.53.17:10004",
"denomination": 10.00010000,
"state": "QUEUE",
"entries_count": 0
}
],
"keys_left": 996,
"warnings": ""
}
{% endhighlight %}
*See also: none*
{% endautocrossref %}

View file

@ -68,6 +68,7 @@ This file is licensed under the terms of its source texts{%endcomment%}
{% assign summary_getNewAddress="returns a new Dash address for receiving payments. If an account is specified, payments received with the address will be credited to that account." %} {% assign summary_getNewAddress="returns a new Dash address for receiving payments. If an account is specified, payments received with the address will be credited to that account." %}
{% assign summary_getPeerInfo="returns data about each connected network node." %} {% assign summary_getPeerInfo="returns data about each connected network node." %}
{% assign summary_getPoolInfo="returns an object containing mixing pool related information." %} {% assign summary_getPoolInfo="returns an object containing mixing pool related information." %}
{% assign summary_getPrivateSendInfo="returns an object containing an information about PrivateSend settings and state." %}
{% assign summary_getRawChangeAddress="returns a new Dash address for receiving change. This is for use with raw transactions, not normal use." %} {% assign summary_getRawChangeAddress="returns a new Dash address for receiving change. This is for use with raw transactions, not normal use." %}
{% assign summary_getRawMemPool="returns all transaction identifiers (TXIDs) in the memory pool as a JSON array, or detailed information about each transaction in the memory pool as a JSON object." %} {% assign summary_getRawMemPool="returns all transaction identifiers (TXIDs) in the memory pool as a JSON array, or detailed information about each transaction in the memory pool as a JSON object." %}
{% assign summary_getRawTransaction="gets a hex-encoded serialized transaction or a JSON object describing the transaction. By default, Dash Core only stores complete transaction data for UTXOs and your own transactions, so the RPC may fail on historic transactions unless you use the non-default `txindex=1` in your Dash Core startup settings." %} {% assign summary_getRawTransaction="gets a hex-encoded serialized transaction or a JSON object describing the transaction. By default, Dash Core only stores complete transaction data for UTXOs and your own transactions, so the RPC may fail on historic transactions unless you use the non-default `txindex=1` in your Dash Core startup settings." %}

View file

@ -277,6 +277,12 @@ th.tg-sort-header::-moz-selection { background:transparent; }th.tg-sort-header::
<td class="tg-baqh">Y</td> <td class="tg-baqh">Y</td>
<td class="tg-baqh"></td> <td class="tg-baqh"></td>
</tr> </tr>
<tr>
<td class="tg-yw4l">Dash</td>
<td class="tg-yw4l"><a href="#getprivatesendinfo">GetPrivateSendInfo</a></td>
<td class="tg-baqh">Y</td>
<td class="tg-baqh">Added in 0.14.1</td>
</tr>
<tr> <tr>
<td class="tg-b7b8">Dash</td> <td class="tg-b7b8">Dash</td>
<td class="tg-b7b8"><a href="#getsuperblockbudget">GetSuperblockBudget</a></td> <td class="tg-b7b8"><a href="#getsuperblockbudget">GetSuperblockBudget</a></td>

View file

@ -135,6 +135,7 @@ http://opensource.org/licenses/MIT.
[rpc getnewaddress]: /en/developer-reference#getnewaddress [rpc getnewaddress]: /en/developer-reference#getnewaddress
[rpc getpeerinfo]: /en/developer-reference#getpeerinfo [rpc getpeerinfo]: /en/developer-reference#getpeerinfo
[rpc getpoolinfo]: /en/developer-reference#getpoolinfo [rpc getpoolinfo]: /en/developer-reference#getpoolinfo
[rpc getprivatesendinfo]: /en/developer-reference#getprivatesendinfo
[rpc getrawchangeaddress]: /en/developer-reference#getrawchangeaddress [rpc getrawchangeaddress]: /en/developer-reference#getrawchangeaddress
[rpc getrawmempool]: /en/developer-reference#getrawmempool [rpc getrawmempool]: /en/developer-reference#getrawmempool
[rpc getrawtransaction]: /en/developer-reference#getrawtransaction [rpc getrawtransaction]: /en/developer-reference#getrawtransaction

View file

@ -204,6 +204,8 @@ untrusted source.
{% include devdoc/dash-core/rpcs/rpcs/getpoolinfo.md %} {% include devdoc/dash-core/rpcs/rpcs/getpoolinfo.md %}
{% include devdoc/dash-core/rpcs/rpcs/getprivatesendinfo.md %}
{% include devdoc/dash-core/rpcs/rpcs/getrawchangeaddress.md %} {% include devdoc/dash-core/rpcs/rpcs/getrawchangeaddress.md %}
{% include devdoc/dash-core/rpcs/rpcs/getrawmempool.md %} {% include devdoc/dash-core/rpcs/rpcs/getrawmempool.md %}