Repository navigation
Treasury
- Contract Name: Treasury.sol
- Type/Category: Treasury/Governance
- Contract Source: https://github.com/element-fi/council/blob/main/contracts/features/Treasury.sol
The Treasury contract is an isolated holder of Element governance funds that allows an authorized address to move them. This isolation improves the security of the system and prevents a bug from compounding to total fund loss.
The contract only contains the functionality to allow an authorized address to move the ERC20 and ETH tokens it contains; to set ERC20 allowances or to make generic calls. The stored data is the authorized address.
The contract receives a call from an address and then checks if it is authorized to move funds. If the address is authorized, it makes an ERC20 transaction that can move funds or set allowances.
Sending the funds to the wrong address (person or contract) or approving the wrong contract can result in the loss of funds.
It is important to note that, if the ownership of the contract is reset, it should be reset to an address that can make calls or the funds in the treasury will be frozen in place.
Council Wiki
Technical Guides
- Getting Started
- Council Deployment Guide
- Reference UI Deployment Guide (GitHub Pages)
- How to Create Your Own Voting Vault with Council
- SDK Guide: Using Typescript to interact with Council Contracts
- Contributors Guide
Video Tutorials
- Council UI Overview
- Deploying the Council UI to Github Pages
- Get Started with the Council SDK
- Extending the SDK
Governance Proposal Framework
- Governance Proposal Framework Template
- DAO (Social) Proposal Template
- Protocol (Executable) Proposal Template
Smart Contract Documentation
- Overview
- Core Voting
- Voting Vaults Overview
- Voting Vault Example: Locking Vault
- Voting Vault Example: Vesting Vault
- Voting Vault Example: Governance Steering Council (GSC)
- Possible Voting Vaults Examples
- Timelock
- Treasury
- Spender
- Optimistic Grants
- Optimistic Rewards
- Simple Proxy
Glossaries
Security and Audits