Méthode RPC getBlockHeight

Renvoie la hauteur de bloc actuelle du nœud

$ curl https://api.devnet.solana.com -s -X \
> POST -H "Content-Type: application/json" -d '
> {
> "jsonrpc": "2.0",
> "id": 1,
> "method": "getBlockHeight",
> "params": [
> {
> "commitment": "finalized"
> }
> ]
> }
> '

params

objectoptional

Objet de configuration

result

Response
{
"jsonrpc": "2.0",
"result": 1233,
"id": 1
}
u64

Hauteur de bloc actuelle.

Is this page helpful?