Skip to content

Commit 48b9e6e

Browse files
committed
Updated verus cli commands
1 parent effb3eb commit 48b9e6e

File tree

2 files changed

+208
-38
lines changed

2 files changed

+208
-38
lines changed

faq-cli/clifaq-02_verus_commands.md

+207-37
Original file line numberDiff line numberDiff line change
@@ -853,6 +853,32 @@ Examples:
853853

854854
### `notaries height timestamp`
855855

856+
### `processupgradedata {upgradedata}`
857+
Returns the txid and index where an output is spent.
858+
859+
#### Arguments:
860+
```json
861+
{
862+
"upgradeid" (string) The VDXF key identifier
863+
"minimumdaemonversion" (string) The minimum version required for the upgrade
864+
"activationheight" (number) The block height to activate
865+
"activationtime" (number) Epoch time to activate, depending on upgrade
866+
}
867+
```
868+
#### Result:
869+
```json
870+
{
871+
"txid" (string) The transaction id
872+
"index" (number) The spending input index
873+
,...
874+
}
875+
```
876+
Examples:
877+
```bash
878+
> verus processupgradedata '{"txid": "0437cd7f8525ceed2324359c2d0ba26006d92d856a9c20fa0241106ee5a597c9", "index": 0}'
879+
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id":"curltest", "method": "processupgradedata", "params": [{"txid": "0437cd7f8525ceed2324359c2d0ba26006d92d856a9c20fa0241106ee5a597c9", "index": 0}] }' -H 'content-type: text/plain;' http://127.0.0.1:27486/
880+
```
881+
856882
### `verifychain ( checklevel numblocks )`
857883
Verifies blockchain database.
858884

@@ -1248,7 +1274,44 @@ Using json rpc
12481274
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id":"curltest", "method": "getidentity", "params": ["name@"] }' -H 'content-type: text/plain;' http://127.0.0.1:27486/
12491275
```
12501276

1251-
### `getidentitytrust '["id",...]'` ***`NEW`***
1277+
### `getidentitycontent "name@ || iid" (heightstart) (heightend) (txproofs) (txproofheight) (vdxfkey)`
1278+
1279+
#### Arguments:
1280+
"name@ || iid" (string, required) name followed by "@" or i-address of an identity
1281+
"heightstart" (number, optional) default=0, only return content from this height forward, inclusive
1282+
"heightend" (number, optional) default=0 which means max height, only return content up to this height,
1283+
inclusive. -1 means also return values from the mempool.
1284+
"txproofs" (bool, optional) default=false, if true, returns proof of ID
1285+
"txproofheight" (number, optional) default="height", height from which to generate a proof
1286+
"vdxfkey" (vdxf key, optional) default=null, more selective search for specific content in ID
1287+
1288+
#### Result:
1289+
1290+
#### Examples:
1291+
```bash
1292+
> verus getidentitycontent "name@"
1293+
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id":"curltest", "method": "getidentitycontent", "params": ["name@"] }' -H 'content-type: text/plain;' http://127.0.0.1:27486/
1294+
```
1295+
1296+
### `getidentityhistory "name@ || iid" (heightstart) (heightend) (txproofs) (txproofheight)`
1297+
1298+
#### Arguments:
1299+
"name@ || iid" (string, required) name followed by "@" or i-address of an identity
1300+
"heightstart" (number, optional) default=0, only return content from this height forward, inclusive
1301+
"heightend" (number, optional) default=0 which means max height, only return content up to this height,
1302+
inclusive. -1 means also return values from the mempool.
1303+
"txproofs" (bool, optional) default=false, if true, returns proof of ID
1304+
"txproofheight" (number, optional) default="height", height from which to generate a proof
1305+
1306+
#### Result:
1307+
1308+
#### Examples:
1309+
```bash
1310+
> verus getidentityhistory "name@"
1311+
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id":"curltest", "method": "getidentityhistory", "params": ["name@"] }' -H 'content-type: text/plain;' http://127.0.0.1:27486/
1312+
```
1313+
1314+
### `getidentitytrust '["id",...]'`
12521315
#### Arguments:
12531316
```json
12541317
"["id",...]" (strarray, optional) if specified, only returns rating values for specified IDs, otherwise all
@@ -1946,20 +2009,7 @@ Examples:
19462009
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id":"curltest", "method": "getblocktemplate", "params": [] }' -H 'content-type: text/plain;' http://127.0.0.1:27486/
19472010
```
19482011

1949-
### `getlocalsolps`
1950-
Returns the average local solutions per second since this node was started.
1951-
This is the same information shown on the metrics screen (if enabled).
1952-
1953-
#### Result:
1954-
xxx.xxxxx (numeric) Solutions per second average
1955-
1956-
Examples:
1957-
```bash
1958-
> verus getlocalsolps
1959-
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id":"curltest", "method": "getlocalsolps", "params": [] }' -H 'content-type: text/plain;' http://127.0.0.1:27486/
1960-
```
1961-
1962-
### `getlastmininingdistribution` ***`NEW`***
2012+
### `getlastmininingdistribution`
19632013
Retrieves the last used mining distribution when making a block
19642014

19652015
#### Arguments
@@ -1980,6 +2030,38 @@ none
19802030
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id":"curltest", "method": "getlastminingdistribution", "params": [] }' -H 'content-type: text/plain;' http://127.0.0.1:27486/
19812031
```
19822032

2033+
### `getlocalsolps`
2034+
Returns the average local solutions per second since this node was started.
2035+
This is the same information shown on the metrics screen (if enabled).
2036+
2037+
#### Result:
2038+
xxx.xxxxx (numeric) Solutions per second average
2039+
2040+
Examples:
2041+
```bash
2042+
> verus getlocalsolps
2043+
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id":"curltest", "method": "getlocalsolps", "params": [] }' -H 'content-type: text/plain;' http://127.0.0.1:27486/
2044+
```
2045+
2046+
### `getminingdistribution`
2047+
Retrieves current mining distribution
2048+
2049+
#### Arguments:
2050+
"name@ || iid" (string, required) name followed by "@" or i-address of an identity
2051+
"heightstart" (number, optional) default=0, only return content from this height forward, inclusive
2052+
"heightend" (number, optional) default=0 which means max height, only return content up to this height,
2053+
inclusive. -1 means also return values from the mempool.
2054+
"txproofs" (bool, optional) default=false, if true, returns proof of ID
2055+
"txproofheight" (number, optional) default="height", height from which to generate a proof
2056+
2057+
#### Result:
2058+
2059+
#### Examples:
2060+
```bash
2061+
> verus getidentityhistory "name@"
2062+
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id":"curltest", "method": "getidentityhistory", "params": ["name@"] }' -H 'content-type: text/plain;' http://127.0.0.1:27486/
2063+
```
2064+
19832065
### `getmininginfo`
19842066
Returns a json object containing mining-related information.
19852067
#### Result:
@@ -2627,7 +2709,7 @@ Examples:
26272709
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id":"curltest", "method": "getlaunchinfo", "params": ["currencyid"] }' -H 'content-type: text/plain;' http://127.0.0.1:27486/
26282710
```
26292711

2630-
### `getblocktemplate ( "jsonrequestobject" )`
2712+
### `getmergedblocktemplate ( "jsonrequestobject" )`
26312713
If the request parameters include a 'mode' key, that is used to explicitly select between the default 'template' request or a 'proposal'.
26322714
It returns data needed to construct a block to work on.
26332715
See https://en.bitcoin.it/wiki/BIP_0022 for full specification.
@@ -2637,11 +2719,6 @@ See https://en.bitcoin.it/wiki/BIP_0022 for full specification.
26372719
```
26382720
{
26392721
"mode":"template" (string, optional) This must be set to "template" or omitted
2640-
"rewarddistribution":{
2641-
"(recipientaddress)":n, (addressorid, relativeweight) key value to determine distribution
2642-
"(recipientaddress)":n,
2643-
"...
2644-
"}
26452722
"capabilities":[ (array, optional) A list of strings
26462723
"support" (string) client side supported feature, 'longpoll', 'coinbasetxn', 'coinbasevalue', 'proposal', 'serverlist', 'workid'
26472724
,...
@@ -2652,14 +2729,14 @@ See https://en.bitcoin.it/wiki/BIP_0022 for full specification.
26522729
```json
26532730
{
26542731
"version" : n, (numeric) The block version
2655-
"previousblockhash" : "xxxx", (string) The hash of current highest block
2656-
"finalsaplingroothash" : "xxxx", (string) The hash of the final sapling root
2732+
"previousblockhash" : "xxxx", (string) The hash of current highest block
2733+
"finalsaplingroothash" : "xxxx", (string) The hash of the final sapling root
26572734
"transactions" : [ (array) contents of non-coinbase transactions that should be included in the next block
26582735
{
2659-
"data" : "xxxx", (string) transaction data encoded in hexadecimal (byte-for-byte)
2660-
"hash" : "xxxx", (string) hash/id encoded in little-endian hexadecimal
2661-
"depends" : [ (array) array of numbers
2662-
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
2736+
"data" : "xxxx", (string) transaction data encoded in hexadecimal (byte-for-byte)
2737+
"hash" : "xxxx", (string) hash/id encoded in little-endian hexadecimal
2738+
"depends" : [ (array) array of numbers
2739+
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
26632740
,...
26642741
],
26652742
"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
@@ -2669,24 +2746,25 @@ See https://en.bitcoin.it/wiki/BIP_0022 for full specification.
26692746
,...
26702747
],
26712748
"coinbasetxn" : { ... }, (json object) information for coinbase transaction
2672-
"target" : "xxxx", (string) The hash target
2749+
"target" : "xxxx", (string) The hash target
26732750
"mintime" : xxx, (numeric) The minimum timestamp appropriate for next block time in seconds since epoch (Jan 1 1970 GMT)
26742751
"mutable" : [ (array of string) list of ways the block template may be changed
26752752
"value" (string) A way the block template may be changed, e.g. 'time', 'transactions', 'prevblock'
26762753
,...
26772754
],
2678-
"noncerange" : "00000000ffffffff", (string) A range of valid nonces
2679-
"sigoplimit" : n, (numeric) limit of sigops in blocks
2680-
"sizelimit" : n, (numeric) limit of block size
2681-
"curtime" : ttt, (numeric) current timestamp in seconds since epoch (Jan 1 1970 GMT)
2682-
"bits" : "xxx", (string) compressed target of next block
2683-
"height" : n (numeric) The height of the next block
2755+
"noncerange" : "00000000ffffffff", (string) A range of valid nonces
2756+
"sigoplimit" : n, (numeric) limit of sigops in blocks
2757+
"sizelimit" : n, (numeric) limit of block size
2758+
"curtime" : ttt, (numeric) current timestamp in seconds since epoch (Jan 1 1970 GMT)
2759+
"bits" : "xxx", (string) compressed target of next block
2760+
"merged_bits": "xxx", (string) compressed target of next merged block
2761+
"height" : n (numeric) The height of the next block
26842762
}
26852763
```
26862764
Examples:
26872765
```bash
2688-
> verus getblocktemplate
2689-
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id":"curltest", "method": "getblocktemplate", "params": [] }' -H 'content-type: text/plain;' http://127.0.0.1:27486/
2766+
> verus getmergedblocktemplate
2767+
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id":"curltest", "method": "getblockmergedtemplate", "params": [] }' -H 'content-type: text/plain;' http://127.0.0.1:27486/
26902768
```
26912769

26922770
### `getnotarizationdata "currencyid"`
@@ -2708,6 +2786,63 @@ Examples:
27082786
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id":"curltest", "method": "getnotarizationdata", "params": ["currencyid"] }' -H 'content-type: text/plain;' http://127.0.0.1:27486/
27092787
```
27102788

2789+
### 'getnotarizationproofs {json object}'
2790+
Returns proofs to a caller for requested challenges. Some proofs can either independently or in combination
2791+
with other proofs over time invalidate or force a competing chain to provide more proofs in order to confirm
2792+
any pending cross-chain notarization of an alternate chain that may not agree with us.
2793+
2794+
* It is not valid to have a challenge request with both confirmnotarization and confirmroot.
2795+
2796+
#### Arguments:
2797+
"challengerequests" (array, required) one or more challenge requests for unconfirmed notarizations on a bridged system
2798+
```json
2799+
[
2800+
{
2801+
"type":"vrsc::evidence.skipchallenge" || "iCwxpRL6h3YeCRtGjgQSsqoKdZCuM4Dxaf",
2802+
"evidence":{CNotaryEvidence},
2803+
"entropyhash":"hex",
2804+
"proveheight":n,
2805+
"atheight":n
2806+
},
2807+
{
2808+
"type":"vrsc::evidence.validitychallenge" || "iCPb8ywQna7jYV2SHrGZ6vQMj7kuyWFxvb",
2809+
"evidence":{CNotaryEvidence},
2810+
"entropyhash":"hex",
2811+
"fromheight":n,
2812+
"toheight":n,
2813+
"challengedroot":{CPRoofRoot},
2814+
"confirmnotarization":{expectednotarization}, | "confirmroot":{CPRoofRoot}
2815+
},
2816+
{"type":"vrsc::evidence.primaryproof" || "iKDesmiEkEjDG61nQSZJSGhWvC8x8xA578",
2817+
"priornotarizationref":{CUTXORef} || "priorroot":{CProofRoot
2818+
},
2819+
"challengeroots":
2820+
[
2821+
{
2822+
"indexkey":{object},
2823+
"proofroot":{CProofRoot}
2824+
},
2825+
...
2826+
],
2827+
"evidence":{CNotaryEvidence},
2828+
"entropyhash":"hex",
2829+
"confirmnotarization":{newnotarization}, |
2830+
"confirmroot":{CPRoofRoot}},
2831+
"fromheight":n,
2832+
"toheight":n},
2833+
...
2834+
]
2835+
```
2836+
#### Results:
2837+
```json
2838+
{"evidence":[{CNotaryEvidence}, ...] (array) notary evidence challenges, including proofs for challenges requested
2839+
```
2840+
#### Examples:
2841+
```bash
2842+
> verus getnotarizationproofs '[{"type":"iCwxpRL6h3YeCRtGjgQSsqoKdZCuM4Dxaf", "evidence":{CNotaryEvidence}, "proveheight":n, "atheight":n}, ...]'
2843+
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id":"curltest", "method": "getnotarizationproofs", "params": [[{"type":"iCwxpRL6h3YeCRtGjgQSsqoKdZCuM4Dxaf", "evidence":{CNotaryEvidence}, "proveheight":n, "atheight":n}, ...]] }' -H 'content-type: text/plain;' http://127.0.0.1:27486/
2844+
```
2845+
27112846
### `getpendingtransfers "chainname"`
27122847
Returns all pending transfers for a particular chain that have not yet been aggregated into an export.
27132848
#### Arguments:
@@ -2927,6 +3062,41 @@ Examples:
29273062
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id":"curltest", "method": "submitacceptednotarization", "params": ["{earnednotarization}" "{notaryevidence}"] }' -H 'content-type: text/plain;' http://127.0.0.1:27486/
29283063
```
29293064

3065+
### `submitchallenges [json array]`
3066+
Submits one or more cryptographic challenges to existing, unconfirmed notarizations, proving the existence
3067+
of an alternate chain. Whether the alternate chain has more power than the chain with a pending notarization
3068+
is not required, only that it has moved forward multiple blocks since the prior notarization.
3069+
3070+
Requires that the local wallet have funds for fees.
3071+
3072+
#### Arguments:
3073+
"challenges" (array, required) one or more challenges to unconfirmed notarizations on this system
3074+
```json
3075+
[
3076+
{
3077+
"type":"vrsc::evidence.skipchallenge" || "iCwxpRL6h3YeCRtGjgQSsqoKdZCuM4Dxaf" ||
3078+
"type":"vrsc::evidence.validitychallenge" || "iCPb8ywQna7jYV2SHrGZ6vQMj7kuyWFxvb",
3079+
"notarizationref":{"txid":"hexvalue","voutnum":n},
3080+
"forkroot":{},
3081+
"challengeroot":{},
3082+
"evidence":{}
3083+
},
3084+
{...},
3085+
...
3086+
]
3087+
```
3088+
3089+
#### Result:
3090+
```json
3091+
[{"txid":"hex"}, {"error":"errorstring"}, ...] (array) results of submitted challenge transactions
3092+
```
3093+
3094+
#### Examples:
3095+
```bash
3096+
> verus submitchallenges '[{"notarizationref":{"txid":"hexvalue","voutnum":n},"challengeroot":{},"evidence":{}}]'
3097+
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id":"curltest", "method": "submitchallenges", "params": [[{"notarizationref":{"txid":"hexvalue","voutnum":n},"challengeroot":{},"evidence":{}}]] }' -H 'content-type: text/plain;' http://127.0.0.1:27486/
3098+
```
3099+
29303100
### `submitimports '{"sourcesystemid":"systemid", "notarizationtxid":"txid", "notarizationtxoutnum":n, "exports":[{"txid":"hexid", "txoutnum":n, "partialtransactionproof":"hexstr", Fresendw"transfers": [{transfer1}, {transfer2},...]}, ...]}'`
29313101
Accepts a set of exports from another system to post to the VRSC network.
29323102

@@ -5353,4 +5523,4 @@ Perform a joinsplit and return the JSDescription.
53535523

53545524
compiled by Oink.vrsc@, additions by Mike@, grewalsatinder@ and allbits@
53555525

5356-
Note: last revision date 2023-02-12.
5526+
Note: last revision date 2023-03-19.

index.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ If you have any questions about the information here, need help or have suggesti
8686

8787
## CLI wallet specific Information
8888
[Verusd options list](#!faq-cli/clifaq-01_verusd_options.md) ***`UPDATED to v0.9.9-2`***
89-
[Verus command list](#!faq-cli/clifaq-02_verus_commands.md) ***`UPDATED to v0.9.6-1`***
89+
[Verus command list](#!faq-cli/clifaq-02_verus_commands.md) ***`UPDATED to v0.9.9-2`***
9090
[Remarks on Windows command line formatting](#!faq-windows/winfaq-01_cli_formatting.md)
9191

9292
## Q&A Archive

0 commit comments

Comments
 (0)