In the testnet, I deployed a token contract (address is 0xe76b0fb0f4b43200831ac72303c00ecab7be2e6acba86899e2627154017697b9
) and minted an asset using the contract (AssetId is 0xaaace66e1fa88bccfddfefe172c1cd2e8187ca435fd49fce0cd3101450a788f8
). I can observe the asset in Fuel Wallet, but I can’t read the name and symbol I set in the contract.
I use the fuel typescript SDK to read these token information normally:
const assetAddress = Address.fromAddressOrString("0xaaace66e1fa88bccfddfefe172c1cd2e8187ca435fd49fce0cd3101450a788f8")
const assetId: AssetId = {
bits: assetAddress.toB256(),
};
const { value } = await contract.functions.decimals(assetId).simulate();
console.log(value)