The client to use to make the request AvalancheCoreClient
The asset ID GetCurrentSupplyParameters
The current supply. GetCurrentSupplyReturnType
import { createAvalancheCoreClient } from '@avalanche-sdk/client'
import { avalanche } from '@avalanche-sdk/client/chains'
import { getCurrentSupply } from '@avalanche-sdk/client/methods/pChain'
const client = createAvalancheCoreClient({
chain: avalanche,
transport: {
type: "http",
url: "<url>",
},
})
const supply = await getCurrentSupply(client, {
assetID: "FvwEAhmxKfeiG8SnEvq42hc6whRyY3EFYAvebMqDNDGCgxN5Z"
})
Get the current supply of an asset.