Skip to content
BaseHub by wbnns Updated

Rollup node RPC

Beyond the execution-layer JSON-RPC namespaces, the Base rollup node exposes its own RPC surface. The method documented here, optimism_outputAtBlock, is the one most integrators reach for: it hands back the 32-byte L2 output root for a chosen block, which is the value bridges and proof systems anchor against.

Given an L2 block number, this method returns that block’s output root together with the metadata needed to reason about it.

NameTypeDescription
blockNumberQUANTITY, 64 bitsL2 integer block number
NameTypeDescription
versionDATA, 32 BytesOutput root version number, beginning with 0
outputRootDATA, 32 BytesThe output root
blockRefObjectInstance of L2BlockRef
withdrawalStorageRootDATA, 32 BytesStorage root of the L2ToL1MessagePasser contract
stateRootDATA, 32 BytesThe state root
syncStatusObjectInstance of SyncStatus

The input and output types follow the engine API specification.

The object types referenced by the rollup node API are listed below. They extend the structures defined in the engine API specs.

  • hash: DATA, 32 Bytes
  • number: QUANTITY, 64 Bits
  • hash: DATA, 32 Bytes
  • number: QUANTITY, 64 Bits
  • parentHash: DATA, 32 Bytes
  • timestamp: QUANTITY, 64 Bits
  • hash: DATA, 32 Bytes
  • number: QUANTITY, 64 Bits
  • parentHash: DATA, 32 Bytes
  • timestamp: QUANTITY, 64 Bits
  • l1origin: BlockID
  • sequenceNumber: QUANTITY, 64 Bits - distance to first block of epoch

A point-in-time snapshot of the rollup driver’s view of both chains.