mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-12 23:18:14 +01:00
Rationalize currency unit to "BTC"
Previously various user-facing strings have used inconsistent currency units "BTC", "btc" and "bitcoins". This adds a single constant and uses it for each reference to the currency unit. Also adds a description of the unit for --maxtxfee, and adds the missing "amount" field description to the (deprecated) move RPC command.
This commit is contained in:
@@ -390,7 +390,7 @@ UniValue sendtoaddress(const UniValue& params, bool fHelp)
|
||||
+ HelpRequiringPassphrase() +
|
||||
"\nArguments:\n"
|
||||
"1. \"bitcoinaddress\" (string, required) The bitcoin address to send to.\n"
|
||||
"2. \"amount\" (numeric, required) The amount in btc to send. eg 0.1\n"
|
||||
"2. \"amount\" (numeric, required) The amount in " + CURRENCY_UNIT + " to send. eg 0.1\n"
|
||||
"3. \"comment\" (string, optional) A comment used to store what the transaction is for. \n"
|
||||
" This is not part of the transaction, just kept in your wallet.\n"
|
||||
"4. \"comment-to\" (string, optional) A comment to store the name of the person or organization \n"
|
||||
@@ -452,7 +452,7 @@ UniValue listaddressgroupings(const UniValue& params, bool fHelp)
|
||||
" [\n"
|
||||
" [\n"
|
||||
" \"bitcoinaddress\", (string) The bitcoin address\n"
|
||||
" amount, (numeric) The amount in btc\n"
|
||||
" amount, (numeric) The amount in " + CURRENCY_UNIT + "\n"
|
||||
" \"account\" (string, optional) The account (DEPRECATED)\n"
|
||||
" ]\n"
|
||||
" ,...\n"
|
||||
@@ -556,7 +556,7 @@ UniValue getreceivedbyaddress(const UniValue& params, bool fHelp)
|
||||
"1. \"bitcoinaddress\" (string, required) The bitcoin address for transactions.\n"
|
||||
"2. minconf (numeric, optional, default=1) Only include transactions confirmed at least this many times.\n"
|
||||
"\nResult:\n"
|
||||
"amount (numeric) The total amount in btc received at this address.\n"
|
||||
"amount (numeric) The total amount in " + CURRENCY_UNIT + " received at this address.\n"
|
||||
"\nExamples:\n"
|
||||
"\nThe amount from transactions with at least 1 confirmation\n"
|
||||
+ HelpExampleCli("getreceivedbyaddress", "\"1D1ZrZNe3JUo7ZycKEYQQiQAWd9y54F4XZ\"") +
|
||||
@@ -614,7 +614,7 @@ UniValue getreceivedbyaccount(const UniValue& params, bool fHelp)
|
||||
"1. \"account\" (string, required) The selected account, may be the default account using \"\".\n"
|
||||
"2. minconf (numeric, optional, default=1) Only include transactions confirmed at least this many times.\n"
|
||||
"\nResult:\n"
|
||||
"amount (numeric) The total amount in btc received for this account.\n"
|
||||
"amount (numeric) The total amount in " + CURRENCY_UNIT + " received for this account.\n"
|
||||
"\nExamples:\n"
|
||||
"\nAmount received by the default account with at least 1 confirmation\n"
|
||||
+ HelpExampleCli("getreceivedbyaccount", "\"\"") +
|
||||
@@ -707,7 +707,7 @@ UniValue getbalance(const UniValue& params, bool fHelp)
|
||||
"2. minconf (numeric, optional, default=1) Only include transactions confirmed at least this many times.\n"
|
||||
"3. includeWatchonly (bool, optional, default=false) Also include balance in watchonly addresses (see 'importaddress')\n"
|
||||
"\nResult:\n"
|
||||
"amount (numeric) The total amount in btc received for this account.\n"
|
||||
"amount (numeric) The total amount in " + CURRENCY_UNIT + " received for this account.\n"
|
||||
"\nExamples:\n"
|
||||
"\nThe total amount in the wallet\n"
|
||||
+ HelpExampleCli("getbalance", "") +
|
||||
@@ -793,14 +793,15 @@ UniValue movecmd(const UniValue& params, bool fHelp)
|
||||
"\nArguments:\n"
|
||||
"1. \"fromaccount\" (string, required) The name of the account to move funds from. May be the default account using \"\".\n"
|
||||
"2. \"toaccount\" (string, required) The name of the account to move funds to. May be the default account using \"\".\n"
|
||||
"3. minconf (numeric, optional, default=1) Only use funds with at least this many confirmations.\n"
|
||||
"4. \"comment\" (string, optional) An optional comment, stored in the wallet only.\n"
|
||||
"3. amount (numeric) Quantity of " + CURRENCY_UNIT + " to move between accounts.\n"
|
||||
"4. minconf (numeric, optional, default=1) Only use funds with at least this many confirmations.\n"
|
||||
"5. \"comment\" (string, optional) An optional comment, stored in the wallet only.\n"
|
||||
"\nResult:\n"
|
||||
"true|false (boolean) true if successfull.\n"
|
||||
"\nExamples:\n"
|
||||
"\nMove 0.01 btc from the default account to the account named tabby\n"
|
||||
"\nMove 0.01 " + CURRENCY_UNIT + " from the default account to the account named tabby\n"
|
||||
+ HelpExampleCli("move", "\"\" \"tabby\" 0.01") +
|
||||
"\nMove 0.01 btc timotei to akiko with a comment and funds have 6 confirmations\n"
|
||||
"\nMove 0.01 " + CURRENCY_UNIT + " timotei to akiko with a comment and funds have 6 confirmations\n"
|
||||
+ HelpExampleCli("move", "\"timotei\" \"akiko\" 0.01 6 \"happy birthday!\"") +
|
||||
"\nAs a json rpc call\n"
|
||||
+ HelpExampleRpc("move", "\"timotei\", \"akiko\", 0.01, 6, \"happy birthday!\"")
|
||||
@@ -867,7 +868,7 @@ UniValue sendfrom(const UniValue& params, bool fHelp)
|
||||
"\nArguments:\n"
|
||||
"1. \"fromaccount\" (string, required) The name of the account to send funds from. May be the default account using \"\".\n"
|
||||
"2. \"tobitcoinaddress\" (string, required) The bitcoin address to send funds to.\n"
|
||||
"3. amount (numeric, required) The amount in btc. (transaction fee is added on top).\n"
|
||||
"3. amount (numeric, required) The amount in " + CURRENCY_UNIT + " (transaction fee is added on top).\n"
|
||||
"4. minconf (numeric, optional, default=1) Only use funds with at least this many confirmations.\n"
|
||||
"5. \"comment\" (string, optional) A comment used to store what the transaction is for. \n"
|
||||
" This is not part of the transaction, just kept in your wallet.\n"
|
||||
@@ -877,7 +878,7 @@ UniValue sendfrom(const UniValue& params, bool fHelp)
|
||||
"\nResult:\n"
|
||||
"\"transactionid\" (string) The transaction id.\n"
|
||||
"\nExamples:\n"
|
||||
"\nSend 0.01 btc from the default account to the address, must have at least 1 confirmation\n"
|
||||
"\nSend 0.01 " + CURRENCY_UNIT + " from the default account to the address, must have at least 1 confirmation\n"
|
||||
+ HelpExampleCli("sendfrom", "\"\" \"1M72Sfpbz1BPpXFHz9m3CdqATR44Jvaydd\" 0.01") +
|
||||
"\nSend 0.01 from the tabby account to the given address, funds must have at least 6 confirmations\n"
|
||||
+ HelpExampleCli("sendfrom", "\"tabby\" \"1M72Sfpbz1BPpXFHz9m3CdqATR44Jvaydd\" 0.01 6 \"donation\" \"seans outpost\"") +
|
||||
@@ -932,7 +933,7 @@ UniValue sendmany(const UniValue& params, bool fHelp)
|
||||
"1. \"fromaccount\" (string, required) DEPRECATED. The account to send the funds from. Should be \"\" for the default account\n"
|
||||
"2. \"amounts\" (string, required) A json object with addresses and amounts\n"
|
||||
" {\n"
|
||||
" \"address\":amount (numeric) The bitcoin address is the key, the numeric amount in btc is the value\n"
|
||||
" \"address\":amount (numeric) The bitcoin address is the key, the numeric amount in " + CURRENCY_UNIT + " is the value\n"
|
||||
" ,...\n"
|
||||
" }\n"
|
||||
"3. minconf (numeric, optional, default=1) Only use the balance confirmed at least this many times.\n"
|
||||
@@ -1233,7 +1234,7 @@ UniValue listreceivedbyaddress(const UniValue& params, bool fHelp)
|
||||
" \"involvesWatchonly\" : true, (bool) Only returned if imported addresses were involved in transaction\n"
|
||||
" \"address\" : \"receivingaddress\", (string) The receiving address\n"
|
||||
" \"account\" : \"accountname\", (string) DEPRECATED. The account of the receiving address. The default account is \"\".\n"
|
||||
" \"amount\" : x.xxx, (numeric) The total amount in btc received by the address\n"
|
||||
" \"amount\" : x.xxx, (numeric) The total amount in " + CURRENCY_UNIT + " received by the address\n"
|
||||
" \"confirmations\" : n (numeric) The number of confirmations of the most recent transaction included\n"
|
||||
" }\n"
|
||||
" ,...\n"
|
||||
@@ -1405,11 +1406,11 @@ UniValue listtransactions(const UniValue& params, bool fHelp)
|
||||
" transaction between accounts, and not associated with an address,\n"
|
||||
" transaction id or block. 'send' and 'receive' transactions are \n"
|
||||
" associated with an address, transaction id and block details\n"
|
||||
" \"amount\": x.xxx, (numeric) The amount in btc. This is negative for the 'send' category, and for the\n"
|
||||
" \"amount\": x.xxx, (numeric) The amount in " + CURRENCY_UNIT + ". This is negative for the 'send' category, and for the\n"
|
||||
" 'move' category for moves outbound. It is positive for the 'receive' category,\n"
|
||||
" and for the 'move' category for inbound funds.\n"
|
||||
" \"vout\" : n, (numeric) the vout value\n"
|
||||
" \"fee\": x.xxx, (numeric) The amount of the fee in btc. This is negative and only available for the \n"
|
||||
" \"fee\": x.xxx, (numeric) The amount of the fee in " + CURRENCY_UNIT + ". This is negative and only available for the \n"
|
||||
" 'send' category of transactions.\n"
|
||||
" \"confirmations\": n, (numeric) The number of confirmations for the transaction. Available for 'send' and \n"
|
||||
" 'receive' category of transactions.\n"
|
||||
@@ -1600,10 +1601,10 @@ UniValue listsinceblock(const UniValue& params, bool fHelp)
|
||||
" \"account\":\"accountname\", (string) DEPRECATED. The account name associated with the transaction. Will be \"\" for the default account.\n"
|
||||
" \"address\":\"bitcoinaddress\", (string) The bitcoin address of the transaction. Not present for move transactions (category = move).\n"
|
||||
" \"category\":\"send|receive\", (string) The transaction category. 'send' has negative amounts, 'receive' has positive amounts.\n"
|
||||
" \"amount\": x.xxx, (numeric) The amount in btc. This is negative for the 'send' category, and for the 'move' category for moves \n"
|
||||
" \"amount\": x.xxx, (numeric) The amount in " + CURRENCY_UNIT + ". This is negative for the 'send' category, and for the 'move' category for moves \n"
|
||||
" outbound. It is positive for the 'receive' category, and for the 'move' category for inbound funds.\n"
|
||||
" \"vout\" : n, (numeric) the vout value\n"
|
||||
" \"fee\": x.xxx, (numeric) The amount of the fee in btc. This is negative and only available for the 'send' category of transactions.\n"
|
||||
" \"fee\": x.xxx, (numeric) The amount of the fee in " + CURRENCY_UNIT + ". This is negative and only available for the 'send' category of transactions.\n"
|
||||
" \"confirmations\": n, (numeric) The number of confirmations for the transaction. Available for 'send' and 'receive' category of transactions.\n"
|
||||
" \"blockhash\": \"hashvalue\", (string) The block hash containing the transaction. Available for 'send' and 'receive' category of transactions.\n"
|
||||
" \"blockindex\": n, (numeric) The block index containing the transaction. Available for 'send' and 'receive' category of transactions.\n"
|
||||
@@ -1686,7 +1687,7 @@ UniValue gettransaction(const UniValue& params, bool fHelp)
|
||||
"2. \"includeWatchonly\" (bool, optional, default=false) Whether to include watchonly addresses in balance calculation and details[]\n"
|
||||
"\nResult:\n"
|
||||
"{\n"
|
||||
" \"amount\" : x.xxx, (numeric) The transaction amount in btc\n"
|
||||
" \"amount\" : x.xxx, (numeric) The transaction amount in " + CURRENCY_UNIT + "\n"
|
||||
" \"confirmations\" : n, (numeric) The number of confirmations\n"
|
||||
" \"blockhash\" : \"hash\", (string) The block hash\n"
|
||||
" \"blockindex\" : xx, (numeric) The block index\n"
|
||||
@@ -1699,7 +1700,7 @@ UniValue gettransaction(const UniValue& params, bool fHelp)
|
||||
" \"account\" : \"accountname\", (string) DEPRECATED. The account name involved in the transaction, can be \"\" for the default account.\n"
|
||||
" \"address\" : \"bitcoinaddress\", (string) The bitcoin address involved in the transaction\n"
|
||||
" \"category\" : \"send|receive\", (string) The category, either 'send' or 'receive'\n"
|
||||
" \"amount\" : x.xxx (numeric) The amount in btc\n"
|
||||
" \"amount\" : x.xxx (numeric) The amount in " + CURRENCY_UNIT + "\n"
|
||||
" \"vout\" : n, (numeric) the vout value\n"
|
||||
" }\n"
|
||||
" ,...\n"
|
||||
@@ -2165,7 +2166,7 @@ UniValue settxfee(const UniValue& params, bool fHelp)
|
||||
"settxfee amount\n"
|
||||
"\nSet the transaction fee per kB.\n"
|
||||
"\nArguments:\n"
|
||||
"1. amount (numeric, required) The transaction fee in BTC/kB rounded to the nearest 0.00000001\n"
|
||||
"1. amount (numeric, required) The transaction fee in " + CURRENCY_UNIT + "/kB rounded to the nearest 0.00000001\n"
|
||||
"\nResult\n"
|
||||
"true|false (boolean) Returns true if successful\n"
|
||||
"\nExamples:\n"
|
||||
@@ -2194,14 +2195,14 @@ UniValue getwalletinfo(const UniValue& params, bool fHelp)
|
||||
"\nResult:\n"
|
||||
"{\n"
|
||||
" \"walletversion\": xxxxx, (numeric) the wallet version\n"
|
||||
" \"balance\": xxxxxxx, (numeric) the total confirmed bitcoin balance of the wallet\n"
|
||||
" \"unconfirmed_balance\": xxx, (numeric) the total unconfirmed bitcoin balance of the wallet\n"
|
||||
" \"immature_balance\": xxxxxx, (numeric) the total immature balance of the wallet\n"
|
||||
" \"balance\": xxxxxxx, (numeric) the total confirmed balance of the wallet in " + CURRENCY_UNIT + "\n"
|
||||
" \"unconfirmed_balance\": xxx, (numeric) the total unconfirmed balance of the wallet in " + CURRENCY_UNIT + "\n"
|
||||
" \"immature_balance\": xxxxxx, (numeric) the total immature balance of the wallet in " + CURRENCY_UNIT + "\n"
|
||||
" \"txcount\": xxxxxxx, (numeric) the total number of transactions in the wallet\n"
|
||||
" \"keypoololdest\": xxxxxx, (numeric) the timestamp (seconds since GMT epoch) of the oldest pre-generated key in the key pool\n"
|
||||
" \"keypoolsize\": xxxx, (numeric) how many new keys are pre-generated\n"
|
||||
" \"unlocked_until\": ttt, (numeric) the timestamp in seconds since epoch (midnight Jan 1 1970 GMT) that the wallet is unlocked for transfers, or 0 if the wallet is locked\n"
|
||||
" \"paytxfee\": x.xxxx, (numeric) the transaction fee configuration, set in btc/kb\n"
|
||||
" \"paytxfee\": x.xxxx, (numeric) the transaction fee configuration, set in " + CURRENCY_UNIT + "/kB\n"
|
||||
"}\n"
|
||||
"\nExamples:\n"
|
||||
+ HelpExampleCli("getwalletinfo", "")
|
||||
@@ -2278,7 +2279,7 @@ UniValue listunspent(const UniValue& params, bool fHelp)
|
||||
" \"address\" : \"address\", (string) the bitcoin address\n"
|
||||
" \"account\" : \"account\", (string) DEPRECATED. The associated account, or \"\" for the default account\n"
|
||||
" \"scriptPubKey\" : \"key\", (string) the script key\n"
|
||||
" \"amount\" : x.xxx, (numeric) the transaction amount in btc\n"
|
||||
" \"amount\" : x.xxx, (numeric) the transaction amount in " + CURRENCY_UNIT + "\n"
|
||||
" \"confirmations\" : n (numeric) The number of confirmations\n"
|
||||
" }\n"
|
||||
" ,...\n"
|
||||
|
||||
Reference in New Issue
Block a user