The client to use. AvalancheCoreClient
The subnet ID GetStakingAssetIDParameters
The staking asset ID. GetStakingAssetIDReturnType
import { createAvalancheCoreClient } from '@avalanche-sdk/client'
import { avalanche } from '@avalanche-sdk/client/chains'
import { getStakingAssetID } from '@avalanche-sdk/client/methods/pChain'
const client = createAvalancheCoreClient({
chain: avalanche,
transport: {
type: "http",
url: "<url>",
},
})
const stakingAssetID = await getStakingAssetID(client, {
subnetID: "11111111111111111111111111111111LpoYY"
})
Get the staking asset ID for a subnet.