AAVE_Protocols

Protecting Aave users with smart, automated defenses against liquidations.”

AAVE_Protocols

Created At

ETHGlobal New Delhi

Project Description

AAVE_last_dance is a protocol/app built on top of Aave (a decentralized lending protocol) that offers reactive liquidation protection or a “last line of defense” for borrowers. In other words: when a user’s position is close to being liquidated on Aave, this system intervenes (automatically, smartly) to prevent the liquidation from executing — giving borrowers more breathing room or avoiding forced closure. It’s like a safety net that watches borrowers’ collateral/debt health and takes action when things are dangerously close to thresholds.

How it's Made

I built AAVE_last_dance solo, handling everything from the smart contracts to the frontend. On the smart contract side, I used Solidity to implement a reactive contract (AaveLiquidationProtectionReactive) based on the AbstractReactive framework. This contract listens for Aave position events and automatically executes protective actions—like partial repayments or collateral adjustments—when a user’s health factor approaches the liquidation threshold. On the frontend, I built a Next.js + TypeScript dashboard that lets users connect their wallets, view their Aave positions, and configure liquidation protection strategies. I integrated Wagmi + Ethers.js for wallet connections and contract interactions to make the experience smooth and reliable. For development and deployment, I relied on Foundry to compile, test, and push the contracts quickly. On the monitoring side, I wrote scripts to track Aave borrower health in real time and trigger interventions through the contract when risks appeared. Since I built this project solo, I had to wear multiple hats—smart contract engineer, frontend developer, and system integrator. One particularly hacky part was reverse-engineering Aave’s event logs and mapping them into destinationBytecode for the reactive system, so my contract knew exactly when to step in. It was messy, but it made the protection mechanism work seamlessly. In the end, AAVE_last_dance brings together Solidity contracts, monitoring scripts, and a modern React/Next.js frontend into a single, automated “last line of defense” against Aave liquidations.

background image mobile

Join the mailing list

Get the latest news and updates