Configuration
Configuration options and settings for @tetherto/wdk-protocol-lending-aave-evm
import AaveProtocolEvm from '@tetherto/wdk-protocol-lending-aave-evm'
import { WalletAccountEvm } from '@tetherto/wdk-wallet-evm'
// Create wallet account first
const account = new WalletAccountEvm(seedPhrase, "0'/0/0", {
provider: 'https://ethereum-rpc.publicnode.com'
})
// Create lending service
const aave = new AaveProtocolEvm(account)
Account Configuration
The service uses the wallet account configuration to connect to the target network and sign transactions.
import { WalletAccountEvm, WalletAccountReadOnlyEvm } from '@tetherto/wdk-wallet-evm'
// Full access account
const account = new WalletAccountEvm(seedPhrase, "0'/0/0", {
provider: 'https://ethereum-rpc.publicnode.com'
})
// Read-only account (quotes, reads)
const readOnly = new WalletAccountReadOnlyEvm('0xYourAddress', {
provider: 'https://ethereum-rpc.publicnode.com'
})
const aave = new AaveProtocolEvm(account)
ERC‑4337 (Account Abstraction)
When using ERC‑4337 smart accounts, you can optionally specify a paymasterToken per operation to sponsor gas.
Network Support
Aave V3 spans multiple EVM chains (Ethereum, Arbitrum, Base, Optimism, Polygon, Avalanche, BNB, Celo, Gnosis, Linea, Scroll, Soneium, Sonic, ZkSync, Metis). Ensure the correct RPC and token addresses for the target chain.
Operation Options
Each operation accepts a simple options object:
Common Parameters
token (string): ERC‑20 token address
amount (bigint): token amount in base units
onBehalfOf (string, optional): another address to act for (supply/borrow/repay)
to (string, optional): destination address (withdraw)
Note: amount must be > 0. Addresses must be valid/non‑zero. A provider is required for any write.
Get started with WDK in a Node.js environment
WDK Lending Aave EVM Protocol API
Get started with WDK's Lending Aave EVM Protocol API
WDK Lending Aave EVM Protocol Usage
Get started with WDK's Lending Aave EVM Protocol usage
Connect with developers, ask questions, share your projects
Report bugs, request features, and get technical help
For sensitive or private matters, contact our team directly