js
js copied to clipboard
When creating a candy machine 0x52 eh
The following error occurs when I create a candy machine with a collection.
Maybe I am missing something? I've tried creating the nft with the minimum input and it does not work. The Metaplex identity is with my wallet
Code to create the nft
const {uri, metadata} = await metaplex.value.nfts().uploadMetadata({
name: title,
description: description,
// image: metafile,
symbol: title,
}).run()
const {
nft,
mintAddress,
metadataAddress,
masterEditionAddress,
tokenAddress,
} = await metaplex.value
.nfts()
.create({
uri,
name: title,
maxSupply: null,
sellerFeeBasisPoints: 200,
// isCollection: true
})
.run();
Code to create candy machine
const { candyMachine } = await client
.create({
price: sol(1),
itemsAvailable: toBigNumber(1),
sellerFeeBasisPoints: 500,
collection: nft.address,
})
.run();