deposit namespace emits a program that makes protocol deposits, withdrawals, stakes or wraps from data. deposit.depositSource(spec) returns a function main() program with each call and its approval, which routes.compileSauceProgram compiles; deposit.listDepositTemplates() lists the supported calls, one template per protocol and action (aave-v3 supply, lido stake, weth unwrap, …).
@eco-incorp/sauce.
deposit.depositCallStatement
Function · @eco-incorp/sauce
One deposit’s full statement block (any "balance" binding line, the approve line if
applicable, then the protocol call) for spec - for splicing into a larger, hand-written
program. varSuffix disambiguates EVERY local this block binds - the depositAmtN balance read
and a template’s own selector const - when several deposits share one program (depositSource
passes the spec’s own index).
deposit.depositImportLines
Function · @eco-incorp/sauce
The import lines a depositSource(specs) program needs: each resolved template’s own
imports, plus IERC20 iff any spec needs an approval or an ERC20 balance read. De-duped by
exact line, in first-seen order, with IERC20 first.
deposit.depositSource
Function · @eco-incorp/sauce
A complete, compilable function main() { ... } program: one deposit statement block per spec,
in the given order, inside ONE function.
deposit.DepositSourceOptions
Interface · @eco-incorp/sauce
