Balancer V3 Gauges
Reports an account's gauge-staked Balancer V3 LP plus claimable rewards across any gauge.
Reports an account's gauge-staked Balancer V3 LP plus claimable rewards across any gauge. The staked LP is decomposed pro-rata into the pool's underlying tokens (valued via the gauge's lp_token pool), and BAL plus the gauge's extra reward tokens are reported as accrued rewards. Wallet-held (unstaked) LP is the separate Balancer V3 Pools adapter.
Type: Meta-adapter
protocolSubId:
keccak256("balancer-v3-gauges")Instance key: the gauge address, widened to bytes32.
Positions returned
Staking
Staking
false
Pro-rata share of one underlying pool token, from the account's gauge-staked LP
Rewards (BAL)
Rewards
false
Claimable BAL, minted via the Balancer Minter
Rewards (extra)
Rewards
false
Claimable amount of each extra gauge reward token
Tokens not registered in NAVCalculator are skipped, as are zero amounts and asset-filtered tokens.
Balance calculation
Staking legs use staked = gauge.balanceOf(account) and the same BalancerV3PoolLib.poolBalanceOfIndexed decomposition as the Pools adapter (live-scaled-18 share → raw units, ERC4626 unwrap via previewRedeem), applied to the gauge lp_token pool. As in the Pools adapter, the tokens are iterated in index order and each leg is keyed on the pool-token index, so a pool holding the same underlying at two indices is decomposed correctly; a transiently-zero scaling factor or token rate yields a 0 leg.
BAL rewards (claimableBal) emulate the gauge inflation checkpoint off-chain:
integrateFraction is recomputed by walking weekly boundaries (WEEK = 7 * 86400) from the last period to block.timestamp, accumulating integrate_inv_supply from the inflation rate, capped relative weight, and working_supply. It tries the mainnet model (calculateIntegrateFraction, up to 500 weeks, with a future-epoch rate switch via the token admin) and falls back to the L2 model (calculateIntegrateFractionL2, up to 256 weeks, per-week inflation_rate(week)). A killed gauge zeroes the rate. Any revert yields 0.
Extra rewards come from gauge.claimable_reward(account, token) for each reward_tokens(i) (BAL excluded here, since it is handled via the minter).
Identity
positionId:
abi.encode(address gauge)positionKind:
Staking·Rewards
There is no labels field on the position. The adapter implements positionLabels(positionId), which returns ["Staking Gauge", "<sym0>/<sym1>/…"] from the staked pool's underlying token symbols — surfaced only by the verbose reads (getAccountPositionsVerbose / getAccountNavVerbose); the full breadcrumb is [protocolName, ...labels].
Constructor
balancerMinter_
Balancer Minter contract (must be a contract); resolves the BAL token, token admin, and minted amounts
navCalculator_
NAVCalculator address (must be a contract); source of the asset registry and the instance set
Registration
Registered as a meta-adapter via addMetaBalanceAdapter(adapter), then per-gauge instances are added with addMetaInstances. Each instance coordinate is the gauge address widened to bytes32.
Last updated