GHO Bank is a decentralized application which stakes your assets on your behalf on Aave V3 Market. The purpose of the project is to automate the whole staking process and availing staking rewards. Also with GHO tokens as decentralized governed stable coin, borrowing them and using them as the primary token for all the transactions as well as for paying of gas fees.
Following are the important components for the project:
- Server: listens and executes the supply & supplyWithPermit functions in Bank Contract
- Client: a decentralized application that helps you stake, withdraw, borrow GHO and earn stake rewards.
- Contract: Bank contract which helps the server interact with AAVE V3 Market on the behalf of the user.
The whole listening event works on the prerequisites of viem watchContractEvents.
The above illustration depicts the addition of new transaction approvals that are to be signed by the user where the assets threshold
is fetch during the onboarding.
The above illustration depicts the execution of supply function when the approval is given after a certain delay set by the user during the onboarding.
The tokens automatically staked on the behalf of the user can be leveraged by the user to borrow GHO casually and use it for all kind of transactions and as well as a paymaster i.e. using GHO for paying gas fees.
Contracts: https://github.com/keshavsharma25/gho-bank Server: https://github.com/keshavsharma25/gho-bank-server
Bank Contract Address: 0x6851b17D206Fb6820780F797343AFfC3a1f0b556
Due to time constraints, we were not able to complete the following:
- Decentralized App Frontend
- Dashboard
- GHO Permits
- Send Assets
- Smart Wallet Integration
- Database integration in frontend
We hope to complete this project even after the hackathon and improve the UX of defi apps.