Skip to main content

getBlockProduction RPC Method

Returns recent block production information from the current or previous epoch.

Parameters

object optional
Configuration object containing the following fields:
commitment string optional
The level of commitment desired when querying state
identity string optional
Only return results for this validator identity (base-58 encoded)
range object optional
Slot range to return block production for
  • firstSlot: <u64> - first slot to return block production information for (inclusive)
  • lastSlot: <u64> optional - last slot to return block production information for (inclusive)
    • If not provided, defaults to the highest slot
  • If parameter not provided, defaults to current epoch

Code Sample

Response

Result Details

The result will be an RpcResponse JSON object with value equal to:
  • byIdentity: <object>
    • A dictionary of validator identities (base-58 encoded strings)
    • Each value is a two-element array:
      • First element: number of leader slots
      • Second element: number of blocks produced
  • range: <object>
    • firstSlot: <u64> - first slot of the block production information (inclusive)
    • lastSlot: <u64> - last slot of block production information (inclusive)