Documentation
¶
Index ¶
- Constants
- type GetBlockchainIDArgs
- type GetBlockchainIDReply
- type GetNetworkIDReply
- type GetNetworkNameReply
- type GetNodeIDReply
- type GetNodeIPReply
- type GetNodeVersionReply
- type GetTxFeeResponse
- type GetVMsReply
- type IsBootstrappedArgs
- type IsBootstrappedResponse
- type LP
- type LPsReply
- type Peer
- type PeersArgs
- type PeersReply
- type ProofOfPossession
- type Service
- type UptimeResponse
Constants ¶
const ( MethodGetNodeVersion = "info.getNodeVersion" MethodGetNodeID = "info.getNodeID" MethodGetNodeIP = "info.getNodeIP" MethodGetNetworkID = "info.getNetworkID" MethodGetNetworkName = "info.getNetworkName" MethodGetBlockchainID = "info.getBlockchainID" MethodPeers = "info.peers" MethodIsBootstrapped = "info.isBootstrapped" MethodUpgrades = "info.upgrades" MethodUptime = "info.uptime" MethodLps = "info.lps" MethodGetTxFee = "info.getTxFee" MethodGetVMs = "info.getVMs" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GetBlockchainIDArgs ¶
type GetBlockchainIDArgs struct {
Alias string `json:"alias"`
}
GetBlockchainIDArgs are the arguments for calling GetBlockchainID.
type GetBlockchainIDReply ¶
GetBlockchainIDReply are the results from calling GetBlockchainID.
type GetNetworkIDReply ¶
GetNetworkIDReply are the results from calling GetNetworkID.
type GetNetworkNameReply ¶
type GetNetworkNameReply struct {
NetworkName string `json:"networkName"`
}
GetNetworkNameReply is the result from calling GetNetworkName.
type GetNodeIDReply ¶
type GetNodeIDReply struct {
NodeID ids.NodeID `json:"nodeID"`
NodePOP *ProofOfPossession `json:"nodePOP"`
}
GetNodeIDReply are the results from calling GetNodeID.
type GetNodeIPReply ¶
GetNodeIPReply are the results from calling GetNodeIP.
type GetNodeVersionReply ¶
type GetNodeVersionReply struct {
Version string `json:"version"`
DatabaseVersion string `json:"databaseVersion"`
RPCProtocolVersion types.Uint32 `json:"rpcProtocolVersion"`
GitCommit string `json:"gitCommit"`
VMVersions map[string]string `json:"vmVersions"`
}
GetNodeVersionReply are the results from calling GetNodeVersion.
type GetTxFeeResponse ¶
type GetTxFeeResponse struct {
TxFee types.Uint64 `json:"txFee"`
CreateAssetTxFee types.Uint64 `json:"createAssetTxFee"`
CreateNetworkTxFee types.Uint64 `json:"createNetworkTxFee"`
TransformChainTxFee types.Uint64 `json:"transformChainTxFee"`
CreateChainTxFee types.Uint64 `json:"createChainTxFee"`
AddNetworkValidatorFee types.Uint64 `json:"addNetworkValidatorFee"`
AddNetworkDelegatorFee types.Uint64 `json:"addNetworkDelegatorFee"`
}
GetTxFeeResponse are the results from calling GetTxFee.
type GetVMsReply ¶
GetVMsReply contains the response metadata for GetVMs.
type IsBootstrappedArgs ¶
type IsBootstrappedArgs struct {
Chain string `json:"chain"`
}
IsBootstrappedArgs are the arguments for calling IsBootstrapped.
type IsBootstrappedResponse ¶
type IsBootstrappedResponse struct {
IsBootstrapped bool `json:"isBootstrapped"`
}
IsBootstrappedResponse are the results from calling IsBootstrapped.
type LP ¶
type LP struct {
SupportWeight types.Uint64 `json:"supportWeight"`
Supporters set.Set[ids.NodeID] `json:"supporters"`
ObjectWeight types.Uint64 `json:"objectWeight"`
Objectors set.Set[ids.NodeID] `json:"objectors"`
AbstainWeight types.Uint64 `json:"abstainWeight"`
}
LP is information about an LP proposal.
type PeersReply ¶
PeersReply are the results from calling Peers.
type ProofOfPossession ¶
type ProofOfPossession struct {
PublicKey string `json:"publicKey"`
ProofOfPossession string `json:"proofOfPossession"`
}
ProofOfPossession is a JSON-friendly representation of a BLS PoP.
type Service ¶
type Service interface {
GetNodeVersion(ctx context.Context) (*GetNodeVersionReply, error)
GetNodeID(ctx context.Context) (*GetNodeIDReply, error)
GetNodeIP(ctx context.Context) (*GetNodeIPReply, error)
GetNetworkID(ctx context.Context) (*GetNetworkIDReply, error)
GetNetworkName(ctx context.Context) (*GetNetworkNameReply, error)
GetBlockchainID(ctx context.Context, args *GetBlockchainIDArgs) (*GetBlockchainIDReply, error)
Peers(ctx context.Context, args *PeersArgs) (*PeersReply, error)
IsBootstrapped(ctx context.Context, args *IsBootstrappedArgs) (*IsBootstrappedResponse, error)
Upgrades(ctx context.Context) (*map[string]any, error)
Uptime(ctx context.Context) (*UptimeResponse, error)
Lps(ctx context.Context) (*LPsReply, error)
GetTxFee(ctx context.Context) (*GetTxFeeResponse, error)
GetVMs(ctx context.Context) (*GetVMsReply, error)
}
Service defines the info API contract.