getBlockProduction RPC 方法
返回当前或前一个 epoch 的最近区块生产信息。
$ curl https://api.devnet.solana.com -s -X \> POST -H "Content-Type: application/json" -d '> {> "jsonrpc": "2.0",> "id": 1,> "method": "getBlockProduction",> "params": [> {> "commitment": "finalized"> }> ]> }> '
params
objectoptional
配置对象
result
Response
{"jsonrpc": "2.0","result": {"context": {"slot": 9887},"value": {"byIdentity": {"85iYT5RuzRTDgjyRa3cP8SYhM2j21fj7NhfJ3peu1DPr": [9888, 9886]},"range": {"firstSlot": 0,"lastSlot": 9887}}},"id": 1}
object
结果将是一个 RpcResponse JSON 对象,其值等于:
Is this page helpful?