-
Notifications
You must be signed in to change notification settings - Fork 6
Open
Labels
Description
Description
Create a token adapter contract that facilitates the movement of collateral tokens in and out of the system. The adapter should interact directly with the Vault Engine Contracts to manage collateral balances on vaults.
Tasks
- Design the collateral token adapter contract interface
- Implement method for depositing and locking collateral tokens within the adapter. The locked collateral should be represented in the Vault module
- Implement method for withdrawing locked collateral tokens from the adapter
- Integrate the adapter with the Vault Module Contracts. The adapter should call the Vault module to create a representation of the collateral tokens and also remove the representation as needed.
- Write tests to ensure the functionality of the collateral token adapter
NB: This has previously been implemented here: https://github.com/Descent-Collective/protocol-core/blob/module/adapter/contracts/adapter.sol#L13