0

I am looking for a way to hide the tokenURI values from other people as they can call the tokenURI contract from etherscan and by editing the URL of it, they can snipe the rarest NFT's in my project and this is an unwanted situation.

https://etherscan.io/address/0xF407B994F05d2b2cA66534517a9C85a117Db54A5 For example, in this contract, you can call the tokenURI of a minted token and it returns the link of their api, which is https://ploddingpirateapi.herokuapp.com/api/token/962 and people just can edit the "962" section in the link and could see the unminted NFT's and just wait for his turn to buy this.

Instead of calling my own api like in this project, I have my metadatas on Pinata IPFS.

Any way of preventing this situation is fine by me. If I don't verify the contract in etherscan, they won't be able to see it but also I won't be able to withdraw the contract's balance.

1
  • anything stored on the blockchain and ipfs is visible to everyone if they have the knowledge to decode it. what you can do is not to add the base URI and not publish them on ipfs until all tokens are minted. You need to add extra functions to your smart contract to be able to set the base URI once.
    – Majd TL
    Nov 8 at 12:59
0

I am looking for a way to hide the tokenURI

Public blockchains, by definition, have all data public so there is no way you can do this. Even if EtherScan does not show it it is very easy to dig out.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.