This repository contains multiple implementations of two EIPs (Ethereum Improvement Proposals):
- ERC-7432 (Non-Fungible Token Roles).
- ERC-7589 (Semi-Fungible Token Roles).
The goal of these EIPs is to introduce role management for NFTs. Each role assignment is associated with one or more
NFTs and expire automatically at a given timestamp. Token Roles can be deeply integrated with dApps to create a
utility-sharing mechanism. A good example is in digital real estate. A user can create a digital property NFT and grant
a keccak256("PROPERTY_MANAGER")
role to another user, allowing them to delegate specific utility without compromising
ownership. The same user could also grant multiple keccak256("PROPERTY_TENANT")
roles, allowing additional users to
access the digital property.
You can find the full specification here: ERC-721 Token Roles and ERC-1155 Token Roles.
- ERC-7432 NFT Roles Registry: ERC-721 NFT Owners can grant roles without depositing NFTs.
- ERC-7589 SFT Roles Registry: ERC-1155 NFT Owners can grant roles after depositing NFTs.
- ERC-7589 Single-Role SFT Roles Registry: ERC-1155 NFT Owners can grant a single pre-defined role after depositing NFTs.
npm ci
npm run build
npm run test