The PotionVault is the main Poison.Finance contract, it implements the logic for Vault, through which users can mint new pTokens against their deposited collateral (BUSD, USDt, USDc, DAI, MIM, tUSD, FRAX, or ibTokens like cDAI, cUSDC, cUSDT, aDAI). Current prices of minted pTokens are provided by Cahinlink Price Oracles and determine the Cratio of each Vault. The PotionVault Contract also contains the logic for liquidating Vaults with Cratios below the minimum for their minted pTokens.
interface IPotionVault {
function open(uint collateral, uint amount, uint id, uint synid) external;
function close(uint id) external;
function deposit(uint id, uint collateral) external;
function withdraw(uint id, uint amount) external;
function burn(uint id, uint amount) external;
function mint(uint id, uint amount) external;
function liquidate(uint id, address account, uint amount) external;