Skip to content

SDK, router and quoter

Read about the two trusted integrations an interface calls into, what each one needs from it, and the approvals behind them.

On this page

The npm package

hookr-sdk 1.6.1 is the TypeScript package for building on Hookr from any app, launcher or agent. It runs on viem, holds no wallet and signs nothing.

npm install hookr-sdk viem
What it gives youExports
The addresses, deployment and chain for viemHOOKR_1, RELEASES, CHAIN_ID, ROBINHOOD_CHAIN, releaseAddress
The release manifest every builder takes, read from the chainreadReleaseManifest, releaseManifest
A token launch with Hook Blocks, or pools for an existing token, each with arb recapture unless its member names RECAPTURE_OFFbuildLaunch, buildLaunchAdvised, buildLaunchFamily, RECAPTURE_OFF
Quotes through HookrQuoter and swaps through HookrRouterbuildQuote, buildSwap, poolId
The approvals a swap or a launch needsswapAllowance, launchFunding, buildApprovals
The gas floor a swap on a pool with arb recapture needslaneGasFloor
King of the Pool: a pool's roundreadKingOfThePool
Hookr on Monad: the release, the chain for viem, the contracts' clock and the gas a send carriesHOOKR_1_MONAD, MONAD_CHAIN, releaseOn, readContractClock, sendGasLimit
Hookr on Arbitrum: the release, the chain for viem and the core a new pool bindsHOOKR_1_ARBITRUM, ARBITRUM_CHAIN, rulesModule
Limit orders on Robinhood Chain: place, cancel and fill an order, and claim its tipbuildCreateOrder, buildCancelOrder, buildFillOrder, buildClaimBounty, readLimitOrder
Revenue tokens on Robinhood Chain: a token's reads and its holders' claim and sync callsreadRevenueToken, buildRevenueClaimAll, buildRevenueSync

Each builder returns the chain id, the contract, the call data and the value; your wallet sends it.

This page covers what hookr-sdk wraps.

Router and quoter

A Hookr pool is an ordinary Uniswap v4 pool on HookrRoot, so it trades through the Universal Router or through Hookr's own router, HookrRouter. HookrQuoter quotes it either way. Their addresses, and every other address, render below from the release book the app ships; none is typed into this page.

Hookr’s core and own-hook contracts

HookrRoot is the hook every Hookr pool names, and each pool records the Rules it opens with. The core, HookrRules, carries every Hook Block in one Rules contract, with six parts pinned by code hash and a key for each block HookrRoot admits.

HookrOwnedRootFactoryV2 deploys a hook of your own with its own lane, and the two swap modules are admitted under the combined core, HookrRules 0x8AD0…e52e. Each is verified on chain; the table below lists these contracts.

ContractAddress
HookrRoot, the hook every Hookr pool names0x89c9FB50d1f03192230FFB1c279BB6E7d3Fe6aCc
HookrRules, the core0x342bAA22e202954593b04B7eD1663621E0565d46
HookrViewSwap, part of the core0x844faE4347517180bf4656b67E4BFc27D194693F
HookrClaims, part of the core0x8D0583b408e2959FA0450c54F749C1A4Dad3d335
HookrRecapture, part of the core0x97D440593912234b78432A030fb5186BD2A3Bc86
HookrLimitBlocks, part of the core0xc42E47679dd06DDcC07acc72ca710f6E60ACC3A9
HookrCoreBlocks, part of the core0xdA360B744F8C816acbb97fF65cC4Cd81e27Df375
HookrBinder, part of the core0x0B0f08c381ed6902FAb74b470fe7f8A58E8EA269
HookrCoreSettle, the library HookrCoreBlocks links0x7E169f0c49Db67F1a4f6f3c48A69B2e244b85191
HookrLauncher, for new tokens0x70a66ADF39B5c9FfEE4A9F081C182edfbb7DBD0C
HookrFamilyRouter, for new tokens0xbc56F48f873841d26a5a02575263d82f68e12864
HookrFamilyLock, for new tokens0x5248AF9139DaDEf0C5296342b7BE441deDf0adC2
HookrTokenDeployer, for new tokens0xE703F2Cd21A8dEE05dbC81b693201D602772B2d8
HookrVestingMilestoneFactory, for new tokens0xCBe4Fa6Ca5f14Ed30435524dc9629DC1719DbCB0
PayLaterFactory, for new tokens0xFc3e9e435C79e1712CF949C6ea921fA165cadEf3
Swap Cut key0x9394881A6Fe570adEC4480471B4D52652d263878
Exit Clock key0x2b6aB976d05Dcc7Cad53bF9324Fe892511036348
Holder Pot key0x740b2Da80eBB44613C2b44f380D55ECBECbFf11f
Storm Fee key0xD577087cbf9bEC0Ca0392efD8A83C3fE6A09Bd1f
Wallet Cap key0xfe5c29D2d6B7aC383A63291a771197e4D83E1d9c
Buy/Sell Block's pause and lock key0xa64be3B5eC9B7310CBd3F77736ca5D6Fa81C5BCb
Sandwich Guard key0xa214e747d1a8E767F88ed2170be62E22ED79a269
King of the Pool key0xD691021b7cbee6bFB1ACF73A3E1126603D1B26F9
HookrRules, combined: the core a hook of your own copies0x8AD0aC66DbeBcc047e8d216666C925E797e5e52e
HookrRecapture, the combined core's arb recapture split0x1172a3cC44ce8E8E3F1f0e58a9A0E9678b7118f8
HookrOwnedRootFactoryV2, deploys a hook of your own with its own lane0x4888f030F9D789Bf71F45B275dA7A7812036dE7e
HookrLane, the lane of a hook HookrOwnedRootFactoryV2 deploys0xa83007AB66cF977132c58F5a138E1e92A005Fff3
HookrRamsesV3Fill, swap module admitted under the combined core0x446e409484dE756662f2C238c9bDECB9f50f5B8F
HookrPonsCurveFill, swap module admitted under the combined core0xEa0A512dFA4D8CcaFA31E485bd189703D8BaAa27
HookrLpBoost, LP Time-Lock Boost for gauges opened on it0xa301A960716a070394826092e6fF113A156A80D1
HookrCodeStoreRoot, code HookrOwnedRootFactoryV2 deploys from0xB41EB84679855602522ecd0093ff6343EB3ceEc4
HookrCodeStoreCore0, code HookrOwnedRootFactoryV2 deploys from0xd71167314A50589C7C8CD9Cc9C81939f5DDDb190
HookrCodeStoreCore1, code HookrOwnedRootFactoryV2 deploys from0xe4731fFC8a0A0C10213C872F5c17b3f895A82a83

Hookr’s contracts

The table lists Hookr’s 34 core contracts, rendered from the release book the app ships, source commit 412960b37a631ce145d49fb4a1887f04a4d1fa74: HookrRoot, the hook every Hookr pool names, first, then the contracts a swap passes through, then the rest in the order they were deployed.

Each one’s source is verified on RobinScan, on Sourcify as an exact match and on Blockscout as a full match. The arb recapture table below repeats HookrLane and adds What The Hook’s executor. None of the contracts they add is in the release book.

ContractAddress
HookrRoot0x89c9FB50d1f03192230FFB1c279BB6E7d3Fe6aCc
HookrRules, the release's0x4a71c270b1520F94064268102AebD744b0DE7942
HookrLane0x9A8a1006469BA196f8FEfc017a53505C83A060BB
HookrRecapture0xF83569E564d70daebc35950f66a73f2e2B915583
HookrRouter0xC2Bc9a3fe6c4Ce8C2F7EB4655b0869b01D8c93C9
HookrQuoter0x445D7891381Aa7F91F5048EdBC6a611ccBDe7865
HookrLauncher0x1cf2748A6670572425eAbf9Ab9e5BC4eb2eB8Ef4
HookrRegistry0x463c82beA1a52F4Cc05ca0741a24F0AD24bA4602
HookrTreasury0x2242F7FC75606500503075f29ea8cDA684EfB4a9
HookrForwarder0xe7863CC0E2Fb783b44c279aB159bcD812c2ceA1c
HookrRegistryChecks0xB9F5c54E5Cc7ac6c7a96335E5A334Cf4eA496E98
HookrRegistryAdmin0x675ac2102E8c69E2467F64656E3c235AF3901Ac1
HookrLaunchChecks0x8567369a70100828611BB6F44ec051B48F10fb59
HookrTokenDeployer0x1B23D6d7beBcB61E39317E9F0Bc02AEB91aFCcAe
HookrReferralRegistry0xefD1DfBA80c06E72F793601706c3a1c71aab3057
HookrProgramsAdmin0x40B40D65543E70a9C757eda1A2208517a8BC7292
HookrPrograms0x9fA204AC99176782Fd20615b2b2A516D1F8C328F
HookrMilestoneNFTFactory0xa340F964F1E685c681dC3ABB5B0405E608914d00
HookrProgramValidator0x33e0249083Be7Cd8bD2fe175E0671AcfD0516850
HookrReferralDistributor0x690539c53212899A9c6AEEE3b4B6737A5c4851d9
HookrFamilyRouter0x854f3Fa7AC342B244DF0d9A8c8F597b051aAE559
HookrFamilyLock0xfAFEcE64099C1E791C4B46189c277f00c0c7e00b
HookrCompliance0x9D205e8a68464761A9d84bdeCcEa0C3CB1e7B1EC
HookrComplianceGuard0x6CD70db1ac99344416a6fD7184e23FA8f09f313A
HookrAccountCalls0x0579a95A7760070E2d6D34e5beCe571e5F1c4818
HookrPaymasterAdmin0x1d81F4B131832f741392edf7B91b4CF099FbB008
HookrPaymaster0x1c4682915092E742231ea038C4fcA61e96a83c99
HookrRootFactory0x21E438FaBE10770afb4407cF6b09d32369CBdCE4
HookrSessionAdvisory0x78Bc6b7302Dda8632e661c8d74966bdBea1c66b1
HookrFeeAdvisory0x3B6b3f00684987B831fcF9EB5f0d5B806afF7306
HookrLiquidityVault0xA408923EF811945Ef119Bc700B1950Dab65467Fc
HookrOwnedProfiles0xb46c318B6AEA2d6274f5566da414b09fDa6CC325
HookrOwnedRootsLens0x6Bb5c9d21dD095F788cb8373d0143429ad277366
HookrOwnedRootFactory0xA6c2a401597301dFf57A59bC8F70a9622499f3ec

Arb recapture

The registry opened the lane on HookrRoot on 2026-10-07. The executor is What The Hook’s contract, not Hookr’s.

ContractAddress
HookrLane, the arb recapture lane on HookrRoot0x9A8a1006469BA196f8FEfc017a53505C83A060BB
What The Hook's arb recapture executor, 25% of each arb recapture's profit0x4B4c16681401454140a9dBca55e5c186BBE8D728

hookr-sdk carries the ABIs with the addresses.

Approvals

The two paths do not share an approval model, and mixing them up is the most common integration failure.

PathNative inputERC-20 input
HookrRoutermsg.value equal to the inputa plain ERC-20 approve to the router, which swapAllowance returns
Universal Routermsg.value equal to the inputapprove the token to Permit2, then approve the Universal Router as a Permit2 spender with an amount and an expiry
PositionManager mintmsg.value up to amount0Maxapprove the token to Permit2, then approve PositionManager as a Permit2 spender

A plain ERC-20 approval to the Universal Router or to PositionManager is not read, and the swap or mint fails to settle. A direct HookrRouter swap is the opposite: it pulls with transferFrom and does not read Permit2. Only a gasless swap, which the payer signs and a relayer sends, pulls through Permit2 (permit2Allowance).

Quoting

Swapping and quoting covers both: the V4Quoter-shaped functions for the Universal Router, and quote for HookrRouter, which buildQuote builds.

On a pool with arb recapture on, a swap must also carry the lane's gas floor plus its own gas: laneGasFloor in the SDK, or gasFloor from laneOf(id) on the root. eth_estimateGas includes the floor. Send the estimate plus a sixth.

Reading a Pool

A pool's Hook Blocks are frozen at launch, so one read at any block is correct for the life of the pool. Read the release first with readReleaseManifest(client, HOOKR_1), which refuses any contract whose code is not the code the release deployed, then read the pool against it.

Do not reconstruct a configuration from events.

Before You Ship

  • Check that the pool's hooks is HookrRoot. buildSwap and buildQuote refuse any other.
  • Give every swap an amount bound, a price bound and a deadline within the next hour; the builders refuse a swap without them.
  • Quote the path you route: the V4Quoter-shaped functions for the Universal Router, quote for HookrRouter.
  • Check the wallet's chain, the payer, the token approvals and the slippage yourself.
  • Put the lane's gas floor on a swap against a pool with arb recapture on.