Technical Implementation
The ProudCamel
smart contract is built using the Solidity programming language and inherits from multiple OpenZeppelin contracts to ensure its security and adherence to the latest industry standards.
Standards and Contracts
The contract employs a combination of the ERC721A standard for the NFTs, the ERC2981 standard for royalties, and the ERC165Storage for interface introspection. Additionally, the contract relies on Chainlink's AggregatorV3Interface for fetching the price feed.
Functionality
Public Minting: Users can mint a specified amount of NFTs during the public minting stage. The contract checks that the user is not a bot, that the total supply has not been exceeded, and that the amount to be minted does not exceed the maximum allowed for public minting. The user must send the correct Ether amount to mint the NFTs.
Presale Minting: Whitelisted users can mint a specified number of NFTs during the presale stage. The contract checks that the user is not a bot, that the user's Merkle proof is valid, and that the user's remaining minting allowance is not exceeded. The user must send the correct Ether amount to mint the NFTs.
Distribution: The contract owner can distribute the Ether balance in the contract between the
ONCHAIN
andOFFCHAIN
wallets.Token URI: The contract generates a token URI for each NFT, based on a base URI and a specified extension (default: ".json"). The owner can update the base URI and the extension as needed.
ERC2981 Royalties: The contract supports ERC2981 royalties, with a default royalty of 2.5% assigned to the contract creator.
Customizability
The contract provides various functions for the owner to customize the NFT project:
Set the Merkle root for the presale whitelist.
Enable/disable public minting.
Set the NFT price in USD.
Update the base URI and URI extension.
Mint NFTs directly to an address (owner only).
Overall, the ProudCamel
smart contract is designed to facilitate the creation and distribution of NFTs while promoting Sharia-compliant practices and Middle East market accessibility. The contract's structure allows for a seamless and secure minting process, enabling the project to grow and evolve in the future.
Last updated