Zenland as a smart contract escrow dApp is inspired by the need for decentralized escrow that is transparent, simple, geographically unrestricted, and less expensive than other existing escrow services. As a team with backgrounds in digital marketing, IT, web3, and cryptocurrency trading, we had to deal with strangers through P2P marketplaces and forums. To avoid being scammed some of us used third-party escrow, and some spent time researching other user's IP, location, social media profiles, forum posts and activity, service reviews, etc. As a result, we have become increasingly frustrated with how inefficient, human-dependent, and costly P2P trade became. This made us realize that many more people had to pay heavy escrow fees, go through hurdles of paperwork, or spend hours figuring out if the person they deal with can be trusted. Altogether it has contributed to the idea of a simple UI to create, deploy, and manage escrow contracts on a public blockchain without any external influence or additional cost.
What it does
The dApp we developed is the first decentralized escrow with stablecoin support for trustless P2P deals (websites, domain names, etc.). Much like a regular escrow it receives payment from the buyer's wallet address and releases it to the seller's wallet address after the product/service delivery. The difference is that the escrow is done through the use of smart contracts run on a public blockchain that receives and releases stablecoins when the contract conditions are met. For unsettled cases, users may request a neutral third party (a dispute agent) to review and resolve their case. Only in this case, Zenland allows third-party to review the conditions buyer and seller agreed to, and decide who gets the coins kept by the escrow contract. Dispute agents are individuals assigned to unsettled cases and will be voted by DAO as the demand for them grows in the future.
How we built it
Within the first week of researching escrow built before us powered by smart contracts on Ethereum, Polygon, and other EVM-compatible public blockchains, we knew there haven't been a similar dApp built for our end user - an online buyer or seller with no knowledge of code or smart contracts. So, the concept of escrow contract managed in real-time by both participants through a series of contract actions changing the contract state had to be visualized in Figma with multiple "if … else" scenarios. Next came the actual development process with unit tests. At this point, we had to consider as many user stories as we can to improve the dApp's UI/UX, build a secure wallet login, and state-neutral third-party rights for unsettled case resolution. Also, for transparency reasons, contract log messages were integrated with the contract-specific chat where users may track all their changes and interactions with the particular contract. Then, it was time for alfa testing where the team, our colleagues, and a few forum friends deployed over 150 contracts to multiple test networks including Polygon Mumbai and Ethereum Rinkeby with various amounts of USDT, USDC, and DAI.
Challenges we ran into
The biggest challenge was the escrow smart contract logic. Because no other project known to us has had a working escrow with smart contracts, we had to build specific constraints for when, where, and how buyers and sellers interact with the contract and the money it keeps. To protect a buyer from fraud, the contract had "buyer protection time or BPT", a time during which a buyer may release payment from the contract or open a dispute if not satisfied with the delivery. The contract rules allow a seller to release payment himself if neither action is taken by the buyer and BPT has ended. This conditional self-release has also posed a technical challenge.
Then, for cases when neither buyer nor seller is satisfied with the deal, a neutral third party with conditional access to a specific contract, the agent, had to be introduced and integrated with the contract itself and its chat.
A lesser challenge was to connect the control interface to MetaMask so that the user could confirm the transaction to call a specific contract function while on the page.
Accomplishments that we're proud of
As a small team with 4 full-time developers, UX/UI designer, QA, and 2 market researchers we had first to develop the concept in detail to spare developers from tedious work of rewriting the code. As of today, we are humbled to see contributions made by each team member to finally build a secure and simple alternative to centralized escrow. The results of the test contracts, both in technical (RPC, gas limits, contract calls, etc.), and non-technical terms (UI design), also look promising.
## What we learned
Zenland escrow dApp is a combined effort to bring value to the community through safety and certainty in the murky waters of P2P trade. Throughout the concept and dApp development we have grown professionally by resolving technical issues, implementing new techniques, exercising our Solidity, Python, and React skills, and ultimately implementing a business logic of escrow in smart contracts. Yet, most importantly, we have grown as a team from various cultural and religious backgrounds. This project not only shaped who we are as professionals but helped us understand the potential of trustless web3 in bringing people together.
What's next for Zenland
We believe Zenland is a smart contract-centered project that has a real-world potential to expand beyond escrow contracts. However, as the long journey starts with the first step, Zenland team aims soon to introduce the escrow to the general public, gather more feedback, work on dApp's accessibility connecting more wallets, and add more features based on initial feedback.
Log in or sign up for Devpost to join the conversation.