Shred Delivery and Sender are now live! Get earliest access to raw Solana data and optimized transaction sending. Learn about Shred Delivery | Learn about Sender
简体中文
返回两个插槽之间的已确认区块列表。
cURL
curl --request POST \ --url https://mainnet.helius-rpc.com/ \ --header 'Content-Type: application/json' \ --data '{ "jsonrpc": "2.0", "id": "1", "method": "getBlocks", "params": [ 5, 10, { "commitment": "finalized" } ] }'
{ "jsonrpc": "2.0", "id": "1", "result": [ 5, 6, 7, 8, 9, 10 ] }
您的 Helius API 密钥。您可以在仪表板中免费获取一个。
JSON-RPC协议版本。
2.0
"2.0"
请求的唯一标识符。
"1"
要调用的RPC方法名称。
getBlocks
"getBlocks"
方法的请求参数。
Show child attributes
成功检索到确认的区块。
与请求匹配的标识符。
在 start_slot 和 end_slot 之间确认的区块列表。
[5, 6, 7, 8, 9, 10]
此页面对您有帮助吗?