ConvexAIEth
calc_wrapped_from_want
calc_wrapped_from_want
Calculates amount of want tokens after wrapping.
Parameters:
Return value:
unwrap
unwrap
If wrapped amount is greater than 0, remove wrapped amount from curve's liquidity and deposit balance of the contract to the wrapped ethereum.
Parameters:
Return value:
wrap
wrap
Calculates wrapped amount from want amount, removes wrapped tokens from wrapped ethereum and after converting them, deposits them to the curve's pool.
Parameters:
Return value:
prepareReturn
prepareReturn
Calculates curve and convex tokens and swaps them to ETH, sells extra rewards, after that is done, calculates and returns value of profit, loss and dept payment.
Parameters:
Return value:
Last updated