Skip to content

KillariDev/reverse-trades-hook

Repository files navigation

Rollback Hook

Rollback Hook

Rollback Hook is an Uniswap V4 hook hook built for prediction markets, giving liquidity providers a way to manage risk during rapid price movements. It introduces a mechanism where queued trades can be reversed for up to one hour before becoming permanent. This provides protection when markets experience sudden volatility, such as moments when an outcome becomes clear even though the market is still officially active. The contract is deployed on Sepolia

The pool deployer can choose when to trigger a rollback. Once this happens, the pool is no longer usable, and liquidity providers can withdraw their positions. The deployer holds only this single privilege: the ability to revert up to one hour of recent trades, without any additional control over the market.

Usage

Compile Contracts

npm run contracts

Run Tests

npm run test

Deploy to Sepolia

npm run deploy

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published