Skip to content

A Bed and Breakfast dApp run on Ethereum. Includes a token + schedule system (Solidity) and full front-end (React + ethers.js) built with Hardhat.

License

Notifications You must be signed in to change notification settings

LambyPants/Hotel-ETH

Repository files navigation


Hotel ETH - Watch Demo Video

Hotel ETH

A (fictional) Bed-and-Breakfast run on Ethereum
Come Book a Room on Sepolia Testnet
View the Demo »
Contact Lamby · Report Bug · LinkedIn

Table of Contents

  1. About The Project
  2. Getting Started
  3. Contact
  4. License

About The Project

Hotel ETH is demo project showcasing how a traditional, fixed-price business could be run on Ethereum.

Key features include:

  • An ERC-20 token
    • can be purchased in advance with ETH at a fixed USD price (using Chainlink pricing oracles)
    • can be redeemed for a night at the Hotel (1 token = 1 night).
    • can be refunded to users after redemption if the booking is in the future
  • A full reservation and business management system built with Solidity.
    • owners can change the fixed USD price of tokens (similar to how hotel rates change)
    • owners receive any proceeds (in ETH) at time of sale
    • owners can mint / burn tokens freely
  • A full front-end interface built in React + Ethers.js
    • users can purchase tokens at a price set by the owner (paid in ETH)
    • users can redeem + refund tokens used to book reservations at the Hotel
    • users can see / check availibilty at the hotel and view all of their previous reservations
    • the UI dynamically updates when other users make reservations at the Hotel
    • the UI/UX performs automatic field + action validation
  • A development pipelines built for local, rinkeby, and kovan network environments.

This project is meant for educational purposes only, but in theory you could extend the functionality to run a real (or virtual) business with the underlying infrastructure.

Built With

Getting Started

Install MetaMask

You will need an Ethereum wallet installed to use the demo or run this project locally. I recommend MetaMask.

Obtain Test ETH

Obtaining test ETH is harder than it should be. 2024 update - it's even harder now. Good luck! I recommend the Chainlink faucet.

Buy, Redeem and Refund Tokens

You can purchase tokens in the app after connecting your wallet. the Price is set by the Hotel Owner and is paid in ETH.

The app is deployed on Sepolia Testnet.

Running Locally

For Developers

  1. Clone the repo

    git clone https://github.com/LambyPants/Hotel-ETH
  2. Install NPM packages

    npm install
  3. Run local blockchain + development server

    npm run dev

    To deploy your own version of the app, you need to fill in the keys.js file generated for you on install:

    module.exports = {
      DEPLOY_PRIVATE_KEY: '',
      ALCHEMY_API_KEY_SEPOLIA: ''
    };

Contact

Ryan (Lamby) Lambert - appsbylamby@gmail.com

View my other projects: https://github.com/LambyPants

License

Distributed under the MIT License. See LICENSE.txt for more information.

(back to top)

About

A Bed and Breakfast dApp run on Ethereum. Includes a token + schedule system (Solidity) and full front-end (React + ethers.js) built with Hardhat.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published