KOR Protocol Developer Docs
  • KOR Protocol: Introduction
    • Overview
    • Partners
  • Overview of KOR SDK
    • Notable Features
    • Merits of using KOR SDK
    • Use Cases
  • SDK Reference
    • Introduction
    • SDK Installation
    • SDK Initialization
    • Client Methods
      • Asset
      • NFT
      • On-Chain IP
      • On-Chain License
      • Royalty Distribution
      • Conflict Management
    • Tutorials
      • Pre-requisites
      • Mint and Register in Own Collection
      • Mint in KOR Collection and Register
      • Register Existing Minted Token as IP
      • Launch 100-Song Album via IPFS
      • Launch 5-Song Album via AWS S3
      • Register Asset as Derivative
      • Update License Terms of Existing IP
      • Raise, resolve and cancel conflicts
      • Create a copy NFT of an IP
    • Releases
    • Deployed Smart Contracts
  • Essential Business Flows
  • Architecture
    • Overview
    • Event Listener
    • Modules
      • Asset Module
      • NFT Module
      • On-Chain IP Module
      • On-Chain License Module
      • Royalty Distribution Module
      • Conflict Management Module
  • Key Definitions
  • Community
Powered by GitBook
On this page
  • Pre-requisites
  • Step 1: Upload asset folder to AWS S3
  • Step 2: Create metadata and upload to AWS S3
  • Step 3: Create an Artist collection (which will contain NFT's that can be minted by users)
  • Step 4: Create a License
  • Step 5: Attach a License
  • Step 6: Mint NFT from Artist collection
  • Step 7: Activate Royalty
  • Step 8: Pay Royalty
  • Step 9: Claim Royalty
  1. SDK Reference
  2. Tutorials

Launch 5-Song Album via AWS S3

PreviousLaunch 100-Song Album via IPFSNextRegister Asset as Derivative

Last updated 4 months ago

This use case is ideal for artists who want to register their work, such as an album with 5 songs, as intellectual property (IP). If you’re looking to store your album's assets and metadata on AWS S3 and protect each song under a unified IP Collection, this scenario will walk you through the steps to tokenize and license your music as NFTs, ensuring your creative work is protected and properly licensed. Additionally, users can enable royalties, pay royalties, and claim royalties using a snapshot ID.

Pre-requisites

You can refer this for basic setup before you can start with the following steps.

Step 1: Upload asset folder to AWS S3

In this step, each file will be uploaded to S3's presigned URLIn this step, you will upload a folder of assets to AWS S3 using the function from the Asset module, utilizing S3's presigned URLs for each file.

const urls = await Promise.all(
  files.map(async (file, index) => {
  return await korSDK.uploadAssetToURL(
    file,
    inputValues[index]
    );
  })
);

By executing this step, you successfully upload each file in your asset folder to AWS S3 through S3's presigned URLs using the uploadAssetToURL function. This ensures efficient and secure cloud storage for your assets, allowing them to be easily accessed and managed in the subsequent steps of the workflow.

Step 2: Create metadata and upload to AWS S3

In this step, you will create metadata files for your assets and upload them to AWS S3 using the function and S3's presigned URLs.

const urls = await Promise.all(
  files.map(async (file, index) => {
  return await korSDK.uploadAssetToURL(
    file,
    inputValues[index]
    );
  })
);

By executing this step, you successfully generate metadata files for your assets and upload them to AWS S3 via presigned URLs using the uploadAssetToURL function. This step ensures that your asset metadata is securely stored and ready for use in subsequent processes, such as minting and IP registration.

Step 3: Create an Artist collection (which will contain NFT's that can be minted by users)

const data = await korSDK.createIPCollection({
  name: name,
  symbol: symbol,
  licenseTermID: licenseTermID,
  licensors: [licensor1, licensor2, licensor3],
  maxSupply: maxSupply,
  mintPrice: minPrice,
});

By executing this step, you successfully create an artist collection using the createIPCollection function. With parameters like name, symbol, licenseTermID, licensors, maxSupply, and mintPrice, you establish a collection where users can mint NFTs.

Step 4: Create a License

const data = await korSDK.createSmartLicense({
    isRoyaltyAllowed: isRoyaltyAllowed,
    isCommercialUseAllowed: isCommercialUseAllowed,
    isExpirable: isExpirable,
    isDerivativeAllowed: isDerivativeAllowed,
    licenseFee: licenseFee,
});

By executing this step, you create a customized license that outlines how your NFT can be used, shared, or monetized.

Step 5: Attach a License

const data = await korSDK.attachSmartLicense({
    ipId: ipId,
    licenseTermId: licenseTermId,
});

By executing this step, your NFT is now governed by the license terms, formally binding it to the usage rights and conditions you set. This attachment ensures that all interactions with the NFT respect the specified licensing framework, safeguarding your intellectual property rights.

Step 6: Mint NFT from Artist collection

const data = await korSDK.mintIPFromIPCollection({
  recipientAddress: recipientAddress,
  ipID: ipID,
  uri: baseTokenURI,
});

By executing this step, you successfully mint an NFT from your artist collection using the mintIPFromIPCollection function. The minted NFT is automatically registered as intellectual property, inheriting the licensing terms defined at the collection level.

Step 7: Activate Royalty

const data = await korSDK.activateRoyalty({
    ip: ip,
    royaltyTokenName: royaltyTokenName,
    royaltyTokenSymbol: royaltyTokenSymbol,
    mintRTSupply: mintRTSupply,
});

By executing this step, you have successfully activated royalties for the IP. Users can now pay royalties and claim their respective royalty tokens.

Step 8: Pay Royalty

const data = await korSDK.payRoyalty({
    ip: ip,
    amount: amount,
});

By executing this step, you have successfully paid the royalty. A snapshot ID will be generated as output, and the tokens will be distributed among the holders based on their respective shares, making them available for claim.

Step 9: Claim Royalty

const data = await korSdkObj?.collectRevenue({
      ip: ip.current.value as `0x${string}`,
      snapshotId: Number(snapshotId.current.value),
});

By executing this step, you have successfully claimed your royalty tokens.

By following this workflow, you’ve successfully registered your album as intellectual property, allowing you to store your assets and metadata on AWS S3. Each song is tokenized and licensed under a unified IP Collection, ensuring your music is protected and properly licensed as NFTs, safeguarding your creative rights in the digital space. Additionally, you have implemented functionalities to activate, pay, and claim royalties.

If this specific approach doesn’t suit your use case, explore other tutorials to find the best fit for your NFT and IP needs!

In this step, you will create an artist collection using the NFT module's function, allowing users to mint NFTs from the collection.

In this step, you create a license for your IP, defining the specific predefined terms such as royalty, commercial use, expiration, and derivative rights, using the function from the License Module. This step is optional. If you have already created a license, you can skip this step and directly attach the license using the license term ID.

In this step, you attach the newly created license to your IP, enforcing the terms established in Step 4 using the function.

In this step, you will mint an NFT from your artist collection using the NFT module's function, automatically registering it as an IP and enforcing the attached license.

In this step, you activate royalty on an IP using function. This allows users to pay royalties and claim royalty tokens associated with the IP. The process involves creating a royalty token and distributing shares to the user, which can subsequently be further distributed by the user as needed.

In this step, you pay royalty using function. The royalty tokens will be distributed among the holders based on their respective shares and will be available for them to claim.

In this step, royalty token holders can claim their tokens using the function. The claim is made based on the snapshot ID generated during the royalty payment step.

link
createIPCollection
mintIPFromIPCollection
activateRoyalty
payRoyalty
collectRevenue
createSmartLicense
attachSmartLicense
uploadAssetToURL
uploadAssetToURL