Actions9
Get Block Info
AI-generatedOverview
This node interacts with the Blockstream API (Esplora) to retrieve detailed information about a specific Bitcoin block using its block hash. It supports multiple Bitcoin networks including mainnet, testnet, Liquid, and Liquid testnet. This node is useful for blockchain analysts, developers, or anyone needing to fetch block data such as block height, timestamp, transaction count, and other block metadata.
Use Case Examples
- Retrieve information about a Bitcoin mainnet block by providing its block hash.
- Fetch details of a testnet block for testing or development purposes.
Properties
| Name | Meaning |
|---|---|
| Network | Selects the Bitcoin network to query (mainnet, testnet, Liquid, or Liquid testnet). |
| Block Hash | The hash of the block to retrieve information for. This is a required string input. |
Output
JSON
json- The JSON object containing detailed information about the specified block, including metadata such as block height, timestamp, transaction count, and other block-specific data returned by the Blockstream API.
Dependencies
- Blockstream API (Esplora) endpoint accessed via HTTP requests using axios library.
Troubleshooting
- Common issues include providing an invalid or non-existent block hash, which will result in an error from the API.
- Network selection must match the block hash network; querying a mainnet block hash on testnet will fail.
- API request failures due to network issues or rate limiting may occur; ensure stable internet connection and consider retry logic if needed.
Links
- Blockstream API Documentation - Official documentation for the Blockstream Esplora API used to fetch Bitcoin blockchain data.