The moving parts
A deposit flows through three on-chain pieces — the vault, the TWAP oracle, and Polymarket’s Conditional Tokens Framework — and external yield sources.RobinLens sits alongside as a read-only aggregator for the data you need to build and preview transactions.
Contracts
Contract addresses and governance
Full address table for Polygon mainnet, including the vault proxy, oracle,
lens, CTF, and USDC.e.
Deposit pipeline
When you deposit, the vault matches opposing sides within each market and converts the matched pair into yield-bearing USDC.1
Pair opposing sides
Within a single market, the vault pairs YES against NO. A YES and a NO token
of the same market together represent a full set worth
1 USDC of
collateral.2
Merge to USDC
The vault merges each matched pair on the Polymarket CTF, burning the paired
outcome tokens and releasing the underlying USDC.
3
Supply to Yield Strategy
The merged USDC is supplied to one or multiple ERC-4626 vaults, where it
earns organic yield for the life of the deposit.
Unmatched tokens stay idle. If you deposit more of one side than there is of
the opposite side to pair with, the surplus sits in the vault until a
counterpart arrives to pair with it. The yield that the vault earns is
socialized between all depositors (matched or unmatched) of a market.
Withdraw pipeline
A withdrawal reverses the pipeline: it burns your shares, reconstitutes the outcome tokens, and returns them alongside the organic yield those shares earned.1
Burn shares
The vault burns the ERC-1155 shares you specify for each market and side.
2
Withdraw USDC and split
If outcome tokens are needed, the vault withdraws USDC from the yield
startegy vault and splits that USDC back into YES and NO tokens on the
Polymarket CTF.
3
Return tokens and yield
You receive the underlying outcome tokens plus the organic USDC yield those
shares accrued.
Shares & accounting
Shares are ERC-1155 — one token per(market, side) pair. The vault tracks each side independently because YES and NO can be matched, valued, and withdrawn at different rates.
The vault uses dual-index accounting to value those shares:
lossIndex— tracks impermanent loss on a side, so shares redeem for the loss-adjusted amount of outcome tokens they are currently worth.yieldPerShare— tracks accrued organic yield per share, so each share claims its proportional cut of the on-chain yield.
INDEX_SCALE=1e18. Organic yield is split three ways before it reaches a wallet:
- Per market, by TVL — native yield is socialized across the market in proportion to staked value.
- Per side, by TWAP price — the market’s TWAP (
PRICE_SCALE=1e6) determines how that market’s yield divides between the YES and NO sides. - Per user, by indices — the
lossIndexandyieldPerSharesnapshots resolve each wallet’s individual share of its side.
RobinLens — batchGetUserYield, batchGetMarketIndexes, and batchGetUserPortfolio return them aligned to your conditionIds. See Reading on-chain state for the twapPricesYes convention used by those calls.
Organic yield vs. bonuses
The contracts pay only the organic yield, distributed through the
lossIndex + yieldPerShare accounting above. The 6% guarantee floor, the
+1% matching bonus, and the +1% points boost are an off-chain programme
operated by Robin. They are computed at withdrawal and paid in a single USDC
transaction from Robin’s operator wallet, separate from the on-chain
withdrawal — the vault itself never touches them. See
Conventions for the APY breakdown, and the Yield
Guarantee overview for the programme details.Next steps
Conventions
Units, ids, the Side enum, and the APY breakdown shape.
Deposits
Build PULL and PUSH deposits with correctly sorted, aligned arrays.
Reading on-chain state
Query shares, assets, yield, and previews through
RobinLens.