Skip to content

Commit bfeb264

Browse files
doc priv_debugGetStateRoot (#680)
Signed-off-by: Alexandra Tran <[email protected]>
1 parent 721c075 commit bfeb264

File tree

1 file changed

+41
-0
lines changed

1 file changed

+41
-0
lines changed

docs/Reference/API-Methods.md

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6297,6 +6297,47 @@ For private contracts, `priv_call` is the same as [`eth_call`](#eth_call) for pu
62976297
}
62986298
```
62996299

6300+
### `priv_debugGetStateRoot`
6301+
6302+
Returns the state root of the specified privacy group at the specified block.
6303+
6304+
#### Parameters
6305+
6306+
`data` - 32-byte [privacy Group ID](../Concepts/Privacy/Privacy-Groups.md).
6307+
6308+
`quantity|tag` - Integer representing a block number or one of the string tags `latest`,
6309+
`earliest`, or `pending`, as described in
6310+
[Block Parameter](../HowTo/Interact/APIs/Using-JSON-RPC-API.md#block-parameter).
6311+
6312+
#### Returns
6313+
6314+
`result` : `data` - 32-byte state root.
6315+
6316+
!!! example
6317+
6318+
=== "curl HTTP"
6319+
6320+
```bash
6321+
curl -X POST --data '{"jsonrpc":"2.0","method":"priv_debugGetStateRoot","params":["xJdxvWOEmrs2MCkKWlgArTzWIXFfU/tmVxI3EKssVTk=","latest"],"id":1}' http://127.0.0.1:8545
6322+
```
6323+
6324+
=== "wscat WS"
6325+
6326+
```bash
6327+
{"jsonrpc":"2.0","method":"priv_debugGetStateRoot","params":["xJdxvWOEmrs2MCkKWlgArTzWIXFfU/tmVxI3EKssVTk=","latest"],"id":1}
6328+
```
6329+
6330+
=== "JSON result"
6331+
6332+
```json
6333+
{
6334+
"jsonrpc" : "2.0",
6335+
"id" : 1,
6336+
"result" : "0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421"
6337+
}
6338+
6339+
```
6340+
63006341
### `priv_distributeRawTransaction`
63016342

63026343
Distributes a signed, RLP encoded

0 commit comments

Comments
 (0)