@moltbankhq/aave-earn-mod
v0.1.0
Published
Aave Earn Capability. Provides cap.moltbank.aave-earn — Moltbank-orchestrated USDC deposit and withdraw flows on Aave V3 (Base / Arbitrum). Deposit routes through account_execute (session-key path) or account_propose (Safe proposal path). Withdraw always
Readme
Aave Earn Mod
Aave V3 Earn (USDC supply/withdraw) Capability for Moltbank. Runs Safe-native — the user's Moltbank Safe is the position holder throughout; no EOA deposit wallets, no bridges, no swaps, no LI.FI.
See SKILL.md for the full capability surface and CLI reference.
Auth model
This mod never holds wallet keys. All Safe execution flows through
the trusted host (architecture spec §10.1: only the trusted core
signs). The mod builds Aave protocol calldata (approve, supply,
withdraw) and either:
- composes it into deposit/withdraw flows via existing APP MCP tools (Phase 3 bridge), or
- emits it as
build-deposit/build-withdrawcalldata for the caller to submit through their own Safe path.
The mod has no Safe SDK import, no Safe7579 session knowledge, and no direct Pimlico bundler use.
Capabilities
cap.moltbank.earn— Moltbank-orchestrated deposit / withdraw / propose, plus the read endpoints (balance / rates / history / resolve-addresses / build-deposit / build-withdraw / policy-spec).
The full command surface and behavioral expectations are in SKILL.md.
Configuration
Optional config at ~/.moltbank/mods/aave-earn/config.json:
{
"environment": "development",
"baseRpcUrl": "https://mainnet.base.org"
}Both fields are optional. When neither field is set and the
MOLTBANK_APP_ENVIRONMENT env var is unset, the mod defaults to
development (Base Sepolia) — never silently to mainnet.
Field reference: schemas/config.schema.json.
Chain selection
The user-facing chain is always --chain base. Internally:
| Environment | Network |
|---------------------------|----------------------|
| production / sandbox | Aave V3 Base mainnet |
| development / unset | Aave V3 Base Sepolia |
Resolution priority: MOLTBANK_APP_ENVIRONMENT env >
config.environment > 'development' default. This mirrors the APP
chain-selection rule documented at APP/TEST_MODE.md:51-57.
Addresses
All Aave V3 addresses (Pool Addresses Provider, USDC underlying,
aUSDC) come from @bgd-labs/aave-address-book.
The active Pool is resolved at runtime via
IPoolAddressesProvider.getPool(); the active data provider via
getPoolDataProvider(). No Aave addresses are hand-maintained in this
package.
Spec alignment
- §10.1 (only the trusted core signs): the mod composes calldata but never signs. Safe execution stays in the host.
- Mod-only feature, no APP UI: APP follows the Polymarket /
Pump.fun precedent. There is no
/earnroute, no/form-earnroute, no Earn React surface in APP. CLI and agent MCP only. - Safe-native: the Safe is the deposit / withdraw target on Aave. No EOA deposit wallets, no bridge step.
Migration plan
See Escritorio/aave-earn-mod-extraction-plan.md (local) for the
phased extraction plan that produced this package.
