Cap
Reports an account's Cap Finance position as two USDC-denominated legs — liquid cUSD (Supplied) and staked stcUSD (Staking).
Last updated
Reports an account's Cap Finance position as two USDC-denominated legs — liquid cUSD (Supplied) and staked stcUSD (Staking).
Reports an account's Cap Finance position as two structurally distinct legs, each valued in USDC: the base synthetic dollar cUSD (held directly) and the staked, yield-bearing savings token stcUSD. Splitting them lets a consumer tell held cUSD apart from staked stcUSD. The adapter wraps one fixed Cap deployment, so it is a plain adapter.
Type: Plain adapter
protocolSubId: keccak256("cap")
Source: CapBalanceAdapter.sol
Up to two positions per account — each leg is skipped when its balance is zero:
cUSD
Supplied
false
Directly-held cUSD, valued in USDC via the burn quote
stcUSD
Staking
false
Staked cUSD (stcUSD shares), redeemed to cUSD then valued in USDC
The NAV path (getAdapterPositions) values each leg independently:
getBurnAmount also returns a protocol fee, which is discarded — only amountOut is reported.
The no-arg balance getters (getAdapterBalances / getAdapterBalanceForAsset) still report the combined USDC total for the USDC asset (quoting the burn on cUSD + stcUSD→cUSD in one call). Only the NAV getAdapterPositions path splits the two legs; the split figures may differ from the combined one by at most burn-quote rounding.
positionId: abi.encode(address token) — cUSD for the supplied leg, stcUSD for the staking leg
positionKind: Supplied (cUSD) · Staking (stcUSD)
labels: ["Stablecoin", "cUSD"] · ["Savings", "stcUSD"]
shape enumeration: the adapter implements IPositionEnumerable, advertised via ERC-165. Both shapes are pinned at construction, so positionIds() returns the cUSD and stcUSD ids — byte-identical to the ones the legs emit — letting a configuration view list and label the pair with no account. This adapter is why the interface exists: it derives labels per positionId, so it answers the account-less positionLabels("") probe with an empty array and was otherwise indistinguishable from a broken adapter.
cUsd_
Cap cUSD token (ERC-20 + getBurnAmount quote interface)
stcUsd_
Cap stcUSD token (ERC-4626-like, redeems to cUSD)
usdc_
USDC address — the underlying asset reported, and the getBurnAmount target
navCalculator_
NAV Calculator contract
The three token addresses and navCalculator_ must each be deployed contracts; a zero address reverts with InvalidArguments.
Plain adapter — registered with addBalanceAdapters([adapter]) and removed with removeBalanceAdapters([adapter]) (MANAGER-gated). No instance set.
Last updated
cUSD leg: cUSD.balanceOf(account) > 0
→ amount = CUSD.getBurnAmount(USDC, cUSD balance).amountOut // Supplied
stcUSD leg: stcUSD.balanceOf(account) > 0
→ cUsdEquiv = stcUSD.convertToAssets(stcUSD balance) // ERC-4626 redeem to cUSD
→ amount = CUSD.getBurnAmount(USDC, cUsdEquiv).amountOut // Stakingconstructor(address cUsd_, address stcUsd_, address usdc_, address navCalculator_)