This repository contains the smart contracts source code and markets configuration for Hang Protocol V1. The repository uses Hardhat as development enviroment for compilation, testing and deployment tasks.
The hang protocol is an innovative lending protocol that can return profits to both borrowers and lenders by utilizing 'the Use Right Delegated Interest Rate Structure'. The hang protocol is a 100% DAO operated by smart contracts, and all processes such as loans, repayments, and risk management are processed without human intervention.
The hang protocol has the functions to implement a loan with three characteristics: 1) interest free, 2) no maturity, and 3) leverage, and its structure is different from the general lending protocol. The biggest difference in terms of technology can be summarized in three ways: interest rate model, liquidity pool management, and risk management.
The documentation of Hang V1 is in the following Hang V1 documentation link. At the documentation you can learn more about the protocol.
Follow the next steps to setup the repository:
- Install
node.js & npm
and Runnpm install
- Create an enviroment file named
.env
and fill the next enviroment variables
# Mnemonic, only first address will be used
MNEMONIC=""
# Add Alchemy or Infura provider keys, alchemy takes preference at the config level
ALCHEMY_KEY=""
INFURA_KEY=""
# Optional Etherscan key, for automatize the verification of the contracts at Etherscan
ETHERSCAN_KEY=""
# Optional, if you plan to use Tenderly scripts
TENDERLY_PROJECT=""
TENDERLY_USERNAME=""