GET /api/v1/capacity) or trustlessly on-chain (RobinLens.getDepositCapacity).
Capacity is global (vault-wide), not per-market. A deposit is a batch
across markets, so always check the whole batch together — two batches
that each fit on their own can exceed capacity when combined.
The two tiers
A deposit pairs opposing YES/NO tokens, merges each pair to USDC, and supplies that USDC to the external yield (ERC-4626) vault. Capacity is enforced at two points along that pipeline.Tier 1 is a conservative guard against a large, unbalanced deposit that
could later need more USDC than the vault can hold. Tier 2 is the hard limit
— paired USDC must fit the external vault’s current
maxDeposit. For a
balanced (fully-matched) deposit, tier 2 is the binding constraint; a very
one-sided deposit can hit tier 1 first.Check via the API
GET /api/v1/capacity returns the global headroom and, when you pass a prospective batch, whether it fits and when it doesn’t, which tier blocks it, where each market’s tokens land, and which side to reduce. No wallet needed.
Reading the guidance
Whether a token fits depends on which side of the pool it lands on, so a single “remaining USDC” number can’t tell a user what to change. The response splits it:binding: "internal"— the batch raises the vault’s worst-case pairing exposure too much (paired USDC fills the cap, unmatched tokens reserve it). Markets withblocking: "unmatched"are the cause;overSidenames the side to reduce. Staking theirmatchingSideinstead avoids growing the surplus and consume external capacity instead.binding: "external"— the paired USDC doesn’t fit the yield vault right now. Markets withblocking: "matched"are the cause;overSidenames the side to reduce. Unmatched tokens don’t touch this tier at all.
overSide control on each blocking market.
Calls are per-IP rate-limited. Debounce user input instead of calling on every keystroke or slider tick.
Read it on-chain
RobinLens exposes the same two reads the API wraps, evaluated exactly as a real deposit would be — including skipping the internal tier when an admin has disabled it.
Next steps
Deposits
Build the deposit batch once capacity confirms it fits.
Reading on-chain state
The rest of the
RobinLens read surface.