【发布时间】:2022-11-10 12:09:30
【问题描述】:
我的任务是列出所有验证者及其帐户地址。这是 RPC,它可以列出所有验证器,https://buf.build/cosmos/cosmos-sdk/docs/main:cosmos.staking.v1beta1#cosmos.staking.v1beta1.Query.Validators。验证器消息原型如下。我的问题是我如何获得验证者的账户地址,它没有账户地址。有什么建议吗?
message Validator {
// operator_address defines the address of the validator's operator; bech encoded in JSON.
string operator_address = 1;
// consensus_pubkey is the consensus public key of the validator, as a Protobuf Any.
google.protobuf.Any consensus_pubkey = 2;
// jailed defined whether the validator has been jailed from bonded status or not.
bool jailed = 3;
// status is the validator status (bonded/unbonding/unbonded).
BondStatus status = 4;
// tokens define the delegated tokens (incl. self-delegation).
string tokens = 5;
// delegator_shares defines total shares issued to a validator's delegators.
string delegator_shares = 6;
// description defines the description terms for the validator.
Description description = 7;
// unbonding_height defines, if unbonding, the height at which this validator has begun unbonding.
int64 unbonding_height = 8;
// unbonding_time defines, if unbonding, the min time for the validator to complete unbonding.
google.protobuf.Timestamp unbonding_time = 9;
// commission defines the commission parameters.
Commission commission = 10;
// min_self_delegation is the validator's self declared minimum self delegation.
string min_self_delegation = 11;
}
【问题讨论】:
标签: go cosmos-sdk