by 0x87956abc4078a0cc3b89b419928b857b8af826ed (Nacho)
Linked Draft Proposal
Summary
Proposed is an enhanced architecture and design for LinkedWearables to address client performance issues caused by low-performing API Resolvers and a simplification process for new third parties, from inception to maintenance of collections
Abstract
After initially considering shutting down Linked Wearables due to performance drawbacks, it has become evident that the functionality is highly valued by the community and has a significant potential for expansion and adoption. However, the current model also presents bureaucratic challenges and can be cumbersome for content creators.
Motivation
To foster greater adoption and streamline the cost and maintenance of LinkedWearables, it is necessary to implement a new process and architecture capable of adapting to the demand while preventing any potential performance issues for the client. This new model can also help improve the user experience when managing LinkedWearables in-world.
Specification
We propose the following changes to the current Linked Wearables implementation:
- Remove the ThirdParties API dependency:
- Enhance the URN already used for third-party wearables to provide enough information about the NFT item with a Linked Wearable associated.
- Validate NFT Ownerships on-chain using a RPC Provider and the corresponding Smart Contracts.
- Creating a new UI on top of the builder to manage Linked Wearable Collections
- Fetching all Linked Wearables for the backpack using a new service that will feed from the builder.
- Allow third parties to “Pay” directly to the DAO rather than going through a 4M MANA threshold voting process.
- Create a migration plan for existing thirdparties.
Impacts
Reduced entry costs and complexity for Third-Party Providers:
- Eliminated Resolver API: Third-party providers no longer need to invest in developing, deploying, and maintaining a resolver API to validate LinkedWearables ownership.
New Cost Structure:
- DAO-Covered RPC Calls: The DAO will cover the cost of new RPC calls used to retrieve user-owned NFTs and validate asset ownership in scenarios like profile deployment, node synchronization, and profile sanitization. The cost of the NFT API will be waived from the Foundation to the DAO. For pricing examples, you can refer to the available pricing plans at https://docs.alchemy.com/reference/pricing-plans - the API calls and costs will be capped to avoid unexpected expending.
This new cost will be covered by a new third-party registration process, but it is beyond the scope of this poll. They will be addressed in a subsequent poll to discuss and determine fees and the permissible quantity of allowed published wearables.
Implementation Pathways
Standardized URN: Implement a new URN format that incorporates all necessary segments for performing on-chain ownership validations of the associated NFTs.
urn:decentraland:matic:collections-thirdparty:[3rd-party-NAME]:
[contractAddressChain]:[contractAddress]:[itemId]:[NFTTokenId]
3rd-party-NAME
: Name of the Third PartycontractAddressChain
: The Chain of the NFT’s smart contracts (Polygon, Ethereum).contractAddress
: The address of an ERC-721 or ERC-1155 smart contract for the NFT collection that will have associated Decentraland Item.itemId
: the id of the Decentraland wearable.NFTTokenId
: the 3rd party NFT tokenId that will have the associated wearable.
LinkedWearables Service: Create a service specifically designed to manage LinkedWearables and its third-party providers. This service will:
- Store Third-Party Information: Securely store data from third-party providers, including smart contract addresses for their collections, chain IDs used, and NFT IDs corresponding to specific Decentraland wearables.
- Retrieve User-Owned LinkedWearables: Upon receiving a user’s wallet address, the service will efficiently return URNs for all LinkedWearables owned by that user. This process involves retrieving the owned NFTs associated with the wallet and cross-referencing them with Decentraland wearables stored in the local database with the information set by the third party.
Decentraland UI: Third-Party Provider Management
- Registration and Management Portal: Implement a dedicated user interface for third-party providers. This interface will allow providers to:
- Register as a Provider: Complete a streamlined registration process.
- Collection Management: Manage their collections of LinkedWearables and the mappings between the NFTs and the Decentraland Wearables.
- Data Storage: Information entered by providers during registration and management will be securely stored within the LinkedWearables service.
Catalyst Ownership Validation and Backpack Management:
- LinkedWearables URN use: Leveraging the extended URN format enables Catalyst to perform ownership validation of NFTs associated with the LinkedWearbles. The URNs provide all necessary information for Catalyst to directly call the relevant smart contracts using RPC calls.
- Backpack Endpoint: Introduce a new “backpack endpoint” within Catalyst. Clients can use this endpoint to request all LinkedWearables associated with a specific wallet address. This streamlines backpack management by eliminating the need to filter items provider-by-provider, as is currently required.
Smart Contract Updates
- The existing version of the smart contracts responsible for managing third-party information must undergo an upgrade to enable the registration of new third parties.
Use Case: Update Collection from the Builder
External Image
Use Case: Retrieve All Linked Wearables for Display in the Backpack
External Image
Conclusion
Removing third-party APIs and implementing changes to the URN will ensure all NFT item ownership validation occurs on-chain, enhancing reliability. This model simplifies the onboarding process for new third parties by eliminating API development and maintenance costs. On the other hand, it establishes a mechanism to boost adoption among third parties and facilitates more efficient wearables management within the client interface.