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_getUncleByBlockHashAndIndex is the standard Ethereum JSON-RPC call that returns the uncle (ommer) block header at a given index within the block identified by a block hash. It exists on Arbitrum One — the ETH-denominated Optimistic Rollup running Nitro/ArbOS — for API compatibility, but Arbitrum One produces no uncle blocks: a single sequencer orders transactions and there is no proof-of-work fork race, so no ommers are ever referenced. As a result this method always returns null on Arbitrum One regardless of the block hash or index you pass. The endpoint is https://arbitrum.therpc.io/YOUR_API_KEY (chain ID 42161, 0xa4b1).
null and yield no header to analyze.| # | Nome | Tipo | Obrigatório | Descrição |
|---|---|---|---|---|
| 1 | blockHash | string (hex) | Sim | The hash of the block that references the uncle. |
| 2 | uncleIndex | string (hex) | Sim | Zero-based index of the uncle within the block's uncles array. |
| Tipo | Descrição |
|---|---|
| object | null | Block header object (no transactions array): number, hash, parentHash, sha3Uncles, miner, stateRoot, transactionsRoot, receiptsRoot, logsBloom, difficulty, gasLimit, gasUsed, timestamp, extraData, mixHash, nonce. Returns null if not found. |
Try it live in the Arbitrum One playground.
| Código | Mensagem | Causa |
|---|---|---|
-32602 | Invalid params | Block hash or uncle index is malformed. |
null for any block; the same is true of post-Merge proof-of-stake chains generally."0x2" or higher always returns null. On Arbitrum One even index "0x0" is null.Parâmetros
0x-prefixed 32-byte block hash
0x-prefixed hex integer (e.g. "0x0")