The NFT.Kred API provides a complete suite of methods to design, mint, and deliver your NFTs. In this section we examine the NFT.Kred app and the API calls it uses to deliver this functionality.
From the menu, we can select Create an NFT to start the design and mint application flow.
This brings up the NFT designer.
The /nft/upload call is used to upload your images. You can't change existing images, but you can upload new images and then use /nft/edit to update your NFT as long as it has not yet been distributed to users.
Once and NFT has been distributed, its appearance and core properties are frozen, though the NFT metadata can be updated at any time.
The design tool allows users to set the name, images, colours, and background pattern of the NFT, set the value of the NFT and the number of NFTs in the batch, and choose whether each NFT in the batch has its own message stream, or if all NFTs are combined in a mesh. NFTs can also be marked as private and/or NSFW at this point.
The design is rendered immediately using SVG.
Once a design is completed and the NFT is minuted, the system automatically generates image files for the NFT, to be embedded in sites that don't need or can't use the full SVG layout, such as light mobile apps or notification feeds. The full list of available images is provided via the metadata call, /nft/data. The metadata endpoint is also linked directly from ERC721 tokens, so that third-party wallets and exchanges can automatically detect and display your NFTs.
By saving the NFT using the /draft method the design is stored without immediately creating an NFT, and the details are saved for retrieval by the /drafts method. Users can page through existing designs, modify them using the NFT designer, and save them again using /draft or mint an NFT using /mint.
Users can add metadata to NFTs that is included with every API call that returns NFT data. Unlike key data (the name, appearance, and value of the NFT) which is bound to the blockchain, metadata can be updated at any time via the /meta call.
Additional NFT types can be defined with different sets of metadata fields. These can be simply informative, as in the case of an artist NFT intended to showcase an artist's work.
Or they can be active fields such as one-time redeemable offers in marketing campaigns. These can be implemented using callbacks.
When an NFT is minted, it is immediately listed on the blockchain. With POA, this only takes around five seconds, and multiple NFTs can be batched and listed simultaneously.
When minting an NFT to the POA network - and with all POA operations - the API will wait for confirmation from POA before returning. If the operation cannot be completed (insufficient funds, for example, or an issue with the network itself) the API will return an appropriate error status and no transaction will take place.
When operating on the Ethereum mainnet, transactions are recorded first in the local database, and then submitted to the blockchain and monitored for success. The API will return immediately and note the details of the transaction in progress.
An NFT with an incomplete Ethereum transaction pending will have the transaction details included with the NFT data and cannot have further transactions applied until the pending transaction either completes or fails.
Updated about a year ago