Converting existing smart contract artworks to ERC 721

I have around 400 physical artworks on Ethereum mainnet. I would like to apply ERC 721 standard. So, is it possible to migrate existing artworks?

:computer: Environment
openzeppelin version 3.0.2
Truffle
Metamask wallet(pipeline)

:memo:Details
I am more than interested to know

  • I am not using upgradable smart contract, can i convert my existing smart contract (keeping the contract address) to ERC 721 ?

  • What is the best way and practice to migrate my existing products to ERC 721 standard?

  • We are planning to go-live, so should we use ERC 721 presets?

  • We are storing metadata on-the-chain (11 metadata are there), and we are planning to continue the same when following ERC 721 standard. Is there any problem? Could you please share a code sample with multiple metadata on-the-chain?

  • As IPFS is a non-persistent storage, can we rely on it to store metadata?

  • If we use centralized servers to store metadata, how can we convince users that it is not tampered?

  • If we are NOT planning to store fungible products or multiple types of artwork, should we think about implementing ERC 1155, instead of 721?

  • I think Metamask is not support ERC 1155 standard. Is this correct?

Thanks in advance!!

1 Like

Hi @irshad,

Welcome to the community :wave:

If your original contract is not upgradeable then you won't be able to use the same contract address for an ERC721 contract.

It depends what functionality your contract has.
You could ask holders to voluntarily migrate and you mint them a token and burn (or put beyond use the old one), or you could potentially wrap the old token with ERC721.
You could mint new tokens for holders at a specific blocknumber (as agreed with your community). They would then hold the old token and a new ERC721.

I would recommend looking at what other NFT projects have done for this migration previously and what works for your community.
I held a https://dada.nyc/ piece that was converted to ERC721.
Crypto Punks are being wrapped as ERC721, see: https://wrappedpunks.com/

You may also want to look at creating an upgradeable contract for any future changes: https://docs.openzeppelin.com/learn/upgrading-smart-contracts

As you are doing onchain metadata then you may want to extend the OpenZeppelin Contracts ERC721 so you can add your own metadata. Though it the preset met your purposes you could extend that.

See: https://docs.openzeppelin.com/contracts/3.x/extending-contracts

Metadata for each token is off chain in the EIP (due to cost of storage): https://eips.ethereum.org/EIPS/eip-721
Apps, wallets and services may only use off chain metadata (as it isn't standardised for onchain), so you may also want to provide the meta off chain in addition to onchain.

Otherwise the only issue could be the cost of minting with onchain metadata. Though depending on the value of the artwork, this may or may not be significant.

You may want to look at other ERC721 projects to see what they store on chain for metadata: https://etherscan.io/tokens-nft

You could maintain your own copy, and also pin it. You may want to use a third party service such as: https://pinata.cloud/

You could have a hash onchain of the metadata or just the image, but then you may as well look at storing the metadata or at least the image in decentralized storage

Otherwise your community needs to trust that you will not tamper with the metadata.

There is currently more eco-system support for ERC721 than ERC1155. e.g. Etherscan and numerous wallets support ERC721. It depends on the needs of your community.

It also depends how you want to group your artwork. Will you have a single contract for all the artwork, or will you have one contract per collection.

MetaMask desktop doesn't support ERC1155. ERC721 is limited to display of the quantity of tokens. I am not sure what support there is on mobile.

Feel free to ask all the questions that you need.