github.com/ava-labs/avalanchego@v1.11.11/proto/validatorstate/validator_state.proto (about)

     1  syntax = "proto3";
     2  
     3  package validatorstate;
     4  
     5  import "google/protobuf/empty.proto";
     6  
     7  option go_package = "github.com/ava-labs/avalanchego/proto/pb/validatorstate";
     8  
     9  service ValidatorState {
    10    // GetMinimumHeight returns the minimum height of the blocks in the optimal
    11    // proposal window.
    12    rpc GetMinimumHeight(google.protobuf.Empty) returns (GetMinimumHeightResponse);
    13    // GetCurrentHeight returns the current height of the P-chain.
    14    rpc GetCurrentHeight(google.protobuf.Empty) returns (GetCurrentHeightResponse);
    15    // GetSubnetID returns the subnetID of the provided chain.
    16    rpc GetSubnetID(GetSubnetIDRequest) returns (GetSubnetIDResponse);
    17    // GetValidatorSet returns the weights of the nodeIDs for the provided
    18    // subnet at the requested P-chain height.
    19    rpc GetValidatorSet(GetValidatorSetRequest) returns (GetValidatorSetResponse);
    20  }
    21  
    22  message GetMinimumHeightResponse {
    23    uint64 height = 1;
    24  }
    25  
    26  message GetCurrentHeightResponse {
    27    uint64 height = 1;
    28  }
    29  
    30  message GetSubnetIDRequest {
    31    bytes chain_id = 1;
    32  }
    33  
    34  message GetSubnetIDResponse {
    35    bytes subnet_id = 1;
    36  }
    37  
    38  message GetValidatorSetRequest {
    39    uint64 height = 1;
    40    bytes subnet_id = 2;
    41  }
    42  
    43  message Validator {
    44    bytes node_id = 1;
    45    uint64 weight = 2;
    46    bytes public_key = 3;
    47  }
    48  
    49  message GetValidatorSetResponse {
    50    repeated Validator validators = 1;
    51  }