Skip to main content

gettxoutsetinfo

POST

Returns statistics about the unspent transaction output (UTXO) set.

🚧 The response may take a long time!

The method iterates over the entire UTXO set, so it takes a long time to complete.

Set hash_type to none if you do not need the hash to be computed.

param[0]
hashTypestringrequired
The UTXO set hash to compute.
  • hash_serialized_3: Computes the serialized hash of the UTXO set.
  • muhash: Computes the MuHash of the UTXO set.
  • none: Does not compute a hash.
param[1]
hashOrHeightstringrequired
The block hash or height to compute the statistics for. A height is passed as an integer.To query a block other than the current best block, coinstatsindex must be enabled on the node.
param[2]
useIndexbooleanrequired
Whether to use coinstatsindex when it is available.
Responses
heightinteger
The height of the block the statistics were computed for.
bestblockstring
The hash of the block the statistics were computed for.
txoutsinteger
The number of unspent transaction outputs.
bogosizeinteger
A database-independent metric for the size of the UTXO set.
hash_serialized_3string
The serialized hash of the UTXO set. Returned only when hash_type is hash_serialized_3.
muhashstring
The MuHash of the UTXO set. Returned only when hash_type is muhash.
transactionsinteger
The number of transactions with unspent outputs. Returned only when coinstatsindex is not used.
disk_sizeinteger
The estimated size of the chainstate on disk, in bytes. Returned only when coinstatsindex is not used.
total_amountnumber
The total amount of coins in the UTXO set, denominated in BTC.
total_unspendable_amountnumber
The total amount permanently excluded from the UTXO set.It is denominated in BTC and returned only when coinstatsindex is used.
Amount details for the target block. Returned only when coinstatsindex is used.
prevout_spentnumber
The total amount of prevouts spent in the block, denominated in BTC.
coinbasenumber
The coinbase amount of the block, denominated in BTC.
new_outputs_ex_coinbasenumber
The total amount of new outputs excluding the coinbase, denominated in BTC.
unspendablenumber
The total amount of unspendable outputs created in the block, denominated in BTC.
Unspendable amounts broken down by cause. All values are denominated in BTC.
genesis_blocknumber
The amount that is unspendable because of the genesis block reward.
bip30number
The amount that is unspendable because of transactions overwritten under BIP 30.
scriptsnumber
The amount that is unspendable because of unspendable scripts, such as OP_RETURN.
unclaimed_rewardsnumber
The block reward amount that miners did not claim.
codestringrequired
Code identifying the cause of the failed request.
messagestringrequired
Detailed message including the name and value of the invalid parameter.
{
"code": "ERROR_CODE",
"message": "Unauthorized"
}
cURL
curl -X POST 'https://bitcoin-mainnet.nodit.io' \
-H 'Content-Type: application/json' \
-H 'X-API-KEY: nodit-demo' \
-d '{
"jsonrpc": "2.0",
"id": 1,
"method": "gettxoutsetinfo",
"params": [
"hash_serialized_3",
820000,
true
]
}'