eth_getBlockReceipt - Flashblocks

This returns the receipt of a block — preconfirmed OR finalized. Preconfirmed receipts are identifiable by their zero blockHash (0x00...00) and blockNumber: null. Once the parent block seals (within 2 seconds), the same receipt returns with a real block hash. This zero-hash convention is the canonical way to distinguish preconfirmed vs finalized receipts without additional RPC calls.

Parameters

ParameterTypeRequiredDescription
blockNumberQUANTITYTAGYes

Request Example

bashcurl --location --request POST 'https://shared.eu-central-1.getblock.io/<ACCESS-TOKEN>/' \
--header 'Content-Type: application/json' \
--data-raw '{
  "jsonrpc": "2.0",
  "method": "eth_getBlockReceipts",
  "params": [
    "pending"
  ],
  "id": "getblock.io"
}'
javascriptimport axios from 'axios';

const data = JSON.stringify({
  "jsonrpc": "2.0",
  "method": "eth_getBlockReceipts",
  "params": [
    "pending"
  ],
  "id": "getblock.io"
});

const config = {
    method: 'post',
    url: 'https://shared.eu-central-1.getblock.io/<ACCESS-TOKEN>/',
    headers: {
        'Content-Type': 'application/json'
    },
    data: data
};

axios(config)
    .then(response => console.log(JSON.stringify(response.data, null, 2)))
    .catch(error => console.log(error));
pythonimport requests
import json

url = "https://shared.eu-central-1.getblock.io/<ACCESS-TOKEN>/"

payload = json.dumps({{
  "jsonrpc": "2.0",
  "method": "eth_getBlockReceipts",
  "params": [
    "pending"
  ],
  "id": "getblock.io"
})

headers = {
    'Content-Type': 'application/json'
}

response = requests.post(url, headers=headers, data=payload)
print(response.text)
rustuse reqwest::Client;
use serde_json::json;

#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
    let client = Client::new();

    let payload = json!({
  "jsonrpc": "2.0",
  "method": "eth_getBlockReceipts",
  "params": [
    "pending"
  ],
  "id": "getblock.io"
});

    let response = client
        .post("https://shared.eu-central-1.getblock.io/<ACCESS-TOKEN>/")
        .header("Content-Type", "application/json")
        .json(&payload)
        .send()
        .await?;

    let result: serde_json::Value = response.json().await?;
    println!("{:#?}", result);

    Ok(())
}

Response Example

json{
    "jsonrpc": "2.0",
    "result": [
        {
            "type": "0x7e",
            "status": "0x1",
            "cumulativeGasUsed": "0xb496",
            "logs": [],
            "depositNonce": "0x2ddfd39",
            "depositReceiptVersion": "0x1",
            "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
            "transactionHash": "0xd6586cd3a1cf6f2a79dfdc513863cbaff925578131dc9e42872acdc3dab4aee9",
            "transactionIndex": "0x0",
            "blockHash": "0xe9526259318b13325e3926a3d29a4323d53d7e3c25ebfcf6b0f7ace7376af639",
            "blockNumber": "0x2ddfd36",
            "gasUsed": "0xb496",
            "effectiveGasPrice": "0x0",
            "blobGasUsed": "0x41e8",
            "from": "0xdeaddeaddeaddeaddeaddeaddeaddeaddead0001",
            "to": "0x4200000000000000000000000000000000000015",
            "contractAddress": null,
            "l1GasPrice": "0x1564212e",
            "l1GasUsed": "0x72a",
            "l1Fee": "0x0",
            "l1BaseFeeScalar": "0x8dd",
            "l1BlobBaseFee": "0x1571d4a",
            "l1BlobBaseFeeScalar": "0x101c12",
            "daFootprintGasScalar": "0x94"
  }
   ],
    "id": "getblock.io"
}

Response Parameters

FieldTypeDescription
result.blockHashDATA0x00...00 (zero hash) for preconfirmed receipts; real block hash for finalized
result.blockNumberQUANTITYnull for preconfirmed; block number in hex for finalized
result.statusQUANTITY0x1 = success, 0x0 = reverted
result.gasUsedQUANTITYActual gas consumed
result.effectiveGasPriceQUANTITYEffective gas price paid
result.logsarray of LogEvent logs emitted during execution

Use Cases

  • Wallet UIs showing preconfirmed transaction success within 200ms of submission
  • Polling for confirmed inclusion at 200ms cadence instead of 2s
  • Distinguishing 'transaction preconfirmed' vs 'transaction finalized' UX states
  • Detecting transaction revert or success before block seal

Error Handling

Status CodeError MessageCause
403ForbiddenMissing or invalid <ACCESS-TOKEN>
-32602Invalid paramsRequest parameters are missing or malformed
-32603Internal errorServer-side error while processing the request
429Too Many RequestsRate limit exceeded for your plan

SDK Integration

javascriptimport { ethers } from 'ethers';

const provider = new ethers.JsonRpcProvider('https://shared.eu-central-1.getblock.io/<ACCESS-TOKEN>/');

// Generic JSON-RPC call — 'pending' returns Flashblocks-preconfirmed state:
const result = await provider.send('eth_getBlockReceipts', ["pending"]);
console.log(result);

// Many standard methods have typed wrappers on ethers Provider that accept 'pending':
javascriptimport { createPublicClient, http } from 'viem';

const client = createPublicClient({
    transport: http('https://shared.eu-central-1.getblock.io/<ACCESS-TOKEN>/')
});

// viem's read methods accept blockTag: 'pending' for Flashblocks-preconfirmed state:
const result = await client.request({
    method: 'eth_getBlockReceipts',
    params: ["pending"]
});
console.log(result);