getblockhash
BitcoinC1Returns the hash of the block at the requested height. Combine with getblock to fetch the block by number.
Endpoint
POST https://api.1st-node.com/v1/bitcoin/rpcParameters
| Name | Type | Description |
|---|---|---|
| height | number | Block height to look up. |
Returns
string — the block hash (hex).
Request
curl https://api.1st-node.com/v1/bitcoin/rpc \
-H "Authorization: Bearer $ONE_KEY" \
-H "content-type: application/json" \
-d '{
"jsonrpc": "2.0",
"id": 1,
"method": "getblockhash",
"params": [854120]
}'{
"jsonrpc": "2.0",
"id": 1,
"method": "getblockhash",
"params": [854120]
}Response
{
"jsonrpc": "2.0",
"id": 1,
"result": "00000000000000000000f1c7…"
}More blocks methods on Bitcoin
充值、拿密钥、上线。
自助开通。支持加密货币或银行卡。按额度计费——重型原语更贵,简单调用很便宜。
获取 API 密钥