Its an NFT project made for the Atom Dao Bounty and the simpler version of this is the winner of that bounty. You can checkout the project HERE
Merkle-Tree NFT Whitelisting uses the ERC721 based contract to generate NFTs and Merkle Tree helps to keep the record of Whitelisted Address
git clone https://github.com/mecskyverse/Merkle-Tree-NFT.git
Make sure You have NPM and NODEJS installed with their path setup
cd hardhat-nft npm install
Here the hardhat project will install the dependencies
now you can open the
Scripts/deploy.js
You will See
-
You can edit script or add account in leaves which you wanted to use in Merkle Tree
-
Make a .env file in folder and add your account Private Key and API key
Goerli_Api_Key =<api url>
Goerli_Private_Key =<Your private key>
3.Run
npx hardhat compile
npx hardhat run scripts/deploy.js --network rinkeby
Take the ABI code from
artifacts/contracts/MyToken.json
and contract address from your terminal
paste in
nft-next-app/constants/index.js
Run npx hardhat run scripts/deploy.js --network rinkeby
-
cd .. cd nft-next-app
-
npm install
GO TO NFT-whitelisting/nft-next-app/pages/index.js
change the addresses variable in both
mintNFT and checkVerification function
then run npm run dev
and open your local host at port 3000
run
npm run dev
and open port 3000 of local host
- Connect your metamast account
- click on Veriry Account
- If you have Account in the merkle tree Then
- Account will verify and you will get a button to mint nft
- Click on Mint Nft
- Confirm the Transaction from your metamask extension
And Congrats You have succesfully minted your NFT.