xHousing

Overview

In Abuja, Nigeria, the real estate market faces significant challenges that hinder both investors and developers. The high cost of entry, lack of access to liquid funds, and rising construction costs due to inflation create a market that is inaccessible to many potential investors and strained for developers. This situation results in insufficient housing availability, sub-standard construction quality, and expensive housing prices, both for purchase and rental. xHousing aims to address these multifaceted issues by leveraging blockchain technology to democratise real estate investment and provide developers with much-needed liquidity.

Dashboard View Dashboard View

Properties View Properties View

Features

Tokenization of Real Estate

  1. Fractional Ownership: Real estate properties are tokenized, allowing multiple investors to own fractions of a property.
  2. xProject Tokens (XPT): Each property has its own SFT collection representing fractional ownership. These tokens are called xProject Token (XPT).

XHT Token

  1. Native Token: Used for initial fundraising and rewarding participants.
  2. Staking: Users can stake XHT and Property SFTs to earn rewards.
  3. Governance: Stakers receive governance NFTs for voting rights and loyalty programs.

Referral System

  1. Bonuses: Referrers earn bonuses when users they referred claim property rent or staking rewards.
  2. Royalties: Referrers earn a fraction of the royalties from secondary sales of XPTs.

Rent Rewards

  1. Monthly Distribution: Rent paid in various currencies is converted to XHT and distributed to XPT holders of that property over a year.
  2. Burn Mechanism: A fraction of the rent converted to XHT is burned, increasing the token's value.

Impact and Relevance

Democratization of Real Estate Investment

  1. Accessibility: Allows individuals with limited capital to invest in real estate, traditionally a high-barrier market.
  2. Inclusivity: Broadens the investor base and democratizes access to lucrative real estate investments.

Support for Estate Developers

  1. Liquidity: Provides developers with immediate funds through token sales, ensuring timely and quality project completion.
  2. Affordable Housing: Helps address the housing challenges in Abuja by enabling the development of high-quality, affordable housing projects.

Economic Growth

  1. Boosting Investments: By facilitating more investments in real estate, the platform contributes to economic stability and growth in the region.
  2. Job Creation: Development projects lead to job creation and improved infrastructure in local communities.

Detailed Description of the dApp's Design and Architecture

Architecture

The backend of the xHousing dApp is powered by four smart contracts deployed on the MultiversX devnet. The frontend is a Next.js app, and it is deployed at x-housing.vercel.app

Smart Contracts

  1. Coinbase Contract: Link to code

    The Coinbase contract is responsible for managing the distribution and economics of XHT tokens within the xHousing platform. It interacts with the XHTModule to perform token operations such as minting and burning. The contract ensures efficient token supply management by distributing XHT tokens to users participating in platform activities (e.g., fundraising, staking, referrals) and burning tokens to support deflationary mechanisms. Ownership and access control mechanisms are included to restrict certain operations to authorized parties, maintaining the integrity and security of the platform's token economy.

    Deployment: erd1qqqqqqqqqqqqqpgqmepkngjhgw4kff4u976rmdpjpv3uc4mp0fuskv4y8j

  2. xHousing Contract: Link to code

    The xHousing contract is the main contract for the xHousing ecosystem. The management of ecosystem users will is done in this contract. User referrals, staking and governance is done here. Collection of staking rewards is also done here.

    Deployment: erd1qqqqqqqqqqqqqpgqxaz0puawlrgazrq2d0qg58thd776fjaz0fusy7eqgv

  3. xProject Template Contract: Link to code

    The xProject contract template serves as the foundational blueprint for deploying individual real estate projects within the xHousing ecosystem. Each xProject contract represents a unique real estate development, managing its ownership, revenue distribution, and participant interactions.

    Deployment: erd1qqqqqqqqqqqqqpgq2dwfaw667t5tp059jdfhwxqj34lwn8t80fusl3l40l

  4. xProject Funding Contract: Link to code

    The xProjectFunding contract is designed to manage the crowdfunding process for real estate projects within the xHousing ecosystem. This contract owns and deploys xProject contracts which represents the properties on the platform. This contract facilitates the collection of funds from participants, handles participant registrations, deploys the xProject contract upon successful funding, and disburses tokens (XHT and SFT) to contributors. If the funding goal is not met by the deadline, it allows participants to withdraw their funds.

    Deployment: erd1qqqqqqqqqqqqqpgq4qv8rgwxwmf9ujnlsxe2mgg9vgzdgjnu0fusn9thex

Media

Project Set Up

Prerequisites

You must have your environment setup for MultiversX development and NextJS app development. Yarn is also required for NodeJS package management.

Deploy Contracts

  • Clone this repository
  • cd interact-rs
  • Create a config.toml file with the following content set
contracts_owner_pem = "path-to-pem-file.pem" # Used to deploy all contracts
gateway = "the-multiversx-public-gateway-you-chose-or-alocal-one" # eg "https://devnet-gateway.multiversx.com"
  • Run cargo run start-ico. This will deploy all the contracts and create an interaction folder for the deploment network. The folder will contain info about the contracts and ecosystem state.
  • Inside the interaction folder a state.toml file will be created, copy the contents and populate the appropriate x-housing-ui/src/config/** file
  • Now cd into the x-housing-ui folder and run yarn install
  • Run yarn build-{CONFIG} where CONFIG can be devnet, localnet, etc
  • Finally run yarn preview then visit the page at http://localhost:3000