v1/{chainName}/block_v2/{startDate}/{endDate}/ REST API Endpoint
Path Parameters
chainName
string
The blockchain name to query (e.g., eth-mainnet, bsc-mainnet)
startDate
string
The start date for the block query in YYYY-MM-DD format
endDate
string
The end date for the block query in YYYY-MM-DD format
Query Parameters
page-size
integer
The number of results to return per page
page-number
integer
The page number to retrieve
Returns
data
object
The main response data object
updated_at
string
The timestamp indicating the last update time of the data
chain_id
integer
The unique identifier for the blockchain
chain_name
string
The name of the blockchain (e.g., 'eth-mainnet')
items
array
The list of block items
block_hash
string
The unique hash of the block
signed_at
string
The timestamp when the block was signed
height
integer
The block height in the blockchain
block_parent_hash
string
The hash of the parent block
extra_data
string
The additional data stored in the block
miner_address
string
The address of the miner who mined the block
mining_cost
integer
The cost of mining the block
gas_used
integer
The gas used in the block
gas_limit
integer
The maximum gas limit for the block
transactions_link
string
The link to the transactions associated with the block
pagination
object
The pagination details for the response
has_more
boolean
The flag indicating if there are more pages of data
page_number
integer
The current page number
page_size
integer
The number of items per page
total_count
integer
The total number of items (nullable)
error
boolean
The flag indicating if an error occurred
error_message
string
The error message if an error occurred
error_code
integer
The error code if an error occurred
Request
1curl --location 'https://api.covalenthq.com/v1/eth-mainnet/block_v2/2023-01-01/2023-12-31/' \2--header 'Content-Type: application/json' \3--header 'Authorization: Bearer YOUR_API_KEY'
Don't have an account yet?
Create your QuickNode endpoint in seconds and start building
Get started for free