Skip to main content

bb_getblock RPC Method

Returns information about the block with transaction objects.

Updated on
Oct 13, 2023

bb_getblock RPC Method

Please note that this RPC method requires the Blockbook RPC add-on enabled on your QuickNode endpoint.

Parameters

block
string
REQUIRED
The block hash or block height (as a string)
object
array
The options object with the following fields:
page
integer
The page you would like to retrieve.

Returns

result
object
The details of the result
page
integer
The page number returned in this response
totalPages
integer
The number of pages available for your original query
itemsOnPage
integer
The maximum number of transactions returned in this response
hash
string
The block hash
previousBlockHash
string
The hash of the previous block
nextBlockHash
string
The hash of the next block
height
integer
The block height or index
confirmations
integer
The number of confirmations, or -1 if the block is not on the main chain
size
integer
The size of the block in bytes
time
integer
The block time expressed in UNIX epoch time
version
integer
The block version
merkleRoot
string
The merkle root
nonce
string
A number that miners adjust in order to find a block hash that meets the network's specified difficulty target
bits
string
The value of the nBits field in the block header
difficulty
string
The estimated amount of work done to find this block relative to the estimated amount of work done to find block 0
txCount
integer
Total number of transactions within the returned block
txs
array
A list of txs
txid
string
The transaction id
vin
array
An array of transaction objects used as inputs for the current transaction
n
integer
The nonce of this transaction
isAddress
boolean
Boolean value of whether there is an address or not
value
string
The value of this transaction in satoshis
vout
array
An array of output transaction objects for the current transaction
value
string
The value of this transaction in satoshis
n
integer
The nonce of this transaction
addresses
string
An array of addresses in this transaction
isAddress
boolean
Boolean value of whether there is an address or not
blockHash
string
The hash of the block at which the transaction was included
blockHeight
integer
The block height at which the transaction output was created
confirmations
integer
The number of confirmations since this transaction was included in a block
blockTime
integer
The unix timestamp of when the block was confirmed
value
string
The total value of the transaction in satoshis
valueIn
string
The value transmitted in the transaction less fees denominated in satoshis
fees
string
The fees for the transaction denominated in satoshis
Request
1
curl https://docs-demo.btc.quiknode.pro/ \
2
-X POST \
3
-H "Content-Type: application/json" \
4
--data '{"method": "bb_getblock", "params": ["000000000000000000016ad86be0be4793bf450d07816ed016cf375838b1dc2b", {"page": 1}]}'
Don't have an account yet?
Create your QuickNode endpoint in seconds and start building
Get started for free