All trading on Strike uses USDT as collateral. Before placing orders, your wallet must approve the Vault to spend USDT.
Approve USDT
// Idempotent — skips if allowance is already sufficientclient.vault().approve_usdt().await?;
This calls USDT.approve(vault, type(uint256).max). It checks the current allowance first and skips the transaction if approval is already set. Safe to call every time your bot starts.
Strike uses ERC-1155 outcome tokens — each market has a YES token ID and a NO token ID. Tokens are minted when batches clear and can be redeemed after market resolution.
Token IDs
Token Balances
Token Approval for Selling
To place SellYes or SellNoorders, the OrderBook must be approved to transfer your outcome tokens:
Redemption
After a market is resolved via Pyth oracle, winning outcome tokens can be redeemed 1:1 for USDT. Losing tokens are worthless.
Check Balances
Redeem
This calls Redemption.redeem(factoryMarketId, amount) on-chain.
Collateral Model Summary
In Strike, 1 YES + 1 NO = 1 USDT (fully collateralized). Both sides of the orderbook lock USDT — askers do NOT need to hold outcome tokens to sell. See Batch Auctions for details on how collateral flows during clearing.
let yes_id = client.tokens().yes_token_id(market_id).await?;
let no_id = client.tokens().no_token_id(market_id).await?;
let signer = client.signer_address().unwrap();
let yes_balance = client.tokens().balance_of(signer, yes_id).await?;
let no_balance = client.tokens().balance_of(signer, no_id).await?;
let order_book = client.config().addresses.order_book;
// Check if already approved
let approved = client.tokens().is_approved_for_all(signer, order_book).await?;
if !approved {
client.tokens().set_approval_for_all(order_book, true).await?;
}
let signer = client.signer_address().unwrap();
// Returns (yes_balance, no_balance)
let (yes, no) = client.redeem().balances(market_id, signer).await?;
println!("YES: {yes}, NO: {no}");
// Redeem winning tokens for USDT
client.redeem().redeem(market_id, amount).await?;