Type alias CreateCandyMachineBuilderParams<T>

CreateCandyMachineBuilderParams<T>: {
    collection: {
        address: PublicKey;
        updateAuthority: Signer;
    };
    sellerFeeBasisPoints: number;
    itemsAvailable: BigNumber;
    symbol?: undefined | string;
    creators?: undefined | Omit<Creator, "verified">[];
    isMutable?: undefined | boolean;
    authority?: undefined | PublicKey | Signer;
    candyMachine?: undefined | Signer;
    guards?: undefined | Partial<T>;
    groups?: undefined | {
        label: string;
        guards: Partial<T>;
    }[];
    maxEditionSupply?: undefined | BigNumber;
    itemSettings?: undefined | CandyMachineConfigLineSettings | CandyMachineHiddenSettings;
    withoutCandyGuard?: undefined | boolean;
    createCandyMachineAccountInstructionKey?: undefined | string;
    initializeCandyMachineInstructionKey?: undefined | string;
    wrapCandyGuardInstructionKey?: undefined | string;
}

Type Parameters

Type declaration

  • collection: {
        address: PublicKey;
        updateAuthority: Signer;
    }

    The Collection NFT that all NFTs minted from this Candy Machine should be part of. This must include its address and the update authority as a Signer.

    Example

    If you do not have a Collection NFT yet, you can create one using the create method of the NFT module and setting isCollection to true.

    const { nft } = await metaplex.
    .nfts()
    .create({ isCollection: true, name: 'My Collection', ... });

    You can now use nft.address as the address of the collection and provide the update authority as a signer, which by default, should be metaplex.identity().

  • sellerFeeBasisPoints: number

    The royalties that should be set on minted NFTs in basis points.

    Example

    { sellerFeeBasisPoints: 250 } // For 2.5% royalties.
    
  • itemsAvailable: BigNumber

    The total number of items availble in the Candy Machine, minted or not.

    Example

    { itemsAvailable: toBigNumber(1000) } // For 1000 items.
    
  • Optional symbol?: undefined | string

    The symbol to use when minting NFTs (e.g. "MYPROJECT")

    This can be any string up to 10 bytes and can be made optional by providing an empty string.

    Default Value

    ""

  • Optional creators?: undefined | Omit<Creator, "verified">[]

    Array of creators that should be set on minted NFTs.

    See

    Creator

    Default Value

    Defaults to using the authority parameter as the only creator.

    [{ address: authority, share: 100 }]
    
  • Optional isMutable?: undefined | boolean

    Whether the minted NFTs should be mutable or not.

    We recommend setting this to true unless you have a specific reason. You can always make NFTs immutable in the future but you cannot make immutable NFTs mutable ever again.

    Default Value

    true

  • Optional authority?: undefined | PublicKey | Signer

    Refers to the authority that is allowed to manage the Candy Machine. This includes updating its data, authorities, inserting items, etc.

    By default, it is required as a Signer in order to create and wrap its Candy Guard. However, when withoutCandyGuard is set to true, it may be provided as a PublicKey instead.

    Default Value

    metaplex.identity()

  • Optional candyMachine?: undefined | Signer

    The Candy Machine to create as a Signer. This expects a brand new Keypair with no associated account.

    Default Value

    Keypair.generate()

  • Optional guards?: undefined | Partial<T>

    The settings of all guards we wish to activate.

    Any guard not provided or set to null will be disabled.

    This parameter is ignored if withoutCandyGuard is set to true.

    Default Value

    {}, i.e. no guards are activated.

  • Optional groups?: undefined | {
        label: string;
        guards: Partial<T>;
    }[]

    This parameter allows us to create multiple minting groups that have their own set of requirements — i.e. guards.

    When groups are provided, the guards parameter becomes a set of default guards that will be applied to all groups. If a specific group enables a guard that is also present in the default guards, the group's guard will override the default guard.

    For each group, any guard not provided or set to null will be disabled.

    This parameter is ignored if withoutCandyGuard is set to true.

    Default Value

    [], i.e. no groups are created.

  • Optional maxEditionSupply?: undefined | BigNumber

    The maximum number of editions that can be printed from the minted NFTs.

    For most use cases, you'd want to set this to 0 to prevent minted NFTs to be printed multiple times.

    Note that you cannot set this to null which means unlimited editions are not supported by the Candy Machine program.

    Default Value

    toBigNumber(0)

  • Optional itemSettings?: undefined | CandyMachineConfigLineSettings | CandyMachineHiddenSettings

    Settings related to the Candy Machine's items.

    These can either be inserted manually within the Candy Machine or they can be infered from a set of hidden settings.

    • If type is hidden, the Candy Machine is using hidden settings.
    • If type is configLines, the Candy Machine is using config line settings.

    Default Value

    Defaults to using configLines settings with:

    • No prefixes.
    • A length of 32 for the name.
    • A length of 200 for the URI.
    • Random mint ordering.
    {
    itemSettings: {
    type: 'configLines',
    prefixName: '',
    nameLength: 32,
    prefixUri: '',
    uriLength: 200,
    isSequential: false,
    }
    }

    See

  • Optional withoutCandyGuard?: undefined | boolean

    Whether to skip the part of this operation that creates a Candy Guard for the new Candy Machine. When set to true, no Candy Guard will be created for the Candy Machine.

    Default Value

    false

  • Optional createCandyMachineAccountInstructionKey?: undefined | string

    A key to distinguish the instruction that creates the Candy Machine account.

  • Optional initializeCandyMachineInstructionKey?: undefined | string

    A key to distinguish the instruction that initializes the Candy Machine account.

  • Optional wrapCandyGuardInstructionKey?: undefined | string

    A key to distinguish the instruction that wraps the Candy Machine in a Candy Guard.

Generated using TypeDoc