NFT Kit
Easy NFT SDK Methods is a set of functions provided by the Easy NFT SDK in the KrypCore Web3 SDK. This SDK simplifies the process of creating and interacting with NFTs (Non-Fungible Tokens) on the blockchain. With the Easy NFT SDK, developers can easily deploy ERC-721 and ERC-1155 NFT collections, as well as mint NFTs within those collections.
To use the Easy NFT SDK, import the required modules and initialize the necessary objects:
Table of Contents
Create Collection
Mint NFT
Bootstrapping the SDK for NFT kit
const krypcore_web3_sdk = require("@krypc/krypcore-web3-sdk");
const EasyNftService = new krypcore_web3_sdk.Services.EasyNft(configFilePath);Now, let's explore the available methods and their usage:
SDK Methods
createNFTCollection (ERC-721)
Deploys an ERC-721 or ERC-1155 NFT collection on a specific blockchain network.
Parameters:
standard(string): The NFT standard to deploy ("ERC721"or"ERC1155").chainId(string): The ID of the blockchain network where the collection will be deployed.name(string): The name of the NFT collection.description(string): The description of the NFT collection.symbol(string): The symbol or ticker of the NFT collection.accessToken(string): The access token for wallet authentication.isPublic(boolean, optional): Flag indicating if the collection is public (default:false).
Usage:
mintNFT (ERC-721)
Mints a new ERC-721 or ERC-1155 NFT.
Parameters:
chainId(string): The ID of the blockchain network where the NFT will be minted.contractAddress(string): The address of the NFT contract.standard(string): The NFT standard ("ERC721"or"ERC1155").name(string): The name of the NFT.description(string): The description of the NFT.quantity(number or null): The quantity of NFTs to mint (set tonullfor ERC-721).attributes(array): An array of NFT attributes.file(File): The file object of the NFT image or media.recipientAddress(string): The address of the recipient.accessToken(string): The access token for wallet authentication.
Usage:
createNFTCollection (ERC-1155)
Deploys an ERC-1155 NFT collection on a specific blockchain network.
Parameters:
standard(string): The NFT standard to deploy ("ERC1155").chainId(string): The ID of the blockchain network where the collection will be deployed.name(string): The name of the NFT collection.description(string): The description of the NFT collection.symbol(string): The symbol or ticker of the NFT collection.accessToken(string): The access token for wallet authentication.isPublic(boolean, optional): Flag indicating if the collection is public (default:false).
Usage:
mintNFT (ERC-1155)
Mints a new ERC-1155 NFT.
Parameters:
chainId(string): The ID of the blockchain network where the NFT will be minted.contractAddress(string): The address of the NFT contract.standard(string): The NFT standard ("ERC1155").name(string): The name of the NFT.description(string): The description of the NFT.quantity(number): The quantity of NFTs to mint.attributes(array): An array of NFT attributes.file(File): The file object of the NFT image or media.recipientAddress(string): The address of the recipient.accessToken(string): The access token for wallet authentication.
Usage:
These methods allow you to deploy and mint ERC-721 and ERC-1155 NFTs on the specified blockchain network. Make sure to provide the necessary parameters based on your requirements and utilize the returned data as needed.
Last updated
Was this helpful?