getBlockhash

Requisição JSON-RPC

{
"jsonrpc": "2.0",
"id": 1,
"method": "getBlockhash",
"params": []
}

Resposta JSON-RPC

{
"jsonrpc": "2.0",
"id": 1,
"result": {
"blockhash": "base58Blockhash"
}
}

Exemplo cURL

curl -X POST http://localhost:8080 \
-H "Content-Type: application/json" \
-d '{"jsonrpc":"2.0","id":1,"method":"getBlockhash","params":[]}'

SDK TypeScript

const { blockhash } = await client.getBlockhash();
console.log("Current blockhash:", blockhash);

Is this page helpful?

Índice

Editar Página

Gerenciado por

© 2026 Fundação Solana.
Todos os direitos reservados.
Conecte-se
  • Blog