What this does
This plug rebalances an Aave position toward a debt target set at the liquidation ceiling divided by a caller supplied health factor divisor. It asks the caller for the Aave market, the supply_token collateral, the target_health_factor divisor, and the borrow_token debt asset. When current debt exceeds target it repays borrow_token and withdraws supply_token; otherwise it supplies supply_token and borrows borrow_token to lever up. Sizing this by hand or against a stale oracle price can misjudge the ceiling and push the position toward liquidation.
Actions · 23























Related plugs · 8