Arbitrum One
Pronto para usar isso em produção?
O plano gratuito cobre projetos pessoais. O pay-as-you-go escala sem cartão de crédito.
Arbitrum One
O plano gratuito cobre projetos pessoais. O pay-as-you-go escala sem cartão de crédito.
eth_getUncleCountByBlockNumber returns the number of uncle blocks referenced by the block at a given height or block tag ("latest", "earliest", "safe", "finalized", etc.), as a hex-encoded integer. On Arbitrum One — the ETH-fee Optimistic Rollup built on Nitro/ArbOS — that count is always "0x0", because the chain's single sequencer orders blocks with no proof-of-work fork race and therefore never produces ommers. It is the height-addressed counterpart of eth_getUncleCountByBlockHash, retained for Ethereum JSON-RPC compatibility. The endpoint is https://arbitrum.therpc.io/YOUR_API_KEY (chain ID 42161, 0xa4b1).
"0x0", so the computed rate is a constant zero.eth_getUncleByBlockNumberAndIndex; since Arbitrum One always reports zero, the detail fetch can be skipped.| # | Nome | Tipo | Obrigatório | Descrição |
|---|---|---|---|---|
| 1 | blockTag | string | Sim | The block to count uncles in. |
| Tipo | Descrição |
|---|---|
| string (hex) | Hex-encoded uncle count. |
Try it live in the Arbitrum One playground.
| Código | Mensagem | Causa |
|---|---|---|
-32602 | Invalid params | Block tag is malformed or unrecognised. |
"0x0" regardless of the block height or tag, the same as post-Merge proof-of-stake chains; do not build logic that expects a non-zero uncle count here."0x0", not a number — parse it (for example with parseInt(value, 16)) before any numeric comparison.Parâmetros
hex block number or "latest"/"earliest"/"pending"/"safe"/"finalized"