referrerpolicy=no-referrer-when-downgrade

Function pallet_nfts::pallet::dispatchables::mint

source ·
pub fn mint<T: Config<I>, I: 'static>(
    collection: T::CollectionId,
    item: T::ItemId,
    mint_to: <<T as SystemConfig>::Lookup as StaticLookup>::Source,
    witness_data: Option<MintWitness<T::ItemId, DepositBalanceOf<T, I>>>,
)
Expand description

Mint an item of a particular collection.

The origin must be Signed and the sender must comply with the mint_settings rules.

  • collection: The collection of the item to be minted.
  • item: An identifier of the new item.
  • mint_to: Account into which the item will be minted.
  • witness_data: When the mint type is HolderOf(collection_id), then the owned item_id from that collection needs to be provided within the witness data object. If the mint price is set, then it should be additionally confirmed in the witness_data.

Note: the deposit will be taken from the origin and not the owner of the item.

Emits Issued event when successful.

Weight: O(1)

§Warning: Doc-Only

This function is an automatically generated, and is doc-only, uncallable stub. See the real version in Pallet::mint.