Metode RPC isBlockhashValid

Mengembalikan apakah sebuah blockhash masih valid atau tidak

Batasan Versi

Metode ini hanya tersedia di solana-core v1.9 atau yang lebih baru. Silakan gunakan getFeeCalculatorForBlockhash untuk solana-core v1.8 dan di bawahnya.

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

params

stringrequired

Blockhash dari blok yang akan dievaluasi, sebagai string yang dikodekan base-58

objectoptional

Objek konfigurasi yang berisi bidang-bidang berikut:

result

Response
{
"jsonrpc": "2.0",
"result": {
"context": { "slot": 2483 },
"value": false
},
"id": 45
}
bool

Apakah blockhash masih valid

Is this page helpful?