Create NFT ===== - [RMV2-2](https://rsklabs.atlassian.net/browse/RMV2-2) ## User Story ### B2B As a software developer I want to be able to develop an application mechanism where producers of my business vertical are able to share their work on an open marketplace ### B2C As an artefact producer I want to be able to create an NFT asset representing my artefact, so that I can monetize my work ### Requirements --- # Substories/subtasks Upload an image (or any file) to RIF Storage to be linked to the product for sale --- - [RMV2-1](https://rsklabs.atlassian.net/browse/RMV2-1) ### User Story #### B2B As a software developer I want to have a unified, easy-to-use developer interface (SDK, API) to upload an image to the IPFS, so that I can programmatically save and manage files in the decentralized way. #### B2C As an artefact producer I want to be able to upload an image to the IPFS via an NFT Marketplace application, so that I can add the result of my work to an open marketplace. #### Requirements Name + Description to the product for sale --- - [RMV2-3](https://rsklabs.atlassian.net/browse/RMV2-3) ### User Story #### B2B As a software developer I want to have a unified, easy-to-use developer interface to set a name and description for a digital asset, so that I can programmatically set and change these properties. #### B2C As an artefact producer I want to be able to provide a name and description to my digital asset via an NFT Marketplace application, so that I can communicate to other marketplace actors in succinct and detailed ways what is the result of my work. #### Requirements 1. The name MUST be mandatory 2. The description MAY be optional Link attached to the product for sale --- - [RMV2-4](https://rsklabs.atlassian.net/browse/RMV2-4) ### User Story #### B2B As a software developer I want to have a unified, easy-to-use developer interface to attach an external link to a digital asset, so that I can programmatically provide access to more actions/information about my work. #### B2C As an artefact producer I want to attach an external link to my digital asset via an NFT Marketplace application, so that I can share more details about my work, myself or create a gateway to my business. #### Requirements Number of identical copies of the product for sale --- - [RMV2-5](https://rsklabs.atlassian.net/browse/RMV2-5) ### User Story #### B2B As a software developer I want to have a unified, easy-to-use developer interface to set a number of identical digital assets I’m going to create, so that I can programmatically define it for each specific artefact. #### B2C As an artefact producer I want to be able to set how many copies of the result of my work I want to add, so that I can customize the supply based on my economy or other incentives. #### Requirements Mint NFT based on the product for sale attributes --- - [RMV2-6](https://rsklabs.atlassian.net/browse/RMV2-6) ### User Story #### B2B As a software developer I want to have a unified, easy-to-use developer interface to mint a NFT taking into account input data from the artefact producer. #### B2C As an artefact producer I want to be able to mint a NFT based on my work’s characteristics for a later listing on the marketplace. #### Requirements 1. Standards: It has to support a. ERC721 b. ERC1155 2. TokenID Strategy: the MKP owner should be able to define it as they please. a. Implement a default strategy: Random Id (MUST be provided by default by our engine) b. Leave space for devs to write other preferred strategies (eg: incrementalID, formulaID, etc) #### Acceptance Criteria: 1. The Owner of the minted token is the one who created it or the allowed minter 2. The TokenID should be identical to the one used during generation (with the selected strategy) 3. Validate minted token is compliant with selected ERC (721 or 1155) 4. Full test coverage 5. Developer should be able to deploy independently 6. Documented in Github and Devportal --- # Diagrams ```sequence title: Sequence analysis participant RSK participant IPFS participant EngineSC participant IMintSC participant EngineSDK participant Owner participant Producer # B2B Owner->EngineSDK: getWhitelistedMintContracts EngineSDK-->Owner: IMintSC[] Owner->EngineSDK: use mintContracts[] EngineSDK->>RSK: new CustomMintSC():[] RSK->>IMintSC: deploy EngineSDK->EngineSDK: whitelistedMints < mintContracts EngineSDK-->Owner: address[] Note over Owner: Deploy Marketplace: Owner->>RSK: new EngineSC(options) RSK->>EngineSC: deploy RSK-->Owner: # B2C Producer->Owner: upload product Owner->EngineSDK: create NFT from product EngineSDK->IPFS: upload product (opt.) IPFS-->EngineSDK: hash Owner->EngineSDK: getWhitelistedMints EngineSDK->EngineSC: isWhitelistedMint(): whitelistedMints EngineSDK-->Owner: whitelistedMints[] Owner->EngineSDK: whitelistedMints[#].call(hash) EngineSDK->IMintSC: create NFT IMintSC-->EngineSDK: NFT EngineSDK-->Owner: NFT Owner-->>Producer: Note over Owner: Opt. manual asset registration Owner->EngineSDK: Register NFT EngineSDK->EngineSC: Register NFT EngineSC-->EngineSDK: assets EngineSDK-->Owner: assets Owner-->Producer: ``` :::info Note: $Owner ∋ Kahlo$ ::: --- # Q&A: - **Q**: - ***A***: