getblock - Hush 3.10.3 RPC
getblock "hash|height" ( verbosity ) If verbosity is 0, returns a string that is serialized, hex-encoded data for the block. If verbosity is 1, returns an Object with information about the block. If verbosity is 2, returns an Object with information about the block and information about each transaction. Arguments: 1. "hash|height" (string, required) The block hash or height 2. verbosity (numeric, optional, default=1) 0 for hex encoded data, 1 for a json object, and 2 for json object with transaction data Result (for verbosity = 0): "data" (string) A string that is serialized, hex-encoded data for the block. Result (for verbosity = 1): { "hash" : "hash", (string) the block hash (same as provided hash) "confirmations" : n, (numeric) The number of notarized DPoW confirmations, or -1 if the block is not on the main chain "rawconfirmations" : n,(numeric) The number of raw confirmations, or -1 if the block is not on the main chain "size" : n, (numeric) The block size "height" : n, (numeric) The block height or index (same as provided height) "version" : n, (numeric) The block version "merkleroot" : "xxxx", (string) The merkle root "finalsaplingroot" : "xxxx", (string) The root of the Sapling commitment tree after applying this block "tx" : [ (array of string) The transaction ids "transactionid" (string) The transaction id ,... ], "time" : ttt, (numeric) The block time in seconds since epoch (Jan 1 1970 GMT) "nonce" : n, (numeric) The nonce "bits" : "1d00ffff", (string) The bits "difficulty" : x.xxx, (numeric) The difficulty "previousblockhash" : "hash", (string) The hash of the previous block "nextblockhash" : "hash" (string) The hash of the next block } Result (for verbosity = 2): { ..., Same output as verbosity = 1. "tx" : [ (array of Objects) The transactions in the format of the getrawtransaction RPC. Different from verbosity = 1 "tx" result. ,... ], ,... Same output as verbosity = 1. } Examples: > hush-cli getblock "00000000febc373a1da2bd9f887b105ad79ddc26ac26c2b28652d64e5207c5b5" > curl --user myusername --data-binary '{"jsonrpc": "1.0", "id":"curltest", "method": "getblock", "params": ["00000000febc373a1da2bd9f887b105ad79ddc26ac26c2b28652d64e5207c5b5"] }' -H 'content-type: text/plain;' http://127.0.0.1:18031/ > hush-cli getblock 12800 > curl --user myusername --data-binary '{"jsonrpc": "1.0", "id":"curltest", "method": "getblock", "params": [12800] }' -H 'content-type: text/plain;' http://127.0.0.1:18031/
Maintained by The Hush Developers
Welcome to the Hush full node RPC developer documentation!!! You finally made it.
Addressindex
Blockchain
coinsupply
getbestblockhash
getblock
getblockchaininfo
getblockcount
getblockhash
getblockhashes
getblockheader
getblockmerkletree
getchaintips
getchaintxstats
getdifficulty
getmempoolinfo
getrawmempool
getspentinfo
gettxout
gettxoutproof
gettxoutsetinfo
kvsearch
kvupdate
minerids
notaries
verifychain
verifytxoutproof
getbestblockhash
getblock
getblockchaininfo
getblockcount
getblockhash
getblockhashes
getblockheader
getblockmerkletree
getchaintips
getchaintxstats
getdifficulty
getmempoolinfo
getrawmempool
getspentinfo
gettxout
gettxoutproof
gettxoutsetinfo
kvsearch
kvupdate
minerids
notaries
verifychain
verifytxoutproof
Crosschain
Generating
Mining
NSPV
Network
Rawtransactions
Util
Wallet
abortrescan
addmultisigaddress
backupwallet
cleanwallettransactions
convertpassphrase
dumpprivkey
dumpwallet
encryptwallet
getaccount
getaccountaddress
getaddressesbyaccount
getalldata
getbalance
getnewaddress
getrawchangeaddress
getreceivedbyaccount
getreceivedbyaddress
getrescaninfo
gettransaction
getunconfirmedbalance
getwalletinfo
importaddress
importprivkey
importwallet
keypoolrefill
listaccounts
listaddresses
listaddressgroupings
listlockunspent
listreceivedbyaccount
listreceivedbyaddress
listsinceblock
listtransactions
listunspent
lockunspent
move
opreturn_burn
rescan
resendwallettransactions
sendfrom
sendmany
sendtoaddress
setaccount
setpubkey
settxfee
signmessage
z_anonsetblockdelta
z_anonsettxdelta
z_consolidationstatus
z_exportkey
z_exportviewingkey
z_exportwallet
z_getbalance
z_getbalances
z_getinfo
z_getnewaddress
z_getnotescount
z_getoperationresult
z_getoperationstatus
z_getstats
z_gettotalbalance
z_importkey
z_importviewingkey
z_importwallet
z_listaddresses
z_listnullifiers
z_listoperationids
z_listreceivedaddress
z_listreceivedbyaddress
z_listsentbyaddress
z_listunspent
z_mergetoaddress
z_sendmany
z_shieldcoinbase
z_sweepstatus
z_viewtransaction
addmultisigaddress
backupwallet
cleanwallettransactions
convertpassphrase
dumpprivkey
dumpwallet
encryptwallet
getaccount
getaccountaddress
getaddressesbyaccount
getalldata
getbalance
getnewaddress
getrawchangeaddress
getreceivedbyaccount
getreceivedbyaddress
getrescaninfo
gettransaction
getunconfirmedbalance
getwalletinfo
importaddress
importprivkey
importwallet
keypoolrefill
listaccounts
listaddresses
listaddressgroupings
listlockunspent
listreceivedbyaccount
listreceivedbyaddress
listsinceblock
listtransactions
listunspent
lockunspent
move
opreturn_burn
rescan
resendwallettransactions
sendfrom
sendmany
sendtoaddress
setaccount
setpubkey
settxfee
signmessage
z_anonsetblockdelta
z_anonsettxdelta
z_consolidationstatus
z_exportkey
z_exportviewingkey
z_exportwallet
z_getbalance
z_getbalances
z_getinfo
z_getnewaddress
z_getnotescount
z_getoperationresult
z_getoperationstatus
z_getstats
z_gettotalbalance
z_importkey
z_importviewingkey
z_importwallet
z_listaddresses
z_listnullifiers
z_listoperationids
z_listreceivedaddress
z_listreceivedbyaddress
z_listsentbyaddress
z_listunspent
z_mergetoaddress
z_sendmany
z_shieldcoinbase
z_sweepstatus
z_viewtransaction