Docs

rollup_getInfo - Get Rollup Information

Optimism compatibility note for rollup_getInfo. Dwellir's public Optimism endpoints do not expose rollup metadata on the shared archive surface.

Dwellir's public Optimism endpoints do not expose Optimism rollup metadata on the shared archive surface. A live call to rollup_getInfo returns -32601.

When to Use This Method

Use this page when you need to confirm that a public Dwellir Optimism endpoint does not expose rollup metadata. For fee and chain checks, use standard Ethereum JSON-RPC methods instead.

Live Response

JSON
{
  "jsonrpc": "2.0",
  "id": 1,
  "error": {
    "code": -32601,
    "message": "Method not found"
  }
}

Fallback Check

JavaScript
import { JsonRpcProvider } from 'ethers';

const provider = new JsonRpcProvider('https://api-optimism-mainnet-archive.n.dwellir.com/YOUR_API_KEY');

async function supportsRollupInfo() {
  try {
    await provider.send('rollup_getInfo', []);
    return true;
  } catch (error) {
    if (error?.code === -32601) {
      return false;
    }
    throw error;
  }
}

console.log('Rollup metadata available:', await supportsRollupInfo());

Supported Alternatives

  • Use eth_chainId to confirm you are connected to Optimism mainnet or Sepolia.
  • Use eth_gasPrice and eth_estimateGas for standard transaction pricing.
  • Use the Optimism documentation if you need mode, synced_l1, safe_l2, or unsafe_l2.

Need help? Contact our support team or check the Optimism documentation.