getblockheader
BitcoinC1Returns just the header fields for a block hash — cheaper than getblock when you only need height, time, bits and previous hash.
Endpoint
POST https://api.1st-node.com/v1/bitcoin/rpcParameters
| Name | Type | Description |
|---|---|---|
| blockhash | string | The block hash. |
| verbose | boolean | true for decoded JSON, false for hex. |
Returns
object — the decoded block header.
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": "getblockheader",
"params": ["00000000000000000000f1c7…", true]
}'{
"jsonrpc": "2.0",
"id": 1,
"method": "getblockheader",
"params": ["00000000000000000000f1c7…", true]
}Response
{
"jsonrpc": "2.0",
"id": 1,
"result": { "height": 854120, "time": 1721400000, "previousblockhash": "…" }
}More blocks methods on Bitcoin
Recarga, obtén tu clave y publica.
Autoservicio. Paga en cripto o con tarjeta. Medido por créditos: las primitivas pesadas cuestan más, las simples son baratas.
Obtener clave API