BellswapHook on Robinhood Chain

Uniswap v4 Hook Contract 0xe136bc1a37fa63cbd7051d0545572a69f815a080 on Robinhood Chain · Dynamic fee · Verified contract

Volume (24h)
$13.81K
Value locked (TVL)
$1.79K
All-time volume
$146.37K
Pools using this hook
2
Swaps (24h)
680 (8 traders)
Total swaps
8,546

What it does

A dynamic-fee hook that charges swappers more when a pool's price drifts away from an external reference feed price, and charges the maximum fee when that feed is stale or broken, with all fees going to liquidity providers.

How it works step by step

  • Creates pools only through createPool (caller-chosen curve) or createSyntheticPool (canonical curve against USDG for tokens exposing referenceFeed())
  • Reads Chainlink-style latestRoundData from a base feed and optional quote feed with gas capped at 100,000 and bounded return data
  • Computes gap between pool price and anchor price and charges baseFee plus slope times the excess gap beyond bandBps
  • In Directional mode charges the gap fee only when the swap moves the price away from the anchor, otherwise Symmetric charges both directions
  • Falls back to maxFee in both directions when feeds are stale, broken or the synthetic is not Live, failing closed
  • Takes the larger of the fee at the pre-swap price and at the first-swap-of-block price to prevent intra-block round-trip avoidance
Swap behaviour
On every swap beforeSwap reads the anchor from the reference feed(s), compares it to the pool price and returns a dynamic fee (baseFee plus gap fee, capped at maxFee) with the override flag and no token delta.
Liquidity behaviour
No liquidity callbacks.
Fee behaviour
Dynamic fee set in beforeSwap as baseFee plus a slope-scaled gap fee on the distance between pool price and a reference feed anchor beyond bandBps (gap fee only on away-from-anchor trades in Directional mode), capped at maxFee; fee is the larger of the fee at the pre-swap price and at the block-start price, and maxFee applies when feeds are Stale, Broken or the synthetic is Settled. Fees accrue to LPs through PoolManager; the hook takes no fee.
Owner & admin controls
No owner, no admin function, no proxy, no upgrade path, no pause; pools can only be created through the permissionless createPool and createSyntheticPool functions, and the fee curve of each pool is fixed at creation. The only privileged caller is the PoolManager.

Enabled Uniswap v4 callbacks

beforeInitialize, beforeSwap

beforeInitialize reverts unless the call comes from the hook's own createPool path (OnlyViaCreatePool), so external initialization is blocked. beforeSwap computes and returns the dynamic override fee with a zero return delta.

Security & trust assessment

Risk level: low (verified source, high confidence).

Who controls it: No privileged key exists: the contract has no owner or admin role, so no party can change fees, pause swaps or move funds after deployment. Pool creation is open to anyone and the feed or token contracts referenced by each pool are external trust dependencies, not controlled by the hook.

Risk to user funds: The hook never holds or transfers tokens and has no return-delta permission, so it cannot take or block user or pool funds; its only influence is the fee returned on swaps, which can reach maxFee (up to 10%) in non-Fresh regimes.

Security findings

  • [medium] Reliance on external feeds and settlement state: Pool anchors come from external AggregatorV3 feeds and token decimals/settlementState calls; a stale, broken or unreadable feed or a non-Live synthetic makes the hook charge maxFee in both directions rather than reverting, so trading continues at a high fee.
  • [low] Creator-chosen fee curve on generic pools: Fee is set by the pool creator's cfg (baseFee up to 10,000 pips, maxFee up to 100,000 pips, slope up to 1,000); a creator can deploy a pool with very high fees on a pool they seed, which only affects their own pool's traders.
  • [info] Immutable, no admin surface: Hook is immutable with no owner, proxy, delegatecall or selfdestruct, and holds no user funds; all fees flow to LPs through PoolManager.
  • [info] Bounded external reads: createSyntheticPool and createPool trust the caller-supplied token/feed addresses and rely on staticcalls capped at 100,000 gas with bounded return data.

Contract details

Verified source
Yes (BellswapHook)
Compiler
solc 0.8.26+commit.8a97fa7a
Bytecode size
14,199 bytes
Upgradeable proxy
No
Detected patterns
dynamic-fee

Pools using BellswapHook