NFT Art NFT Minting and Smart Contracts 4 — Questions and Answers
Question 1: What is a 'whitelist' (or allowlist) mint in NFT projects?
- A mint restricted to wallets that have been pre-approved, often at a lower price or earlier access (Correct answer)
- A mint where all tokens are white/blank until revealed
- A government-approved NFT sale
- A mint that excludes international buyers
Correct answer: A mint restricted to wallets that have been pre-approved, often at a lower price or earlier access
Allowlist mints grant early or discounted access to pre-approved wallet addresses, typically stored as a Merkle tree in the contract for gas efficiency.
Question 2: How does a Merkle proof enable efficient whitelist verification in an NFT smart contract?
- It encrypts the buyer's identity
- It allows verifying a wallet is in a list without storing all addresses on-chain (Correct answer)
- It automatically refunds failed transactions
- It generates random trait assignments
Correct answer: It allows verifying a wallet is in a list without storing all addresses on-chain
By storing only a Merkle root on-chain, the contract can verify any wallet's inclusion with a small proof, saving significant gas versus storing thousands of addresses.
Question 3: An artist deploys an upgradeable NFT contract using a proxy pattern. What is the main risk of this approach?
- Higher initial deployment cost
- The contract owner could change the contract logic after buyers purchase, undermining trust (Correct answer)
- NFTs cannot be transferred from proxy contracts
- Royalties cannot be set on proxy contracts
Correct answer: The contract owner could change the contract logic after buyers purchase, undermining trust
Upgradeable contracts give owners power to alter contract behavior post-deployment, which can conflict with buyers' expectations of immutability.
Question 4: What is 'batch minting' and why do artists use it?
- Minting NFTs in groups of 10 for aesthetic reasons
- Minting multiple tokens in a single transaction to save gas costs (Correct answer)
- Using multiple wallets to mint simultaneously
- Scheduling mints to happen at set intervals
Correct answer: Minting multiple tokens in a single transaction to save gas costs
Batch minting combines multiple token creations into one transaction, dramatically reducing per-token gas costs for large collections.
Question 5: What does 'reveal' mean in the context of a generative NFT art launch?
- The artist publicly reveals their identity
- The process where hidden or placeholder metadata is replaced with actual artwork traits after mint (Correct answer)
- Showing the smart contract source code publicly
- Announcing secondary sale royalty percentages
Correct answer: The process where hidden or placeholder metadata is replaced with actual artwork traits after mint
Reveal mechanisms keep traits secret until after minting to prevent buyers from strategically minting only rare tokens by predicting outcomes.
Question 6: Which statement best describes the 'ownerOf' function in ERC-721?
- Returns the address of the contract deployer
- Returns the current owner's wallet address for a given token ID (Correct answer)
- Returns all tokens owned by an address
- Returns the address that last transferred the token
Correct answer: Returns the current owner's wallet address for a given token ID
The ownerOf function takes a token ID and returns the address of its current owner, providing verifiable on-chain proof of ownership.
Question 7: A smart contract has a 'mint price' of 0.08 ETH and a max supply of 10,000. What happens if a buyer sends exactly 0.05 ETH to the mint function?
- They receive a partial NFT
- The transaction reverts and no NFT is minted (Correct answer)
- They receive an NFT but owe the remaining 0.03 ETH
- The contract automatically refunds 0.05 ETH and mints for free
Correct answer: The transaction reverts and no NFT is minted
Properly written contracts use require statements to verify sufficient payment, reverting the entire transaction if the sent value is below the mint price.
What is a 'whitelist' (or allowlist) mint in NFT projects?