This repository contains the smart contracts for Hector DAO, a decentralized autonomous organization operating on the Fantom blockchain. Hector DAO aims to provide a decentralized financial center through various use cases, including staking, bonding, and more.
Hector DAO utilizes a set of smart contracts deployed on the Fantom network to facilitate financial transactions with crypto assets. Participants can acquire the native token, HEC, which carries voting rights within the DAO. HEC can be obtained by exchanging other crypto assets or purchasing from existing holders on the secondary market.
The repository is organized into the following directories:
- bond: Contracts related to the bonding mechanism.
- staking: Contracts for staking HEC tokens.
- treasury: Manages the DAO's treasury operations.
- utils: Utility contracts and libraries.
- voting: Contracts facilitating governance and voting within the DAO.
HectorBondDepository.sol
: Manages the bonding process, allowing users to acquire HEC tokens at a discount by providing liquidity or other assets.HectorStaking.sol
: Handles the staking mechanism, enabling users to stake their HEC tokens in return for rewards.HectorTreasury.sol
: Oversees the treasury, ensuring the DAO's assets are managed and utilized effectively.DAO.sol
: The core governance contract, allowing HEC token holders to propose and vote on changes within the DAO.
To interact with or develop on top of Hector DAO's contracts:
- Clone the Repository:
git clone https://github.com/T-rustdev/hector-dao-smart-contract.git cd hector-dao-contracts
- Install Dependencies: Ensure you have Node.js and npm installed. Then, install the necessary packages:
npm install
- Compile Contracts: Use a Solidity compiler to compile the contracts. For example, with Hardhat:
npx hardhat compile
- Run Testss: Execute the test suite to ensure all contracts function as expected:
npx hardhat test
To deploy the contracts to the Fantom network:
-
Configure Network Settings: Update the hardhat.config.js file with the Fantom network configuration and your deployment account's private key.
-
Deploy Contracts: Run the deployment script:
npx hardhat run scripts/deploy.js --network fantom