"description":"Create a transaction which issues a claim assigning a value to a name. The claim will be authoritative if the transaction amount is greater than the transaction amount of all other unspent transactions which issue a claim over the same name, and it will remain authoritative as long as it remains unspent and there are no other greater unspent transactions issuing a claim over the same name. The amount is a real and is rounded to the nearest 0.00000001",
"arguments":[
{
"name":"name",
"type":"string",
"description":"The name to be assigned the value.",
"is_required":true
},
{
"name":"value",
"type":"string",
"description":"The value to assign to the name encoded in hexadecimal.",
"is_required":true
},
{
"name":"amount",
"type":"number",
"description":"The amount in LBRYcrd to send. eg 0.1",
"is_required":true
}
],
"examples":[],
"returns":"\"transactionid\" (string) The transaction id."
"returns":"{\n \"name\" (string) the original name of the claim (before normalization)\n \"normalized_name\" (string) the name of this claim (after normalization)\n \"value\" (string) metadata of the claim\n \"claimId\" (string) the claimId of this claim\n \"txid\" (string) the hash of the transaction which has successfully claimed this name\n \"n\" (numeric) vout value\n \"amount\" (numeric) txout value\n \"effective amount\" (numeric) txout amount plus amount from all supports associated with the claim\n \"supports\" (array of object) supports for this claim\n [\n \"txid\" (string) the txid of the support\n \"n\" (numeric) the index of the support in the transaction's list of outputs\n \"height\" (numeric) the height at which the support was included in the blockchain\n \"valid at height\" (numeric) the height at which the support is valid\n \"amount\" (numeric) the amount of the support\n \"value\" (string) the metadata of the support if any\n ]\n \"height\" (numeric) the height of the block in which this claim transaction is located\n \"valid at height\" (numeric) the height at which the claim is valid\n}"
"returns":"{\n \"nLastTakeoverHeight\" (numeric) the last height at which ownership of the name changed\n \"normalized_name\" (string) the name of these claims after normalization\n \"claims\": [ (array of object) claims for this name\n {\n \"claimId\" (string) the claimId of this claim\n \"txid\" (string) the txid of this claim\n \"n\" (numeric) the index of the claim in the transaction's list of outputs\n \"nHeight\" (numeric) the height at which the claim was included in the blockchain\n \"nValidAtHeight\" (numeric) the height at which the claim became/becomes valid\n \"nAmount\" (numeric) the amount of the claim\n \"value\" (string) the metadata of the claim\n \"nEffectiveAmount\" (numeric) the total effective amount of the claim, taking into effect whether the claim or support has reached its nValidAtHeight\n \"supports\" : [ (array of object) supports for this claim\n \"txid\" (string) the txid of the support\n \"n\" (numeric) the index of the support in the transaction's list of outputs\n \"nHeight\" (numeric) the height at which the support was included in the blockchain\n \"nValidAtHeight\" (numeric) the height at which the support became/becomes valid\n \"nAmount\" (numeric) the amount of the support\n \"value\" (string) the metadata of the support if any\n ]\n \"name\" (string) the original name of this claim before normalization\n }\n ],\n \"supports without claims\": [ (array of object) supports that did not match a claim for this name\n {\n \"txid\" (string) the txid of the support\n \"n\" (numeric) the index of the support in the transaction's list of outputs\n \"nHeight\" (numeric) the height at which the support was included in the blockchain\n \"nValidAtHeight\" (numeric) the height at which the support became/becomes valid\n \"nAmount\" (numeric) the amount of the support\n }\n ]\n}"
"returns":"[\n {\n \"nOut\" (numeric) the index of the claim or support in the transaction's list of outputs\n \"claim type\" (string) 'claim' or 'support'\n \"name\" (string) the name claimed or supported\n \"claimId\" (string) if a claim, its ID\n \"value\" (string) if a name claim, the value of the claim\n \"supported txid\" (string) if a support, the txid of the supported claim\n \"supported nout\" (numeric) if a support, the index of the supported claim in its transaction\n \"depth\" (numeric) the depth of the transaction in the main chain\n \"in claim trie\" (boolean) if a name claim, whether the claim is active, i.e. has made it into the trie\n \"is controlling\" (boolean) if a name claim, whether the claim is the current controlling claim for the name\n \"in support map\" (boolean) if a support, whether the support is active, i.e. has made it into the support map\n \"in queue\" (boolean) whether the claim is in a queue waiting to be inserted into the trie or support map\n \"blocks to valid\" (numeric) if in a queue, the number of blocks until it's inserted into the trie or support map\n }\n]"
"description":"Return the cryptographic proof that a name maps to a value or doesn't.",
"arguments":[
{
"name":"name",
"type":"string",
"description":"the name to get a proof for",
"is_required":true
},
{
"name":"blockhash",
"type":"string",
"description":"the hash of the block which is the basis of the proof. If none is given, the latest block will be used.",
"is_required":false
}
],
"examples":[],
"returns":"{\n \"nodes\" : [ (array of object) full nodes (i.e.\n those which lead to\n the requested name)\n \"children\" : [ (array of object) the children of\n this node\n \"child\" : { (object) a child node, either leaf or\n reference to a full node\n \"character\" : \"char\" (string) the character which\n leads from the parent\n to this child node\n \"nodeHash\" : \"hash\" (string, if exists) the hash of\n the node if\n this is a \n leaf node\n }\n ]\n \"valueHash\" (string, if exists) the hash of this\n node's value, if\n it has one. If \n this is the\n requested name\n this will not\n exist whether\n the node has a\n value or not\n ]\n \"txhash\" : \"hash\" (string, if exists) the txid of the\n claim which controls\n this name, if there\n is one.\n \"nOut\" : n, (numeric) the nOut of the claim which\n controls this name, if there\n is one.\n \"last takeover height\" (numeric) the most recent height at\n which the value of a name\n changed other than through\n an update to the winning\n bid\n }\n}"
},
{
"name":"gettotalclaimednames",
"namespace":"Claimtrie",
"description":"Return the total number of names that have been successfully claimed, and therefore exist in the trie",
"arguments":[],
"examples":[],
"returns":"\"total names\" (numeric) the total number of\n names in the trie"
},
{
"name":"gettotalclaims",
"namespace":"Claimtrie",
"description":"Return the total number of active claims in the trie",
"arguments":[],
"examples":[],
"returns":"\"total claims\" (numeric) the total number\n of active claims"
},
{
"name":"gettotalvalueofclaims",
"namespace":"Claimtrie",
"description":"Return the total value of the claims in the trie",
"arguments":[
{
"name":"controlling_only",
"type":"boolean",
"description":"only include the value of controlling claims",
"is_required":true
}
],
"examples":[],
"returns":"\"total value\" (numeric) the total value of the\n claims in the trie"
},
{
"name":"getvalueforname",
"namespace":"Claimtrie",
"description":"Return the winning value associated with a name, if one exists",
"arguments":[
{
"name":"name",
"type":"string",
"description":"the name to look up",
"is_required":true
},
{
"name":"blockhash",
"type":"string",
"description":"get the value associated with the name at the block specified by this block hash. If none is given, the latest active block will be used.",
"is_required":false
}
],
"examples":[],
"returns":"\"value\" (string) the value of the name, if it exists\n\"claimId\" (string) the claimId for this name claim\n\"txid\" (string) the hash of the transaction which successfully claimed the name\n\"n\" (numeric) vout value\n\"amount\" (numeric) txout amount\n\"effective amount\" (numeric) txout amount plus amount from all supports associated with the claim\n\"height\" (numeric) the height of the block in which this transaction is located\n\"name\" (string) the original name of this claim (before normalization)"
},
{
"name":"listnameclaims",
"namespace":"Claimtrie",
"description":"Return a list of all transactions claiming names.",
"arguments":[
{
"name":"includesupports",
"type":"boolean",
"description":"Whether to also include claim supports. Default is true.",
"is_required":false
},
{
"name":"activeonly",
"type":"boolean",
"description":"Whether to only include transactions which are still active, i.e. have not been spent. Default is false.",
"returns":"[\n {\n \"name\":\"claimedname\", (string) The name that is claimed.\n \"claimtype\":\"claimtype\", (string) CLAIM or SUPPORT.\n \"claimId\":\"claimId\", (string) The claimId of the claim.\n \"value\":\"value\" (string) The value assigned to the name, if claimtype is CLAIM.\n \"account\":\"accountname\", (string) The account name associated with the transaction. \n It will be \"\" for the default account.\n \"address\":\"lbrycrdaddress\", (string) The lbrycrd address of the transaction.\n \"category\":\"name\" (string) Always name\n \"amount\": x.xxx, (numeric) The amount in LBC.\n \"vout\": n, (numeric) The vout value\n \"fee\": x.xxx, (numeric) The amount of the fee in LBC.\n \"height\": n (numeric) The height of the block in which this transaction was included.\n \"confirmations\": n, (numeric) The number of confirmations for the transaction\n \"blockhash\": \"hashvalue\", (string) The block hash containing the transaction.\n \"blockindex\": n, (numeric) The block index containing the transaction.\n \"txid\": \"transactionid\", (string) The transaction id.\n \"time\": xxx, (numeric) The transaction time in seconds since epoch (midnight Jan 1 1970 GMT).\n \"timereceived\": xxx, (numeric) The time received in seconds since epoch (midnight Jan 1 1970 GMT).\n \"comment\": \"...\", (string) If a comment is associated with the transaction.\n }\n]"
"description":"Increase the value of a claim. Whichever claim has the greatest value, including all support values, will be the authoritative claim, according to the rest of the rules. The name is the name which is claimed by the claim that will be supported, the txid is the txid of the claim that will be supported, nout is the transaction output which contains the claim to be supported, and amount is the amount which will be added to the value of the claim. If the claim is currently the authoritative claim, this support will go into effect immediately . Otherwise, it will go into effect after 100 blocks. The support will be in effect until it is spent, and will lose its effect when the claim is spent or expires. The amount is a real and is rounded to the nearest .00000001",
"returns":"\"transactionid\" (string) The transaction id of the support."
},
{
"name":"updateclaim",
"namespace":"Claimtrie",
"description":"Create a transaction which issues a claim assigning a value to a name, spending the previous txout which issued a claim over the same name and therefore superseding that claim. The claim will be authoritative if the transaction amount is greater than the transaction amount of all other unspent transactions which issue a claim over the same name, and it will remain authoritative as long as it remains unspent and there are no greater unspent transactions issuing a claim over the same name.",
"arguments":[
{
"name":"txid",
"type":"string",
"description":"The transaction containing the unspent txout which should be spent.",
"is_required":true
},
{
"name":"value",
"type":"string",
"description":"The value to assign to the name encoded in hexadecimal.",
"is_required":true
},
{
"name":"amount",
"type":"number",
"description":"The amount in LBRYcrd to use to bid for the name. eg 0.1",
"is_required":true
}
],
"examples":[],
"returns":"\"transactionid\" (string) The new transaction id."
"description":"If verbosity is 0, returns a string that is serialized, hex-encoded data for block 'hash'. If verbosity is 1, returns an Object with information about block <hash>. If verbosity is 2, returns an Object with information about block <hash> and information about each transaction.",
"returns":"\"data\" (string) A string that is serialized, hex-encoded data for block 'hash'.\n\nResult (for verbosity = 1):\n{\n \"hash\" : \"hash\", (string) the block hash (same as provided)\n \"confirmations\" : n, (numeric) The number of confirmations, or -1 if the block is not on the main chain\n \"size\" : n, (numeric) The block size\n \"strippedsize\" : n, (numeric) The block size excluding witness data\n \"weight\" : n (numeric) The block weight as defined in BIP 141\n \"height\" : n, (numeric) The block height or index\n \"version\" : n, (numeric) The block version\n \"versionHex\" : \"00000000\", (string) The block version formatted in hexadecimal\n \"merkleroot\" : \"xxxx\", (string) The merkle root\n \"nameclaimroot\" : \"xxxx\", (string) The hash of the root of the name claim trie\n \"tx\" : [ (array of string) The transaction ids\n \"transactionid\" (string) The transaction id\n ,...\n ],\n \"time\" : ttt, (numeric) The block time in seconds since epoch (Jan 1 1970 GMT)\n \"mediantime\" : ttt, (numeric) The median block time in seconds since epoch (Jan 1 1970 GMT)\n \"nonce\" : n, (numeric) The nonce\n \"bits\" : \"1d00ffff\", (string) The bits\n \"difficulty\" : x.xxx, (numeric) The difficulty\n \"chainwork\" : \"xxxx\", (string) Expected number of hashes required to produce the chain up to this block (in hex)\n \"nTx\" : n, (numeric) The number of transactions in the block.\n \"previousblockhash\" : \"hash\", (string) The hash of the previous block\n \"nextblockhash\" : \"hash\" (string) The hash of the next block\n}\n\nResult (for verbosity = 2):\n{\n ..., Same output as verbosity = 1.\n \"tx\" : [ (array of Objects) The transactions in the format of the getrawtransaction RPC. Different from verbosity = 1 \"tx\" result.\n ,...\n ],\n ,... Same output as verbosity = 1.\n}"
"returns":"{\n \"chain\": \"xxxx\", (string) current network name as defined in BIP70 (main, test, regtest)\n \"blocks\": xxxxxx, (numeric) the current number of blocks processed in the server\n \"headers\": xxxxxx, (numeric) the current number of headers we have validated\n \"bestblockhash\": \"...\", (string) the hash of the currently best block\n \"difficulty\": xxxxxx, (numeric) the current difficulty\n \"mediantime\": xxxxxx, (numeric) median time for the current best block\n \"verificationprogress\": xxxx, (numeric) estimate of verification progress [0..1]\n \"initialblockdownload\": xxxx, (bool) (debug information) estimate of whether this node is in Initial Block Download mode.\n \"chainwork\": \"xxxx\" (string) total amount of work in active chain, in hexadecimal\n \"size_on_disk\": xxxxxx, (numeric) the estimated size of the block and undo files on disk\n \"pruned\": xx, (boolean) if the blocks are subject to pruning\n \"pruneheight\": xxxxxx, (numeric) lowest-height complete block stored (only present if pruning is enabled)\n \"automatic_pruning\": xx, (boolean) whether automatic pruning is enabled (only present if pruning is enabled)\n \"prune_target_size\": xxxxxx, (numeric) the target size used by pruning (only present if automatic pruning is enabled)\n \"softforks\": [ (array) status of softforks in progress\n {\n \"id\": \"xxxx\", (string) name of softfork\n \"version\": xx, (numeric) block version\n \"reject\": { (object) progress toward rejecting pre-softfork blocks\n \"status\": xx, (boolean) true if threshold reached\n },\n }, ...\n ],\n \"bip9_softforks\": { (object) status of BIP9 softforks in progress\n \"xxxx\" : { (string) name of the softfork\n \"status\": \"xxxx\", (string) one of \"defined\", \"started\", \"locked_in\", \"active\", \"failed\"\n \"bit\": xx, (numeric) the bit (0-28) in the block version field used to signal this softfork (only for \"started\" status)\n \"startTime\": xx, (numeric) the minimum median time past of a block at which the bit gains its meaning\n \"timeout\": xx, (numeric) the median time past of a block at which the deployment is considered failed if not yet locked in\n \"since\": xx, (numeric) height of the first block to which the status applies\n \"statistics\": { (object) numeric statistics about BIP9 signalling for a softfork (only for \"started\" status)\n \"period\": xx, (numeric) the length in blocks of the BIP9 signalling period \n \"threshold\": xx, (numeric) the number of blocks with the version bit set required to activate the feature \n \"elapsed\": xx, (numeric) the number of blocks elapsed since the beginning of the current period \n \"count\": xx, (numeric) the number of blocks with the version bit set in the current period \n \"possible\": xx (boolean) returns false if there are not enough blocks left in this period to pass activation threshold \n }\n }\n }\n \"warnings\" : \"...\", (string) any network and blockchain warnings.\n}"
"description":"If verbose is false, returns a string that is serialized, hex-encoded data for blockheader 'hash'. If verbose is true, returns an Object with information about blockheader <hash>.",
"arguments":[
{
"name":"hash",
"type":"string",
"description":"The block hash",
"is_required":true
},
{
"name":"verbose",
"type":"boolean",
"description":"true for a json object, false for the hex encoded data",
"returns":"{\n \"hash\" : \"hash\", (string) the block hash (same as provided)\n \"confirmations\" : n, (numeric) The number of confirmations, or -1 if the block is not on the main chain\n \"height\" : n, (numeric) The block height or index\n \"version\" : n, (numeric) The block version\n \"versionHex\" : \"00000000\", (string) The block version formatted in hexadecimal\n \"merkleroot\" : \"xxxx\", (string) The merkle root\n \"nameclaimroot\" : \"xxxx\", (string) The hash of the root of the name claim trie\n \"time\" : ttt, (numeric) The block time in seconds since epoch (Jan 1 1970 GMT)\n \"mediantime\" : ttt, (numeric) The median block time in seconds since epoch (Jan 1 1970 GMT)\n \"nonce\" : n, (numeric) The nonce\n \"bits\" : \"1d00ffff\", (string) The bits\n \"difficulty\" : x.xxx, (numeric) The difficulty\n \"chainwork\" : \"0000...1f3\" (string) Expected number of hashes required to produce the current chain (in hex)\n \"nTx\" : n, (numeric) The number of transactions in the block.\n \"previousblockhash\" : \"hash\", (string) The hash of the previous block\n \"nextblockhash\" : \"hash\", (string) The hash of the next block\n}\n\nResult (for verbose=false):\n\"data\" (string) A string that is serialized, hex-encoded data for block 'hash'."
},
{
"name":"getblockstats",
"namespace":"Blockchain",
"description":"Compute per block statistics for a given window. All amounts are in satoshis. It won't work for some heights with pruning. It won't work without -txindex for utxo_size_inc, *fee or *feerate stats.",
"arguments":[
{
"name":"hash_or_height",
"type":"number",
"description":"The block hash or height of the target block",
"is_required":true
},
{
"name":"stats",
"type":"array",
"description":"Values to plot, by default all values (see result below) [ \"height\", (string, optional) Selected statistic \"time\", (string, optional) Selected statistic ,... ]",
"returns":"{ (json object)\n \"avgfee\": xxxxx, (numeric) Average fee in the block\n \"avgfeerate\": xxxxx, (numeric) Average feerate (in satoshis per virtual byte)\n \"avgtxsize\": xxxxx, (numeric) Average transaction size\n \"blockhash\": xxxxx, (string) The block hash (to check for potential reorgs)\n \"feerate_percentiles\": [ (array of numeric) Feerates at the 10th, 25th, 50th, 75th, and 90th percentile weight unit (in satoshis per virtual byte)\n \"10th_percentile_feerate\", (numeric) The 10th percentile feerate\n \"25th_percentile_feerate\", (numeric) The 25th percentile feerate\n \"50th_percentile_feerate\", (numeric) The 50th percentile feerate\n \"75th_percentile_feerate\", (numeric) The 75th percentile feerate\n \"90th_percentile_feerate\", (numeric) The 90th percentile feerate\n ],\n \"height\": xxxxx, (numeric) The height of the block\n \"ins\": xxxxx, (numeric) The number of inputs (excluding coinbase)\n \"maxfee\": xxxxx, (numeric) Maximum fee in the block\n \"maxfeerate\": xxxxx, (numeric) Maximum feerate (in satoshis per virtual byte)\n \"maxtxsize\": xxxxx, (numeric) Maximum transaction size\n \"medianfee\": xxxxx, (numeric) Truncated median fee in the block\n \"mediantime\": xxxxx, (numeric) The block median time past\n \"mediantxsize\": xxxxx, (numeric) Truncated median transaction size\n \"minfee\": xxxxx, (numeric) Minimum fee in the block\n \"minfeerate\": xxxxx, (numeric) Minimum feerate (in satoshis per virtual byte)\n \"mintxsize\": xxxxx, (numeric) Minimum transaction size\n \"outs\": xxxxx, (numeric) The number of outputs\n \"subsidy\": xxxxx, (numeric) The block subsidy\n \"swtotal_size\": xxxxx, (numeric) Total size of all segwit transactions\n \"swtotal_weight\": xxxxx, (numeric) Total weight of all segwit transactions divided by segwit scale factor (4)\n \"swtxs\": xxxxx, (numeric) The number of segwit transactions\n \"time\": xxxxx, (numeric) The block time\n \"total_out\": xxxxx, (numeric) Total amount in all outputs (excluding coinbase and thus reward [ie subsidy + totalfee])\n \"total_size\": xxxxx, (numeric) Total size of all non-coinbase transactions\n \"total_weight\": xxxxx, (numeric) Total weight of all non-coinbase transactions divided by segwit scale factor (4)\n \"totalfee\": xxxxx, (numeric) The fee total\n \"txs\": xxxxx, (numeric) The number of transactions (excluding coinbase)\n \"utxo_increase\": xxxxx, (numeric) The increase/decrease in the number of unspent outputs\n \"utxo_size_inc\": xxxxx, (numeric) The increase/decrease in size for the utxo index (not discounting op_return and similar)\n}"
"returns":"[\n {\n \"height\": xxxx, (numeric) height of the chain tip\n \"hash\": \"xxxx\", (string) block hash of the tip\n \"branchlen\": 0 (numeric) zero for main chain\n \"status\": \"active\" (string) \"active\" for the main chain\n },\n {\n \"height\": xxxx,\n \"hash\": \"xxxx\",\n \"branchlen\": 1 (numeric) length of branch connecting the tip to the main chain\n \"status\": \"xxxx\" (string) status of the chain (active, valid-fork, valid-headers, headers-only, invalid)\n }\n]\nPossible values for status:\n1. \"invalid\" This branch contains at least one invalid block\n2. \"headers-only\" Not all blocks for this branch are available, but the headers are valid\n3. \"valid-headers\" All blocks are available for this branch, but they were never fully validated\n4. \"valid-fork\" This branch is not part of the active chain, but is fully validated\n5. \"active\" This is the tip of the active main chain, which is certainly valid"
"returns":"{\n \"time\": xxxxx, (numeric) The timestamp for the final block in the window in UNIX format.\n \"txcount\": xxxxx, (numeric) The total number of transactions in the chain up to that point.\n \"window_final_block_hash\": \"...\", (string) The hash of the final block in the window.\n \"window_block_count\": xxxxx, (numeric) Size of the window in number of blocks.\n \"window_tx_count\": xxxxx, (numeric) The number of transactions in the window. Only returned if \"window_block_count\" is > 0.\n \"window_interval\": xxxxx, (numeric) The elapsed time in the window in seconds. Only returned if \"window_block_count\" is > 0.\n \"txrate\": x.xx, (numeric) The average rate of transactions per second in the window. Only returned if \"window_interval\" is > 0.\n}"
"returns":"[ (json array of strings)\n \"transactionid\" (string) The transaction id of an in-mempool ancestor transaction\n ,...\n]\n\nResult (for verbose=true):\n{ (json object)\n \"transactionid\" : { (json object)\n \"size\" : n, (numeric) virtual transaction size as defined in BIP 141. This is different from actual serialized size for witness transactions as witness data is discounted.\n \"fee\" : n, (numeric) transaction fee in LBC (DEPRECATED)\n \"modifiedfee\" : n, (numeric) transaction fee with fee deltas used for mining priority (DEPRECATED)\n \"time\" : n, (numeric) local time transaction entered pool in seconds since 1 Jan 1970 GMT\n \"height\" : n, (numeric) block height when transaction entered pool\n \"descendantcount\" : n, (numeric) number of in-mempool descendant transactions (including this one)\n \"descendantsize\" : n, (numeric) virtual transaction size of in-mempool descendants (including this one)\n \"descendantfees\" : n, (numeric) modified fees (see above) of in-mempool descendants (including this one) (DEPRECATED)\n \"ancestorcount\" : n, (numeric) number of in-mempool ancestor transactions (including this one)\n \"ancestorsize\" : n, (numeric) virtual transaction size of in-mempool ancestors (including this one)\n \"ancestorfees\" : n, (numeric) modified fees (see above) of in-mempool ancestors (including this one) (DEPRECATED)\n \"wtxid\" : hash, (string) hash of serialized transaction, including witness data\n \"fees\" : {\n \"base\" : n, (numeric) transaction fee in LBC\n \"modified\" : n, (numeric) transaction fee with fee deltas used for mining priority in LBC\n \"ancestor\" : n, (numeric) modified fees (see above) of in-mempool ancestors (including this one) in LBC\n \"descendant\" : n, (numeric) modified fees (see above) of in-mempool descendants (including this one) in LBC\n }\n \"depends\" : [ (array) unconfirmed transactions used as inputs for this transaction\n \"transactionid\", (string) parent transaction id\n ... ]\n \"spentby\" : [ (array) unconfirmed transactions spending outputs from this transaction\n \"transactionid\", (string) child transaction id\n ... ]\n }, ...\n}"
},
{
"name":"getmempooldescendants",
"namespace":"Blockchain",
"description":"If txid is in the mempool, returns all in-mempool descendants.",
"arguments":[
{
"name":"txid",
"type":"string",
"description":"The transaction id (must be in mempool)",
"is_required":true
},
{
"name":"verbose",
"type":"boolean",
"description":"True for a json object, false for array of transaction ids",
"returns":"[ (json array of strings)\n \"transactionid\" (string) The transaction id of an in-mempool descendant transaction\n ,...\n]\n\nResult (for verbose=true):\n{ (json object)\n \"transactionid\" : { (json object)\n \"size\" : n, (numeric) virtual transaction size as defined in BIP 141. This is different from actual serialized size for witness transactions as witness data is discounted.\n \"fee\" : n, (numeric) transaction fee in LBC (DEPRECATED)\n \"modifiedfee\" : n, (numeric) transaction fee with fee deltas used for mining priority (DEPRECATED)\n \"time\" : n, (numeric) local time transaction entered pool in seconds since 1 Jan 1970 GMT\n \"height\" : n, (numeric) block height when transaction entered pool\n \"descendantcount\" : n, (numeric) number of in-mempool descendant transactions (including this one)\n \"descendantsize\" : n, (numeric) virtual transaction size of in-mempool descendants (including this one)\n \"descendantfees\" : n, (numeric) modified fees (see above) of in-mempool descendants (including this one) (DEPRECATED)\n \"ancestorcount\" : n, (numeric) number of in-mempool ancestor transactions (including this one)\n \"ancestorsize\" : n, (numeric) virtual transaction size of in-mempool ancestors (including this one)\n \"ancestorfees\" : n, (numeric) modified fees (see above) of in-mempool ancestors (including this one) (DEPRECATED)\n \"wtxid\" : hash, (string) hash of serialized transaction, including witness data\n \"fees\" : {\n \"base\" : n, (numeric) transaction fee in LBC\n \"modified\" : n, (numeric) transaction fee with fee deltas used for mining priority in LBC\n \"ancestor\" : n, (numeric) modified fees (see above) of in-mempool ancestors (including this one) in LBC\n \"descendant\" : n, (numeric) modified fees (see above) of in-mempool descendants (including this one) in LBC\n }\n \"depends\" : [ (array) unconfirmed transactions used as inputs for this transaction\n \"transactionid\", (string) parent transaction id\n ... ]\n \"spentby\" : [ (array) unconfirmed transactions spending outputs from this transaction\n \"transactionid\", (string) child transaction id\n ... ]\n }, ...\n}"
},
{
"name":"getmempoolentry",
"namespace":"Blockchain",
"description":"Returns mempool data for given transaction",
"arguments":[
{
"name":"txid",
"type":"string",
"description":"The transaction id (must be in mempool)",
"returns":"{ (json object)\n \"size\" : n, (numeric) virtual transaction size as defined in BIP 141. This is different from actual serialized size for witness transactions as witness data is discounted.\n \"fee\" : n, (numeric) transaction fee in LBC (DEPRECATED)\n \"modifiedfee\" : n, (numeric) transaction fee with fee deltas used for mining priority (DEPRECATED)\n \"time\" : n, (numeric) local time transaction entered pool in seconds since 1 Jan 1970 GMT\n \"height\" : n, (numeric) block height when transaction entered pool\n \"descendantcount\" : n, (numeric) number of in-mempool descendant transactions (including this one)\n \"descendantsize\" : n, (numeric) virtual transaction size of in-mempool descendants (including this one)\n \"descendantfees\" : n, (numeric) modified fees (see above) of in-mempool descendants (including this one) (DEPRECATED)\n \"ancestorcount\" : n, (numeric) number of in-mempool ancestor transactions (including this one)\n \"ancestorsize\" : n, (numeric) virtual transaction size of in-mempool ancestors (including this one)\n \"ancestorfees\" : n, (numeric) modified fees (see above) of in-mempool ancestors (including this one) (DEPRECATED)\n \"wtxid\" : hash, (string) hash of serialized transaction, including witness data\n \"fees\" : {\n \"base\" : n, (numeric) transaction fee in LBC\n \"modified\" : n, (numeric) transaction fee with fee deltas used for mining priority in LBC\n \"ancestor\" : n, (numeric) modified fees (see above) of in-mempool ancestors (including this one) in LBC\n \"descendant\" : n, (numeric) modified fees (see above) of in-mempool descendants (including this one) in LBC\n }\n \"depends\" : [ (array) unconfirmed transactions used as inputs for this transaction\n \"transactionid\", (string) parent transaction id\n ... ]\n \"spentby\" : [ (array) unconfirmed transactions spending outputs from this transaction\n \"transactionid\", (string) child transaction id\n ... ]\n}"
"returns":"{\n \"size\": xxxxx, (numeric) Current tx count\n \"bytes\": xxxxx, (numeric) Sum of all virtual transaction sizes as defined in BIP 141. Differs from actual serialized size because witness data is discounted\n \"usage\": xxxxx, (numeric) Total memory usage for the mempool\n \"maxmempool\": xxxxx, (numeric) Maximum memory usage for the mempool\n \"mempoolminfee\": xxxxx (numeric) Minimum fee rate in LBC/kB for tx to be accepted. Is the maximum of minrelaytxfee and minimum mempool fee\n \"minrelaytxfee\": xxxxx (numeric) Current minimum relay fee for transactions\n}"
"description":"Returns all transaction ids in memory pool as a json array of string transaction ids. Hint: use getmempoolentry to fetch a specific transaction from the mempool.",
"returns":"[ (json array of string)\n \"transactionid\" (string) The transaction id\n ,...\n]\n\nResult: (for verbose = true):\n{ (json object)\n \"transactionid\" : { (json object)\n \"size\" : n, (numeric) virtual transaction size as defined in BIP 141. This is different from actual serialized size for witness transactions as witness data is discounted.\n \"fee\" : n, (numeric) transaction fee in LBC (DEPRECATED)\n \"modifiedfee\" : n, (numeric) transaction fee with fee deltas used for mining priority (DEPRECATED)\n \"time\" : n, (numeric) local time transaction entered pool in seconds since 1 Jan 1970 GMT\n \"height\" : n, (numeric) block height when transaction entered pool\n \"descendantcount\" : n, (numeric) number of in-mempool descendant transactions (including this one)\n \"descendantsize\" : n, (numeric) virtual transaction size of in-mempool descendants (including this one)\n \"descendantfees\" : n, (numeric) modified fees (see above) of in-mempool descendants (including this one) (DEPRECATED)\n \"ancestorcount\" : n, (numeric) number of in-mempool ancestor transactions (including this one)\n \"ancestorsize\" : n, (numeric) virtual transaction size of in-mempool ancestors (including this one)\n \"ancestorfees\" : n, (numeric) modified fees (see above) of in-mempool ancestors (including this one) (DEPRECATED)\n \"wtxid\" : hash, (string) hash of serialized transaction, including witness data\n \"fees\" : {\n \"base\" : n, (numeric) transaction fee in LBC\n \"modified\" : n, (numeric) transaction fee with fee deltas used for mining priority in LBC\n \"ancestor\" : n, (numeric) modified fees (see above) of in-mempool ancestors (including this one) in LBC\n \"descendant\" : n, (numeric) modified fees (see above) of in-mempool descendants (including this one) in LBC\n }\n \"depends\" : [ (array) unconfirmed transactions used as inputs for this transaction\n \"transactionid\", (string) parent transaction id\n ... ]\n \"spentby\" : [ (array) unconfirmed transactions spending outputs from this transaction\n \"transactionid\", (string) child transaction id\n ... ]\n }, ...\n}"
"returns":"{\n \"bestblock\": \"hash\", (string) The hash of the block at the tip of the chain\n \"confirmations\" : n, (numeric) The number of confirmations\n \"value\" : x.xxx, (numeric) The transaction value in LBC\n \"scriptPubKey\" : { (json object)\n \"asm\" : \"code\", (string) \n \"hex\" : \"hex\", (string) \n \"reqSigs\" : n, (numeric) Number of required signatures\n \"type\" : \"pubkeyhash\", (string) The type, eg pubkeyhash\n \"addresses\" : [ (array of string) array of lbrycrd addresses\n \"address\" (string) lbrycrd address\n ,...\n ]\n },\n \"coinbase\" : true|false (boolean) Coinbase or not\n}"
"description":"Returns a hex-encoded proof that \"txid\" was included in a block. NOTE: By default this function only works sometimes. This is when there is an unspent output in the utxo for this transaction. To make it always work, you need to maintain a transaction index, using the -txindex command line option or specify the block in which the transaction is included manually (by blockhash).",
"returns":"{\n \"height\":n, (numeric) The current block height (index)\n \"bestblock\": \"hex\", (string) The hash of the block at the tip of the chain\n \"transactions\": n, (numeric) The number of transactions with unspent outputs\n \"txouts\": n, (numeric) The number of unspent transaction outputs\n \"bogosize\": n, (numeric) A meaningless metric for UTXO set size\n \"hash_serialized_2\": \"hash\", (string) The serialized hash\n \"disk_size\": n, (numeric) The estimated size of the chainstate on disk\n \"total_amount\": x.xxx (numeric) The total amount\n}"
},
{
"name":"preciousblock",
"namespace":"Blockchain",
"description":"Treats a block as if it were received before others with the same work. A later preciousblock call can override the effect of an earlier one. The effects of preciousblock are not retained across restarts.",
"arguments":[
{
"name":"blockhash",
"type":"string",
"description":"the hash of the block to mark as precious",
"description":"The block height to prune up to. May be set to a discrete height, or a unix timestamp to prune blocks whose block time is at least 2 hours older than the provided timestamp.",
"description":"EXPERIMENTAL warning: this call may be removed or changed in future releases. Scans the unspent transaction output set for entries that match certain output descriptors.",
"arguments":[],
"examples":[
{
"title":"addr(<address>) Outputs whose scriptPubKey corresponds to the specified address (does not include P2PK)"
},
{
"title":"raw(<hex script>) Outputs whose scriptPubKey equals the specified hex scripts"
},
{
"title":"combo(<pubkey>) P2PK, P2PKH, P2WPKH, and P2SH-P2WPKH outputs for the given pubkey"
},
{
"title":"pkh(<pubkey>) P2PKH outputs for the given pubkey"
},
{
"title":"sh(multi(<n>,<pubkey>,<pubkey>,...)) P2SH-multisig outputs for the given threshold and pubkeys"
},
{
"title":"In the above, <pubkey> either refers to a fixed public key in hexadecimal notation, or to an xpub/xprv optionally followed by one"
},
{
"title":"or more path elements separated by \"/\", and optionally ending in \"/*\" (unhardened), or \"/*'\" or \"/*h\" (hardened) to specify all"
},
{
"title":"unhardened or hardened child keys."
},
{
"title":"In the latter case, a range needs to be specified by below if different from 1000."
},
{
"title":"For more information on output descriptors, see the documentation in the doc/descriptors.md file."
},
{
"title":"Arguments:"
},
{
"title":"1. \"action\" (string, required) The action to execute"
},
{
"title":"\"start\" for starting a scan"
},
{
"title":"\"abort\" for aborting the current scan (returns true when abort was successful)"
},
{
"title":"\"status\" for progress report (in %) of the current scan"
},
{
"title":"2. \"scanobjects\" (array, required) Array of scan objects"
},
{
"title":"[ Every scan object is either a string descriptor or an object:"
},
{
"title":"\"descriptor\", (string, optional) An output descriptor"
},
{
"title":"{ (object, optional) An object with output descriptor and metadata"
},
{
"title":"\"desc\": \"descriptor\", (string, required) An output descriptor"
},
{
"title":"\"range\": n, (numeric, optional) Up to what child index HD chains should be explored (default: 1000)"
},
{
"title":"},"
},
{
"title":"..."
},
{
"title":"]"
},
{
"title":"Result:"
},
{
"title":"{"
},
{
"title":"\"unspents\": ["
},
{
"title":"{"
},
{
"title":"\"txid\" : \"transactionid\", (string) The transaction id"
},
{
"title":"\"vout\": n, (numeric) the vout value"
},
{
"title":"\"scriptPubKey\" : \"script\", (string) the script key"
},
{
"title":"\"amount\" : x.xxx, (numeric) The total amount in LBC of the unspent output"
},
{
"title":"\"height\" : n, (numeric) Height of the unspent transaction output"
},
{
"title":"}"
},
{
"title":",...],"
},
{
"title":"\"total_amount\" : x.xxx, (numeric) The total amount of all found unspent outputs in LBC"
"description":"Verifies that a proof points to a transaction in a block, returning the transaction it commits to and throwing an RPC error if the block is not in our best chain",
"arguments":[
{
"name":"proof",
"type":"string",
"description":"The hex-encoded proof generated by gettxoutproof",
"description":"Returns an object containing information about memory usage.",
"arguments":[
{
"name":"\"mode\" determines what kind of information is returned. This argument is optional, the default mode is \"stats\".\n - \"stats\" returns general statistics about memory usage in the daemon.\n - \"mallocinfo\" returns an XML string describing low-level heap state",
"type":"only available if compiled with glibc 2.10+",
"returns":"{\n \"locked\": { (json object) Information about locked memory manager\n \"used\": xxxxx, (numeric) Number of bytes used\n \"free\": xxxxx, (numeric) Number of bytes available in current arenas\n \"total\": xxxxxxx, (numeric) Total number of bytes managed\n \"locked\": xxxxxx, (numeric) Amount of bytes that succeeded locking. If this number is smaller than total, locking pages failed at some point and key data could be swapped to disk.\n \"chunks_used\": xxxxx, (numeric) Number allocated chunks\n \"chunks_free\": xxxxx, (numeric) Number unused chunks\n }\n}\n\nResult (mode \"mallocinfo\"):\n\"<malloc version=\"1\">...\""
"description":"Gets and sets the logging configuration. When called without an argument, returns the list of categories with status that are currently being debug logged or not. When called with arguments, adds or removes categories from debug logging and return the lists above. The arguments are evaluated in order \"include\", \"exclude\". If an item is both included and excluded, it will thus end up being excluded. The valid logging categories are: net, tor, mempool, http, bench, zmq, db, rpc, estimatefee, addrman, selectcoins, reindex, cmpctblock, rand, prune, proxy, mempoolrej, libevent, coindb, qt, leveldb In addition, the following are available as category names with special meanings: - \"all\", \"1\" : represent all logging categories. - \"none\", \"0\" : even if other logging categories are specified, ignore all of them.",
"arguments":[
{
"name":"include",
"type":"array",
"description":"A json array of categories to add debug logging [ \"category\" (string) the valid logging category ,... ]",
"is_required":false
},
{
"name":"exclude",
"type":"array",
"description":"A json array of categories to remove debug logging [ \"category\" (string) the valid logging category ,... ]",
"returns":"{ (json object where keys are the logging categories, and values indicates its status\n \"category\": 0|1, (numeric) if being debug logged or not. 0:inactive, 1:active\n ...\n}"
},
{
"name":"stop",
"namespace":"Control",
"description":"Stop lbrycrd server.",
"arguments":[],
"examples":[]
},
{
"name":"uptime",
"namespace":"Control",
"description":"Returns the total uptime of the server.",
"description":"If the request parameters include a 'mode' key, that is used to explicitly select between the default 'template' request or a 'proposal'. It returns data needed to construct a block to work on. For full specification, see BIPs 22, 23, 9, and 145: https://github.com/bitcoin/bips/blob/master/bip-0022.mediawiki https://github.com/bitcoin/bips/blob/master/bip-0023.mediawiki https://github.com/bitcoin/bips/blob/master/bip-0009.mediawiki#getblocktemplate_changes https://github.com/bitcoin/bips/blob/master/bip-0145.mediawiki",
"description":"A json object in the following spec { \"mode\":\"template\" (string, optional) This must be set to \"template\", \"proposal\" (see BIP 23), or omitted \"capabilities\":[ (array, optional) A list of strings \"support\" (string) client side supported feature, 'longpoll', 'coinbasetxn', 'coinbasevalue', 'proposal', 'serverlist', 'workid' ,... ], \"rules\":[ (array, optional) A list of strings \"support\" (string) client side supported softfork deployment ,... ] }",
"returns":"{\n \"version\" : n, (numeric) The preferred block version\n \"rules\" : [ \"rulename\", ... ], (array of strings) specific block rules that are to be enforced\n \"vbavailable\" : { (json object) set of pending, supported versionbit (BIP 9) softfork deployments\n \"rulename\" : bitnumber (numeric) identifies the bit number as indicating acceptance and readiness for the named softfork rule\n ,...\n },\n \"vbrequired\" : n, (numeric) bit mask of versionbits the server requires set in submissions\n \"previousblockhash\" : \"xxxx\", (string) The hash of current highest block\n \"transactions\" : [ (array) contents of non-coinbase transactions that should be included in the next block\n {\n \"data\" : \"xxxx\", (string) transaction data encoded in hexadecimal (byte-for-byte)\n \"txid\" : \"xxxx\", (string) transaction id encoded in little-endian hexadecimal\n \"hash\" : \"xxxx\", (string) hash encoded in little-endian hexadecimal (including witness data)\n \"depends\" : [ (array) array of numbers \n n (numeric) transactions before this one (by 1-based index in 'transactions' list) that must be present in the final block if this one is\n ,...\n ],\n \"fee\": n, (numeric) difference in value between transaction inputs and outputs (in satoshis); for coinbase transactions, this is a negative Number of the total collected block fees (ie, not including the block subsidy); if key is not present, fee is unknown and clients MUST NOT assume there isn't one\n \"sigops\" : n, (numeric) total SigOps cost, as counted for purposes of block limits; if key is not present, sigop cost is unknown and clients MUST NOT assume it is zero\n \"weight\" : n, (numeric) total transaction weight, as counted for purposes of block limits\n }\n ,...\n ],\n \"coinbaseaux\" : { (json object) data that should be included in the coinbase's scriptSig content\n \"flags\" : \"xx\" (string) key name is to be ignored, and value included in scriptSig\n },\n \"coinbasevalue\" : n, (numeric) maximum allowable input to coinbase transaction, including the generation award and transaction fees (in satoshis)\n \"coinbasetxn\" : { ... }, (json object) information for coinbase transaction\n \"target\" : \"xxxx\", (string) The hash target\n \"mintime\" : xxx, (numeric) The minimum timestamp appropriate for next block time in seconds since epoch (Jan 1 1970 GMT)\n \"mutable\" : [ (array of string) list of ways the block template may be changed \n \"value\" (string) A way the block template may be changed, e.g. 'time', 'transactions', 'prevblock'\n ,...\n ],\n \"noncerange\" : \"00000000ffffffff\", (string) A range of valid nonces\n \"sigoplimit\" : n, (numeric) limit of sigops in blocks\n \"sizelimit\" : n, (numeric) limit of block size\n \"weightlimit\" : n, (numeric) limit of block weight\n \"curtime\" : ttt, (numeric) current timestamp in seconds since epoch (Jan 1 1970 GMT)\n \"bits\" : \"xxxxxxxx\", (string) compressed target of next block\n \"height\" : n (numeric) The height of the next block\n \"claimtrie\" : \"00000000ffffffff\", (string) The root hash of the claim trie in hex\n}"
"returns":"{\n \"blocks\": nnn, (numeric) The current block\n \"currentblockweight\": nnn, (numeric) The last block weight\n \"currentblocktx\": nnn, (numeric) The last block transaction\n \"difficulty\": xxx.xxxxx (numeric) The current difficulty\n \"networkhashps\": nnn, (numeric) The network hashes per second\n \"pooledtx\": n (numeric) The size of the mempool\n \"chain\": \"xxxx\", (string) current network name as defined in BIP70 (main, test, regtest)\n \"warnings\": \"...\" (string) any network and blockchain warnings\n}"
"description":"Returns the estimated network hashes per second based on the last n blocks. Pass in [blocks] to override # of blocks, -1 specifies since last difficulty change. Pass in [height] to estimate the network speed at the time when a certain block was found.",
"description":"API-Compatibility for previous API. Must be zero or null. DEPRECATED. For forward compatibility use named arguments and omit this parameter.",
"description":"The fee value (in satoshis) to add (or subtract, if negative). Note, that this value is not a fee rate. It is a value to modify absolute fee of the TX. The fee is not actually paid, only the algorithm for selecting transactions into a block considers the transaction as it would have paid a higher (or lower) fee.",
"description":"Attempts to add or remove a node from the addnode list. Or try a connection to a node once. Nodes added using addnode (or -connect) are protected from DoS disconnection and are not required to be full nodes/support SegWit as other outbound peers are (though such peers will not be synced from).",
"description":"Immediately disconnects from the specified peer node. Strictly one out of 'address' and 'nodeid' can be provided to identify the node. To disconnect by nodeid, either set 'address' to the empty string, or call using the named 'nodeid' argument only.",
"returns":"[\n {\n \"addednode\" : \"192.168.0.201\", (string) The node IP address or name (as provided to addnode)\n \"connected\" : true|false, (boolean) If connected\n \"addresses\" : [ (list of objects) Only when connected = true\n {\n \"address\" : \"192.168.0.201:8333\", (string) The lbrycrd server IP and port we're connected to\n \"connected\" : \"outbound\" (string) connection, inbound or outbound\n }\n ]\n }\n ,...\n]"
"returns":"{\n \"totalbytesrecv\": n, (numeric) Total bytes received\n \"totalbytessent\": n, (numeric) Total bytes sent\n \"timemillis\": t, (numeric) Current UNIX time in milliseconds\n \"uploadtarget\":\n {\n \"timeframe\": n, (numeric) Length of the measuring timeframe in seconds\n \"target\": n, (numeric) Target in bytes\n \"target_reached\": true|false, (boolean) True if target is reached\n \"serve_historical_blocks\": true|false, (boolean) True if serving historical blocks\n \"bytes_left_in_cycle\": t, (numeric) Bytes left in current time cycle\n \"time_left_in_cycle\": t (numeric) Seconds left in current time cycle\n }\n}"
"returns":"{\n \"version\": xxxxx, (numeric) the server version\n \"subversion\": \"/Satoshi:x.x.x/\", (string) the server subversion string\n \"protocolversion\": xxxxx, (numeric) the protocol version\n \"localservices\": \"xxxxxxxxxxxxxxxx\", (string) the services we offer to the network\n \"localrelay\": true|false, (bool) true if transaction relay is requested from peers\n \"timeoffset\": xxxxx, (numeric) the time offset\n \"connections\": xxxxx, (numeric) the number of connections\n \"networkactive\": true|false, (bool) whether p2p networking is enabled\n \"networks\": [ (array) information per network\n {\n \"name\": \"xxx\", (string) network (ipv4, ipv6 or onion)\n \"limited\": true|false, (boolean) is the network limited using -onlynet?\n \"reachable\": true|false, (boolean) is the network reachable?\n \"proxy\": \"host:port\" (string) the proxy that is used for this network, or empty if none\n \"proxy_randomize_credentials\": true|false, (string) Whether randomized credentials are used\n }\n ,...\n ],\n \"relayfee\": x.xxxxxxxx, (numeric) minimum relay fee for transactions in LBC/kB\n \"incrementalfee\": x.xxxxxxxx, (numeric) minimum fee increment for mempool limiting or BIP 125 replacement in LBC/kB\n \"localaddresses\": [ (array) list of local addresses\n {\n \"address\": \"xxxx\", (string) network address\n \"port\": xxx, (numeric) network port\n \"score\": xxx (numeric) relative score\n }\n ,...\n ]\n \"warnings\": \"...\" (string) any network and blockchain warnings\n}"
"returns":"[\n {\n \"id\": n, (numeric) Peer index\n \"addr\":\"host:port\", (string) The IP address and port of the peer\n \"addrbind\":\"ip:port\", (string) Bind address of the connection to the peer\n \"addrlocal\":\"ip:port\", (string) Local address as reported by the peer\n \"services\":\"xxxxxxxxxxxxxxxx\", (string) The services offered\n \"relaytxes\":true|false, (boolean) Whether peer has asked us to relay transactions to it\n \"lastsend\": ttt, (numeric) The time in seconds since epoch (Jan 1 1970 GMT) of the last send\n \"lastrecv\": ttt, (numeric) The time in seconds since epoch (Jan 1 1970 GMT) of the last receive\n \"bytessent\": n, (numeric) The total bytes sent\n \"bytesrecv\": n, (numeric) The total bytes received\n \"conntime\": ttt, (numeric) The connection time in seconds since epoch (Jan 1 1970 GMT)\n \"timeoffset\": ttt, (numeric) The time offset in seconds\n \"pingtime\": n, (numeric) ping time (if available)\n \"minping\": n, (numeric) minimum observed ping time (if any at all)\n \"pingwait\": n, (numeric) ping wait (if non-zero)\n \"version\": v, (numeric) The peer version, such as 70001\n \"subver\": \"/Satoshi:0.8.5/\", (string) The string version\n \"inbound\": true|false, (boolean) Inbound (true) or Outbound (false)\n \"addnode\": true|false, (boolean) Whether connection was due to addnode/-connect or if it was an automatic/inbound connection\n \"startingheight\": n, (numeric) The starting height (block) of the peer\n \"banscore\": n, (numeric) The ban score\n \"synced_headers\": n, (numeric) The last header we have in common with this peer\n \"synced_blocks\": n, (numeric) The last block we have in common with this peer\n \"inflight\": [\n n, (numeric) The heights of blocks we're currently asking from this peer\n ...\n ],\n \"whitelisted\": true|false, (boolean) Whether the peer is whitelisted\n \"bytessent_per_msg\": {\n \"addr\": n, (numeric) The total bytes sent aggregated by message type\n ...\n },\n \"bytesrecv_per_msg\": {\n \"addr\": n, (numeric) The total bytes received aggregated by message type\n ...\n }\n }\n ,...\n]"
"description":"Requests that a ping be sent to all other nodes, to measure ping time. Results provided in getpeerinfo, pingtime and pingwait fields are decimal seconds. Ping command is handled in queue with all other commands, so it measures processing backlog, not just network ping.",
"description":"time in seconds how long (or until when if [absolute] is set) the IP is banned (0 or empty means using the default time of 24h which can also be overwritten by the -bantime startup argument)",
"returns":"\"psbt\" (string) The base64-encoded partially signed transaction"
},
{
"name":"combinerawtransaction",
"namespace":"Rawtransactions",
"description":"Combine multiple partially signed transactions into one transaction. The combined transaction may be another partially signed transaction or a fully signed transaction.",
"arguments":[
{
"name":"txs",
"type":"string",
"description":"A json array of hex strings of partially signed transactions [ \"hexstring\" (string) A transaction hash ,... ]",
"returns":"\"hex\" (string) The hex-encoded raw transaction with signature(s)"
},
{
"name":"converttopsbt",
"namespace":"Rawtransactions",
"description":"Converts a network serialized transaction to a PSBT. This should be used only with createrawtransaction and fundrawtransaction createpsbt and walletcreatefundedpsbt should be used for new applications.",
"arguments":[
{
"name":"hexstring",
"type":"string",
"description":"The hex string of a raw transaction",
"is_required":true
},
{
"name":"permitsigdata",
"type":"boolean",
"description":"If true, any signatures in the input will be discarded and conversion. will continue. If false, RPC will fail if any signatures are present.",
"is_required":false
},
{
"name":"iswitness",
"type":"boolean",
"description":"Whether the transaction hex is a serialized witness transaction. If iswitness is not present, heuristic tests will be used in decoding. If true, only witness deserializaion will be tried. If false, only non-witness deserialization wil be tried. Only has an effect if permitsigdata is true.",
"returns":"\"psbt\" (string) The resulting raw transaction (base64-encoded string)"
},
{
"name":"createpsbt",
"namespace":"Rawtransactions",
"description":"Creates a transaction in the Partially Signed Transaction format. Implements the Creator role.",
"arguments":[
{
"name":"inputs",
"type":"array",
"description":"A json array of json objects [ { \"txid\":\"id\", (string, required) The transaction id \"vout\":n, (numeric, required) The output number \"sequence\":n (numeric, optional) The sequence number } ,... ]",
"is_required":true
},
{
"name":"outputs",
"type":"array",
"description":"a json array with outputs (key-value pairs), where none of the keys are duplicated. That is, each address can only appear once and there can only be one 'data' object. [ { \"address\": x.xxx, (obj, optional) A key-value pair. The key (string) is the lbry address, the value (float or string) is the amount in LBC }, { \"data\": \"hex\" (obj, optional) A key-value pair. The key must be \"data\", the value is hex encoded data } ,... More key-value pairs of the above form. For compatibility reasons, a dictionary, which holds the key-value pairs directly, is also accepted as second parameter. ]",
"is_required":true
},
{
"name":"locktime",
"type":"number",
"description":"Raw locktime. Non-0 value also locktime-activates inputs",
"is_required":false
},
{
"name":"replaceable",
"type":"boolean",
"description":"Marks this transaction as BIP125 replaceable. Allows this transaction to be replaced by a transaction with higher fees. If provided, it is an error if explicit sequence numbers are incompatible.",
"description":"Create a transaction spending the given inputs and creating new outputs. Outputs can be addresses or data. Returns hex-encoded raw transaction. Note that the transaction's inputs are not signed, and it is not stored in the wallet or transmitted to the network.",
"description":"A json array of json objects [ { \"txid\":\"id\", (string, required) The transaction id \"vout\":n, (numeric, required) The output number \"sequence\":n (numeric, optional) The sequence number } ,... ]",
"description":"a json array with outputs (key-value pairs), where none of the keys are duplicated. That is, each address can only appear once and there can only be one 'data' object. [ { \"address\": x.xxx, (obj, optional) A key-value pair. The key (string) is the lbry address, the value (float or string) is the amount in LBC }, { \"data\": \"hex\" (obj, optional) A key-value pair. The key must be \"data\", the value is hex encoded data } ,... More key-value pairs of the above form. For compatibility reasons, a dictionary, which holds the key-value pairs directly, is also accepted as second parameter. ]",
"description":"Marks this transaction as BIP125 replaceable. Allows this transaction to be replaced by a transaction with higher fees. If provided, it is an error if explicit sequence numbers are incompatible.",
"returns":"{\n \"asm\":\"asm\", (string) Script public key\n \"hex\":\"hex\", (string) hex encoded public key\n \"type\":\"type\", (string) The output type\n \"reqSigs\": n, (numeric) The required signatures\n \"addresses\": [ (json array of string)\n \"address\" (string) lbry address\n ,...\n ],\n \"p2sh\",\"address\" (string) address of P2SH script wrapping this redeem script (not returned if the script is already a P2SH).\n}"
},
{
"name":"finalizepsbt",
"namespace":"Rawtransactions",
"description":"Finalize the inputs of a PSBT. If the transaction is fully signed, it will produce a network serialized transaction which can be broadcast with sendrawtransaction. Otherwise a PSBT will be created which has the final_scriptSig and final_scriptWitness fields filled for inputs that are complete. Implements the Finalizer and Extractor roles.",
"arguments":[
{
"name":"psbt",
"type":"string",
"description":"A base64 string of a PSBT",
"is_required":true
},
{
"name":"extract",
"type":"boolean",
"description":"If true and the transaction is complete, extract and return the complete transaction in normal network serialization instead of the PSBT.",
"is_required":false
}
],
"examples":[
{
"cli":"> lbrycrd-cli finalizepsbt \"psbt\""
}
],
"returns":"{\n \"psbt\" : \"value\", (string) The base64-encoded partially signed transaction if not extracted\n \"hex\" : \"value\", (string) The hex-encoded network transaction if extracted\n \"complete\" : true|false, (boolean) If the transaction has a complete set of signatures\n ]\n}"
"description":"Add inputs to a transaction until it has enough in value to meet its out value. This will not modify existing inputs, and will add at most one change output to the outputs. No existing outputs will be modified unless \"subtractFeeFromOutputs\" is specified. Note that inputs which were signed may need to be resigned after completion since in/outputs have been added. The inputs added will not be signed, use signrawtransaction for that. Note that all existing inputs must have their previous output transaction be in the wallet. Note that all inputs selected must be of standard form and P2SH scripts must be in the wallet using importaddress or addmultisigaddress (to calculate fees). You can see whether this is the case by checking the \"solvable\" field in the listunspent output. Only pay-to-pubkey, multisig, and P2SH versions thereof are currently supported for watch-only",
"description":"{ \"changeAddress\" (string, optional, default pool address) The bitcoin address to receive the change \"changePosition\" (numeric, optional, default random) The index of the change output \"change_type\" (string, optional) The output type to use. Only valid if changeAddress is not specified. Options are \"legacy\", \"p2sh-segwit\", and \"bech32\". Default is set by -changetype. \"includeWatching\" (boolean, optional, default false) Also select inputs which are watch only \"lockUnspents\" (boolean, optional, default false) Lock selected unspent outputs \"feeRate\" (numeric, optional, default not set: makes wallet determine the fee) Set a specific fee rate in LBC/kB \"subtractFeeFromOutputs\" (array, optional) A json array of integers. The fee will be equally deducted from the amount of each specified output. The outputs are specified by their zero-based index, before any change output is added. Those recipients will receive less bitcoins than you enter in their corresponding amount field. If no outputs are specified here, the sender pays the fee. [vout_index,...] \"replaceable\" (boolean, optional) Marks this transaction as BIP125 replaceable. Allows this transaction to be replaced by a transaction with higher fees \"conf_target\" (numeric, optional) Confirmation target (in blocks) \"estimate_mode\" (string, optional, default=UNSET) The fee estimate mode, must be one of: \"UNSET\" \"ECONOMICAL\" \"CONSERVATIVE\" } for backward compatibility: passing in a true instead of an object will result in {\"includeWatching\":true}",
"is_required":false
},
{
"name":"iswitness",
"type":"boolean",
"description":"Whether the transaction hex is a serialized witness transaction If iswitness is not present, heuristic tests will be used in decoding",
"returns":"{\n \"hex\": \"value\", (string) The resulting raw transaction (hex-encoded string)\n \"fee\": n, (numeric) Fee in LBC the resulting transaction pays\n \"changepos\": n (numeric) The position of the added change output, or -1\n}"
"description":"NOTE: By default this function only works for mempool transactions. If the -txindex option is enabled, it also works for blockchain transactions. If the block which contains the transaction is known, its hash can be provided even for nodes without -txindex. Note that if a blockhash is provided, only that block will be searched and if the transaction is in the mempool or other blocks, or if this node does not have the given block available, the transaction will not be found. DEPRECATED: for now, it also works for transactions with unspent outputs. Return the raw transaction data. If verbose is 'true', returns an Object with information about 'txid'. If verbose is 'false' or omitted, returns a string that is serialized, hex-encoded data for 'txid'.",
"returns":"\"data\" (string) The serialized, hex-encoded data for 'txid'\n\nResult (if verbose is set to true):\n{\n \"in_active_chain\": b, (bool) Whether specified block is in the active chain or not (only present with explicit \"blockhash\" argument)\n \"hex\" : \"data\", (string) The serialized, hex-encoded data for 'txid'\n \"txid\" : \"id\", (string) The transaction id (same as provided)\n \"hash\" : \"id\", (string) The transaction hash (differs from txid for witness transactions)\n \"size\" : n, (numeric) The serialized transaction size\n \"vsize\" : n, (numeric) The virtual transaction size (differs from size for witness transactions)\n \"weight\" : n, (numeric) The transaction's weight (between vsize*4-3 and vsize*4)\n \"version\" : n, (numeric) The version\n \"locktime\" : ttt, (numeric) The lock time\n \"vin\" : [ (array of json objects)\n {\n \"txid\": \"id\", (string) The transaction id\n \"vout\": n, (numeric) \n \"scriptSig\": { (json object) The script\n \"asm\": \"asm\", (string) asm\n \"hex\": \"hex\" (string) hex\n },\n \"sequence\": n (numeric) The script sequence number\n \"txinwitness\": [\"hex\", ...] (array of string) hex-encoded witness data (if any)\n }\n ,...\n ],\n \"vout\" : [ (array of json objects)\n {\n \"value\" : x.xxx, (numeric) The value in LBC\n \"n\" : n, (numeric) index\n \"scriptPubKey\" : { (json object)\n \"asm\" : \"asm\", (string) the asm\n \"hex\" : \"hex\", (string) the hex\n \"reqSigs\" : n, (numeric) The required sigs\n \"type\" : \"pubkeyhash\", (string) The type, eg 'pubkeyhash'\n \"addresses\" : [ (json array of string)\n \"address\" (string) lbry address\n ,...\n ]\n }\n }\n ,...\n ],\n \"blockhash\" : \"hash\", (string) the block hash\n \"confirmations\" : n, (numeric) The confirmations\n \"time\" : ttt, (numeric) The transaction time in seconds since epoch (Jan 1 1970 GMT)\n \"blocktime\" : ttt (numeric) The block time in seconds since epoch (Jan 1 1970 GMT)\n}"
"description":"Submits raw transaction (serialized, hex-encoded) to local node and network. Also see createrawtransaction and signrawtransaction calls.",
"arguments":[
{
"name":"hexstring",
"type":"string",
"description":"The hex string of the raw transaction)",
"description":"DEPRECATED. Sign inputs for raw transaction (serialized, hex-encoded). The second optional argument (may be null) is an array of previous transaction outputs that this transaction depends on but may not yet be in the block chain. The third optional argument (may be null) is an array of base58-encoded private keys that, if given, will be the only keys used to sign the transaction.",
"description":"An json array of previous dependent transaction outputs [ (json array of json objects, or 'null' if none provided) { \"txid\":\"id\", (string, required) The transaction id \"vout\":n, (numeric, required) The output number \"scriptPubKey\": \"hex\", (string, required) script key \"redeemScript\": \"hex\", (string, required for P2SH or P2WSH) redeem script \"amount\": value (numeric, required) The amount spent } ,... ]",
"description":"A json array of base58-encoded private keys for signing [ (json array of strings, or 'null' if none provided) \"privatekey\" (string) private key in base58-encoding ,... ]",
"is_required":false
},
{
"name":"sighashtype",
"type":"string",
"description":"The signature hash type. Must be one of \"ALL\" \"NONE\" \"SINGLE\" \"ALL|ANYONECANPAY\" \"NONE|ANYONECANPAY\" \"SINGLE|ANYONECANPAY\"",
"returns":"{\n \"hex\" : \"value\", (string) The hex-encoded raw transaction with signature(s)\n \"complete\" : true|false, (boolean) If the transaction has a complete set of signatures\n \"errors\" : [ (json array of objects) Script verification errors (if there are any)\n {\n \"txid\" : \"hash\", (string) The hash of the referenced, previous transaction\n \"vout\" : n, (numeric) The index of the output to spent and used as input\n \"scriptSig\" : \"hex\", (string) The hex-encoded signature script\n \"sequence\" : n, (numeric) Script sequence number\n \"error\" : \"text\" (string) Verification or signing error related to the input\n }\n ,...\n ]\n}"
"description":"Sign inputs for raw transaction (serialized, hex-encoded). The second argument is an array of base58-encoded private keys that will be the only keys used to sign the transaction. The third optional argument (may be null) is an array of previous transaction outputs that this transaction depends on but may not yet be in the block chain.",
"description":"An json array of previous dependent transaction outputs [ (json array of json objects, or 'null' if none provided) { \"txid\":\"id\", (string, required) The transaction id \"vout\":n, (numeric, required) The output number \"scriptPubKey\": \"hex\", (string, required) script key \"redeemScript\": \"hex\", (string, required for P2SH or P2WSH) redeem script \"amount\": value (numeric, required) The amount spent } ,... ]",
"is_required":false
},
{
"name":"sighashtype",
"type":"string",
"description":"The signature hash type. Must be one of \"ALL\" \"NONE\" \"SINGLE\" \"ALL|ANYONECANPAY\" \"NONE|ANYONECANPAY\" \"SINGLE|ANYONECANPAY\"",
"returns":"{\n \"hex\" : \"value\", (string) The hex-encoded raw transaction with signature(s)\n \"complete\" : true|false, (boolean) If the transaction has a complete set of signatures\n \"errors\" : [ (json array of objects) Script verification errors (if there are any)\n {\n \"txid\" : \"hash\", (string) The hash of the referenced, previous transaction\n \"vout\" : n, (numeric) The index of the output to spent and used as input\n \"scriptSig\" : \"hex\", (string) The hex-encoded signature script\n \"sequence\" : n, (numeric) Script sequence number\n \"error\" : \"text\" (string) Verification or signing error related to the input\n }\n ,...\n ]\n}"
"description":"Returns if raw transaction (serialized, hex-encoded) would be accepted by mempool. This checks if the transaction violates the consensus or policy rules. See sendrawtransaction call.",
"returns":"[ (array) The result of the mempool acceptance test for each raw transaction in the input array.\n Length is exactly one for now.\n {\n \"txid\" (string) The transaction hash in hex\n \"allowed\" (boolean) If the mempool allows this tx to be inserted\n \"reject-reason\" (string) Rejection string (only present when 'allowed' is false)\n }\n]"
"returns":"{\n \"address\":\"multisigaddress\", (string) The value of the new multisig address.\n \"redeemScript\":\"script\" (string) The string value of the hex-encoded redemption script.\n}"
"description":"Estimates the approximate fee per kilobyte needed for a transaction to begin confirmation within conf_target blocks if possible and return the number of blocks for which the estimate is valid. Uses virtual transaction size as defined in BIP 141 (witness data is discounted).",
"description":"The fee estimate mode. Whether to return a more conservative estimate which also satisfies a longer history. A conservative estimate potentially returns a higher feerate and is more likely to be sufficient for the desired target, but is not as responsive to short term drops in the prevailing fee market. Must be one of: \"UNSET\" (defaults to CONSERVATIVE) \"ECONOMICAL\" \"CONSERVATIVE\"",
"returns":"{\n \"feerate\" : x.x, (numeric, optional) estimate fee rate in LBC/kB\n \"errors\": [ str... ] (json array of strings, optional) Errors encountered during processing\n \"blocks\" : n (numeric) block number where estimate was found\n}\n\nThe request target will be clamped between 2 and the highest target\nfee estimation is able to return based on how long it has been running.\nAn error is returned if not enough transactions and blocks\nhave been observed to make an estimate for any number of blocks."
"description":"Return information about the given lbry address. DEPRECATION WARNING: Parts of this command have been deprecated and moved to getaddressinfo. Clients must transition to using getaddressinfo to access this information before upgrading to v0.18. The following deprecated fields have moved to getaddressinfo and will only be shown here with -deprecatedrpc=validateaddress: ismine, iswatchonly, script, hex, pubkeys, sigsrequired, pubkey, addresses, embedded, iscompressed, account, timestamp, hdkeypath, kdmasterkeyid.",
"returns":"{\n \"isvalid\" : true|false, (boolean) If the address is valid or not. If not, this is the only property returned.\n \"address\" : \"address\", (string) The lbry address validated\n \"scriptPubKey\" : \"hex\", (string) The hex encoded scriptPubKey generated by the address\n \"isscript\" : true|false, (boolean) If the key is a script\n \"iswitness\" : true|false, (boolean) If the address is a witness address\n \"witness_version\" : version (numeric, optional) The version number of the witness program\n \"witness_program\" : \"hex\" (string, optional) The hex value of the witness program\n}"
"description":"Mark in-wallet transaction <txid> as abandoned This will mark this transaction and all its in-wallet descendants as abandoned which will allow for their inputs to be respent. It can be used to replace \"stuck\" or evicted transactions. It only works on transactions which are not included in a block and are not currently in the mempool. It has no effect on transactions which are already abandoned.",
"description":"Add a nrequired-to-sign multisignature address to the wallet. Requires a new wallet backup. Each key is a Bitcoin address or hex-encoded public key. This functionality is only intended for use with non-watchonly addresses. See `importaddress` for watchonly p2sh address support. If 'label' is specified, assign address to that label.",
"returns":"{\n \"address\":\"multisigaddress\", (string) The value of the new multisig address.\n \"redeemScript\":\"script\" (string) The string value of the hex-encoded redemption script.\n}"
"description":"Bumps the fee of an opt-in-RBF transaction T, replacing it with a new transaction B. An opt-in RBF transaction with the given txid must be in the wallet. The command will pay the additional fee by decreasing (or perhaps removing) its change output. If the change output is not big enough to cover the increased fee, the command will currently fail instead of adding new inputs to compensate. (A future implementation could improve this.) The command will fail if the wallet or mempool contains a transaction that spends one of T's outputs. By default, the new fee will be calculated automatically using estimatesmartfee. The user can specify a confirmation target for estimatesmartfee. Alternatively, the user can specify totalFee, or use RPC settxfee to set a higher fee rate. At a minimum, the new fee rate must be high enough to pay an additional new relay fee (incrementalfee returned by getnetworkinfo) to enter the node's mempool.",
"arguments":[
{
"name":"txid",
"type":"string",
"description":"The txid to be bumped",
"is_required":true
},
{
"name":"options",
"type":"object",
"description":"{ \"confTarget\" (numeric, optional) Confirmation target (in blocks) \"totalFee\" (numeric, optional) Total fee (NOT feerate) to pay, in satoshis. In rare cases, the actual fee paid might be slightly higher than the specified totalFee if the tx change output has to be removed because it is too close to the dust threshold. \"replaceable\" (boolean, optional, default true) Whether the new transaction should still be marked bip-125 replaceable. If true, the sequence numbers in the transaction will be left unchanged from the original. If false, any input sequence numbers in the original transaction that were less than 0xfffffffe will be increased to 0xfffffffe so the new transaction will not be explicitly bip-125 replaceable (though it may still be replaceable in practice, for example if it has unconfirmed ancestors which are replaceable). \"estimate_mode\" (string, optional, default=UNSET) The fee estimate mode, must be one of: \"UNSET\" \"ECONOMICAL\" \"CONSERVATIVE\" }",
"is_required":false
}
],
"examples":[
{
"title":"Bump the fee, get the new transaction's txid",
"cli":"> lbrycrd-cli bumpfee <txid>"
}
],
"returns":"{\n \"txid\": \"value\", (string) The id of the new transaction\n \"origfee\": n, (numeric) Fee of the replaced transaction\n \"fee\": n, (numeric) Fee of the new transaction\n \"errors\": [ str... ] (json array of strings) Errors encountered during processing (may be empty)\n}"
},
{
"name":"createwallet",
"namespace":"Wallet",
"description":"Creates and loads a new wallet.",
"arguments":[
{
"name":"wallet_name",
"type":"string",
"description":"The name for the new wallet. If this is a path, the wallet will be created at the path location.",
"is_required":true
},
{
"name":"disable_private_keys",
"type":"boolean",
"description":"Disable the possibility of private keys (only watchonlys are possible in this mode).",
"returns":"{\n \"name\" : <wallet_name>, (string) The wallet name if created successfully. If the wallet was created using a full path, the wallet_name will be the full path.\n \"warning\" : <warning>, (string) Warning message if wallet was not loaded cleanly.\n}"
"description":"Dumps all wallet keys in a human-readable format to a server-side file. This does not allow overwriting existing files. Imported scripts are included in the dumpfile, but corresponding BIP173 addresses, etc. may not be added automatically by importwallet. Note that if your wallet contains keys which are not derived from your HD seed (e.g. imported keys), these are not covered by only backing up the seed itself, and must be backed up too (e.g. ensure you back up the whole dumpfile).",
"description":"Encrypts the wallet with 'passphrase'. This is for first time encryption. After this, any calls that interact with private keys such as sending or signing will require the passphrase to be set prior the making these calls. Use the walletpassphrase call for this, and then walletlock call. If the wallet is already encrypted, use the walletpassphrasechange call.",
"description":"The account for the address. It can also be set to the empty string \"\" to represent the default account. The account does not need to exist, it will be created and a new address created if there is no account by the given name.",
"returns":"{ (json object with addresses as keys)\n \"address\": { (json object with information about address)\n \"purpose\": \"string\" (string) Purpose of address (\"send\" for sending address, \"receive\" for receiving address)\n },...\n}"
},
{
"name":"getaddressinfo",
"namespace":"Wallet",
"description":"Return information about the given bitcoin address. Some information requires the address to be in the wallet.",
"arguments":[
{
"name":"address",
"type":"string",
"description":"The bitcoin address to get the information of.",
"returns":"{\n \"address\" : \"address\", (string) The bitcoin address validated\n \"scriptPubKey\" : \"hex\", (string) The hex encoded scriptPubKey generated by the address\n \"ismine\" : true|false, (boolean) If the address is yours or not\n \"iswatchonly\" : true|false, (boolean) If the address is watchonly\n \"isscript\" : true|false, (boolean) If the key is a script\n \"iswitness\" : true|false, (boolean) If the address is a witness address\n \"witness_version\" : version (numeric, optional) The version number of the witness program\n \"witness_program\" : \"hex\" (string, optional) The hex value of the witness program\n \"script\" : \"type\" (string, optional) The output script type. Only if \"isscript\" is true and the redeemscript is known. Possible types: nonstandard, pubkey, pubkeyhash, scripthash, multisig, nulldata, witness_v0_keyhash, witness_v0_scripthash, witness_unknown\n \"hex\" : \"hex\", (string, optional) The redeemscript for the p2sh address\n \"pubkeys\" (string, optional) Array of pubkeys associated with the known redeemscript (only if \"script\" is \"multisig\")\n [\n \"pubkey\"\n ,...\n ]\n \"sigsrequired\" : xxxxx (numeric, optional) Number of signatures required to spend multisig output (only if \"script\" is \"multisig\")\n \"pubkey\" : \"publickeyhex\", (string, optional) The hex value of the raw public key, for single-key addresses (possibly embedded in P2SH or P2WSH)\n \"embedded\" : {...}, (object, optional) Information about the address embedded in P2SH or P2WSH, if relevant and known. It includes all getaddressinfo output fields for the embedded address, excluding metadata (\"timestamp\", \"hdkeypath\", \"hdseedid\") and relation to the wallet (\"ismine\", \"iswatchonly\", \"account\").\n \"iscompressed\" : true|false, (boolean) If the address is compressed\n \"label\" : \"label\" (string) The label associated with the address, \"\" is the default account\n \"account\" : \"account\" (string) DEPRECATED. This field will be removed in V0.18. To see this deprecated field, start bitcoind with -deprecatedrpc=accounts. The account associated with the address, \"\" is the default account\n \"timestamp\" : timestamp, (number, optional) The creation time of the key if available in seconds since epoch (Jan 1 1970 GMT)\n \"hdkeypath\" : \"keypath\" (string, optional) The HD keypath if the key is HD and available\n \"hdseedid\" : \"<hash160>\" (string, optional) The Hash160 of the HD seed\n \"hdmasterkeyid\" : \"<hash160>\" (string, optional) alias for hdseedid maintained for backwards compatibility. Will be removed in V0.18.\n \"labels\" (object) Array of labels associated with the address.\n [\n { (json object of label data)\n \"name\": \"labelname\" (string) The label\n \"purpose\": \"string\" (string) Purpose of address (\"send\" for sending address, \"receive\" for receiving address)\n },...\n ]\n}"
"description":"If account is not specified, returns the server's total available balance. The available balance is what the wallet considers currently spendable, and is thus affected by options which limit spendability such as -spendzeroconfchange. If account is specified (DEPRECATED), returns the balance in the account. Note that the account \"\" is not the same as leaving the parameter out. The server total may be different to the balance in the default \"\" account.",
"name":"To use this deprecated argument, start bitcoind with -deprecatedrpc=accounts. The account string may be given as a\n specific account name to find the balance associated with wallet keys in\n a named account, or as the empty string",
"type":"\"\"",
"description":"to find the balance associated with wallet keys not in any named account, or as \"*\" to find the balance associated with all wallet keys regardless of account. When this option is specified, it calculates the balance in a different way than when it is not specified, and which can count spends twice when there are conflicting pending transactions (such as those created by the bumpfee command), temporarily resulting in low or even negative balances. In general, account balance calculation is not considered reliable and has resulted in confusing outcomes, so it is recommended to avoid passing this argument.",
"description":"Only include transactions confirmed at least this many times. The default is 1 if an account is provided or 0 if no account is provided",
"description":"Returns a new Bitcoin address for receiving payments. If 'label' is specified, it is added to the address book so payments received with the address will be associated with 'label'.",
"description":"The label name for the address to be linked to. If not provided, the default label \"\" is used. It can also be set to the empty string \"\" to represent the default label. The label does not need to exist, it will be created if there is no label by the given name.",
"returns":"{\n \"amount\" : x.xxx, (numeric) The transaction amount in LBC\n \"fee\": x.xxx, (numeric) The amount of the fee in LBC. This is negative and only available for the \n 'send' category of transactions.\n \"confirmations\" : n, (numeric) The number of confirmations\n \"blockhash\" : \"hash\", (string) The block hash\n \"blockindex\" : xx, (numeric) The index of the transaction in the block that includes it\n \"blocktime\" : ttt, (numeric) The time in seconds since epoch (1 Jan 1970 GMT)\n \"txid\" : \"transactionid\", (string) The transaction id.\n \"time\" : ttt, (numeric) The transaction time in seconds since epoch (1 Jan 1970 GMT)\n \"timereceived\" : ttt, (numeric) The time received in seconds since epoch (1 Jan 1970 GMT)\n \"bip125-replaceable\": \"yes|no|unknown\", (string) Whether this transaction could be replaced due to BIP125 (replace-by-fee);\n may be unknown for unconfirmed transactions not in the mempool\n \"details\" : [\n {\n \"account\" : \"accountname\", (string) DEPRECATED. This field will be removed in a V0.18. To see this deprecated field, start bitcoind with -deprecatedrpc=accounts. The account name involved in the transaction, can be \"\" for the default account.\n \"address\" : \"address\", (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 LBC\n \"label\" : \"label\", (string) A comment for the address/transaction, if any\n \"vout\" : n, (numeric) the vout value\n \"fee\": x.xxx, (numeric) The amount of the fee in LBC. This is negative and only available for the \n 'send' category of transactions.\n \"abandoned\": xxx (bool) 'true' if the transaction has been abandoned (inputs are respendable). Only available for the \n 'send' category of transactions.\n }\n ,...\n ],\n \"hex\" : \"data\" (string) Raw data for transaction\n}"
"returns":"{\n \"walletname\": xxxxx, (string) the wallet name\n \"walletversion\": xxxxx, (numeric) the wallet version\n \"balance\": xxxxxxx, (numeric) the total confirmed balance of the wallet in LBC\n \"unconfirmed_balance\": xxx, (numeric) the total unconfirmed balance of the wallet in LBC\n \"immature_balance\": xxxxxx, (numeric) the total immature balance of the wallet in LBC\n \"txcount\": xxxxxxx, (numeric) the total number of transactions in the wallet\n \"keypoololdest\": xxxxxx, (numeric) the timestamp (seconds since Unix epoch) of the oldest pre-generated key in the key pool\n \"keypoolsize\": xxxx, (numeric) how many new keys are pre-generated (only counts external keys)\n \"keypoolsize_hd_internal\": xxxx, (numeric) how many new keys are pre-generated for internal use (used for change outputs, only appears if the wallet is using this feature, otherwise external keys are used)\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 LBC/kB\n \"hdseedid\": \"<hash160>\" (string, optional) the Hash160 of the HD seed (only present when HD is enabled)\n \"hdmasterkeyid\": \"<hash160>\" (string, optional) alias for hdseedid retained for backwards-compatibility. Will be removed in V0.18.\n \"private_keys_enabled\": true|false (boolean) false if privatekeys are disabled for this wallet (enforced watch-only wallet)\n}"
"description":"Adds an address or script (in hex) that can be watched as if it were in your wallet but cannot be used to spend. Requires a new wallet backup.",
"description":"Add the P2SH version of the script as well Note: This call can take over an hour to complete if rescan is true, during that time, other rpc calls may report that the imported address exists but related transactions are still missing, leading to temporarily incorrect/bogus balances and unspent outputs until rescan completes. If you have the full public key, you should call importpubkey instead of this. Note: If you import a non-standard raw script in hex form, outputs sending to it will be treated as change, and not show up in many RPCs.",
"description":"Import addresses/scripts (with private or public keys, redeem script (P2SH)), rescanning all addresses in one-shot-only (rescan can be disabled via options). Requires a new wallet backup.",
"arguments":[
{
"name":"requests",
"type":"array",
"description":"Data to be imported [ (array of json objects) { \"scriptPubKey\": \"<script>\" | { \"address\":\"<address>\" }, (string / json, required) Type of scriptPubKey (string for script, json for address) \"timestamp\": timestamp | \"now\" , (integer / string, required) Creation time of the key in seconds since epoch (Jan 1 1970 GMT), or the string \"now\" to substitute the current synced blockchain time. The timestamp of the oldest key will determine how far back blockchain rescans need to begin for missing wallet transactions. \"now\" can be specified to bypass scanning, for keys which are known to never have been used, and 0 can be specified to scan the entire blockchain. Blocks up to 2 hours before the earliest key creation time of all keys being imported by the importmulti call will be scanned. \"redeemscript\": \"<script>\" , (string, optional) Allowed only if the scriptPubKey is a P2SH address or a P2SH scriptPubKey \"pubkeys\": [\"<pubKey>\", ... ] , (array, optional) Array of strings giving pubkeys that must occur in the output or redeemscript \"keys\": [\"<key>\", ... ] , (array, optional) Array of strings giving private keys whose corresponding public keys must occur in the output or redeemscript \"internal\": <true> , (boolean, optional, default: false) Stating whether matching outputs should be treated as not incoming payments aka change \"watchonly\": <true> , (boolean, optional, default: false) Stating whether matching outputs should be considered watched even when they're not spendable, only allowed if keys are empty \"label\": <label> , (string, optional, default: '') Label to assign to the address (aka account name, for now), only allowed with internal=false } ,... ]",
"is_required":true
},
{
"name":"options",
"type":"json",
"description":"{ \"rescan\": <false>, (boolean, optional, default: true) Stating if should rescan the blockchain after all imports } Note: This call can take over an hour to complete if rescan is true, during that time, other rpc calls may report that the imported keys, addresses or scripts exists but related transactions are still missing.",
"description":"Adds a private key (as returned by dumpprivkey) to your wallet. Requires a new wallet backup. Hint: use importmulti to import more than one private key.",
"description":"Rescan the wallet for transactions Note: This call can take over an hour to complete if rescan is true, during that time, other rpc calls may report that the imported key exists but related transactions are still missing, leading to temporarily incorrect/bogus balances and unspent outputs until rescan completes.",
"description":"Imports funds without rescan. Corresponding address or script must previously be included in wallet. Aimed towards pruned wallets. The end-user is responsible to import additional transactions that subsequently spend the imported outputs or rescan after the point in the blockchain the transaction is included.",
"arguments":[
{
"name":"rawtransaction",
"type":"string",
"description":"A raw transaction in hex funding an already-existing address in wallet",
"is_required":true
},
{
"name":"txoutproof",
"type":"string",
"description":"The hex output from gettxoutproof that contains the transaction",
"description":"Adds a public key (in hex) that can be watched as if it were in your wallet but cannot be used to spend. Requires a new wallet backup.",
"description":"Rescan the wallet for transactions Note: This call can take over an hour to complete if rescan is true, during that time, other rpc calls may report that the imported pubkey exists but related transactions are still missing, leading to temporarily incorrect/bogus balances and unspent outputs until rescan completes.",
"returns":"{ (json object where keys are account names, and values are numeric balances\n \"account\": x.xxx, (numeric) The property name is the account name, and the value is the total balance for the account.\n ...\n}"
},
{
"name":"listaddressgroupings",
"namespace":"Wallet",
"description":"Lists groups of addresses which have had their common ownership made public by common use as inputs or as the resulting change in past transactions",
"returns":"[\n {\n \"involvesWatchonly\" : true, (bool) Only returned if imported addresses were involved in transaction\n \"address\" : \"receivingaddress\", (string) The receiving address\n \"account\" : \"accountname\", (string) DEPRECATED. Backwards compatible alias for label.\n \"amount\" : x.xxx, (numeric) The total amount in LBC received by the address\n \"confirmations\" : n, (numeric) The number of confirmations of the most recent transaction included\n \"label\" : \"label\", (string) The label of the receiving address. The default label is \"\".\n \"txids\": [\n \"txid\", (string) The ids of transactions received with the address \n ...\n ]\n }\n ,...\n]"
"returns":"[\n {\n \"involvesWatchonly\" : true, (bool) Only returned if imported addresses were involved in transaction\n \"account\" : \"accountname\", (string) DEPRECATED. Backwards compatible alias for label.\n \"amount\" : x.xxx, (numeric) The total amount received by addresses with this label\n \"confirmations\" : n, (numeric) The number of confirmations of the most recent transaction included\n \"label\" : \"label\" (string) The label of the receiving address. The default label is \"\".\n }\n ,...\n]"
"description":"Get all transactions in blocks since block [blockhash], or all transactions if omitted. If \"blockhash\" is no longer a part of the main chain, transactions from the fork point onward are included. Additionally, if include_removed is set, transactions affecting the wallet which were removed are returned in the \"removed\" array.",
"description":"Return the nth block hash from the main chain. e.g. 1 would mean the best block hash. Note: this is not used as a filter, but only affects [lastblock] in the return value",
"is_required":false
},
{
"name":"include_watchonly:",
"type":"boolean",
"description":"Include transactions to watch-only addresses (see 'importaddress')",
"returns":"{\n \"transactions\": [\n \"account\":\"accountname\", (string) DEPRECATED. This field will be removed in V0.18. To see this deprecated field, start bitcoind with -deprecatedrpc=accounts. The account name associated with the transaction. Will be \"\" for the default account.\n \"address\":\"address\", (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 LBC. 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 LBC. 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 When it's < 0, it means the transaction conflicted that many blocks ago.\n \"blockhash\": \"hashvalue\", (string) The block hash containing the transaction. Available for 'send' and 'receive' category of transactions.\n \"blockindex\": n, (numeric) The index of the transaction in the block that includes it. Available for 'send' and 'receive' category of transactions.\n \"blocktime\": xxx, (numeric) The block time in seconds since epoch (1 Jan 1970 GMT).\n \"txid\": \"transactionid\", (string) The transaction id. Available for 'send' and 'receive' category of transactions.\n \"time\": xxx, (numeric) The transaction time in seconds since epoch (Jan 1 1970 GMT).\n \"timereceived\": xxx, (numeric) The time received in seconds since epoch (Jan 1 1970 GMT). Available for 'send' and 'receive' category of transactions.\n \"bip125-replaceable\": \"yes|no|unknown\", (string) Whether this transaction could be replaced due to BIP125 (replace-by-fee);\n may be unknown for unconfirmed transactions not in the mempool\n \"abandoned\": xxx, (bool) 'true' if the transaction has been abandoned (inputs are respendable). Only available for the 'send' category of transactions.\n \"comment\": \"...\", (string) If a comment is associated with the transaction.\n \"label\" : \"label\" (string) A comment for the address/transaction, if any\n \"to\": \"...\", (string) If a comment to is associated with the transaction.\n ],\n \"removed\": [\n <structure is the same as \"transactions\" above, only present if include_removed=true>\n Note: transactions that were re-added in the active chain will appear as-is in this array, and may thus have a positive confirmation count.\n ],\n \"lastblock\": \"lastblockhash\" (string) The hash of the block (target_confirmations-1) from the best block on the main chain. This is typically used to feed back into listsinceblock the next time you call it. So you would generally use a target_confirmations of say 6, so you will be continually re-notified of transactions until they've reached 6 confirmations plus any new ones\n}"
"returns":"[\n {\n \"account\":\"accountname\", (string) DEPRECATED. This field will be removed in V0.18. The account name associated with the transaction. \n It will be \"\" for the default account.\n \"address\":\"address\", (string) The bitcoin address of the transaction. Not present for \n move transactions (category = move).\n \"category\":\"send|receive|move\", (string) The transaction category. 'move' is a local (off blockchain)\n 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 LBC. 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 \"label\": \"label\", (string) A comment for the address/transaction, if any\n \"vout\": n, (numeric) the vout value\n \"fee\": x.xxx, (numeric) The amount of the fee in LBC. 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. Negative confirmations indicate the\n transaction conflicts with the block chain\n \"trusted\": xxx, (bool) Whether we consider the outputs of this unconfirmed transaction safe to spend.\n \"blockhash\": \"hashvalue\", (string) The block hash containing the transaction. Available for 'send' and 'receive'\n category of transactions.\n \"blockindex\": n, (numeric) The index of the transaction in the block that includes it. Available for 'send' and 'receive'\n category of transactions.\n \"blocktime\": xxx, (numeric) The block time in seconds since epoch (1 Jan 1970 GMT).\n \"txid\": \"transactionid\", (string) The transaction id. Available for 'send' and 'receive' category of transactions.\n \"time\": xxx, (numeric) The transaction time in seconds since epoch (midnight Jan 1 1970 GMT).\n \"timereceived\": xxx, (numeric) The time received in seconds since epoch (midnight Jan 1 1970 GMT). Available \n for 'send' and 'receive' category of transactions.\n \"comment\": \"...\", (string) If a comment is associated with the transaction.\n \"otheraccount\": \"accountname\", (string) DEPRECATED. This field will be removed in V0.18. For the 'move' category of transactions, the account the funds came \n from (for receiving funds, positive amounts), or went to (for sending funds,\n negative amounts).\n \"bip125-replaceable\": \"yes|no|unknown\", (string) Whether this transaction could be replaced due to BIP125 (replace-by-fee);\n may be unknown for unconfirmed transactions not in the mempool\n \"abandoned\": xxx (bool) 'true' if the transaction has been abandoned (inputs are respendable). Only available for the \n 'send' category of transactions.\n }\n]"
"description":"Returns array of unspent transaction outputs with between minconf and maxconf (inclusive) confirmations. Optionally filter to only include txouts paid to specified addresses.",
"description":"The minimum confirmations to filter",
"is_required":false
},
{
"name":"maxconf",
"type":"number",
"description":"The maximum confirmations to filter",
"is_required":false
},
{
"name":"addresses",
"type":"string",
"description":"A json array of bitcoin addresses to filter [ \"address\" (string) bitcoin address ,... ]",
"is_required":true
},
{
"name":"include_unsafe",
"type":"boolean",
"description":"Include outputs that are not safe to spend See description of \"safe\" attribute below.",
"is_required":false
},
{
"name":"query_options",
"type":"json",
"description":"JSON with query options { \"minimumAmount\" (numeric or string, default=0) Minimum value of each UTXO in LBC \"maximumAmount\" (numeric or string, default=unlimited) Maximum value of each UTXO in LBC \"maximumCount\" (numeric or string, default=unlimited) Maximum number of UTXOs \"minimumSumAmount\" (numeric or string, default=unlimited) Minimum sum value of all UTXOs in LBC } Result [ (array of json object) { \"txid\" : \"txid\", (string) the transaction id \"vout\" : n, (numeric) the vout value \"address\" : \"address\", (string) the bitcoin address \"label\" : \"label\", (string) The associated label, or \"\" for the default label \"account\" : \"account\", (string) DEPRECATED. This field will be removed in V0.",
"is_required":false
},
{
"name":"To see this deprecated field, start bitcoind with -deprecatedrpc=accounts. The associated account, or \"\" for the default account\n \"scriptPubKey\" : \"key\",",
"type":"string",
"description":"the script key \"amount\" : x.xxx, (numeric) the transaction output amount in LBC \"confirmations\" : n, (numeric) The number of confirmations \"redeemScript\" : n (string) The redeemScript if scriptPubKey is P2SH \"spendable\" : xxx, (bool) Whether we have the private keys to spend this output \"solvable\" : xxx, (bool) Whether we know how to spend this output, ignoring the lack of keys \"safe\" : xxx (bool) Whether this output is considered safe to spend. Unconfirmed transactions from outside keys and unconfirmed replacement transactions are considered unsafe and are not eligible for spending by fundrawtransaction and sendtoaddress. } ,... ]",
"returns":"[ (json array of strings)\n \"walletname\" (string) the wallet name\n ...\n]"
},
{
"name":"loadwallet",
"namespace":"Wallet",
"description":"Loads a wallet from a wallet file or directory. Note that all wallet command-line options used when starting bitcoind will be applied to the new wallet (eg -zapwallettxes, upgradewallet, rescan, etc).",
"arguments":[
{
"name":"filename",
"type":"string",
"description":"The wallet directory or .dat file.",
"returns":"{\n \"name\" : <wallet_name>, (string) The wallet name if loaded successfully.\n \"warning\" : <warning>, (string) Warning message if wallet was not loaded cleanly.\n}"
},
{
"name":"lockunspent",
"namespace":"Wallet",
"description":"Updates list of temporarily unspendable outputs. Temporarily lock (unlock=false) or unlock (unlock=true) specified transaction outputs. If no transaction outputs are specified when unlocking then all current locked transaction outputs are unlocked. A locked transaction output will not be chosen by automatic coin selection, when spending bitcoins. Locks are stored in memory only. Nodes start with zero locked outputs, and the locked output list is always cleared (by virtue of process exit) when a node stops or fails. Also see the listunspent call",
"description":"Whether to unlock (true) or lock (false) the specified transactions",
"is_required":true
},
{
"name":"transactions",
"type":"string",
"description":"A json array of objects. Each object the txid (string) vout (numeric) [ (json array of json objects) { \"txid\":\"id\", (string) The transaction id \"vout\": n (numeric) The output number } ,... ]",
"description":"Deletes the specified transaction from the wallet. Meant for use with pruned wallets and as a companion to importprunedfunds. This will affect wallet balances.",
"returns":"{\n \"start_height\" (numeric) The block height where the rescan has started. If omitted, rescan started from the genesis block.\n \"stop_height\" (numeric) The height of the last rescanned block. If omitted, rescan stopped at the chain tip.\n}"
"description":"The name of the account to send funds from. May be the default account using \"\". Specifying an account does not influence coin selection, but it does associate the newly created transaction with the account, so the account's balance computation and transaction history can reflect the spend.",
"description":"An optional comment to store the name of the person or organization to which you're sending the transaction. This is not part of the transaction, it is just kept in your wallet.",
"is_required":false
}
],
"examples":[
{
"title":"Send 0.01 LBC from the default account to the address, must have at least 1 confirmation",
"description":"A json object with addresses and amounts { \"address\":amount (numeric or string) The bitcoin address is the key, the numeric amount (can be string) in LBC is the value ,... }",
"description":"A json array with addresses. The fee will be equally deducted from the amount of each selected address. Those recipients will receive less bitcoins than you enter in their corresponding amount field. If no addresses are specified here, the sender pays the fee. [ \"address\" (string) Subtract fee from this address ,... ]",
"is_required":false
},
{
"name":"replaceable",
"type":"boolean",
"description":"Allow this transaction to be replaced by a transaction with higher fees via BIP 125",
"description":"A comment to store the name of the person or organization to which you're sending the transaction. This is not part of the transaction, just kept in your wallet.",
"description":"Set or generate a new HD wallet seed. Non-HD wallets will not be upgraded to being a HD wallet. Wallets that are already HD will have a new HD seed set so that new keys added to the keypool will be derived from this new seed. Note that you will need to MAKE A NEW BACKUP of your wallet after setting the HD wallet seed.",
"arguments":[
{
"name":"newkeypool",
"type":"boolean",
"description":"Whether to flush old unused addresses, including change addresses, from the keypool and regenerate it. If true, the next address from getnewaddress and change address from getrawchangeaddress will be from this new seed. If false, addresses (including change addresses if the wallet already had HD Chain Split enabled) from the existing keypool will be used until it has been depleted.",
"is_required":false
},
{
"name":"seed",
"type":"string",
"description":"The WIF private key to use as the new HD seed; if not provided a random seed will be used. The seed value can be retrieved using the dumpwallet command. It is the private key marked hdseed=1",
"description":"Sign inputs for raw transaction (serialized, hex-encoded). The second optional argument (may be null) is an array of previous transaction outputs that this transaction depends on but may not yet be in the block chain.",
"arguments":[
{
"name":"hexstring",
"type":"string",
"description":"The transaction hex string",
"is_required":true
},
{
"name":"prevtxs",
"type":"string",
"description":"An json array of previous dependent transaction outputs [ (json array of json objects, or 'null' if none provided) { \"txid\":\"id\", (string, required) The transaction id \"vout\":n, (numeric, required) The output number \"scriptPubKey\": \"hex\", (string, required) script key \"redeemScript\": \"hex\", (string, required for P2SH or P2WSH) redeem script \"amount\": value (numeric, required) The amount spent } ,... ]",
"is_required":false
},
{
"name":"sighashtype",
"type":"string",
"description":"The signature hash type. Must be one of \"ALL\" \"NONE\" \"SINGLE\" \"ALL|ANYONECANPAY\" \"NONE|ANYONECANPAY\" \"SINGLE|ANYONECANPAY\"",
"returns":"{\n \"hex\" : \"value\", (string) The hex-encoded raw transaction with signature(s)\n \"complete\" : true|false, (boolean) If the transaction has a complete set of signatures\n \"errors\" : [ (json array of objects) Script verification errors (if there are any)\n {\n \"txid\" : \"hash\", (string) The hash of the referenced, previous transaction\n \"vout\" : n, (numeric) The index of the output to spent and used as input\n \"scriptSig\" : \"hex\", (string) The hex-encoded signature script\n \"sequence\" : n, (numeric) Script sequence number\n \"error\" : \"text\" (string) Verification or signing error related to the input\n }\n ,...\n ]\n}"
},
{
"name":"unloadwallet",
"namespace":"Wallet",
"description":"Unloads the wallet referenced by the request endpoint otherwise unloads the wallet specified in the argument. Specifying the wallet name on a wallet endpoint is invalid.",
"arguments":[
{
"name":"wallet_name",
"type":"string",
"description":"The name of the wallet to unload.",
"description":"Creates and funds a transaction in the Partially Signed Transaction format. Inputs will be added if supplied inputs are not enough Implements the Creator and Updater roles.",
"arguments":[
{
"name":"inputs",
"type":"array",
"description":"A json array of json objects [ { \"txid\":\"id\", (string, required) The transaction id \"vout\":n, (numeric, required) The output number \"sequence\":n (numeric, optional) The sequence number } ,... ]",
"is_required":true
},
{
"name":"outputs",
"type":"array",
"description":"a json array with outputs (key-value pairs), where none of the keys are duplicated. That is, each address can only appear once and there can only be one 'data' object. [ { \"address\": x.xxx, (obj, optional) A key-value pair. The key (string) is the bitcoin address, the value (float or string) is the amount in LBC }, { \"data\": \"hex\" (obj, optional) A key-value pair. The key must be \"data\", the value is hex encoded data } ,... More key-value pairs of the above form. For compatibility reasons, a dictionary, which holds the key-value pairs directly, is also accepted as second parameter. ]",
"is_required":true
},
{
"name":"locktime",
"type":"number",
"description":"Raw locktime. Non-0 value also locktime-activates inputs",
"is_required":false
},
{
"name":"options",
"type":"object",
"description":"{ \"changeAddress\" (string, optional, default pool address) The bitcoin address to receive the change \"changePosition\" (numeric, optional, default random) The index of the change output \"change_type\" (string, optional) The output type to use. Only valid if changeAddress is not specified. Options are \"legacy\", \"p2sh-segwit\", and \"bech32\". Default is set by -changetype. \"includeWatching\" (boolean, optional, default false) Also select inputs which are watch only \"lockUnspents\" (boolean, optional, default false) Lock selected unspent outputs \"feeRate\" (numeric, optional, default not set: makes wallet determine the fee) Set a specific fee rate in LBC/kB \"subtractFeeFromOutputs\" (array, optional) A json array of integers. The fee will be equally deducted from the amount of each specified output. The outputs are specified by their zero-based index, before any change output is added. Those recipients will receive less bitcoins than you enter in their corresponding amount field. If no outputs are specified here, the sender pays the fee. [vout_index,...] \"replaceable\" (boolean, optional) Marks this transaction as BIP125 replaceable. Allows this transaction to be replaced by a transaction with higher fees \"conf_target\" (numeric, optional) Confirmation target (in blocks) \"estimate_mode\" (string, optional, default=UNSET) The fee estimate mode, must be one of: \"UNSET\" \"ECONOMICAL\" \"CONSERVATIVE\" }",
"is_required":false
},
{
"name":"bip32derivs",
"type":"boolean",
"description":"If true, includes the BIP 32 derivation paths for public keys if we know them",
"returns":"{\n \"psbt\": \"value\", (string) The resulting raw transaction (base64-encoded string)\n \"fee\": n, (numeric) Fee in LBC the resulting transaction pays\n \"changepos\": n (numeric) The position of the added change output, or -1\n}"
},
{
"name":"walletlock",
"namespace":"Wallet",
"description":"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.",
"arguments":[],
"examples":[
{
"title":"Set the passphrase for 2 minutes to perform a transaction",
"description":"Stores the wallet decryption key in memory for 'timeout' seconds. This is needed prior to performing transactions related to private keys such as sending bitcoins",
"arguments":[
{
"name":"passphrase",
"type":"string",
"description":"The wallet passphrase",
"is_required":true
},
{
"name":"timeout",
"type":"number",
"description":"The time to keep the decryption key in seconds; capped at 100000000 (~3 years). Note: Issuing the walletpassphrase command while the wallet is already unlocked will set a new unlock time that overrides the old one.",
"description":"Update a PSBT with input information from our wallet and then sign inputs that we can sign for.",
"arguments":[
{
"name":"psbt",
"type":"string",
"description":"The transaction base64 string",
"is_required":true
},
{
"name":"sign",
"type":"boolean",
"description":"Also sign the transaction when updating",
"is_required":false
},
{
"name":"sighashtype",
"type":"string",
"description":"The signature hash type to sign with if not specified by the PSBT. Must be one of \"ALL\" \"NONE\" \"SINGLE\" \"ALL|ANYONECANPAY\" \"NONE|ANYONECANPAY\" \"SINGLE|ANYONECANPAY\"",
"is_required":false
},
{
"name":"bip32derivs",
"type":"boolean",
"description":"If true, includes the BIP 32 derivation paths for public keys if we know them",
"is_required":false
}
],
"examples":[
{
"cli":"> lbrycrd-cli walletprocesspsbt \"psbt\""
}
],
"returns":"{\n \"psbt\" : \"value\", (string) The base64-encoded partially signed transaction\n \"complete\" : true|false, (boolean) If the transaction has a complete set of signatures\n ]\n}"
},
{
"name":"getzmqnotifications",
"namespace":"Zmq",
"description":"Returns information about the active ZeroMQ notifications.",
"returns":"[\n { (json object)\n \"type\": \"pubhashtx\", (string) Type of notification\n \"address\": \"...\" (string) Address of the publisher\n },\n ...\n]"