Clique module

clique_discard

This method drops a currently running proposal. The signer will not cast further votes (either for or against) the address.
Invocation
{"method":"clique_discard","params":[signer]}
Parameter
Type
Description
signer
Address
Returned type
Description
Boolean
Example request of clique_discard
1
curl --data '{"method":"clique_discard","params":[signer],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json" -X POST localhost:8545
Copied!

clique_getBlockSigner

Retrieves the signer of the block with the given hash. Returns error of a block with the given hash does not exist.
Invocation
{"method":"clique_getBlockSigner","params":[hash]}
Parameter
Type
Description
hash
Hash
Returned type
Description
Address
Example request of clique_getBlockSigner
1
curl --data '{"method":"clique_getBlockSigner","params":[hash],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json" -X POST localhost:8545
Copied!

clique_getSigners

Retrieves the list of authorized signers.
Invocation
{"method":"clique_getSigners","params":[]}
Returned type
Description
Address
Example request of clique_getSigners
1
curl --data '{"method":"clique_getSigners","params":[],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json" -X POST localhost:8545
Copied!

clique_getSignersAnnotated

Retrieves the list of authorized signers but with signer names instead of addresses
Invocation
{"method":"clique_getSignersAnnotated","params":[]}
Returned type
Description
String
Example request of clique_getSignersAnnotated
1
curl --data '{"method":"clique_getSignersAnnotated","params":[],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json" -X POST localhost:8545
Copied!

clique_getSignersAtHash

Retrieves the list of authorized signers at the specified block by hash.
Invocation
{"method":"clique_getSignersAtHash","params":[hash]}
Parameter
Type
Description
hash
Hash
Returned type
Description
Address
Example request of clique_getSignersAtHash
1
curl --data '{"method":"clique_getSignersAtHash","params":[hash],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json" -X POST localhost:8545
Copied!

clique_getSignersAtHashAnnotated

Retrieves the list of authorized signers at the specified block by hash but with signer names instead of addresses
Invocation
{"method":"clique_getSignersAtHashAnnotated","params":[hash]}
Parameter
Type
Description
hash
Hash
Returned type
Description
String
Example request of clique_getSignersAtHashAnnotated
1
curl --data '{"method":"clique_getSignersAtHashAnnotated","params":[hash],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json" -X POST localhost:8545
Copied!

clique_getSignersAtNumber

Retrieves the list of authorized signers at the specified block by block number.
Invocation
{"method":"clique_getSignersAtNumber","params":[number]}
Parameter
Type
Description
number
Quantity
Returned type
Description
Address
Example request of clique_getSignersAtNumber
1
curl --data '{"method":"clique_getSignersAtNumber","params":[number],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json" -X POST localhost:8545
Copied!

clique_getSnapshot

Retrieves a snapshot of all clique state at a given block.
Invocation
{"method":"clique_getSnapshot","params":[]}
Returned type
Description
Snapshot object
Example request of clique_getSnapshot
Objects in clique_getSnapshot
1
curl --data '{"method":"clique_getSnapshot","params":[],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json" -X POST localhost:8545
Copied!
Snapshot
Field name
Type
Number
Quantity
Hash
Hash
Signers
Array
SignerLimit
Quantity

clique_getSnapshotAtHash

Retrieves the state snapshot at a given block.
Invocation
{"method":"clique_getSnapshotAtHash","params":[hash]}
Parameter
Type
Description
hash
Hash
Returned type
Description
Snapshot object
Example request of clique_getSnapshotAtHash
Objects in clique_getSnapshotAtHash
1
curl --data '{"method":"clique_getSnapshotAtHash","params":[hash],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json" -X POST localhost:8545
Copied!
Snapshot
Field name
Type
Number
Quantity
Hash
Hash
Signers
Array
SignerLimit
Quantity

clique_produceBlock

Forces Clique block producer to produce a new block
Invocation
{"method":"clique_produceBlock","params":[parentHash]}
Parameter
Type
Description
parentHash
Hash
Returned type
Description
Boolean
Example request of clique_produceBlock
1
curl --data '{"method":"clique_produceBlock","params":[parentHash],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json" -X POST localhost:8545
Copied!

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.
Invocation
{"method":"clique_propose","params":[signer, vote]}
Parameter
Type
Description
signer
Address
vote
Boolean
Returned type
Description
Boolean
Example request of clique_propose
1
curl --data '{"method":"clique_propose","params":[signer, vote],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json" -X POST localhost:8545
Copied!
Last modified 1mo ago