info

package
v1.22.88 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewService

func NewService(
	parameters Parameters,
	log log.Logger,
	validators validators.Manager,
	chainManager chains.Manager,
	vmManager vms.Manager,
	myIP *utils.Atomic[netip.AddrPort],
	network network.Network,

) (http.Handler, error)

Types

type Info

type Info struct {
	Parameters
	// contains filtered or unexported fields
}

Info is the API service for unprivileged info on a node

func (*Info) GetBlockchainID

func (i *Info) GetBlockchainID(_ *http.Request, args *apiinfo.GetBlockchainIDArgs, reply *apiinfo.GetBlockchainIDReply) error

GetBlockchainID returns the blockchain ID that resolves the alias that was supplied

func (*Info) GetNetworkID

func (i *Info) GetNetworkID(_ *http.Request, _ *struct{}, reply *apiinfo.GetNetworkIDReply) error

GetNetworkID returns the network ID this node is running on

func (*Info) GetNetworkName

func (i *Info) GetNetworkName(_ *http.Request, _ *struct{}, reply *apiinfo.GetNetworkNameReply) error

GetNetworkName returns the network name this node is running on

func (*Info) GetNodeID

func (i *Info) GetNodeID(_ *http.Request, _ *struct{}, reply *apiinfo.GetNodeIDReply) error

GetNodeID returns the node ID of this node

func (*Info) GetNodeIP

func (i *Info) GetNodeIP(_ *http.Request, _ *struct{}, reply *apiinfo.GetNodeIPReply) error

GetNodeIP returns the IP of this node

func (*Info) GetNodeVersion

func (i *Info) GetNodeVersion(_ *http.Request, _ *struct{}, reply *apiinfo.GetNodeVersionReply) error

GetNodeVersion returns the version this node is running

func (*Info) GetTxFee

func (i *Info) GetTxFee(_ *http.Request, _ *struct{}, reply *apiinfo.GetTxFeeResponse) error

GetTxFee returns the transaction fee in nLUX.

func (*Info) GetVMs

func (i *Info) GetVMs(r *http.Request, _ *struct{}, reply *apiinfo.GetVMsReply) error

GetVMs lists the virtual machines installed on the node

func (*Info) IsBootstrapped

func (i *Info) IsBootstrapped(_ *http.Request, args *apiinfo.IsBootstrappedArgs, reply *apiinfo.IsBootstrappedResponse) error

IsBootstrapped returns nil and sets [reply.IsBootstrapped] == true iff [args.Chain] exists and is done bootstrapping Returns an error if the chain doesn't exist

func (*Info) Lps

func (i *Info) Lps(_ *http.Request, _ *struct{}, reply *apiinfo.LPsReply) error

func (*Info) Peers

func (i *Info) Peers(_ *http.Request, args *apiinfo.PeersArgs, reply *apiinfo.PeersReply) error

Peers returns the list of current validators

func (*Info) Upgrades

func (i *Info) Upgrades(_ *http.Request, _ *struct{}, reply *upgrade.Config) error

Upgrades returns the upgrade schedule this node is running.

func (*Info) Uptime

func (i *Info) Uptime(_ *http.Request, _ *struct{}, reply *apiinfo.UptimeResponse) error

type Parameters

type Parameters struct {
	Version   *version.Application
	NodeID    ids.NodeID
	NodePOP   *signer.ProofOfPossession
	NetworkID uint32
	VMManager vms.Manager
	Upgrades  upgrade.Config

	TxFee            uint64
	CreateAssetTxFee uint64
}

Jump to

Keyboard shortcuts

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