getFirstAvailableBlock

POSTBlocksAll plans

Returns the oldest block from which every later block can be retrieved with getBlock.

Try itSends a real request from your browser to the selected region.
POST
/

getFirstAvailableBlock returns the oldest block from which every later block can be retrieved with getBlock. On Blade Runner and Nexus tier plans it returns 0, the genesis block, because Cube Runner can retrieve every block since genesis from long-term storage.

On Free and Operator tier plans it returns the oldest block from which the region holds every later block, in its cache or its ledger. The value rises as old blocks are pruned. Older blocks are still returned when a cache in any region holds them.

A backward walk through getBlock history that needs every block stops at this slot. minimumLedgerSlot marks the same limit for getTransaction and getSignaturesForAddress.

PlansAll plans
FreeIncluded
OperatorIncluded
Blade RunnerIncluded
NexusIncluded

Parameters

This method takes no parameters.

Result

resultinteger

The oldest slot from which every later block can be retrieved with getBlock. 0 on Blade Runner and Nexus tier plans.

Notes

  • On Free and Operator tier plans, a getBlock request for a block that no cache, ledger or other region holds returns code -32001 with HTTP 200. The message and data.firstAvailableBlock carry this value.