Type alias InsertCandyMachineItemsInput

InsertCandyMachineItemsInput: {
    candyMachine: Pick<CandyMachine, "address" | "itemsAvailable" | "itemsLoaded" | "itemSettings">;
    items: Pick<CandyMachineItem, "name" | "uri">[];
    authority?: Signer;
    index?: number;
}

Type declaration

  • candyMachine: Pick<CandyMachine, "address" | "itemsAvailable" | "itemsLoaded" | "itemSettings">

    The Candy Machine to insert items into.

    We only need a subset of the CandyMachine model. We need its address, its items settings and the number of items loaded and to be loaded so we can check if the operation is valid.

  • items: Pick<CandyMachineItem, "name" | "uri">[]

    The items to insert into the candy machine.

    This only requires the name and the uri to insert for each item.

    Important: If your config line settings use prefixes, you must only provide the part of the name or URI that comes after theses prefixes.

    For example, if your config line settings use the following prefixes:

    • prefixName: My NFT #
    • prefixUri: https://example.com/nfts/

    Then, an item to insert could be: { name: '1', uri: '1.json' }.

    See

    CandyMachineItem

  • Optional authority?: Signer

    The Signer authorized to update the candy machine.

    Default Value

    metaplex.identity()

  • Optional index?: number

    The index we should use to insert the new items. This refers to the index of the first item to insert and the others will follow after it.

    By defaults, this uses the itemsLoaded property so items are simply appended to the current items.

    Default Value

    candyMachine.itemsLoaded

Generated using TypeDoc