helium_py.api.validators.Validators¶
- class helium_py.api.validators.Validators(host=None, port=None, user_agent=None, base_path=None)[source]¶
Bases:
API
Validators client class for Helium Blockchain API.
https://docs.helium.com/api/blockchain/validators
- __init__(host=None, port=None, user_agent=None, base_path=None)¶
Allow for overriding API details at instantiation.
Methods
__init__
([host, port, user_agent, base_path])Allow for overriding API details at instantiation.
all
()Yield all validators.
get_all_validator_rewards_total
(params)Return rewards totals for all validators.
Return currently elected validators.
get_elected_validators_by_election
(election_hash)Return elected validators for the provided block height.
get_elected_validators_by_height
(height)Return elected validators for the provided block height.
get_roles
(address, params)Yield all roles for provided validator address.
get_roles_counts
(address, params)Return roles counts for provided validator address.
Return stats for all validators.
get_validator_rewards
(address, params)Yield rewards information for a validator identified by validator_id.
get_validator_rewards_total
(address, params)Return rewards totals for a validator identified by validator_id.
validator_for_address
(address)Return validators for provided address.
validators_for_name
(name)Return validators identified by provided three-word animal name.
Search for validators by name.
Attributes
base_path
Return a client singleton per API.
host
port
user_agent
- get_all_validator_rewards_total(params: Optional[dict]) dict [source]¶
Return rewards totals for all validators.
- get_elected_validators_by_election(election_hash: str) List[dict] [source]¶
Return elected validators for the provided block height.
- get_elected_validators_by_height(height: int) List[dict] [source]¶
Return elected validators for the provided block height.
- get_roles(address: str, params: Optional[dict]) Generator[dict, None, None] [source]¶
Yield all roles for provided validator address.
- get_roles_counts(address: str, params: Optional[dict]) dict [source]¶
Return roles counts for provided validator address.
- get_validator_rewards(address: str, params: Optional[dict]) Generator[dict, None, None] [source]¶
Yield rewards information for a validator identified by validator_id.
- get_validator_rewards_total(address: str, params: Optional[dict]) dict [source]¶
Return rewards totals for a validator identified by validator_id.