YearnSupply
Action ID: 0x7b4c8fad
Supplies tokens to Yearn vault
const yearnSupplyAction = new dfs.actions.yearn.YearnSupplyAction(token, amount, from, to);
This is a DFS STANDARD_ACTION.
The address from which we're pulling tokens must approve proxy
If amount is uint.max the whole balance is pulled and supplied
Input:
/// @param token The address of token to supply
/// @param amount Amount of token to supply
/// @param from The address from which to pull tokens from
/// @param to The address where received yTokens will be sent to
struct Params {
address token;
uint256 amount;
address from;
address to;
}
Return value:
return bytes32(amountReceived);
Events:
emit ActionEvent("YearnSupply", logData);
logger.logActionDirectEvent("YearnSupply", logData);
Last modified 10mo ago