Home

Get Block Header

POST
https://dot-assethub.nownodes.io/

Authorizations

ApiKeyAuthApiKeyAuth

api-key string

NOWNodes API key passed in the api-key header.

Returns the header of the most recent (best) block in the Polkadot blockchain.

This method is part of the Polkadot JSON-RPC 2.0 specification for chain-related operations. The header contains critical information about the block including hashes, roots, and consensus data.

Body

application/json
jsonrpcstring2.0required

The JSON-RPC protocol version. Must be exactly "2.0".

methodstringchain_getHeaderrequired

The JSON-RPC method to call. For this endpoint, must be "chain_getHeader".

paramsArray<any>required

Parameters for the method. For chain_getHeader, this should be an empty array as it retrieves the latest block header without additional parameters.

idinteger<int32>required

Request identifier that will be returned in the response. Used to match requests with responses when making multiple concurrent calls.

Response

200OK

Successful response containing the block header information.

The header represents the most recent block in the best chain and contains cryptographic commitments to the block's contents and state.

400Bad Request

Bad Request - Invalid JSON-RPC request Possible reasons:

  • Invalid JSON syntax
  • Missing required fields
  • Invalid method name
  • Invalid parameters
500Internal Server Error

Internal Server Error The node encountered an internal error while processing the request.

503Service Unavailable

Service Unavailable The node is currently unavailable, possibly due to maintenance or synchronization.