diff --git a/silkworm/rpc/json_rpc/specification.json b/silkworm/rpc/json_rpc/specification.json index dc52366fe9..6f36c13ed9 100644 --- a/silkworm/rpc/json_rpc/specification.json +++ b/silkworm/rpc/json_rpc/specification.json @@ -10,6 +10,143 @@ "version": "0.0.0" }, "methods": [ + { + "name": "debug_accountRange", + "summary": "Enumerates all accounts at a given block with paging capability.", + "params": [ + { + "name": "Block", + "required": true, + "schema": { + "title": "Block number or tag", + "oneOf": [ + { + "title": "Block number", + "type": "string", + "pattern": "^0x([1-9a-f]+[0-9a-f]*|0)$" + }, + { + "title": "Block tag", + "type": "string", + "enum": [ + "earliest", + "finalized", + "safe", + "latest", + "pending" + ], + "description": "`earliest`: The lowest numbered block the client has available; `finalized`: The most recent crypto-economically secure block, cannot be re-orged outside of manual intervention driven by community coordination; `safe`: The most recent block that is safe from re-orgs under honest majority and certain synchronicity assumptions; `latest`: The most recent block in the canonical chain observed by the client, this block may be re-orged out of the canonical chain even under healthy/normal conditions; `pending`: A sample next block built by the client on top of `latest` and containing the set of transactions usually taken from local mempool. Before the merge transition is finalized, any call querying for `finalized` or `safe` block MUST be responded to with `-39001: Unknown block` error" + } + ] + } + }, + { + "name": "Hashed addresses", + "required": true, + "schema": { + "type": "array", + "items": { + "title": "32 hex encoded bytes", + "type": "string", + "pattern": "^0x[0-9a-f]{0,64}$" + } + } + }, + { + "name": "Maximum results", + "required": true, + "schema": { + "items": { + "title": "hex encoded 64 bit unsigned integer", + "type": "string", + "pattern": "^0x([1-9a-f]+[0-9a-f]*|0)$" + } + } + }, + { + "name": "No Code", + "required": true, + "schema": { + "type": "boolean" + } + }, + { + "name": "No Storage", + "required": true, + "schema": { + "type": "boolean" + } + }, + { + "name": "No preimages", + "required": true, + "schema": { + "type": "boolean" + } + } + ], + "result": { + "name": "DumpAccounts", + "schema": { + "title": "Dumped Accounts", + "type": "object", + "required": [ + "root", + "accounts", + "next" + ], + "additionalProperties": false, + "properties": { + "root": { + "title": "root", + "type": "string", + "pattern": "^0x[0-9a-f]{64}$" + }, + "accounts": { + "title": "accounts", + "type": "object", + "required": [ + "balance", + "nonce" + ], + "additionalProperties": false, + "properties": { + "address": { + "title": "balance", + "type": "string", + "pattern": "^0x([1-9a-f]+[0-9a-f]{0,63})|0$" + }, + "nonce": { + "title": "nonce", + "type": "string", + "pattern": "^0x([1-9a-f]+[0-9a-f]*|0)$" + }, + "root": { + "title": "storageHash", + "type": "string", + "pattern": "^0x[0-9a-f]{64}$" + }, + "codeHash": { + "title": "codeHash", + "type": "string", + "pattern": "^0x[0-9a-f]{64}$" + }, + "code": { + "title": "code", + "type": "string", + "pattern": "^0x[0-9a-f]*$" + } + } + }, + "next": { + "title": "next", + "type": "string", + "pattern": "^(?:[A-Za-z0-9+\\/]{4})*(?:[A-Za-z0-9+\\/]{4}|[A-Za-z0-9+\\/]{3}=|[A-Za-z0-9+\\/]{2}={2})$" + } + } + } + } + }, { "name": "debug_getBadBlocks", "summary": "Returns an array of recent bad blocks that the client has seen on the network.",