Avalanche
Bereit, das in der Produktion aufzurufen?
Das Free-Tier deckt persönliche Projekte ab. Pay-as-you-go skaliert ohne Karte.
Avalanche
Das Free-Tier deckt persönliche Projekte ab. Pay-as-you-go skaliert ohne Karte.
eth_getUncleByBlockHashAndIndex is the Ethereum JSON-RPC call that, on proof-of-work chains, returns the uncle (ommer) block header at a given index within the block identified by a hash. On the Avalanche C-Chain (chain ID 43114, gas paid in AVAX) it is part of the standard EVM API surface but has no real data to return: blocks are produced under the Snowman/Avalanche BFT consensus, not by competing miners, so the chain never creates uncle blocks. As a result this method returns null for every block. The endpoint is https://avalanche.therpc.io/YOUR_API_KEY; the call exists purely so EVM tooling that expects it continues to work against the C-Chain.
null.null; for header research, fetch the canonical block header instead with eth_getBlockByHash.| # | Name | Typ | Erforderlich | Beschreibung |
|---|---|---|---|---|
| 1 | blockHash | string (hex) | Ja | The hash of the block that references the uncle. |
| 2 | uncleIndex | string (hex) | Ja | Zero-based index of the uncle within the block's uncles array. |
| Typ | Beschreibung |
|---|---|
| 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 Avalanche playground.
| Code | Meldung | Ursache |
|---|---|---|
-32602 | Invalid params | Block hash or uncle index is malformed. |
null for any block hash and uncle index, including the most recent blocks.0x0, 0x2, or any other index all return null on Avalanche. Use eth_getBlockByHash for real block header data.Parameter
0x-prefixed 32-byte block hash
0x-prefixed hex integer (e.g. "0x0")