From 748209913806a75f49492abf1796deb5d06d11d9 Mon Sep 17 00:00:00 2001 From: RickiNano <81099017+RickiNano@users.noreply.github.com> Date: Tue, 9 Apr 2024 22:50:27 +0200 Subject: [PATCH] election_statistics documentation --- docs/commands/rpc-protocol.md | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/docs/commands/rpc-protocol.md b/docs/commands/rpc-protocol.md index dad5d260f..ec57a202c 100644 --- a/docs/commands/rpc-protocol.md +++ b/docs/commands/rpc-protocol.md @@ -1689,6 +1689,35 @@ Derive deterministic keypair from **seed** based on **index** --- +### election_statistics +_version 27.0+_ + +Returns the number of each election type, the maximum and average election age from Active Election Container (AEC). + +Values in `max_election_age` and `average_election_age` are in milliseconds. + +**Request:** +```json +{ + "action": "election_statistics" +} +``` +**Response sample:** +```json +{ + "normal": "152", + "priority": "1", + "hinted": "0", + "optimistic": "19", + "total": "172", + "aec_utilization_percentage": "3.42", + "max_election_age": "5493", + "average_election_age": "421" +} +``` + +--- + ### epoch_upgrade _enable_control required, version 20.0+_