Skip to main content
Manage positions outside the order book by splitting collateral into complete sets of outcome tokens, merging balanced tokens back into collateral, or redeeming winning tokens after resolution. Choose an operation based on how you want to change your position: Choose the integration surface you will use to submit position operations.
The examples on this page assume you have a SecureClient configured with either a Relayer API key or a Builder API key.
See Wallets and Authentication for the complete wallet setup and Relayer authorization flow.

Split a Position

Splitting converts pUSD into a complete set of outcome tokens. Every 1 pUSD produces 1 YES token and 1 NO token.
Before splitting, ensure you have:
  1. Enough pUSD in the wallet for the amount you want to split.
  2. Approved the collateral adapter for the market type to spend the wallet’s pUSD.
Call splitPosition() on a SecureClient. The client identifies the market type from the condition ID and selects the correct collateral adapter.
amount is denominated in pUSD base units, so 1_000_000n splits 1 pUSD into 1 YES token and 1 NO token. wait() returns a TransactionOutcome after the transaction settles.

Merge Positions

Merging converts a complete set of outcome tokens back into pUSD. Every 1 YES token and 1 NO token returns 1 pUSD.
Before merging, ensure you have:
  1. Equal amounts of YES and NO tokens.
  2. Approved the collateral adapter for the market type to transfer the wallet’s outcome tokens.
Call mergePositions() on a SecureClient. The client identifies the market type, selects the correct collateral adapter, and checks the wallet’s mergeable balance.
Pass a base-unit bigint to merge a specific amount. "max" merges the smaller of the wallet’s YES and NO balances. wait() returns a TransactionOutcome after the transaction settles.

Redeem Resolved Positions

Redeeming converts outcome tokens into pUSD after a market resolves. Each winning token returns 1 pUSD, while losing tokens return 0.
There is no redemption deadline. Winning tokens remain redeemable at any time after resolution.
Before redeeming, ensure you have:
  1. A resolved market.
  2. Outcome tokens for the market.
  3. Approved the collateral adapter for the market type to transfer the wallet’s outcome tokens.
Call redeemPositions() on a SecureClient. The client uses the condition ID to select the correct collateral adapter for the market type.
Redemption has no amount parameter: it redeems the wallet’s balances for both outcomes. wait() returns a TransactionOutcome after the transaction settles.