RapidNode Docs
Back to WebsiteX/Twitter
  • Welcome
    • What is RapidNode?
  • Solana RPC Nodes
    • RapidNode RPCs Overview
    • Dedicated Nodes
      • Getting Started with Dedicated Nodes
    • Dedicated Staked Connections
    • Common Error Codes
  • RPC
    • HTTP
      • getAccountInfo
      • getBalance
      • getBlock
      • getBlockCommitment
      • getBlockHeight
      • getBlockProduction
      • getBlockTime
      • getBlocks
    • Websocket
  • Data Streaming
    • gRPC
    • Webhooks
  • Solana APIs
    • Priority Fee API
    • Enhanced Transaction API
    • Token Metadata API
  • Guides
    • RPC Proxy — Protect Your Keys
    • Sending Transactions on Solana
  • Resources
    • RapidNode Blog
    • SDKs
    • Transaction Types
    • Status Page
Powered by GitBook
On this page
  1. RPC
  2. HTTP

getBlockProduction

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

PreviousgetBlockHeightNextgetBlockTime

Last updated 4 months ago

getBlockProduction

const response = await fetch('https://mainnet.rapidnode-rpc.com/?api-key=<api-key>', {
    method: 'POST',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify({
      "jsonrpc": "2.0",
      "id": "1",
      "method": "getBlockProduction",
      "params": [
        {}
      ]
    }),
});
const data = await response.json();
{
  "jsonrpc": "2.0",
  "id": "text",
  "result": {
    "context": {
      "slot": 9887
    },
    "value": {
      "byIdentity": {
        "85iYT5RuzRTDgjyRa3cP8SYhM2j21fj7NhfJ3peu1DPr": [
          9888,
          9886
        ]

https://mainnet.rapidnode-rpc.com/?api-key=<api-key>