This project demonstrates a basic Hardhat use case. It comes with a sample contract, a test for that contract, and a script that deploys that contract.
Try running some of the following tasks:
npx hardhat help
npx hardhat test
REPORT_GAS=true npx hardhat test
npx hardhat node
npx hardhat run scripts/deploy.ts
This project includes three Solidity smart contracts that implement an Airdrop system and an ERC-721 token named GauntletNFT on the Ethereum blockchain.
- Name: Airdrop
- SPDX-License-Identifier: MIT
- Dependencies: OpenZeppelin's MerkleProof, IERC721
- constructor(address _token, bytes32 _merkleRoot)
- claim(bytes32[] calldata merkleProof) external
- canClaim(address claimer, bytes32[] calldata merkleProof) public view returns (bool)
- Deploy the Airdrop contract, providing the address of the airdrop NFT token and the merkle root.
- Candidates can claim their airdrop by calling the claim function with a valid merkle proof.
- Name: GauntletNFT
- SPDX-License-Identifier: MIT
- Dependencies: OpenZeppelin's ERC721, ERC721URIStorage, AccessControl, Counters
- constructor()
- safeMint(address to, string memory uri) public onlyRole(MINTER_ROLE)
- Deploy the GauntletNFT contract.
- Mint new NFTs by calling the safeMint function, which can only be called by addresses with the MINTER_ROLE.
##3. IERC721 Interface
###Smart Contract Details Name: IERC721 SPDX-License-Identifier: MIT
- safeMint(addres to) external;
- Implement this interface in contracts that should be able to mint NFTs.