Zcash
gettxoutsetinfo8 额度
返回未花费交易输出集的统计数据
参数
| 名称 | 类型 | 描述 |
|---|---|---|
| hash_type | string | 要计算的 UTXO 集哈希:hash_serialized_3(默认)、muhash 或 none。较旧版本使用 hash_serialized_2。 (可选) |
| hash_or_height | string | number | 要报告的区块哈希或高度。默认为链顶端。仅在启用 coinstatsindex 时才适用于其他区块。 (可选) |
| use_index | boolean | 可用时使用 coinstatsindex。默认为 true。 (可选) |
返回值
类型
Object
height、bestblock、txouts、bogosize、所请求的哈希(hash_serialized_3 或 muhash)、total_amount,以及在不是由 coinstatsindex 提供时的 transactions 和 disk_size。使用 coinstatsindex 时还有 total_unspendable_amount 和 block_info。此调用会扫描整个 UTXO 集,可能需要数分钟。
代码示例
curl https://holy-burned-sky-zcash-mainnet.rpcnode.dev/7c9e6679-7425-40de-944b-e07fc1f90ae7 \
-X POST \
-H 'content-type: application/json' \
-d '{
"jsonrpc": "2.0",
"id": 1,
"method": "gettxoutsetinfo",
"params": [
"hash_serialized_3"
]
}'