project screenshot 1
project screenshot 2
project screenshot 3
project screenshot 4
project screenshot 5
project screenshot 6

ROYALNFT

immutable erc-721 NFT creator royalty broker with built in marketplace as sale price empowering creators as owners of commissioned royalties.

ROYALNFT

Created At

HackFS 2024

Project Description

The ROYALNFT project, presented at EthGlobal HackFS, is an innovative EVM-based smart contract utilizing the ERC721 standard to enable a decentralized marketplace for unique digital assets and data exchange. ROYALNFT emphasizes the empowerment of creators allowing owners to mint and sell digital assets with the benefit of commision from secondary sales through the built-in royalty system.

ROYALNFT leverages the OpenZeppelin's ERC721URIStorage for managing unique tokens with associated metadata, enhancing the NFTs with rich, descriptive information crucial for diverse digital assets like art, collectibles, and other unique data items. NFTROYALTY smart contract architecture is designed to facilitate and spawn a decentrallized marketplace where every NFT owner can acts as an independent agent with sales and minting as a creator provided directly through the NFTROYALTY asset itself. Central platforms become a place to post your contract address and sale price eliminating the need for intermediaries and central platforms. Using the defi "code is law" philosphy ROYALNFT has programmed immutable creator royalties where every owner can mint to become a creator.

Contract Design and Security

ERC721URIStorage Extension: Inherits ERC721 functionalities with added capabilities for handling token-specific metadata, essential for associating each NFT with unique data.

Ownership and Security: Utilizes the Ownable module to ensure that administrative actions are controlled by the contract owner, and the ReentrancyGuard to prevent reentrant attacks during financial transactions, crucial for maintaining integrity and security in token trades.

Key Features

Immutable Variables:

    Deployer: Recognized as the contract creator, with this address being immutable and payable.
    Royalties: Setup includes fixed and percentage-based royalties for the deployer, ensuring they receive compensation from transactions facilitated by the contract.

Structs for Sales and Royalties Management:
    TokenSaleInfo: Stores sales-related data, including the price of each NFT.
    RoyaltyInfo: Captures details about royalties for each NFT, delineating terms for both the creator and deployer.

Mappings:
    tokenSalePrices: Links token IDs with their sale information.
    royalties: Connects token IDs with their respective royalty agreements.

Events:
    Minted: Signals the creation of a new NFT, logging details like the token ID, creator, and initial sale price.
    Sold: Announced upon the sale of an NFT, detailing the transaction's specifics, including the involved parties and the sale price.

Core Functionalities

Minting: Allows any user to create a new NFT by providing a URI and sale price, with the token immediately available for trading upon creation.
Sale Price Management: Empowers NFT owners to adjust their asset's sale price in response to market demands or personal valuation changes.
BrokerNFT: Manages secure transactions for NFT sales, verifying payments, executing transfers, and distributing funds appropriately, including royalty payments.

Additional Utilities

Royalty Calculation: Internally calculates the due royalties based on sale price, comparing fixed amounts to percentage values to ensure fair compensation.
Public Price and Royalty Access: Offers functions like getSalePrice and calculateRoyaltyPublic to improve transparency and facilitate third-party integrations.

Decentralized Marketplace Dynamics

The ROYALNFT contract creates a platform where each NFT owner is not only a creator but also the seller and a stakeholder in the marketplace. This model promotes:

Economic Autonomy: Owners control pricing and sales, directly influencing their financial outcomes based on asset management.

Continuous Creator Compensation: Through royalties, creators continue to receive benefits from their work, encouraging ongoing participation and innovation in the marketplace.

Decentralized Trading: Reduces reliance on centralized authorities, enhancing the platform's resilience and flexibility.

By integrating minting capabilities with dynamic pricing and secure, autonomous sales transactions, the ROYALNFT project at the EthGlobal Hackathon represents a significant advancement in how digital assets will be created, traded, and monetized. Supports truly decentralized and owner-driven marketplaces that will facilate the exchange of data as value in the transition towards a knowledge economy.

How it's Made

Getting the ROYALNFT immutable royalty to its current state took over 100 hours of development and testing. Essential tools include foundry and remix working in tandem. Born of frustration with existing voluntary royalty payment systems ROYALNFT did a deep dive down the rabbit hole creating a compressive solution to immutable royalties as payments. Extrapolated from the concept of a SoulBound that cannot be sold sparked the idea that the transfer function was the key to immutable royalty payments. After crushing thousands of bugs and running forge test -vvv till my fingers hurt progress was made. At the onset, royalty payments were assumed to be one component of my contribution to the EVM community. As ROYALNFT matures and integrates the other project components NFROYALTY.sol will include Hodl721 for adding royalties to existing collections, pkNFT for adding prompt data storage and agent trading with royalties and NFTapi leverage LIT encryption with chainsafe storage. ROYALNFT key feature is the storage of immutable variables: Deployer is recognized as the contract creator, with this address being immutable and payable. Setup includes fixed and percentage-based royalties for the deployer, ensuring the deployer has the option to receive compensation from transactions facilitated by the contract.

Salesand Royaltiy Management Structure :

TokenSaleInfo: Stores sales-related data, including the price of each NFT. RoyaltyInfo: Captures details about royalties for each NFT, delineating terms for both the creator and deployer. Mappings:

tokenSalePrices: Links token IDs with their sale information. royalties: Connects token IDs with their respective royalty agreements.

Events:

Minted: Signals the creation of a new NFT, logging details like the token ID, creator, and initial sale price. Sold: Announced upon the sale of an NFT, detailing the transaction's specifics, including the involved parties and the sale price. Minting: Allows any participant to create a new NFT by providing a URI and sale price, with the token immediately available for trading upon creation. Sale Price Management: Empowers NFT owners to adjust their asset's sale price in response to market demands or personal valuation changes. BrokerNFT: Manages secure transactions for NFT sales, verifying payments, executing transfers, and distributing funds appropriately, including royalty payments. Royalty Calculation: Internally calculates the due royalties based on sale price, comparing fixed amounts to percentage values to ensure fair compensation. Public Price and Royalty Access: Offers functions like getSalePrice and calculateRoyaltyPublic to improve transparency and facilitate third-party integrations.

ROYALNFT provides creators with an immutable commission. brokerNFT function is the key component making the marketplace an asset based event. Every owner mints as a creator to establish royalties on their assets and the sale function is internal to the ROYALNFT. This opens a truly decentralized marketplace of immutable creator controlled rotyalty collections.

The ROYALNFT contract creates a platform where each NFT owner is the creator and the seller as a stakeholder in the marketplace promoting:

Economic Autonomy: Owners control pricing and sales, directly influencing their financial outcomes based on asset management.

Continuous Creator Compensation: Through royalties, creators continue to receive benefits from their work, encouraging ongoing participation and innovation in the marketplace.

Decentralized Trading: Reduces reliance on centralized authorities, enhancing the platform's resilience and flexibility.

By integrating minting capabilities with dynamic pricing and secure, autonomous sales transactions, the ROYALNFT project at EthGlobal represents a significant advancement in how digital assets are created, traded, and monetized. It supports a truly decentralized and owner-driven marketplace empowering owners as creators with immutable royalty commissions for data exchange.

background image mobile

Join the mailing list

Get the latest news and updates