BTB Finance for agents

Protocols / Lending

SparkLend

Stablecoin-focused lending market forked from Aave V3. Supply assets to earn interest, borrow against collateral, and repay or withdraw. Rates are set by governance rather than by utilization.

On-chainEVM3 contractsWebsite · Docs

get_protocol({ "protocol": "sparklend" })

Risks an agent should know

What an agent can do

supplyDeposit an asset to earn interest
approve the Pool for the amount, then Pool.supply(asset, amount, onBehalfOf, 0); spTokens are minted to onBehalfOf
withdrawWithdraw a supplied asset
Pool.withdraw(asset, amount, to); pass type(uint256).max to withdraw the full balance
borrowBorrow against collateral
check getUserAccountData(user).healthFactor first, then Pool.borrow(asset, amount, 2, 0, onBehalfOf); stable mode (1) is not available
repayRepay a variable debt
approve the Pool for the amount, then Pool.repay(asset, amount, 2, onBehalfOf)
toggle-collateralEnable or disable a supplied asset as collateral
Pool.setUserUseReserveAsCollateral(asset, true or false)
check-positionRead collateral, debt and health factor
Pool.getUserAccountData(user); healthFactor below 1e18 means liquidatable

Contracts

ethereum · chain id 1

ContractAddressKey functionsTry
Pool (main market)
pool · proxy
0xC13e21B648A5Ee794902342038FF3aDAB66BE987
source
writesupply(address,uint256,address,uint16)
writewithdraw(address,uint256,address)
writeborrow(address,uint256,uint256,uint16,address)
writerepay(address,uint256,uint256,address)
writesetUserUseReserveAsCollateral(address,bool)
readgetUserAccountData(address)
readgetReserveData(address)
writeflashLoanSimple(address,address,uint256,bytes,uint16)
Full ABI
PoolAddressesProvider (main market)
other
0x02C3eA4e34C0cBd694D2adFa2c690EECbC1793eE
source
readgetPool()
readgetPoolConfigurator()
readgetPriceOracle()
readgetACLManager()
readgetPoolDataProvider()
Full ABI

gnosis · chain id 100

ContractAddressKey functionsTry
Pool (Gnosis market)
pool · proxy
0x2Dae5307c5E3FD1CF5A72Cb6F698f915860607e0
source
writesupply(address,uint256,address,uint16)
writewithdraw(address,uint256,address)
writeborrow(address,uint256,uint256,uint16,address)
writerepay(address,uint256,uint256,address)
readgetUserAccountData(address)
readgetReserveData(address)
Full ABI

Notes

Ethereum addresses for the main market and Gnosis addresses come from Spark's official address registry (SparkLend.sol and Gnosis.sol). Reserve token addresses (spTokens and debt tokens) are in the same file. WETHGateway (ETH deposits) and UiPoolDataProvider are not included because their signatures were not checked against source. Pool functions follow the Aave V3 interface, which Spark documents as its base. Other chains listed on DefiLlama are not covered here.

Sources

Researched 2026-11-28. Addresses are copied from the official sources above; check them before moving large amounts.