Skip to main content
Version: Current

Resource NFTMinter


_10
resource NFTMinter {
_10
}

Resource that an admin or something similar would own to be able to mint new NFTs

Functions

fun mintNFT()


_10
func mintNFT(recipient &{NonFungibleToken.CollectionPublic}, name String, description String, thumbnail String, royalties [MetadataViews.Royalty])

Mints a new NFT with a new ID and deposit it in the recipients collection using their collection reference

Parameters:

  • recipient : A capability to the collection where the new NFT will be deposited
  • name : The name for the NFT metadata
  • description : The description for the NFT metadata
  • thumbnail : The thumbnail for the NFT metadata
  • royalties : An array of Royalty structs, see MetadataViews docs