mirror of
https://github.com/seigler/dash-docs
synced 2025-07-27 09:46:12 +00:00
Dash RPCs - Add details to the voteraw RPC
This commit is contained in:
parent
fb98f6f2f2
commit
b3fc565eba
3 changed files with 100 additions and 5 deletions
|
@ -7,21 +7,113 @@ http://opensource.org/licenses/MIT.
|
||||||
##### VoteRaw
|
##### VoteRaw
|
||||||
{% include helpers/subhead-links.md %}
|
{% include helpers/subhead-links.md %}
|
||||||
|
|
||||||
{% assign summary_voteRaw="" %}
|
{% assign summary_voteRaw="compiles and relays a governance vote with provided external signature instead of signing vote internally" %}
|
||||||
|
|
||||||
|
<!-- __ -->
|
||||||
|
|
||||||
{% autocrossref %}
|
{% autocrossref %}
|
||||||
|
|
||||||
The `voteraw` RPC {{summary_voteRaw}}
|
The `voteraw` RPC {{summary_voteRaw}}
|
||||||
|
|
||||||
|
|
||||||
|
*Parameter #1---masternode transaction hash*
|
||||||
|
|
||||||
|
{% itemplate ntpd1 %}
|
||||||
|
- n: "`masternode-tx-hash`"
|
||||||
|
t: "string (hex)"
|
||||||
|
p: "Required<br>(exactly 1)"
|
||||||
|
d: "Hash of the masternode collateral transaction"
|
||||||
|
|
||||||
|
{% enditemplate %}
|
||||||
|
|
||||||
|
*Parameter #2---vote signal*
|
||||||
|
|
||||||
|
{% itemplate ntpd1 %}
|
||||||
|
- n: "`masternode-tx-index`"
|
||||||
|
t: "string"
|
||||||
|
p: "Required<br>(exactly 1)"
|
||||||
|
d: "Index of the masternode collateral transaction"
|
||||||
|
|
||||||
|
{% enditemplate %}
|
||||||
|
|
||||||
|
*Parameter #3---governance hash*
|
||||||
|
|
||||||
|
{% itemplate ntpd1 %}
|
||||||
|
- n: "`governance-hash`"
|
||||||
|
t: "string (hex)"
|
||||||
|
p: "Required<br>(exactly 1)"
|
||||||
|
d: "Hash of the governance object"
|
||||||
|
|
||||||
|
{% enditemplate %}
|
||||||
|
|
||||||
|
*Parameter #4---vote signal*
|
||||||
|
|
||||||
|
{% itemplate ntpd1 %}
|
||||||
|
- n: "`signal`"
|
||||||
|
t: "string"
|
||||||
|
p: "Required<br>(exactly 1)"
|
||||||
|
d: "Vote signal: `funding`, `valid`, or `delete`"
|
||||||
|
|
||||||
|
{% enditemplate %}
|
||||||
|
|
||||||
|
*Parameter #5---vote outcome*
|
||||||
|
|
||||||
|
{% itemplate ntpd1 %}
|
||||||
|
- n: "`outcome`"
|
||||||
|
t: "string"
|
||||||
|
p: "Required<br>(exactly 1)"
|
||||||
|
d: "Vote outcome: `yes`, `no`, or `abstain`"
|
||||||
|
|
||||||
|
{% enditemplate %}
|
||||||
|
|
||||||
|
*Parameter #6---time*
|
||||||
|
|
||||||
|
{% itemplate ntpd1 %}
|
||||||
|
- n: "`time`"
|
||||||
|
t: "int64_t"
|
||||||
|
p: "Required<br>(exactly 1)"
|
||||||
|
d: "Create time"
|
||||||
|
|
||||||
|
{% enditemplate %}
|
||||||
|
|
||||||
|
*Parameter #7---vote signature*
|
||||||
|
|
||||||
|
{% itemplate ntpd1 %}
|
||||||
|
- n: "`vote-sig`"
|
||||||
|
t: "string (base64)"
|
||||||
|
p: "Required<br>(exactly 1)"
|
||||||
|
d: "The vote signature created by external application (i.e. [Dash Masternode Tool][] or [dashmnb][]).<br><br>Must match the Dash Core ([governance vote signature format][])."
|
||||||
|
|
||||||
|
{% enditemplate %}
|
||||||
|
|
||||||
|
|
||||||
|
*Result---votes for specified governance*
|
||||||
|
|
||||||
|
{% itemplate ntpd1 %}
|
||||||
|
- n: "Result"
|
||||||
|
t: "object"
|
||||||
|
p: "Required<br>(exactly 1)"
|
||||||
|
d: "The vote result"
|
||||||
|
|
||||||
|
{% enditemplate %}
|
||||||
|
|
||||||
|
*Example from Dash Core 0.12.2*
|
||||||
|
|
||||||
{% highlight bash %}
|
{% highlight bash %}
|
||||||
dash-cli -testnet voteraw
|
dash-cli -testnet voteraw \
|
||||||
|
f6c83fd96bfaa47887c4587cceadeb9af6238a2c86fe36b883c4d7a6867eab0f 1 \
|
||||||
|
65a358fefaace40fc07053350be23e519178519290f963dab8ba92f6f85f98c3 \
|
||||||
|
funding yes 1512507255 \
|
||||||
|
H1jXKZQp1TZWBPW11E665OwmGBYV1038FohEr0au7zp+O5BCKmVDP/3rGq38ZMy3KOpwnBu6ehd6jlas79hsRBY=
|
||||||
{% endhighlight %}
|
{% endhighlight %}
|
||||||
|
|
||||||
Result:
|
Result:
|
||||||
{% highlight json %}
|
{% highlight bash %}
|
||||||
*INSERT RESULTS HERE*
|
Voted successfully
|
||||||
{% endhighlight %}
|
{% endhighlight %}
|
||||||
|
|
||||||
*See also:*
|
*See also:*
|
||||||
|
|
||||||
|
* [GObject][rpc gobject]: {{summary_gObject}}
|
||||||
|
|
||||||
{% endautocrossref %}
|
{% endautocrossref %}
|
||||||
|
|
|
@ -138,7 +138,7 @@ This file is licensed under the terms of its source texts{%endcomment%}
|
||||||
{% assign summary_verifyChain="verifies each entry in the local block chain database." %}
|
{% assign summary_verifyChain="verifies each entry in the local block chain database." %}
|
||||||
{% assign summary_verifyMessage="verifies a signed message." %}
|
{% assign summary_verifyMessage="verifies a signed message." %}
|
||||||
{% assign summary_verifyTxOutProof="verifies that a proof points to one or more transactions in a block, returning the transactions the proof commits to and throwing an RPC error if the block is not in our best block chain." %}
|
{% assign summary_verifyTxOutProof="verifies that a proof points to one or more transactions in a block, returning the transactions the proof commits to and throwing an RPC error if the block is not in our best block chain." %}
|
||||||
{% assign summary_voteRaw="" %}
|
{% assign summary_voteRaw="compiles and relays a governance vote with provided external signature instead of signing vote internally" %}
|
||||||
{% assign summary_walletLock="removes the wallet encryption key from memory, locking the wallet. After calling this method, you will need to call `walletpassphrase` again before being able to call any methods which require the wallet to be unlocked." %}
|
{% assign summary_walletLock="removes the wallet encryption key from memory, locking the wallet. After calling this method, you will need to call `walletpassphrase` again before being able to call any methods which require the wallet to be unlocked." %}
|
||||||
{% assign summary_walletPassphrase="stores the wallet decryption key in memory for the indicated number of seconds. Issuing the `walletpassphrase` command while the wallet is already unlocked will set a new unlock time that overrides the old one." %}
|
{% assign summary_walletPassphrase="stores the wallet decryption key in memory for the indicated number of seconds. Issuing the `walletpassphrase` command while the wallet is already unlocked will set a new unlock time that overrides the old one." %}
|
||||||
{% assign summary_walletPassphraseChange="changes the wallet passphrase from 'old passphrase' to 'new passphrase'." %}
|
{% assign summary_walletPassphraseChange="changes the wallet passphrase from 'old passphrase' to 'new passphrase'." %}
|
||||||
|
|
|
@ -460,8 +460,10 @@ http://opensource.org/licenses/MIT.
|
||||||
[core paymentrequest.proto]: https://github.com/dashpay/dash/blob/master/src/qt/paymentrequest.proto
|
[core paymentrequest.proto]: https://github.com/dashpay/dash/blob/master/src/qt/paymentrequest.proto
|
||||||
[core script.h]: https://github.com/dashpay/dash/blob/master/src/script/script.h
|
[core script.h]: https://github.com/dashpay/dash/blob/master/src/script/script.h
|
||||||
[creative commons attribution 3.0 license]: https://creativecommons.org/licenses/by/3.0/
|
[creative commons attribution 3.0 license]: https://creativecommons.org/licenses/by/3.0/
|
||||||
|
[Dash Masternode Tool]: https://github.com/Bertrand256/dash-masternode-tool
|
||||||
[Dash Seeder]: https://github.com/nightlydash/dash-seeder/tree/master
|
[Dash Seeder]: https://github.com/nightlydash/dash-seeder/tree/master
|
||||||
[DashJ]: https://github.com/HashEngineering/dashj
|
[DashJ]: https://github.com/HashEngineering/dashj
|
||||||
|
[dashmnb]: https://github.com/chaeplin/dashmnb
|
||||||
[DER]: https://en.wikipedia.org/wiki/X.690#DER_encoding
|
[DER]: https://en.wikipedia.org/wiki/X.690#DER_encoding
|
||||||
[dig command]: https://en.wikipedia.org/wiki/Dig_%28Unix_command%29
|
[dig command]: https://en.wikipedia.org/wiki/Dig_%28Unix_command%29
|
||||||
[DNS A records]: http://tools.ietf.org/html/rfc1035#section-3.2.2
|
[DNS A records]: http://tools.ietf.org/html/rfc1035#section-3.2.2
|
||||||
|
@ -541,3 +543,4 @@ periodically to point to recent code. Last update: 2017-09-05 --> {% endcomment
|
||||||
[spork pubkey]: https://github.com/dashpay/dash/blob/eaf90b77177efbaf9cbed46e822f0d794f1a0ee5/src/chainparams.cpp#L158
|
[spork pubkey]: https://github.com/dashpay/dash/blob/eaf90b77177efbaf9cbed46e822f0d794f1a0ee5/src/chainparams.cpp#L158
|
||||||
[masternode payments pubkey]: https://github.com/dashpay/dash/blob/eaf90b77177efbaf9cbed46e822f0d794f1a0ee5/src/chainparams.cpp#L159
|
[masternode payments pubkey]: https://github.com/dashpay/dash/blob/eaf90b77177efbaf9cbed46e822f0d794f1a0ee5/src/chainparams.cpp#L159
|
||||||
[block subsidy]: https://github.com/dashpay/dash/blob/9ed9474a9eb007bba70278ce19df68e84aeeb712/src/main.cpp#L1741
|
[block subsidy]: https://github.com/dashpay/dash/blob/9ed9474a9eb007bba70278ce19df68e84aeeb712/src/main.cpp#L1741
|
||||||
|
[governance vote signature format]: https://github.com/dashpay/dash/blob/48d63ab296f5613c727306ea39524f51d157a04c/src/governance-vote.cpp#L240-#L241
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue