Closed yonac1 closed 7 months ago
Thanks @yonac1 for the ticket. We'll take a look and circle back.
Could you aid troubleshooting by providing your token id on tesnet. Thanks
@yonac1 how did you add the NFT Token to MetaMask?
Did it auto appear? did you used Hashscan to associate and add token?
I ask, since I was able to add an NFT Token manually using MetaMask, however when doing it trough HashScan, it indeed was added on the ERC-20 Section.
@Nana-EC this seems to be an "issue" with Hashcan and how is it adding tokens to Metamask, when adding tokens to metamask, is done using the method wallet_watchAsset
and params, see example:
type: 'ERC721', // could be ERC20 or ERC721, maybe also ERC1155
options: {
address: tokenAddress, // The address that the token is at.
symbol: tokenSymbol, // A ticker symbol or shorthand, up to 5 chars.
decimals: tokenDecimals, // The number of decimals in the token
image: tokenImage, // A string url of the token logo
},
But taking a look at the hashscan explorer, it looks like is sending always ERC20
on the type
field of the params.
see here.
Thanks @yonac1 for the ticket. We'll take a look and circle back.
Could you aid troubleshooting by providing your token id on tesnet. Thanks
Yes it is: 0.0.6751279
@yonac1 how did you add the NFT Token to MetaMask?
Did it auto appear? did you used Hashscan to associate and add token?
I ask, since I was able to add an NFT Token manually using MetaMask, however when doing it trough HashScan, it indeed was added on the ERC-20 Section.
I had to add it manually, it shown on my balance that I have 1 PBL on HashScan even though It's an NFT, I want to see it in the NFT Tab, I associate the token with ethers like this:
const provider = new ethers.providers.Web3Provider(window.ethereum, "any"); const signer = provider.getSigner(); const abi = [
function associate(),
function dissociate()`];
const nftAddress =
"0x" +
TokenId.fromString(process.env.REACT_APP_NFT_TOKEN_ID)
.toSolidityAddress()
.toString();
let txHash;
const gasLimit = ASSOCIATE_GAS_LIMIT;
const myContract = new ethers.Contract(nftAddress, abi, signer);
const associateTx = await myContract.associate({ gasLimit: gasLimit });
const associateRx = await associateTx.wait();
txHash = associateRx.transactionHash;`
When sending it to a metamask wallet which associate it in that way it doesn't get into the NFT Tab
@AlfredoG87 this is what happen when i'm try to import the NFT
Hello @yonac1, we appreciate your time and effort to open up this ticket, and sorry for this late response! Good thing this will now be my main priority.
it shown on my balance that I have 1 PBL on HashScan even though It's an NFT
On Hashscan, specifically on the Account Detail page, balances
is the section where all your tokens (both fungible and non-fungible) are displayed. The balance displayed on HashScan showing "1 PBL" indicating ownership of 1 token with the symbol PBL. By clicking on the 'PBL' symbol, you'll be directed to the Token Detail page, where you can learn more about the token, including its type (non-fungible in this case), keys, expiration, and other details.
I associate the token with ethers like this:
const provider = new ethers.providers.Web3Provider(window.ethereum, "any"); const signer = provider.getSigner();
const abi = [function associate(), function dissociate()`];
const nftAddress = "0x" + TokenId.fromString(process.env.REACT_APP_NFT_TOKEN_ID) .toSolidityAddress() .toString();
let txHash;
const gasLimit = ASSOCIATE_GAS_LIMIT;
const myContract = new ethers.Contract(nftAddress, abi, signer);
const associateTx = await myContract.associate({ gasLimit: gasLimit });
const associateRx = await associateTx.wait();
txHash = associateRx.transactionHash;`
Excellent! That's exactly how you associate a token using the HIP-719. However, we have good news – manual token association is no longer necessary. HashScan now allows users to connect their wallet directly to the platform, enabling them to associate and add the token to Metamask effortlessly.
For your specific case, follow these steps:
After connecting, you'll notice a button labeled 'Import to Metamask' next to the token address within the Token Detail page. It will look like this image
Click on this button, and it will prompt you to associate the token with the connected account. Additionally, it will ask if you want to add the token to Metamask.
As Fredy has mentioned about this issue above, by clicking the Import to Metamask
button, it will only add that token to the Tokens
tab but not NFTs. I have created a ticket on Hashscan already and will push in the fix soon.
this is what happen when i'm try to import the NFT
I notice you're attempting to manually add the NFT to your Metamask. However, based on the provided picture, it seems there might be confusion between the Token ID and Token Address. Let me clarify:
The Token ID represents the unique identifier (or Serial Number in HTS) of the specific token you own. Follow these steps to find the Token ID for your owned token:
If you still have any question, please don't hesitate to ask!
P.S. Our Testnet recently underwent quarterly maintenance, resulting in a complete reset of the entire Testnet network. All tokens have been wiped off, and all accounts have been updated with new account IDs and keys. We recommend revisiting your Hedera Portal to review and verify your account information.
Thanks for the answer @quiet-node , quick question, In Hedera Mainnet, are the users will have to also import manually the NFT as you mentioned or it will automatically will be in their NFT Tab inside the metamask wallet just like on HashPack or on Ethereum Network on Metamask. and if it manually, are you doing something about it? Customers that using Hedera Metamask inside our dapp can't see their NFT on their wallet Tab as I mentioned.
Hi @yonac1, appreciate your prompt response! Currently, within the Hedera ecosystem, the only automated method for importing tokens into Metamask is through Hashscan.io (the Mirror-Node Explorer). Presently, this process is designed exclusively for ERC20
tokens, leading the Mirror-Node Explorer to incorrectly categorize NFTs as fungible assets in your wallet. I've documented this issue in a new ticket on the Mirror-Node Explorer repo. I'm actively collaborating with the Mirror-Node Explorer team to address this, and the fix will be implemented soon. Once resolved, you and your DApp users won't need to manually import tokens; they can simply visit Hashscan to accomplish this.
Moreover, your team has the option to incorporate a similar importing tokens
flow directly within your DApp using Metamask's wallet_watchasset
feature. For more details, please refer to the official documentation. If your team finds this approach appealing, it offers an additional avenue for a seamless token import experience.
@quiet-node Thank You Very Much!
@yonac1 you're very welcome! We are working on this problem and we will push in the fix soon!
Hello @yonac1, in this PR the mirror-node-explorer team and I have successfully fixed this bug. You can now associate, dissociate tokens (fungible and non-fungible). You can also import the tokens into your wallets. A couple of notes:
Again, thanks for your time opening this ticket! Please feel free to let me know if you have any questions!
Description
HTS NFT is still not compatible with Metamask. I'm trying to send an NFT through HTS to a Hedera Testnet Metamask wallet, but then the NFT shows it to me as a Token in the token list tab inside Metamask instead of under the "NFTs" Tab and it says in the MetaMask "No NFTs yet" I already associated the nft token id
Steps to reproduce
Additional context
No response
Hedera network
testnet
Version
v2.25.0
Operating system
Linux