metaplex-foundation / metaplex

A directory of what the Metaplex Foundation works on!
https://metaplex.com
Apache License 2.0
3.32k stars 6.26k forks source link

Allow Authority to mint ordered NFT on Candy Machine V2 #1295

Closed AnderUstarroz closed 2 years ago

AnderUstarroz commented 2 years ago

Although having the NFT shuffled to avoid bots predicting rare items is a great feature, most projects still want to be able to mint specific NFT before launch. But with CM2 the NFT are randomised even for the authority. That would be a step backwards from CM1, forcing users to create additional candy machines for such a common requirement.

Proposed solution

Mint NFT in order by default when using the Mint authority:

ts-node ~/metaplex/js/packages/cli/src/candy-machine-v2-cli.ts mint_one_token

and maybe add an additional parameter to mint_one_token like -s, --shuffle in case someone actually want to get random tokens, but I doubt it...

AlexLup06 commented 2 years ago

Agree!

peterschwarzdev commented 2 years ago

Although I really like this new CM2, I also found this particular issue a step backwards. It's preferable to mint everything from the same candy machine because many tools generate a list of valid NFTs by looking at what was minted by a specific candy machine.

spreadmycode commented 2 years ago

So, is there any solution to mint ordered? Please help me. I need to mint ordered to airdrop specific NFTs to some wallets.

AnderUstarroz commented 2 years ago

Metaplex guys didn't reply on this issue... Right now the only possibilities I know would be creating another candy machine V1 or mint manually 🤷‍♂️

spreadmycode commented 2 years ago

Metaplex guys didn't reply on this issue... Right now the only possibilities I know would be creating another candy machine V1 or mint manually 🤷‍♂️

Creating CM v1 is not possible now. And you mentioned mint manually. Would you like to explain it in more detail? Perhaps you mean this command? ts-node ~/metaplex/js/packages/cli/src/candy-machine-v2-cli.ts mint_one_token

AnderUstarroz commented 2 years ago

@spreadmycode I haven't done it manually but according some devs on discord (Metaplex channels) it shouldn't be too hard. But you probably don't even need to do that, if you are more used to CM2 and you just want to airdrop a bunch of NFTs to some addresses, you can just create a Candy Machine V2 and mint all items for free using the Mint Authority, then airdrop each NFT to his corresponding final owner.

YrgkenKoutsi commented 2 years ago

@spreadmycode I haven't done it manually but according some devs on discord (Metaplex channels) it shouldn't be too hard. But you probably don't even need to do that, if you are more used to CM2 and you just want to airdrop a bunch of NFTs to some addresses, you can just create a Candy Machine V2 and mint all items for free using the Mint Authority, then airdrop each NFT to his corresponding final owner.

you still need to pay gas fee no?

YrgkenKoutsi commented 2 years ago

my question is: how much would it cost to make a CM2 and mint 1k+ NFTs and then airdrop them to the addresses on a snapshot list? The initial idea was to make a CM2 and let the addresses from the snapshot list mint their own NFTs but this seems difficult with all the randomization in place

AlexLup06 commented 2 years ago

my question is: how much would it cost to make a CM2 and mint 1k+ NFTs and then airdrop them to the addresses on a snapshot list? The initial idea was to make a CM2 and let the addresses from the snapshot list mint their own NFTs but this seems difficult with all the randomization in place

It would cost 0.0012*1000=1.2Sol to mint those NFTs. If you just want to airdrop those NFTs then don’t use candy machine at all and just create the NFTs on the go for each airdrop. I mean you could just create your own candy machine program which does exactly what you want it to do. This shouldn’t be that hard because we have the CM code In the Metaplex repo and you will be able to copy most of the stuff and only change minor parts.

I don’t even think it’s the on chain program that randomizes but just the script calling the program. So you would just be able to modify the script so it mints exactly the one you need.

YrgkenKoutsi commented 2 years ago

my question is: how much would it cost to make a CM2 and mint 1k+ NFTs and then airdrop them to the addresses on a snapshot list? The initial idea was to make a CM2 and let the addresses from the snapshot list mint their own NFTs but this seems difficult with all the randomization in place

It would cost 0.0012*1000=1.2Sol to mint those NFTs. If you just want to airdrop those NFTs then don’t use candy machine at all and just create the NFTs on the go for each airdrop. I mean you could just create your own candy machine program which does exactly what you want it to do. This shouldn’t be that hard because we have the CM code In the Metaplex repo and you will be able to copy most of the stuff and only change minor parts.

I don’t even think it’s the on chain program that randomizes but just the script calling the program. So you would just be able to modify the script so it mints exactly the one you need.

Thank you for the quick reply!

If I create my own candy machine program and do this wouldn't it charge me extra for uploading the images to the blockchain plus arweave fees? I am just trying to figure out which one is the easiest and cheapest way to do this since I am airdroping the nfts on a list of addresses

github-actions[bot] commented 2 years ago

This Issue has received no activity for 30 days. We will close it in 2 days, please reopen if you are still experiencing this issue.

summerplaybook commented 2 years ago

has anyone found a way to do this yet with the existing metaplex library?

stegaBOB commented 2 years ago

The solution to this would be to chain two candy machines together (the initial ones you want to mint) along with the random ones. Or mint the in order NFTs just individually. You can make them be in the same collection using our UI (https://collections.metaplex.com). A fix to allow this isn't something we have planned for the current candy machine v2, but may be something we do at some point in the future with a new machine potentially.

stegaBOB commented 2 years ago

my question is: how much would it cost to make a CM2 and mint 1k+ NFTs and then airdrop them to the addresses on a snapshot list? The initial idea was to make a CM2 and let the addresses from the snapshot list mint their own NFTs but this seems difficult with all the randomization in place

It would cost 0.0012*1000=1.2Sol to mint those NFTs. If you just want to airdrop those NFTs then don’t use candy machine at all and just create the NFTs on the go for each airdrop. I mean you could just create your own candy machine program which does exactly what you want it to do. This shouldn’t be that hard because we have the CM code In the Metaplex repo and you will be able to copy most of the stuff and only change minor parts.

I don’t even think it’s the on chain program that randomizes but just the script calling the program. So you would just be able to modify the script so it mints exactly the one you need.

And it actually is the on chain program that randomizes it to clarify.

AnderUstarroz commented 2 years ago

The solution to this would be to chain two candy machines together (the initial ones you want to mint) along with the random ones. Or mint the in order NFTs just individually. You can make them be in the same collection using our UI (https://collections.metaplex.com). A fix to allow this isn't something we have planned for the current candy machine v2, but may be something we do at some point in the future with a new machine potentially.

Hey @stegaBOB regarding that link you mentioned https://collections.metaplex.com, is there a way to create a collection IDs for already existing collections? That seems to allow only creating new collections, but we would need to update all the existing collections to the new standard.