Fetch information about the current epoch.
HTTP transport instance
Desired commitment level (default: "confirmed")
"confirmed"
Additional call options
Current epoch information including slot index, slots in epoch, and absolute slot
const info = await getEpochInfo(transport);console.log(`Epoch ${info.epoch}, slot index ${info.slotIndex}`); Copy
const info = await getEpochInfo(transport);console.log(`Epoch ${info.epoch}, slot index ${info.slotIndex}`);
1.0.0
Fetch information about the current epoch.