23 releases

0.1.20 Mar 25, 2024
0.1.15 Oct 4, 2023
0.1.10 Mar 23, 2023
0.1.1 Dec 1, 2022
0.0.2 Dec 30, 2021

#1745 in Magic Beans

Download history 1/week @ 2024-02-21 5/week @ 2024-02-28 2/week @ 2024-03-13 476/week @ 2024-03-20 58/week @ 2024-03-27 41/week @ 2024-04-03

575 downloads per month

MIT license

89KB
2K SLoC

Client implementations

The client side of making RPC requests to the Verus daemon.

This crate handles the definition of the Remote-Prodecure-Calls as is defined by the Verus Daemon. It tries to be a stateless wrapper of the RPCs.

Notes

  • Accounts are not supported in Verus and will not be implemented here.

Addressindex

  • getaddressbalance
  • getaddressdeltas
  • getaddressmempool
  • getaddresstxids
  • getaddressutxos
  • getsnapshot

Blockchain

  • coinsupply < height >
  • getbestblockhash
  • getblock "hash|height" ( verbosity )
  • getblockchaininfo
  • getblockcount
  • getblockdeltas "blockhash"
  • getblockhash index
  • getblockhashes timestamp
  • getblockheader "hash" ( verbose )
  • getchaintips
  • getchaintxstats
  • getdifficulty
  • getmempoolinfo
  • getrawmempool ( verbose )
  • getspentinfo
  • gettxout "txid" n ( includemempool )
  • gettxoutproof [ "txid",... ] ( blockhash )
  • gettxoutsetinfo
  • kvsearch key
  • kvupdate key "value" days passphrase
  • minerids height
  • notaries height timestamp
  • verifychain ( checklevel numblocks )
  • verifytxoutproof "proof"
  • z_gettreestate "hash|height"

Control

  • getinfo
  • help ( "command" )
  • stop

Crosschain

  • MoMoMdata symbol kmdheight ccid
  • assetchainproof needs a txid
  • calc_MoM height MoMdepth
  • getNotarisationsForBlock blockHash
  • height_MoM height
  • migrate_completeimporttransaction importTx
  • migrate_converttoexport rawTx dest_symbol export_amount
  • migrate_createimporttransaction burnTx payouts
  • scanNotarisationsDB blockHeight symbol [ blocksLimit=1440 ]

Disclosure

z_getpaymentdisclosure "txid" "js_index" "output_index" ("message") z_validatepaymentdisclosure "paymentdisclosure"

Generating

  • generate numblocks
  • getgenerate
  • setgenerate generate ( genproclimit )

Identity

  • getidentity "name@ || iid" (height) (txproof) (txproofheight)
  • listidentities (includecansign) (includewatchonly)
  • recoveridentity "jsonidentity" (returntx)
  • registeridentity "jsonidregistration" (returntx) feeoffer
  • registernamecommitment "name" "controladdress" ("referralidentity")
  • revokeidentity "nameorID" (returntx)
  • setidentitytimelock "id@" '{"unlockatblock":absoluteblockheight || "setunlockdelay":numberofblocksdelayafterunlock}' (returntx)
  • signfile "address or identity" "filepath/filename" "curentsig"
  • signmessage "address or identity" "message" "currentsig"
  • updateidentity "jsonidentity" (returntx)
  • verifyfile "address or identity" "signature" "filepath/filename" "checklatest"
  • verifyhash "address or identity" "signature" "hexhash" "checklatest"
  • verifymessage "address or identity" "signature" "message" "checklatest"

Marketplace

  • closeoffers ('["offer1_txid", "offer2_txid", ...]') (transparentorprivatefundsdestination) (privatefundsdestination)
  • getoffers "currencyorid" (iscurrency) (withtx)
  • listopenoffers (unexpired) (expired)'
  • makeoffer fromaddress '{"changeaddress":"transparentoriaddress", "expiryheight":blockheight, "offer":{"currency":"anycurrency", "amount":...} | {"identity":"idnameoriaddress",...}', "for":{"address":..., "currency":"anycurrency", "amount":...} | {"name":"identityforswap","parent":"parentid","primaryaddresses":["R-address(s)"],"minimumsignatures":1,...}}' (returntx) (feeamount)
  • takeoffer fromaddress '{"txid":"txid" | "tx":"hextx", "changeaddress":"transparentoriaddress", "deliver":"fullidnameoriaddresstodeliver" | {"currency":"currencynameorid","amount":n}, "accept":{"address":"addressorid","currency":"currencynameorid","amount"} | {identitydefinition}}' (returntx) (feeamount)

Mining

  • getblocksubsidy height
  • getblocktemplate ( "jsonrequestobject" )
  • getlocalsolps
  • getmininginfo
  • getnetworkhashps ( blocks height )
  • getnetworksolps ( blocks height )
  • prioritisetransaction
  • submitblock "hexdata" ( "jsonparametersobject" )

Network

  • addnode "node" "add|remove|onetry"
  • clearbanned
  • disconnectnode "node"
  • getaddednodeinfo dns ( "node" )
  • getconnectioncount
  • getdeprecationinfo
  • getnettotals
  • getnetworkinfo
  • getpeerinfo
  • listbanned
  • ping
  • setban "ip(/netmask)" "add|remove" (bantime) (absolute)

Rawtransactions

  • createrawtransaction [{"txid":"id","vout":n},...] {"address":amount,...} ( locktime ) ( expiryheight )
  • decoderawtransaction "hexstring"
  • decodescript "hex"
  • fundrawtransaction "hexstring"
  • getrawtransaction "txid" ( verbose )
  • sendrawtransaction "hexstring" ( allowhighfees )
  • signrawtransaction "hexstring" ( [{"txid":"id","vout":n,"scriptPubKey":"hex","redeemScript":"hex"},...] ["privatekey1",...] sighashtype )

Util

  • createmultisig nrequired ["key",...]
  • estimatefee nblocks
  • estimatepriority nblocks
  • invalidateblock "hash"
  • jumblr_deposit "depositaddress"
  • jumblr_pause
  • jumblr_resume
  • jumblr_secret "secretaddress"
  • reconsiderblock "hash"
  • validateaddress "komodoaddress"
  • z_validateaddress "zaddr"

VDXF

  • getvdxfid "vdxfuri"

Wallet

  • addmultisigaddress nrequired ["key",...] ( "account" )
  • backupwallet "destination"
  • convertpassphrase "agamapassphrase"
  • dumpprivkey "t-addr"
  • dumpwallet "filename"
  • encryptwallet "passphrase"
  • getaccount "VRSC_address"
  • getaccountaddress "account"
  • getaddressesbyaccount "account"
  • getbalance ( "account" minconf includeWatchonly )
  • getcurrencybalance "address" ( minconf friendlynames)
  • getnewaddress ( "account" )
  • getrawchangeaddress
  • getreceivedbyaccount "account" ( minconf )
  • getreceivedbyaddress "VRSC_address" ( minconf )
  • gettransaction "txid" ( includeWatchonly )
  • getunconfirmedbalance
  • getwalletinfo
  • importaddress "address" ( "label" rescan )
  • importprivkey "komodoprivkey" ( "label" rescan height secret_key)
  • importwallet "filename"
  • keypoolrefill ( newsize )
  • listaccounts ( minconf includeWatchonly)
  • listaddressgroupings
  • listlockunspent
  • listreceivedbyaccount ( minconf includeempty includeWatchonly)
  • listreceivedbyaddress ( minconf includeempty includeWatchonly)
  • listsinceblock ( "blockhash" target-confirmations includeWatchonly)
  • listtransactions ( "account" count from includeWatchonly)
  • listunspent ( minconf maxconf ["address",...] )
  • lockunspent unlock [{"txid":"txid","vout":n},...]
  • move "fromaccount" "toaccount" amount ( minconf "comment" )
  • resendwallettransactions
  • sendfrom "fromaccount" "toKMDaddress" amount ( minconf "comment" "comment-to" )
  • sendmany "fromaccount" {"address":amount,...} ( minconf "comment" ["address",...] )
  • sendtoaddress "KMD_address" amount ( "comment" "comment-to" subtractfeefromamount )
  • setaccount "KMD_address" "account"
  • settxfee amount
  • z_exportkey "zaddr"
  • z_exportviewingkey "zaddr"
  • z_exportwallet "filename"
  • z_getbalance "address" ( minconf )
  • z_getnewaddress ( type )
  • z_getoperationresult (["operationid", ... ])
  • z_getoperationstatus (["operationid", ... ])
  • z_gettotalbalance ( minconf includeWatchonly )
  • z_importkey "zkey" ( rescan startHeight )
  • z_importviewingkey "vkey" ( rescan startHeight )
  • z_importwallet "filename"
  • z_listaddresses ( includeWatchonly )
  • z_listoperationids
  • z_listreceivedbyaddress "address" ( minconf )
  • z_listunspent ( minconf maxconf includeWatchonly ["zaddr",...] )
  • z_mergetoaddress ["fromaddress", ... ] "toaddress" ( fee ) ( transparent_limit ) ( shielded_limit ) ( memo )
  • z_sendmany "fromaddress" [{"address":... ,"amount":...},...] ( minconf ) ( fee )
  • z_shieldcoinbase "fromaddress" "tozaddress" ( fee ) ( limit )
  • z_viewtransaction "txid"
  • zcbenchmark benchmarktype samplecount
  • zcrawjoinsplit rawtx inputs outputs vpub_old vpub_new
  • zcrawkeygen
  • zcrawreceive zcsecretkey encryptednote
  • zcsamplejoinsplit

Dependencies

~8–17MB
~178K SLoC