clique namespace
clique_discard
This method drops a currently running proposal. The signer will not cast further votes (either for or against) the address.
- Parameters
- Request
- Response
signer
: string (address)
curl localhost:8545 \
-X POST \
-H "Content-Type: application/json" \
--data '{
"jsonrpc": "2.0",
"id": 0,
"method": "clique_discard",
"params": [signer]
}'
{
"jsonrpc": "2.0",
"id": 0,
"result": result
}
result
: boolean
clique_getBlockSigner
Retrieves the signer of the block with the given hash. Returns error of a block with the given hash does not exist.
- Parameters
- Request
- Response
hash
: string (hash)
curl localhost:8545 \
-X POST \
-H "Content-Type: application/json" \
--data '{
"jsonrpc": "2.0",
"id": 0,
"method": "clique_getBlockSigner",
"params": [hash]
}'
{
"jsonrpc": "2.0",
"id": 0,
"result": result
}
result
: string (address)
clique_getSigners
Retrieves the list of authorized signers.
- Request
- Response
curl localhost:8545 \
-X POST \
-H "Content-Type: application/json" \
--data '{
"jsonrpc": "2.0",
"id": 0,
"method": "clique_getSigners",
"params": []
}'
{
"jsonrpc": "2.0",
"id": 0,
"result": result
}
result
: array of string (address)
clique_getSignersAnnotated
Retrieves the list of authorized signers but with signer names instead of addresses
- Request
- Response
curl localhost:8545 \
-X POST \
-H "Content-Type: application/json" \
--data '{
"jsonrpc": "2.0",
"id": 0,
"method": "clique_getSignersAnnotated",
"params": []
}'
{
"jsonrpc": "2.0",
"id": 0,
"result": result
}
result
: array of string
clique_getSignersAtHash
Retrieves the list of authorized signers at the specified block by hash.
- Parameters
- Request
- Response
hash
: string (hash)
curl localhost:8545 \
-X POST \
-H "Content-Type: application/json" \
--data '{
"jsonrpc": "2.0",
"id": 0,
"method": "clique_getSignersAtHash",
"params": [hash]
}'
{
"jsonrpc": "2.0",
"id": 0,
"result": result
}
result
: array of string (address)
clique_getSignersAtHashAnnotated
Retrieves the list of authorized signers at the specified block by hash but with signer names instead of addresses
- Parameters
- Request
- Response
hash
: string (hash)
curl localhost:8545 \
-X POST \
-H "Content-Type: application/json" \
--data '{
"jsonrpc": "2.0",
"id": 0,
"method": "clique_getSignersAtHashAnnotated",
"params": [hash]
}'
{
"jsonrpc": "2.0",
"id": 0,
"result": result
}
result
: array of string
clique_getSignersAtNumber
Retrieves the list of authorized signers at the specified block by block number.
- Parameters
- Request
- Response
number
: string (hex integer)
curl localhost:8545 \
-X POST \
-H "Content-Type: application/json" \
--data '{
"jsonrpc": "2.0",
"id": 0,
"method": "clique_getSignersAtNumber",
"params": [number]
}'
{
"jsonrpc": "2.0",
"id": 0,
"result": result
}
result
: array of string (address)
clique_getSnapshot
Retrieves a snapshot of all clique state at a given block.
- Request
- Response
curl localhost:8545 \
-X POST \
-H "Content-Type: application/json" \
--data '{
"jsonrpc": "2.0",
"id": 0,
"method": "clique_getSnapshot",
"params": []
}'
{
"jsonrpc": "2.0",
"id": 0,
"result": result
}
result
: object
hash
: string (hash)number
: string (hex integer)signerLimit
: string (hex integer)signers
: map of string (hex integer)
clique_getSnapshotAtHash
Retrieves the state snapshot at a given block.
- Parameters
- Request
- Response
hash
: string (hash)
curl localhost:8545 \
-X POST \
-H "Content-Type: application/json" \
--data '{
"jsonrpc": "2.0",
"id": 0,
"method": "clique_getSnapshotAtHash",
"params": [hash]
}'
{
"jsonrpc": "2.0",
"id": 0,
"result": result
}
result
: object
hash
: string (hash)number
: string (hex integer)signerLimit
: string (hex integer)signers
: map of string (hex integer)
clique_produceBlock
Forces Clique block producer to produce a new block
- Parameters
- Request
- Response
parentHash
: string (hash)
curl localhost:8545 \
-X POST \
-H "Content-Type: application/json" \
--data '{
"jsonrpc": "2.0",
"id": 0,
"method": "clique_produceBlock",
"params": [parentHash]
}'
{
"jsonrpc": "2.0",
"id": 0,
"result": result
}
result
: boolean
clique_propose
Adds a new authorization proposal that the signer will attempt to push through. If the vote
parameter is true, the local signer votes for the given address to be included in the set of authorized signers. With vote
set to false, the signer is against the address.
- Parameters
- Request
- Response
-
signer
: string (address) -
vote
: boolean
curl localhost:8545 \
-X POST \
-H "Content-Type: application/json" \
--data '{
"jsonrpc": "2.0",
"id": 0,
"method": "clique_propose",
"params": [signer, vote]
}'
{
"jsonrpc": "2.0",
"id": 0,
"result": result
}
result
: boolean