✨
Playground
  • OVERVIEW
    • What is Playground?
    • Core Features
    • API Authentication
  • Guides
    • Trait Templates
      • Create a New Trait Template
        • Adding Media to Trait Templates
        • Setting Render Order for Traits
      • Get Started With a Pre-Made Trait Template
        • Access Passes
        • Achievement Badges
    • Minting New Traits
      • Trait Minting Flows
      • Gas Fee Options for Trait Minting
    • Migrating Metadata for Existing NFT Collections
      • Updating the BaseURI
  • Concepts
    • What are Traits?
      • Ownership and Transfers of Traits
      • Verified Traits
      • Artist Royalties
    • Media
    • Rendering
    • Access Controls
Powered by GitBook
On this page
  1. Guides
  2. Migrating Metadata for Existing NFT Collections

Updating the BaseURI

To update the BaseURI of your NFT collection to our protocol's smart contract address, you must use an admin wallet to call the setBaseURI function in your collection's smart contract. Follow the steps below:

  1. Access your collection's smart contract address: Locate the appropriate blockchain network, such as Ethereum or Polygon. Navigate to the relevant block explorer website (e.g., EtherScan or PolygonScan) and search for your contract address.

  2. Find your NFT collection's smart contract code: On the block explorer website, click on the contract address and then click on the "Contract" tab to access the smart contract code associated with your collection's NFTs.

  3. Locate the setBaseURI function: In your smart contract's configuration file, find the setBaseURI function. This function should accept one parameter—the smart contract address associated with our protocol.

  4. Prepare your admin wallet: Ensure you have an admin wallet authorized to make changes to your smart contract. This wallet should have sufficient funds to cover gas fees when calling the setBaseURI function.

  5. Call the setBaseURI function: Using the admin wallet, call the setBaseURI function on your smart contract, passing the smart contract address associated with our protocol as the parameter.

  6. Verify the updated smart contract code: Ensure the updated smart contract code passes all necessary tests and audits.

  7. Deploy the updated smart contract: Deploy the updated smart contract to the blockchain network hosting your NFT collection.

After completing these steps, all new NFTs created by your collection will automatically use the BaseURI associated with our protocol's smart contract. This allows buyers to access NFT metadata securely and in a decentralized manner, as metadata will be accessed through the blockchain instead of a centralized server.

PreviousMigrating Metadata for Existing NFT CollectionsNextWhat are Traits?

Last updated 2 years ago