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
Example request of clique_discard
curl --data '{"method":"clique_discard","params":[signer],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json" -X POST localhost:8545

See also CLI clique.discard

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
Example request of clique_getBlockSigner
curl --data '{"method":"clique_getBlockSigner","params":[hash],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json" -X POST localhost:8545

See also CLI clique.getBlockSigner

clique_getSigners

Retrieves the list of authorized signers.

Invocation

{"method":"clique_getSigners","params":[]}

This method doesn't have parameters.

Returned type

Description

Address

Example request of clique_getSigners
Example request of clique_getSigners
curl --data '{"method":"clique_getSigners","params":[],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json" -X POST localhost:8545

See also CLI clique.getSigners

clique_getSignersAnnotated

Invocation

{"method":"clique_getSignersAnnotated","params":[]}

This method doesn't have parameters.

Returned type

Description

String

Example request of clique_getSignersAnnotated
Example request of clique_getSignersAnnotated
curl --data '{"method":"clique_getSignersAnnotated","params":[],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json" -X POST localhost:8545

See also CLI clique.getSignersAnnotated

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
Example request of clique_getSignersAtHash
curl --data '{"method":"clique_getSignersAtHash","params":[hash],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json" -X POST localhost:8545

See also CLI clique.getSignersAtHash

clique_getSignersAtHashAnnotated

Invocation

{"method":"clique_getSignersAtHashAnnotated","params":[hash]}

Parameter

Type

Description

hash

Hash

Returned type

Description

String

Example request of clique_getSignersAtHashAnnotated
Example request of clique_getSignersAtHashAnnotated
curl --data '{"method":"clique_getSignersAtHashAnnotated","params":[hash],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json" -X POST localhost:8545

See also CLI clique.getSignersAtHashAnnotated

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
Example request of clique_getSignersAtNumber
curl --data '{"method":"clique_getSignersAtNumber","params":[number],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json" -X POST localhost:8545

See also CLI clique.getSignersAtNumber

clique_getSnapshot

Retrieves a snapshot of all clique state at a given block.

Invocation

{"method":"clique_getSnapshot","params":[]}

This method doesn't have parameters.

Returned type

Description

Snapshot object

Example request of clique_getSnapshot
Objects in clique_getSnapshot
Example request of clique_getSnapshot
curl --data '{"method":"clique_getSnapshot","params":[],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json" -X POST localhost:8545
Objects in clique_getSnapshot

Snapshot

Field name

Type

Number

Quantity

Hash

Hash

Signers

Array

SignerLimit

Quantity

See also CLI clique.getSnapshot

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
Example request of clique_getSnapshotAtHash
curl --data '{"method":"clique_getSnapshotAtHash","params":[hash],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json" -X POST localhost:8545
Objects in clique_getSnapshotAtHash

Snapshot

Field name

Type

Number

Quantity

Hash

Hash

Signers

Array

SignerLimit

Quantity

See also CLI clique.getSnapshotAtHash

clique_produceBlock

Invocation

{"method":"clique_produceBlock","params":[parentHash]}

Parameter

Type

Description

parentHash

Hash

Returned type

Description

Boolean

Example request of clique_produceBlock
Example request of clique_produceBlock
curl --data '{"method":"clique_produceBlock","params":[parentHash],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json" -X POST localhost:8545

See also CLI clique.produceBlock

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
Example request of clique_propose
curl --data '{"method":"clique_propose","params":[signer, vote],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json" -X POST localhost:8545

See also CLI clique.propose