import { Avalanche } from "@avalanche-sdk/chainkit";
const avalanche = new Avalanche({
network: "mainnet",
});
async function run() {
const result = await avalanche.data.primaryNetwork.getNetworkDetails({});
console.log(result);
}
run();{
"validatorDetails": {
"validatorCount": 123,
"totalAmountStaked": "<string>",
"estimatedAnnualStakingReward": "<string>",
"stakingDistributionByVersion": [
{
"version": "<string>",
"amountStaked": "<string>",
"validatorCount": 123
}
],
"stakingRatio": "<string>"
},
"delegatorDetails": {
"delegatorCount": 123,
"totalAmountStaked": "<string>"
}
}Gets network details such as validator and delegator stats.
import { Avalanche } from "@avalanche-sdk/chainkit";
const avalanche = new Avalanche({
network: "mainnet",
});
async function run() {
const result = await avalanche.data.primaryNetwork.getNetworkDetails({});
console.log(result);
}
run();{
"validatorDetails": {
"validatorCount": 123,
"totalAmountStaked": "<string>",
"estimatedAnnualStakingReward": "<string>",
"stakingDistributionByVersion": [
{
"version": "<string>",
"amountStaked": "<string>",
"validatorCount": 123
}
],
"stakingRatio": "<string>"
},
"delegatorDetails": {
"delegatorCount": 123,
"totalAmountStaked": "<string>"
}
}Documentation Index
Fetch the complete documentation index at: https://developers.avacloud.io/llms.txt
Use this file to discover all available pages before exploring further.
Api keys provide higher access to rate limits. To obtain an api key, sign up for an account at https://avacloud.io/.
Either mainnet or testnet/fuji.
mainnet, fuji, testnet Was this page helpful?