blockchain

package
v1.22.9 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 20, 2026 License: BSD-3-Clause Imports: 16 Imported by: 0

Documentation

Overview

Package blockchain provides utilities for blockchain configuration and deployment.

Package blockchain provides helper functions for blockchain operations including peer management, URI handling, and blockchain state queries.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConvertToBLSProofOfPossession

func ConvertToBLSProofOfPossession(publicKey, proofOfPossesion string) (signer.ProofOfPossession, error)

ConvertToBLSProofOfPossession converts public key and proof of possession strings to a ProofOfPossession struct.

func GetAggregatorExtraPeers

func GetAggregatorExtraPeers(
	app *application.Lux,
	clusterName string,
) ([]apiinfo.Peer, error)

GetAggregatorExtraPeers returns a list of peers for the aggregator from the cluster.

func GetAggregatorNetworkUris

func GetAggregatorNetworkUris(app *application.Lux, clusterName string) ([]string, error)

GetAggregatorNetworkUris returns network URIs for the specified cluster.

func GetBlockchainTimestamp

func GetBlockchainTimestamp(network models.Network) (time.Time, error)

GetBlockchainTimestamp returns the current timestamp from the blockchain.

func GetChain added in v1.22.9

func GetChain(chainID ids.ID, network models.Network) (interface{}, error)

GetChain returns chain validators information

func GetChainIDFromBlockchainID added in v1.22.9

func GetChainIDFromBlockchainID(blockchainID ids.ID, network models.Network) (ids.ID, error)

GetChainIDFromBlockchainID returns the chain ID that validates the given blockchain.

func GetKeyForChangeOwner

func GetKeyForChangeOwner(app *application.Lux, network models.Network) (string, error)

GetKeyForChangeOwner prompts for and returns a key address for change ownership.

func PromptValidatorBalance

func PromptValidatorBalance(app *application.Lux, availableBalance float64, prompt string) (float64, error)

PromptValidatorBalance prompts the user to enter a validator balance amount.

func UpdatePChainHeight

func UpdatePChainHeight(
	title string,
) error

UpdatePChainHeight displays a progress bar while waiting for P-Chain height update.

func UrisToPeers

func UrisToPeers(uris []string) ([]apiinfo.Peer, error)

UrisToPeers converts a list of node URIs to peer information.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL