This is a submission for the Build Better on Stellar: Smart Contract Challenge : Create a Tutorial
The Team
- Fabricius Zatti(Fifo): fazzatti
- Victor Hugo Martins: victorhugo-pmartins
Your Tutorial
This submission is complementary to another demo submission in a separate category.
For this submission we decided to record a series of four videos covering a proposed standard for extending asset capabilities with classic wrappers. The proposal defines a structured approach to wrap classic assets with unique custom rules that can be either enforced by asset issuers or made option by any ecosystem builder.
- Playlist link
- Video #1 - Unlocking Stellar's Potential: A New Approach to Asset Wrapping: This video covers the overall concept and objective behind the proposed standard for the Classic Asset Wrappers.
- Video #2 -Dynamic Asset Control with Enforced Wrappers on Stellar: This video covers entirely the hypothetical use case of an enforced wrapper with custom probation rules. It explains the overall concept of the prototype, performs a complete walkthrough the interactive demo and then covers the contracts implementation overview.
- Video #3 -Gamify Your Assets: Optional Wrappers on Stellar: This video covers entirely the hypothetical use case of an optional wrapper with custom gamified campaign. It explains the overall concept of the prototype, performs a complete walkthrough the interactive demo and then covers the contracts implementation overview
- Video #4 -Building a Counter Contract from Scratch with Wrappers: Covers a complete step-by-step building a Counter contract from scratch, leveraging the Wrapper standard, then utilizing the playground project to implement a client and run integration tests in Testnet.
What I Created
We believe the community can benefit in different ways from our submission and the proposed standard discussion:
- Reference contract implementations to serve as reference and base for other use cases in the ecosystem.
- Node project with common automation, typescript clients and a structured way for writting and testing complex contract use cases in Testnet with the Stellar Plus library.
- Interactive live demos to experiment hand-on the use cases and instigate creative ways of innovating with use cases and user experience.
Journey
We had a blast! It's been a long time since we've been maturing the idea of a classic wrapper, but we didn't have the opportunity(and perhaps the initial "pushing" motivator) to try and validate the de approach. We took the opportunity to work on a standard proposal as we moved through the use cases implementation and a lot(for real, A LOT!) of testing! We kept going back, rethinking, prototyping, testing again, rinse and repeat.
In the past, we have experimented with Soroban in many ways, but we believe that a big key differentiator for Stellar is the ability to combine the best of both worlds(Soroban and classic) into hybrid assets. With that in mind, we wanted to explore structured approaches for extending classic assets' behavior in unique ways and also build something for the community's benefit.
The process was highly focused on prototyping and testing first-handed in testnet to get a feel for how well different designs would support different use cases as well as integration with the front end and wallets. Our approach was mainly around:
- Implement quick rounds of the soroban contracts
- Compile
- Implementing/updating the typescript clients
- Running integration tests for Testnet
- Fail/find gaps
- Repeat
We wanted to write more tests in Rust, but there was a limiting factor. Currently, there is no ready-to-use or simple way of simulating different control flags like auth_revocable
in Rust tests(I think I opened an issue about it months ago). With this in mind, we decided to overcome this by quickly building and testing with the typescript clients and Stellar Plus (Shameless plug). This allowed us to get rapid feedback from the behavior in the testnet, which kept our feedback coming and allowed speedy prototyping and refinement.
We're looking forward to getting feedback from the devs and builders in the community!
Top comments (2)
Hey @fazzatti, can you confirm the DEV usernames of Victor so we can award them the completion badge for their profile?
That's AWESOME! Great work!