I came up with this idea because I read that property price might go down in city centers hit by covid as people move to work remotely. After looking around for data sources I found a fantastic feed by the U.K. government for average prices. This can also become a building block for real estate tokenization and on chain mortgages.
What it does
Real Hedge is a new de-fi protocol aiming to provide hedging facilities to real estate property owners. The protocol is comprised of multiple parts:
- Chainlink integration
- Aave integration
- rDAI an ERC20 token for liquidity providers
- REPLC an ERC721 token for representing individual policies
- On chain underwriting
- On chain claims handling
The protocol allows anyone to hedge real estate pricing risks in a fully decentralised fashion. A user can submit a request to purchase a policy to the on-chain underwriter, specifying duration, cover amount and location. The underwriter, using the chainlink oracle and the data sources, creates a policy with a set strike price. Whenever the price goes below the strike price the policy holder can claim the cover amount on his policy. The claiming process also relies on the chainlink network to assess the current property price, if the strike price is met the cover is transferred to the policy holder. The liquidity for paying claims is provided by LPs. LPs earn returns on their investments in two ways, premiums and interests collected on Aave money market.
When an LP deposits DAIs into the protocol, new rDAI are minted for the LP. rDAIs are redeemable for a pro-rata amount of DAI held in treasury. Tokens can be redeemed only if enough liquidity is available for policies claims.
Since policies can potentially have long durations, 90% of the capital stored in treasury is invested in Aave and redeemed as necessary for operational needs.
Each policy is represented by a NFT that can be traded on secondary markets. REPLC tokens are burned on expiry or after a successful claim.
At the moment the protocol covers only the U.K. and it uses primary data from the British government (https://landregistry.data.gov.uk/). The highest price resolution is the local authority area (i.e. Enfield). This helps in preventing possible price manipulations that can happen when tracking prices movements in smaller areas.
How I built it
Solidity, Chainlink, React, Typescript, Truffle Suite, Waffle
Challenges I ran into
Debugging Solidity code is always tricky, also initially finding the right data source for the job.
Accomplishments that I'm proud of
This is now in testnet and it works fine, fetches real prices and can "almost" be used!
What I learned
Chainlink integration, Aave integration, NFTs and much more
What's next for Real Hedge
Final destination is mainnet, before that I to address several outstanding issues
- Auto-complete for the location field
- Better notifications handling
- Realistic pricing model
- Use of current price in pricing
- Handle time durations and delayed data feed
- More geographies