Beatae error blanditiis libero

Query blocks, event logs, network statistics, and validator data from the Polygon PoS blockchain via REST API.

The Polygon Blockchain Explorer API encompasses the block, logs, and stats modules of the Polygon Scan API. These endpoints provide the infrastructure-level data that powers block explorers, network monitors, and DeFi analytics platforms.

Block Module

The block module provides information about specific blocks and their relationship to time:

  • getblockreward – Returns the block reward and uncle rewards for a given block number
  • getblockcountdown – Estimates the seconds until a future block will be produced
  • getblocknobytime – Returns the block number closest to a given Unix timestamp — invaluable for historical data queries
Event Logs Module

The logs module provides filtered access to smart contract event logs:

?module=logs&action=getLogs&fromBlock=X&toBlock=Y&address=0xCONTRACT&topic0=0xEVENT_SIG&apikey=KEY

You can filter logs by block range, contract address, and up to 4 topic hashes (topic0 through topic3) using AND/OR logic via the topic0_1_opr parameter. This is equivalent to a filtered eth_getLogs JSON-RPC call but accessible without a dedicated RPC node.

Network Statistics Module

The stats module returns network-wide metrics:

  • matsupply – Returns the total supply of POL (formerly MATIC) in Wei
  • maticprice – Returns the current POL price in USD and BTC
  • chainsize – PRO: Returns the blockchain size in bytes for a given block range
  • nodecount – PRO: Returns the total number of active Polygon nodes
Validator & Staking Data

Use getminedblocks in the account module to retrieve all blocks produced by a specific validator address, useful for monitoring validator performance and calculating staking rewards over time.