Links

eth_syncing

Returns an object with data about the sync status or false.

Parameters

None

Returns

Object|Boolean - An object with sync status data or FALSE, when not syncing.
  • startingBlock(hex string). QUANTITY - the block at which the import started (will only be reset, after the sync reached his head).
  • currentBlock(hex string). QUANTITY - the current block, same as eth_blockNumber.
  • highestBlock(hex string). QUANTITY - the estimated highest block.

Example

Request

curl
TypeScript
curl https://api.blockvision.org/v1/<api key> \
-X POST \
-H "Content-Type: application/json" \
-d '{
"jsonrpc": "2.0",
"method": "eth_syncing",
"params": [],
"id": 42
}'
import { BlockVisionProvider, BvNetwork } from 'blockvision.js'
// Optional parameters, but default to eth-mainnet and default api-key.
const bv = new BlockVisionProvider(BvNetwork.POL_MAINNET)
// Access BlockVision Enhanced API requests
bv.getSyncing().then(console.log)

Result

{
"jsonrpc": "2.0",
"id": 42,
"result": false
}