Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Trivial] RPC help formatting updates #1670

Merged
merged 1 commit into from
Oct 9, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 8 additions & 7 deletions src/rpc/misc.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -600,7 +600,7 @@ UniValue getaddressmempool(const UniValue& params, bool fHelp)
" \"address\" (string) The base58check encoded address\n"
" \"txid\" (string) The related txid\n"
" \"index\" (number) The related input or output index\n"
" \"satoshis\" (number) The difference of satoshis\n"
" \"duffs\" (number) The difference of duffs\n"
" \"timestamp\" (number) The time the transaction entered the mempool (seconds)\n"
" \"prevtxid\" (string) The previous txid (if spending)\n"
" \"prevout\" (string) The previous transaction output index (if spending)\n"
Expand Down Expand Up @@ -670,10 +670,10 @@ UniValue getaddressutxos(const UniValue& params, bool fHelp)
" {\n"
" \"address\" (string) The address base58check encoded\n"
" \"txid\" (string) The output txid\n"
" \"height\" (number) The block height\n"
" \"outputIndex\" (number) The output index\n"
" \"script\" (strin) The script hex encoded\n"
" \"satoshis\" (number) The number of satoshis of the output\n"
" \"script\" (string) The script hex encoded\n"
" \"duffs\" (number) The number of duffs of the output\n"
" \"height\" (number) The block height\n"
" }\n"
"]\n"
"\nExamples:\n"
Expand Down Expand Up @@ -737,9 +737,10 @@ UniValue getaddressdeltas(const UniValue& params, bool fHelp)
"\nResult:\n"
"[\n"
" {\n"
" \"satoshis\" (number) The difference of satoshis\n"
" \"duffs\" (number) The difference of duffs\n"
" \"txid\" (string) The related txid\n"
" \"index\" (number) The related input or output index\n"
" \"blockindex\" (number) The related block index\n"
" \"height\" (number) The block height\n"
" \"address\" (string) The base58check encoded address\n"
" }\n"
Expand Down Expand Up @@ -821,8 +822,8 @@ UniValue getaddressbalance(const UniValue& params, bool fHelp)
"}\n"
"\nResult:\n"
"{\n"
" \"balance\" (string) The current balance in satoshis\n"
" \"received\" (string) The total number of satoshis received (including change)\n"
" \"balance\" (string) The current balance in duffs\n"
" \"received\" (string) The total number of duffs received (including change)\n"
"}\n"
"\nExamples:\n"
+ HelpExampleCli("getaddressbalance", "'{\"addresses\": [\"XwnLY9Tf7Zsef8gMGL2fhWA9ZmMjt4KPwg\"]}'")
Expand Down
9 changes: 9 additions & 0 deletions src/rpc/rawtransaction.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -252,6 +252,11 @@ UniValue gettxoutproof(const UniValue& params, bool fHelp)
"2. \"block hash\" (string, optional) If specified, looks for txid in the block with this hash\n"
"\nResult:\n"
"\"data\" (string) A string that is a serialized, hex-encoded data for the proof.\n"

"\nExamples:\n"
+ HelpExampleCli("gettxoutproof", "'[\"mytxid\",...]'")
+ HelpExampleCli("gettxoutproof", "'[\"mytxid\",...]' \"blockhash\"")
+ HelpExampleRpc("gettxoutproof", "[\"mytxid\",...], \"blockhash\"")
);

set<uint256> setTxids;
Expand Down Expand Up @@ -324,6 +329,10 @@ UniValue verifytxoutproof(const UniValue& params, bool fHelp)
"1. \"proof\" (string, required) The hex-encoded proof generated by gettxoutproof\n"
"\nResult:\n"
"[\"txid\"] (array, strings) The txid(s) which the proof commits to, or empty array if the proof is invalid\n"

"\nExamples:\n"
+ HelpExampleCli("verifytxoutproof", "\"proof\"")
+ HelpExampleRpc("gettxoutproof", "\"proof\"")
);

CDataStream ssMB(ParseHexV(params[0], "proof"), SER_NETWORK, PROTOCOL_VERSION);
Expand Down