Part 4: Minimal Configuration for Candy Machine V2
A fully on-chain generative NFT distribution program.
Why Candy Machine V2
The second iteration of the well-known Candy Machine, a fully on-chain generative NFT distribution program, provides many improvements over its predecessor. The new version also allows you to create a whole new set of distribution scenarios and offers protection from bot attacks, while providing the same easy-to-use experience.
With our Solana CLI configured, we now need to create the config for our Candy Machine V2 (CMv2). One of the changes moving from v1 to v2 is how we configure the Candy Machine. It reads a JSON file that you can tweak to your liking. There is a full list of all of the options on the Metaplex docs that can be found here.
We will be using their recommended minimal setup configuration. To follow along, you can create a config.json file and place it at ~/dev/
with the following command:
touch ~/dev/config.json
Next, open that file in your text editor of choice and paste the following:
{
"price": 1.0,
"number": 10,
"gatekeeper": null,
"solTreasuryAccount": "<YOUR PUBKEY>",
"splTokenAccount": null,
"splToken": null,
"goLiveDate": "25 Dec 2021 00:00:00 GMT",
"endSettings": null,
"whitelistMintSettings": null,
"hiddenSettings": null,
"storage": "arweave-sol",
"ipfsInfuraProjectId": null,
"ipfsInfuraSecret": null,
"awsS3Bucket": null
}
Replace <YOUR PUBKEY>
with the address of the keypair you previously set up.
Note:
you can run
solana address
in your terminal to obtain your address.
Next, replace the arweave-sol
option with arweave
. Finally, save and close the file.
Now, you should be ready to get going with your mint! But what is an NFT project without some .JPEGs? Letโs get that ready next.
Updated about 1 year ago