It used to be possible to get balance of a specific token using the following SDK function:
options = { chain: "mumbai", tokenAddress: myTokenAddress};
await Moralis.Web3.getERC20(options)
The function still works, However I donโt see this function in the documentation page https://docs.moralis.io/moralis-server/web3-sdk/account
The closest thing I see on there is the following:
await Moralis.Web3API.account.getTokenBalances(options);
But this function gets balances for ALL tokens. If i include the tokenAddress
, value in options
, it ignores that value.
Given that the SDK was updated a few days ago, does this mean that the Moralis.Web3.getERC20()
function has been deprecated? Or will it continue to get supported?