Documentation index

getEpochSchedule

Returns the epoch schedule information from the cluster's genesis configuration. This includes the number of slots per epoch, the leader schedule slot offset, and whether epochs start short and grow. This data is static for a given cluster and is useful for calculating epoch boundaries, predicting when epochs will change, and understanding the timing of stake activation and reward distribution.

Parameters

This method does not accept any parameters.

Response

Returns an object:

FieldTypeDescription
slotsPerEpochu64Maximum number of slots in each epoch
leaderScheduleSlotOffsetu64Number of slots before beginning of an epoch to calculate a leader schedule for that epoch
warmupboolWhether epochs start short and grow
firstNormalEpochu64First normal-length epoch (after warmup)
firstNormalSlotu64First slot of firstNormalEpoch

Code Examples

cURL

Terminal
curl http://88.216.36.108:7999 -X POST -H "Content-Type: application/json" -d '{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "getEpochSchedule",
  "params": []
}'

TypeScript

TypeScript
const response = await fetch("http://88.216.36.108:7999", {
  method: "POST",
  headers: { "Content-Type": "application/json" },
  body: JSON.stringify({
    jsonrpc: "2.0",
    id: 1,
    method: "getEpochSchedule",
    params: []
  }),
});
const { result } = await response.json();
console.log("Slots per epoch:", result.slotsPerEpoch);

Python

Python
import requests

response = requests.post("http://88.216.36.108:7999", json={
    "jsonrpc": "2.0",
    "id": 1,
    "method": "getEpochSchedule",
    "params": []
})
result = response.json()["result"]
print(f"Slots per epoch: {result['slotsPerEpoch']}")

Rust

Rust
use reqwest::Client;
use serde_json::json;

#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
    let client = Client::new();
    let res = client.post("http://88.216.36.108:7999")
        .json(&json!({
            "jsonrpc": "2.0",
            "id": 1,
            "method": "getEpochSchedule",
            "params": []
        }))
        .send().await?
        .text().await?;
    println!("{}", res);
    Ok(())
}

Example Response

JSON
{
  "jsonrpc": "2.0",
  "result": {
    "slotsPerEpoch": 432000,
    "leaderScheduleSlotOffset": 432000,
    "warmup": false,
    "firstNormalEpoch": 0,
    "firstNormalSlot": 0
  },
  "id": 1
}