# POC: Wyre DAO (Test) using Aragon
## Transactions
Calling company template contract
https://rinkeby.etherscan.io/tx/0xb9f6eaa3fb01bc09395e7cd6e43c06da2f1d4539eb4b4e9f5e3a6ad89cfe7b27
- Deploy Token
- Deploy DAO
- Installing App (multiple txs)
- Setup DAO
## DAO properties, and Permissions
WyreD DAO has it's own token called DESK which manages/controls everything related to the DAO. SInce this is a centralized DAO, DESK holders will be Wyre Employees, Advisors etc. DESK holders will be able to manage everything on the DAO through Voting Desk (VotingD) app.
As we can see on the ACL above that VotingD is the manager of everything.
**Kernel**
Kernel is the heart of the DAO and is responsible for everything that is happening on it. APP_MANAGER permission allows VotingD to install, remove apps on our DAO
**ACL**
Access Control List is the list of all the permissions on apps of the DAO. The above list in the table is an ACL. VotingD has permissions to create permissions on the ACL.
Note: Creating permissions mean assigning Manager to any app action. Once a manager is assigned it can add/remove Grantee of that action any no of times.
**Voting**
CREATE_VOTES: TokensD, Any desk token holder can create a vote on our DAO
MODIFY_QUORUM, MODIFY_SUPPORT: VotingD, Through voting among DESK holders, we can change QUORUM, SUPPORT of the votings app.
Note:
1. *Support* is the relative percentage of tokens that are required to vote “Yes” for a proposal to be approved. For example, if “Support” is set to 50%, then more than 50% of the tokens used to vote on a proposal must vote “Yes” for it to pass.
2. *Minimum Approval* is the percentage of the total token supply that is required to vote “Yes” on a proposal before it can be approved. For example, if the “Minimum Approval” is set to 20%, then more than 20% of the outstanding token supply must vote “Yes” on a proposal for it to pass.
**Tokens DESK**
There will be some initial holders of DESK tokens when the DAO is bootstrapped, after that MINT, ISSUE, BURN of new tokens will be controlled by VotingD app.
**Tokens WWBTC**
MINT: Tokens Request, Once a token request app is approved then only tokens request app can mint WWBTC tokens to user who requested
BURN: Redemptions, When someone wants to redeem their WWBTC, they can do it via Redemptions app and they will get equivalent amount of WBTC back. WWBTC will be burned
Note: There is no permission set for ISSUE as there is no other way to issue WWBTC other than minting it through tokens request app.
**Vault**
Our DAO's treasury. It will hold the WBTC sent by users.
Transfer Vault’s Tokens: Redemptions, Finance will be two apps which will be able to transfer funds out of Vault. When someone redeems WWBTC, redemptions app will trabsfer WBTC from Vault to the User.
Finance app will also be able to use Vault to deposit funds into it, withdraw funds out of it (to move into wyre internal which will later be used to generate yield)
**Finance**
App responsible for CREATE, MANAGE, EXECUTE payments and interact with the vault directly. Every action on finance is controlled through VotingD
**Tokens Request**
Set Token Manager: VotingD, action responsible for setting a token manager for requests app. In our case, WWBTC's token manager (Tokens WWBTC) will be assigned.
Set vault: VotingD, where would the money deposited by users whoc are requesting WWBTC go? To the vault set here
Finalise token request: TokensD, anyone who holds Desk tokens can finalise a token request which will mint WWBTC for the user and send WBTC to the vault. This permission can also be changed to VotingD in which case, approval would require voting among Desk holders.
Add/Remove a token from the accepted tokens: Add/Remove tokens which can be accepted
**Redemptions**
TBD
## Access Control List (ACL)
DESK Holders have high concentrated power. They run the DAO, they can vote and manage everything.
What things they can vote on to change is listed below along with other permissions.
| App | Permission | Grantee | Manager |
| ----------------- |:------------------------------------------- | ------- | ------- |
| Kernel | APP_MANAGER | VotingD | VotingD |
| ACL | CREATE_PERMISSIONS | VotingD | VotingD |
| Vault | Transfer Vault's Tokens | Finance, Redemptions | VotingD |
| VotingD | CREATE_VOTES | TokensD | VotingD |
| VotingD | MODIFY_QUORUM | VotingD | VotingD |
| VotingD | MODIFY_SUPPORT | VotingD | VotingD |
| Finance | CREATE_PAYMENTS | VotingD | VotingD |
| Finance | EXECUTE_PAYMENTS | VotingD | VotingD |
| Finance | MANAGE_PAYMENTS | VotingD | VotingD |
| TokensD | MINT | VotingD | VotingD |
| TokensD | BURN | VotingD | VotingD |
| TokensD | ISSUE | VotingD | VotingD |
| TokensWWBTC | MINT | Tokens Request | VotingD |
| TokensWWBTC | BURN | Redemptions | VotingD |
| Tokens Request | Set Token Manager | VotingD | VotingD |
| Tokens Request | Set Vault | VotingD | VotingD |
| Tokens Request | Finalize Token Request | TokensD | VotingD |
| Tokens Request | Add/Remove a token from the accepted tokens | VotingD | VotingD |
| Redemptions | Add token to redemption list | VotingD | VotingD |
| Redemptions | Remove token from redemption list | VotingD | VotingD |
| Redemptions | Redeem tokens from the vault | Any Account | VotingD |
## Steps to Deploy
1. Use Aragon UI to setup the DAO with the company template
2. Local 1hive dao https://rinkeby.client.aragon.org/#/0x2546cC1834D761434242976F5A2970Cc657cf7b7/permissions/
3. Installing new apps from aragon CLI and giving initial permissions so that it shows up in UI
4. 1Hive Installer http://installer.1hive.org/ to install some apps (not all and not multiple instances)
5. Running scripts with set env variables for mainnet
6. Mint tokens: `dao exec $dao $tokenManager mint <YOUR_ADDRESS> 1000000000000000000 $f`
7. `dao install $dao token-manager --app-init none $e` is correct `dao install $dao token-manager --app-init none $e` is also correct. Tx fetching error might come for no reason, just try again after some time.